A service that manages and executes agno agents with OPAL SDK integration
Project description
Niteco Agno Agent Tool Service
A service that manages and executes agno agents with OPAL SDK integration.
Features
- Agent Registry: Register and manage multiple agno agents
- Tool Integration: Seamless integration with OPAL Tools SDK
- FastAPI Backend: RESTful API for agent interactions
- Async Support: Full async/await support for agent operations
- Health Monitoring: Built-in health checks and metrics
Installation
pip install niteco.agno-agent-tool
Quick Start
from fastapi import FastAPI
from agno.agent import Agent
from niteco.agno_agent_tool import create_agno_agent_service
# Create FastAPI app
app = FastAPI()
# Create the service
service = create_agno_agent_service(app)
# Register an agent
agent = Agent(agent_id="my_agent", name="My Agent")
service.register_agent(agent, "I help with general tasks")
# Start the service
@app.on_event("startup")
async def startup():
await service.startup()
@app.on_event("shutdown")
async def shutdown():
await service.shutdown()
API Usage
Once your service is running, you can interact with registered agents:
# Run an agent
curl -X POST "http://localhost:8000/agents/my_agent/run" \
-H "Content-Type: application/json" \
-d '{"message": "Hello, agent!"}'
Core Components
AgnoAgentToolService
The main service class that extends OPAL's ToolsService:
- Manages agent registry
- Provides FastAPI endpoints
- Handles agent execution
- Monitors service health
AgentToolRegistry
Registry for managing agent instances:
- Register/unregister agents
- Track running tasks
- Manage agent metadata
AgentRunRequest
Pydantic model for agent execution requests:
class AgentRunRequest(BaseModel):
message: str
Requirements
- Python >= 3.8
- fastapi >= 0.95.0
- agno >= 1.7.0
- optimizely-opal.opal-tools-sdk >= 0.1.0
- pydantic >= 2.0.0
- uvicorn >= 0.20.0
Development
Install with development dependencies:
pip install niteco.agno-agent-tool[dev]
License
MIT License
Contributing
Contributions are welcome! Please feel free to submit a Pull Request.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file niteco_agno_agent_tool-0.1.0.tar.gz.
File metadata
- Download URL: niteco_agno_agent_tool-0.1.0.tar.gz
- Upload date:
- Size: 5.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
9d2d55633d7ac139845dec94525d263af13ac314a57cad32d46e8ae9505f2419
|
|
| MD5 |
12a247dbec09892b5439d2f809c40893
|
|
| BLAKE2b-256 |
7c54b8c859fe03de1d5e59abbf5994ad3be71c06a5f3fc4f0358a4e04821d519
|
File details
Details for the file niteco_agno_agent_tool-0.1.0-py3-none-any.whl.
File metadata
- Download URL: niteco_agno_agent_tool-0.1.0-py3-none-any.whl
- Upload date:
- Size: 5.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
0f5c8c90b1467837c95ea27d5751e9a19e49bf1090a79a7be98b5c813657c2fb
|
|
| MD5 |
54a92b0501b7749fbd8e0ced6778ae51
|
|
| BLAKE2b-256 |
b3d228d83b4ee4b93051a4204daa8170c3bebf788cbb84e9d09d3a6b9a0a662b
|