NestAI is a comprehensive Python library designed to simplify and enhance interactions with AI models across multiple providers. It offers a unified interface that abstracts away the complexities of working with different AI services, while providing advanced features like semantic caching, cost optimization, and detailed metrics tracking. NestAI is built to be both simple for beginners and powerful for advanced users, making AI integration seamless for any project.
The core of NestAI is its ability to intelligently manage AI requests, automatically selecting the most appropriate and cost-effective provider based on your needs. With built-in security features like PII detection and redaction, NestAI ensures your data remains protected while providing transparent insights into how decisions are made through its comprehensive logging and metrics systems.
β οΈ Version 1.0.0. API may evolve in future releases.
π‘ Semantic Caching reduces costs and improves response times by intelligently reusing similar responses.
- π Simple Interface: Use AI with just a single line of code
- π Multiple Providers: Support for OpenAI, Anthropic, Mistral, Cohere, and more
- π° Cost Optimization: Automatically select the most cost-effective provider and model
- β‘ Caching: Avoid redundant API calls with both exact and semantic caching
- π Streaming: Real-time text streaming for interactive applications
- π Security: PII detection and redaction, encryption, and audit trails
- π Metrics: Detailed usage tracking and performance metrics
- π§© Customization: Plugin system for extending functionality
- π Transparency: Decision logging and cost estimation
- π¦ Batch Processing: Process multiple requests efficiently
- π¬ Conversation Management: Manage conversations with context and memory
- π Pipeline Processing: Create custom processing pipelines
- Python 3.8 or higher
- API keys for the AI providers you wish to use
To install NestAI, use pip:
# Using pip
pip install nestai
# Using pipenv
pipenv install nestai
# Using poetry
poetry add nestaiHelp us to develop more interesting things.
This software is licensed with GPL-3.0.
PigeonPosse is a β¨ code development collective β¨ focused on creating practical and interesting tools that help developers and users enjoy a more agile and comfortable experience. Our projects cover various programming sectors and we do not have a thematic limitation in terms of projects.
This software is licensed with GPL-3.0.
PigeonPosse is a β¨ code development collective β¨ focused on creating practical and interesting tools that help developers and users enjoy a more agile and comfortable experience. Our projects cover various programming sectors and we do not have a thematic limitation in terms of projects.
| Name | Role | GitHub | |
|---|---|---|---|
![]() |
Alejo | Author & Development | @alejomalia |
![]() |
PigeonPosse | Collective | @PigeonPosse |


