Open Source Python Framework

Dhenara AI
Unified Python framework for LLM integrations

A powerful, flexible, and truly open-source Python framework for interacting with AI models from OpenAI, Google AI, Anthropic, and other providers through a consistent interface.

100%
Open Source
6+
Providers
Type Safe
Pydantic
python
from dhenara.ai import AIModelClient
from dhenara.ai.types import AIModelCallConfig, AIModelEndpoint
from dhenara.ai.types.external_api import AIModelAPIProviderEnum
from dhenara.ai.types.genai import AIModelAPI
from dhenara.ai.types.genai.foundation_models.anthropic.chat import Claude37Sonnet

# Create an API
api = AIModelAPI(
    provider=AIModelAPIProviderEnum.ANTHROPIC,
    api_key="your_api_key",
)

# Create an endpoint using a pre-configured model
model_endpoint = AIModelEndpoint(
    api=api,
    ai_model=Claude37Sonnet,
)

# Configure the api call
client = AIModelClient(
    model_endpoint=model_endpoint,
    config=AIModelCallConfig(streaming=True),
    is_async=False,
)

# Generate a response
response = client.generate(prompt="Explain quantum computing in simple terms")

Built for Modern AI Development

Everything you need to integrate AI models into your applications with confidence and ease.

Unified API

Interact with different AI providers through a consistent interface, making it easy to switch between models without changing your code.

Type Safety

Built with Pydantic for robust type checking and validation, ensuring your code is reliable and errors are caught early.

Multiple Providers

Support for OpenAI, Google AI, Anthropic, DeepSeek, Vertex AI, Amazon Bedrock, and Microsoft Azure AI.

Streaming Support

First-class support for streaming responses along with accumulated responses for a consistent developer experience.

Cost Tracking

Monitor token usage and associated costs to keep your AI implementation cost-effective and transparent.

Open Source

Truly open-source and community-focused, designed for transparency and extensibility.

Key Benefit

Genuinely Open Source

Built from the ground up as a community resource, not an afterthought or internal tool. Our open-source commitment means you can trust the code and contribute to its improvement.

Genuinely Open Source
Key Benefit

Multiple Model Support

Easily switch between models and providers at runtime without reconfiguration. Work with foundation models regardless of which provider is serving them.

Multiple Model Support
Key Benefit

Ready for Dhenara Agent

Dhenara AI serves as the foundation for Dhenara Agent, our open-source framework for creating sophisticated AI agents with its own DSL. Build complex agent workflows on top of this robust foundation.

Ready for Dhenara Agent

Why Choose Dhenara AI?

Dhenara AI offers significant advantages compared to other LLM frameworks:

Genuinely open-source with a community-first approach
Unified API across multiple providers with easy switching
Built-in cost tracking and usage monitoring
Strong focus on type safety with Pydantic
First-class streaming support with consistent response handling
Simple configuration with sensible defaults
Foundation for the Dhenara Agent framework

Ready to simplify your AI development?

Get started with Dhenara AI today.

Growing
Community
Multiple
Providers
Type
Safe