Repository navigation
feat(charity_engine): add Charity Engine provider #23223
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 1 commit
7f04601
da81210
617d8b5
7f7c1d7
6721c20
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -94,5 +94,13 @@ | |
| "assemblyai": { | ||
| "base_url": "https://llm-gateway.assemblyai.com/v1", | ||
| "api_key_env": "ASSEMBLYAI_API_KEY" | ||
| }, | ||
| "charity_engine": { | ||
| "base_url": "https://api.charityengine.services/remotejobs/v2/inference/", | ||
| "api_key_env": "CHARITY_ENGINE_API_KEY", | ||
| "api_base_env": "CHARITY_ENGINE_API_BASE", | ||
| "param_mappings": { | ||
| "max_completion_tokens": "max_tokens" | ||
| } | ||
| } | ||
|
Comment on lines
+98
to
104
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The PR submission checklist explicitly requires at least one test to be added for new providers (see the contributing guide and other providers like Following the pattern established by
Comment on lines
+98
to
104
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The This causes two concrete test failures:
Every other JSON-backed provider in this pattern added the enum entry — for example Fix: Add the following line to CHARITY_ENGINE = "charity_engine" |
||
| } | ||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Trailing slash in
base_urlproduces double-slash endpointThe
base_urlvalue ends with/. Indynamic_config.py(line 94-95), theget_complete_urlmethod constructs the final endpoint like this:Because the value ends with
/(not/chat/completions), the constructed URL becomes:The double slash
//in the path could cause routing issues on strict server implementations, even though most servers normalize it. The same pattern exists in thechutesentry and may work in practice, but it is cleaner to remove the trailing slash to match the majority of providers:The corresponding assertion in
test_charity_engine_provider_resolution(line 56) would also need updating to match.