Metadata-Version: 2.4
Name: artificer-agents
Version: 0.1.0a2
Summary: A library for creating agents
Author: Scott
License-Expression: MIT
License-File: LICENSE
Classifier: Development Status :: 3 - Alpha
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.13
Requires-Python: >=3.13
Requires-Dist: artificer-cli>=0.1.0a1
Requires-Dist: fastmcp>=2.0
Requires-Dist: pydantic>=2.0
Requires-Dist: python-dotenv>=1.2.1
Provides-Extra: openai
Requires-Dist: openai>=1.0; extra == 'openai'
Description-Content-Type: text/markdown

# artificer-agents

A lightweight Python library for running deterministic agent loops with MCP tools.

## Installation

```bash
pip install artificer-agents

# With OpenAI support
pip install artificer-agents[openai]
```

Requires Python 3.13+.

## Usage

```python
import asyncio
from pydantic import BaseModel
from artificer.agents import Agent, run_agent
from artificer.mcp import MCPClient
from artificer.models import OpenAIModel

class Input(BaseModel):
    query: str

class Output(BaseModel):
    result: str

agent = Agent(
    name="my-agent",
    system_prompt="You are a helpful assistant.",
    input_schema=Input,
    output_schema=Output,
)

async def main():
    model = OpenAIModel(model="gpt-4o-mini")
    async with MCPClient(["path/to/mcp-server.py"]) as mcp:
        result = await run_agent(agent, Input(query="Hello"), model=model, mcp_client=mcp)
        print(result.output)

asyncio.run(main())
```

## Development

```bash
uv sync                    # Install dependencies
./scripts/check.sh         # Run all checks (lint, format, typecheck, tests)
./scripts/test.sh          # Run tests only
./scripts/format.sh        # Format code
```

## License

MIT
