Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
.DEFAULT_GOAL := default

.PHONY: default install lint test test-unit test-integration nox nox-unit nox-integration test-deps upgrade build clean docs docs-deploy
.PHONY: test-openai test-anthropic test-google test-cerebras test-cohere test-grok test-groq
.PHONY: test-openai test-anthropic test-google test-cerebras test-cohere test-grok test-groq test-openrouter
.PHONY: test-bare test-all-extras clean-cassettes help

default: install lint test
Expand Down Expand Up @@ -57,6 +57,9 @@ test-grok:
test-groq:
uv run nox -s test_groq

test-openrouter:
uv run nox -s test_openrouter

test-bare:
uv run nox -s test_bare

Expand Down Expand Up @@ -120,6 +123,7 @@ help:
@echo " make test-cohere - Test chimeric[cohere] only"
@echo " make test-grok - Test chimeric[grok] only"
@echo " make test-groq - Test chimeric[groq] only"
@echo " make test-openrouter - Test chimeric[openrouter] only"
@echo " make test-bare - Test bare installation (no extras)"
@echo " make test-all-extras - Test all extras installation"
@echo ""
Expand Down
29 changes: 26 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@
[![Groq](https://img.shields.io/badge/Groq-F55036?logo=groq&logoColor=white)](https://groq.com/)
[![Cohere](https://img.shields.io/badge/Cohere-39594A?logo=cohere&logoColor=white)](https://cohere.ai/)
[![Cerebras](https://img.shields.io/badge/Cerebras-FF6B35?logo=cerebras&logoColor=white)](https://cerebras.ai/)
[![OpenRouter](https://img.shields.io/badge/OpenRouter-8A2BE2?logo=openrouter&logoColor=white)](https://openrouter.ai/)

## 📖 Documentation

Expand Down Expand Up @@ -54,7 +55,14 @@ export ANTHROPIC_API_KEY="your-key-here"
```python
from chimeric import Chimeric

client = Chimeric() # Auto-detects API keys from environment
# Auto-detect from environment variables
client = Chimeric()

# Or specify providers explicitly
client = Chimeric(
openai_api_key="sk-...",
anthropic_api_key="sk-ant-..."
)

response = client.generate(
model="gpt-4o",
Expand Down Expand Up @@ -100,6 +108,21 @@ response = client.generate(
print(response.content)
```

### Provider Initialization
```python
# Only initialize specific providers
client = Chimeric(openai_api_key="sk-...") # Only OpenAI

# Mix explicit keys with environment detection
client = Chimeric(
openai_api_key="sk-...", # Explicit OpenAI
detect_from_env=True # Plus any from environment
)

# Auto-detect all from environment
client = Chimeric() # Detects all available providers
```

### Multi-Provider Switching
```python
# Seamlessly switch between providers
Expand All @@ -116,8 +139,8 @@ for model in models:

## 🔧 Key Features

- **Multi-Provider Support**: Switch between 7 major AI providers seamlessly
- **Automatic Detection**: Auto-detects available API keys from environment
- **Multi-Provider Support**: Switch between 8 major AI providers seamlessly
- **Flexible Initialization**: Auto-detect from environment or specify providers explicitly
- **Unified Interface**: Consistent API across all providers
- **Streaming Support**: Real-time response streaming
- **Function Calling**: Tool integration with decorators
Expand Down
Loading