semvec/pypi-packages huggingface dataset:
atomagent 0.1.0
A lightweight Python AI Agent framework with async support
License: MIT
Requires Python: >=3.9
Keywords: ai, agent, llm, openai, async, tools, function-calling

# ⚛️ AtomAgent

[![Python Version](https://img.shields.io/badge/python-3.9%2B-blue.svg)](https://www.python.org/downloads/)
[![License](https://img.shields.io/badge/license-MIT-green.svg)](https://github.com/liuyunrui123/AtomAgent/blob/main/LICENSE)

AtomAgent is a lightweight Python AI Agent framework that supports both synchronous and asynchronous modes, providing a clean tool registration mechanism for building intelligent agents with function calling capabilities.

## ✨ Key Features

- **🔌 Minimal Dependencies**: Only depends on pure Python libraries, no Rust dependencies
- **🎯 OpenAI API Compatible**: Supports all OpenAI API compatible LLMs
- **🔧 Flexible Tool System**: Easy tool registration with decorators
- **🚀 Async Support**: Full async implementation for high concurrency
- **📡 Multi-Tool Calling**: Supports OpenAI's latest tools protocol
- **🔄 Streaming Output**: Real-time streaming responses
- **📝 Detailed Logging**: Built-in hierarchical logging system

## 📦 Installation

```bash
# Basic installation
pip install atomagent
```

## 🚀 Quick Start

```python
from atomagent import AsyncAgent

# Create an agent
agent = AsyncAgent(
    name="Assistant",
    model="gpt-3.5-turbo",
    api_key="your_api_key"
)

# Register a tool
@agent.tool()
def get_weather(city: str) -> str:
    """Get weather information for a city"""
    return f"The weather in {city} is sunny"

# Run the agent
import asyncio

async def main():
    response = await agent.run("What's the weather in Beijing?")
    print(response)

asyncio.run(main())
```

## 📖 Documentation

For detailed documentation and examples, visit: [https://github.com/liuyunrui123/AtomAgent](https://github.com/liuyunrui123/AtomAgent)

## 🤝 Contributing

Contributions are welcome! Please feel free to submit a Pull Request.

## 📄 License

This project is licensed under the MIT License.