Metadata-Version: 2.4
Name: aipype
Version: 0.2.0a1
Summary: A modular AI agent framework with declarative pipeline-based task orchestration
Project-URL: Homepage, https://github.com/mobisoftinfotech/aipype
Project-URL: Repository, https://github.com/mobisoftinfotech/aipype
Project-URL: Issues, https://github.com/mobisoftinfotech/aipype/issues
Author-email: Pritam Barhate <pritambarhate@mobisoftinfotech.com>
Keywords: agents,ai,automation,framework,llm,pipeline
Classifier: Development Status :: 3 - Alpha
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.12
Classifier: Topic :: Scientific/Engineering :: Artificial Intelligence
Classifier: Topic :: Software Development :: Libraries :: Python Modules
Requires-Python: >=3.12
Requires-Dist: beautifulsoup4>=4.12.0
Requires-Dist: chardet>=5.0.0
Requires-Dist: litellm>=1.77.1
Requires-Dist: moviepy>=1.0.3
Requires-Dist: openai>=1.0.0
Requires-Dist: pydantic>=2.0
Requires-Dist: pypdf>=4.0.0
Requires-Dist: python-docx>=1.1.0
Requires-Dist: python-dotenv>=1.0.1
Requires-Dist: readability-lxml>=0.8.1
Requires-Dist: requests>=2.31.0
Requires-Dist: types-requests>=2.31.0
Description-Content-Type: text/markdown

# aipype

Core AI agent framework with declarative pipeline orchestration.

## Installation

```bash
pip install aipype
```

## Quick Start

Use the `@task` decorator for clean, Pythonic agent definitions:

```python
from aipype import PipelineAgent, task, llm, search

class ResearchAgent(PipelineAgent):

    @task
    def find_sources(self) -> dict:
        """Search for articles - no dependencies, runs first."""
        return search(self.config["topic"], max_results=5)

    @task
    def summarize(self, find_sources: dict) -> str:
        """Summarize sources - dependency auto-inferred from parameter."""
        return llm(
            prompt=f"Summarize: {find_sources}",
            model="gpt-4o",
            temperature=0.3
        )

agent = ResearchAgent("research", {"topic": "AI trends"})
agent.run()
agent.display_results()
```

**Key Concepts:**
- `@task` decorator marks methods as pipeline tasks
- Parameter names matching task names create automatic dependencies
- `self.config` provides access to agent configuration
- Helper functions: `llm()`, `search()`, `mcp_server()`, `transform()`

## Environment Variables

```bash
# LLM Providers
export OPENAI_API_KEY=sk-your-key-here
export GEMINI_API_KEY=your-key-here
export OLLAMA_API_BASE=http://localhost:11434

# Search
export SERPER_API_KEY=your-serper-key-here
```

## Development

### Requirements
- Python ≥3.12

