fix(ai): correct the Context Chat embedding API key env var name - #15495
AndyScherzinger merged 1 commit into
Conversation
|
will backport this after #15491 and its backports are in. |
The documented name is CC_EM_API_KEY, but context_chat_backend reads CC_EM_APIKEY. An administrator following the docs gets an unauthenticated embedding client with no obvious sign of why. Signed-off-by: Baki Burak Öğün <63836730+bakiburakogun@users.noreply.github.com>
bc5e792 to
3a98eda
Compare
|
/backport to stable35 |
|
/backport to stable34 |
|
/backport to stable33 |
|
/backport to stable32 |
|
Hello there, We hope that the review process is going smooth and is helpful for you. We want to ensure your pull request is reviewed to your satisfaction. If you have a moment, our community management team would very much appreciate your feedback on your experience with this PR review process. Your feedback is valuable to us as we continuously strive to improve our community developer experience. Please take a moment to complete our short survey by clicking on the following link: https://cloud.nextcloud.com/apps/forms/s/i9Ago4EQRZ7TWxjfmeEpPkf6 Thank you for contributing to Nextcloud and we hope to hear from you soon! (If you believe you should not receive this message, you can add yourself to the blocklist.) |
|
This has been approved since 27 August and the backports were queued on the 31st, so I think it is only the two red checks holding it, and neither of them can go green from here.
The change itself is one line in one file: Happy to rebase or reopen from a branch if that is easier for you, just say which. |
|
thanks for the ping, had created an issue for the labeller, did one for the netlify PR comment too now. |
|
Thanks for your first pull request and welcome to the community! Feel free to keep them coming! If you are looking for issues to tackle then have a look at this selection: https://github.com/nextcloud/documentation/issues?q=is%3Aopen+is%3Aissue+label%3A%22good+first+issue%22 |
The Context Chat scaling section documents the embedding API key as
CC_EM_API_KEY, butcontext_chat_backendreadsCC_EM_APIKEY.In
context_chat_backend/config_parser.py:CC_EM_APIKEYappears four times across the repository;CC_EM_API_KEYappears nowhere. The other three names in the same sentence —CC_EM_BASE_URL,CC_EM_MODEL_NAME,CC_EM_USERNAME,CC_EM_PASSWORD— all match the code.The failure mode is quiet: an administrator who follows the documentation sets a variable nothing reads,
authfalls through toNone, and the backend talks to the embedding service unauthenticated. Depending on how that service answers, the first sign of trouble is an indexing failure some distance away from the cause.I hit this while setting up an on-premises embedding service for a Nextcloud 34 installation.
Only the documented name is changed here. If you would rather the code accept both spellings, I am happy to open that against
context_chat_backendinstead.