Skip to content
Open
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
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -320,6 +320,7 @@ For example, add these lines to your `.bashrc`, `.zshrc`, or equivalent shell pr
```sh
# For OpenAI
export OPENAI_API_KEY="sk-..."
export OPENAI_API_BASE="https://provider.example.com/v1" # Optional: Use a custom OpenAI-compatible endpoint

# For Anthropic
export ANTHROPIC_API_KEY="..."
Expand Down
3 changes: 2 additions & 1 deletion src/voxd/core/aipp.py
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,8 @@ def run_ollama_aipp(prompt: str, model: str = "llama3.2:latest") -> str:


def run_openai_aipp(prompt: str, model: str = "gpt-3.5-turbo") -> str:
url = "https://api.openai.com/v1/chat/completions"
base_url = os.getenv("OPENAI_API_BASE", "https://api.openai.com/v1")
url = f"{base_url}/chat/completions"
headers = {
"Authorization": f"Bearer {os.getenv('OPENAI_API_KEY', '')}",
"Content-Type": "application/json"
Expand Down