feat(compression): add summary_base_url + move compression config to YAML-only#1727
Merged
Conversation
…only - Add summary_base_url config option to compression block for custom OpenAI-compatible endpoints (e.g. zai, DeepSeek, Ollama) - Remove compression env var bridges from cli.py and gateway/run.py (CONTEXT_COMPRESSION_* env vars no longer set from config) - Switch run_agent.py to read compression config directly from config.yaml instead of env vars - Fix backwards-compat block in _resolve_task_provider_model to also fire when auxiliary.compression.provider is 'auto' (DEFAULT_CONFIG sets this, which was silently preventing the compression section's summary_* keys from being read) - Add test for summary_base_url config-to-client flow - Update docs to show compression as config.yaml-only Closes #1591 Based on PR #1702 by @uzaylisak
12cac40 to
b5ed6eb
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds
summary_base_urlconfig option and moves all compression configuration to config.yaml (removing the env var bridge layer).Based on PR #1702 by @uzaylisak. Closes #1591.
Changes
New feature:
summary_base_urlCompression config is now YAML-only
cli.py: Removed compression env var bridge (CONTEXT_COMPRESSION_*no longer set from config)gateway/run.py: Same — removed bridge and env var override checkrun_agent.py: Now reads compression config directly fromconfig.yamlviaload_config()instead of env varsBug fix: backwards-compat block condition
auxiliary.compression.providerdefaults to"auto"inDEFAULT_CONFIG, which is truthy — this silently prevented thecompression.summary_*keys from ever being readnot cfg_providertonot cfg_provider or cfg_provider == "auto"Tests
test_compression_summary_base_url_from_config— verifies the full config → client flowsummary_base_urlDocs
Backward Compatibility
Fully backward compatible. Existing configs work unchanged. Users who set
CONTEXT_COMPRESSION_*env vars directly (not from config bridge) still get them picked up via the generic_get_auxiliary_env_overridefunction.