Repository navigation
fix(rag): use correct provider credentials and support local dev config sync - #1476
Conversation
…local dev config sync
Two fixes:
1. RAG embedding service now uses the embedding provider's own api_key and
base_url instead of incorrectly reusing the chat provider's credentials.
This fixes multi-provider setups where chat and embedding are on different
providers.
2. compose.yml now uses ${PLATFORM_SHARED_CONFIG:-platform-data} for the
shared config volume mount. In local dev (bun dev), set
PLATFORM_SHARED_CONFIG=./examples in .env so RAG/crawler containers
read provider config from the same directory the local platform writes to.
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: ASSERTIVE Plan: Pro Run ID: 📒 Files selected for processing (3)
📝 WalkthroughWalkthroughThe changes introduce configurable embedding service credentials separate from the main LLM provider settings. The compose configuration now supports a Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes 🚥 Pre-merge checks | ✅ 2 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (2 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Comment |
Summary
Embedding uses wrong API key in multi-provider setups:
get_llm_config()was discarding the embedding provider'sapi_keyandbase_url, always using the chat provider's credentials forEmbeddingService. Fixed by addingembedding_api_key/embedding_base_urlto the config dict and using them in both_do_initialize()and_maybe_refresh_clients().Local dev config not syncing to RAG/crawler containers: When platform runs locally via
bun dev, it writes provider config toexamples/providers/on the host. RAG/crawler containers were reading from theplatform-dataDocker named volume — a completely different filesystem. Fixed by parameterizing the shared config volume mount with${PLATFORM_SHARED_CONFIG:-platform-data}. SetPLATFORM_SHARED_CONFIG=./examplesin.envfor local dev.Test plan
PLATFORM_SHARED_CONFIG=./examplesin.env, restart RAG/crawler, change API key in dashboard → verify RAG picks up the new key within 15sPLATFORM_SHARED_CONFIGunset → verify containers useplatform-datanamed volume as beforeSummary by CodeRabbit
Release Notes
New Features
Improvements