Skip to content

Add OpenAI-compatible agent profile#7

Open
WarGloom wants to merge 3 commits into
dimknaf:mainfrom
WarGloom:feat/openai-compatible-profile
Open

Add OpenAI-compatible agent profile#7
WarGloom wants to merge 3 commits into
dimknaf:mainfrom
WarGloom:feat/openai-compatible-profile

Conversation

@WarGloom
Copy link
Copy Markdown
Contributor

This is the focused follow-up from the closed local-agent setup PR. It only adds the generic openai_compatible profile path, so BrainDB can point the internal agent at OpenAI-compatible /v1 endpoints without adding another provider abstraction.

What changed:

  • add openai_compatible to _LLM_PROFILES and let AGENT_BASE_URL override the profile base URL
  • pass AGENT_BASE_URL and AGENT_API_KEY into the API container
  • document the env vars with an Ollama-style example using the generic profile name
  • add unit coverage for the new profile and existing profile regressions

What this does not include:

  • no local_ollama alias
  • no Codex profile or OPENAI_API_KEY passthrough
  • no fast-path save routing
  • no bundled Postgres, manage script, or GPU compose changes

Validation:

  • python -m pytest tests/test_config_profiles.py -q -> 7 passed
  • docker compose config
  • python -m py_compile braindb/config.py tests/conftest.py tests/test_config_profiles.py
  • manual Settings smoke with LLM_PROFILE=openai_compatible, AGENT_MODEL=openai/llama3.2:3b, AGENT_BASE_URL=http://localhost:11434/v1

I could not run the full suite in this shell because the local Python environment is missing agents and psycopg2; the targeted config tests above do not depend on those packages.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant