Metadata-Version: 2.4
Name: pyagent-patterns
Version: 0.1.0
Summary: 18 reusable multi-agent orchestration patterns for LLMs
License: MIT
Keywords: LLM,agents,multi-agent,orchestration,patterns
Classifier: Development Status :: 3 - Alpha
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Topic :: Scientific/Engineering :: Artificial Intelligence
Classifier: Typing :: Typed
Requires-Python: >=3.11
Provides-Extra: dev
Requires-Dist: mypy>=1.10; extra == 'dev'
Requires-Dist: pytest-asyncio>=0.23; extra == 'dev'
Requires-Dist: pytest>=8.0; extra == 'dev'
Requires-Dist: ruff>=0.5; extra == 'dev'
Description-Content-Type: text/markdown

# pyagent-patterns

**18 reusable multi-agent orchestration patterns for LLMs** — zero dependencies, async-first, fully typed.

## Install

```bash
pip install pyagent-patterns
```

## Patterns

| Tier | Patterns |
|------|----------|
| Orchestration | Supervisor, Pipeline, Fan-Out/Fan-In, Hierarchical, Orchestrator-Workers |
| Resolution | Self-Reflection, Cross-Reflection, Debate, Voting, Evaluator-Optimizer |
| Structural | Role-Based, Layered, Topology, Blackboard |
| Advanced | Talker-Reasoner, Swarm, Human-in-the-Loop, ReAct |

Plus: CompositePattern (escalation chains), PatternAdvisor, GuardrailChain, BoundedExecution, CircuitBreaker.

## Quick Example

```python
import asyncio
from pyagent_patterns.base import Agent, MockLLM
from pyagent_patterns.resolution import SelfReflection

llm = MockLLM(responses=["Draft code", "Needs error handling", "Improved code", "APPROVED"])
pattern = SelfReflection(agent=Agent("coder", llm), max_rounds=3)
result = asyncio.run(pattern.run("Write a sorting function"))
print(result.output)
```

## Documentation

Full docs: [pyagent.dev](https://pyagent.dev)
