A service that manages and executes agno agents with OPAL SDK integration
Project description
Niteco Agno Agent Tool
A service that manages and executes agno agents with OPAL SDK integration. This repository contains both the core package and example agent implementations, including an eCommerce Analytics Agent that provides industry KPI benchmarks.
Development Setup
-
Clone the repository:
git clone <repository-url> cd Niteco.Opal-Agno-agent-tool
-
Create virtual environment:
python -m venv venv venv\Scripts\activate # Windows # source venv/bin/activate # Linux/Mac
-
Install dependencies:
pip install -r requirements.txt
Project Structure
├── cr_statistic_agent/ # eCommerce Analytics Agent
│ ├── agent.py # Main agent implementation
│ ├── agent_prompt.py # Agent prompts and configurations
│ ├── csv_output/ # Sample data files
│ └── json_to_csv_parser.py # Data processing utilities
├── niteco/ # Public package source
│ └── agno_agent_tool/ # Agent tool service package
└── requirements.txt # Development dependencies
Running the eCommerce Analytics Agent
cd cr_statistic_agent
python agent.py
The agent service will be available at http://localhost:8001
Core Architecture
AgnoAgentToolService
The main service (niteco/agno_agent_tool/agno_agent_tool_service.py) extends OPAL ToolsService to:
- Manage agno agent lifecycle and registration
- Provide FastAPI endpoints for agent interaction
- Integrate with OPAL SDK for tool registration
- Handle async agent execution with proper error handling
eCommerce Analytics Agent
The example agent (cr_statistic_agent/agent.py) provides:
- eCommerce KPI analysis using DuckDB
- Industry benchmarks from Dynamic Yield dataset (200M+ users, 400+ brands)
- 7 KPI tables: conversion_rate, add_to_cart_rate, cart_abandonment_rate, average_order_value, units_per_transaction, average_transactions_per_user, device_usage
- Automatic CSV to database conversion for analytics
Key Dependencies
- agno - Agent framework providing the base Agent class and tools
- OPAL SDK (
optimizely-opal.opal-tools-sdk) - Tools service integration - FastAPI - Web framework for REST API endpoints
- DuckDB - In-memory analytical database for CSV data processing
- Groq - LLM provider integration
- python-dotenv - Environment variable management
Package Development
Building the Package
The public package is located in /niteco and can be built using:
# Build the package
python setup.py sdist bdist_wheel
# Install package in development mode
pip install -e .
# Install with dev dependencies
pip install -e ".[dev]"
Testing and Quality
# Run tests (if pytest is installed)
pytest
# Code formatting (if available)
black .
isort .
# Type checking (if mypy is installed)
mypy niteco/
Public Package Installation
For end-users, install the published package:
pip install niteco.agno-agent-tool
Contributing
- Make changes in the development environment
- Test your changes with the example agents
- Update the public package in
/nitecoif needed - Submit a pull request
License
MIT License
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.1.tar.gz.
File metadata
- Download URL: niteco_agno_agent_tool-0.1.1.tar.gz
- Upload date:
- Size: 6.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
fbcd5266372d72510d3382b8c4cf3c9c30a8677de1179f799390c63149ad1332
|
|
| MD5 |
73e8201b28fae43133b04b115192ffa6
|
|
| BLAKE2b-256 |
b6d89400a61058d79149adaf9a12075a7725822ccfb87fbcaa4608c152944e44
|
File details
Details for the file niteco_agno_agent_tool-0.1.1-py3-none-any.whl.
File metadata
- Download URL: niteco_agno_agent_tool-0.1.1-py3-none-any.whl
- Upload date:
- Size: 6.3 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 |
2687ea98ced953ba0f99e13c451288e2735da4ebe46512297b3ea8a1efa91b52
|
|
| MD5 |
69a7b10df1e8ef0c7e042a86682d7f8e
|
|
| BLAKE2b-256 |
d3252ce7bd2303b34fd23bfb06d2e2648ed3fb77f6cf1e9d65fd2f73186a4ab7
|