Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: edgee-ai/python-sdk
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: main
Choose a base ref
...
head repository: edgee-ai/python-sdk
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: add-compression-fields
Choose a head ref
Checking mergeability… Don’t worry, you can still create the pull request.
  • 9 commits
  • 5 files changed
  • 2 contributors

Commits on Feb 4, 2026

  1. feat: add optional compression fields to completion requests

    Add support for compression configuration with optional fields that can be
    passed per request to override API key settings.
    
    - Add optional `enable_compression: bool | None` field to `InputObject` dataclass
    - Add optional `compression_rate: float | None` field to `InputObject` dataclass
    - Include compression fields in request body when provided via InputObject or dict input
    - Compression fields are omitted from request when not provided
    - Fields are gateway-internal and not sent to providers
    
    🤖 Generated with [Claude Code](https://claude.ai/code)
    
    Co-Authored-By: Claude <noreply@anthropic.com>
    CLEMENTINATOR and claude committed Feb 4, 2026
    Configuration menu
    Copy the full SHA
    cebbc2b View commit details
    Browse the repository at this point in the history
  2. ruff

    CLEMENTINATOR committed Feb 4, 2026
    Configuration menu
    Copy the full SHA
    c483db7 View commit details
    Browse the repository at this point in the history
  3. feat: add compression response field to SendResponse

    - Add Compression dataclass with input_tokens, saved_tokens, and rate fields
    - Add optional compression field to SendResponse for root-level compression data
    CLEMENTINATOR committed Feb 4, 2026
    Configuration menu
    Copy the full SHA
    db38a5c View commit details
    Browse the repository at this point in the history
  4. test: add compression response field tests

    - Add test for response with compression field
    - Add test for response without compression field
    - Update _handle_non_streaming_response to parse compression data
    CLEMENTINATOR committed Feb 4, 2026
    Configuration menu
    Copy the full SHA
    9b320ff View commit details
    Browse the repository at this point in the history
  5. docs: add compression field documentation to README

    - Add example showing how to access compression data in responses
    - Add compression info to features list
    CLEMENTINATOR committed Feb 4, 2026
    Configuration menu
    Copy the full SHA
    0ba06cd View commit details
    Browse the repository at this point in the history
  6. docs: add compression example

    - Add example showing how to enable compression and set compression rate
    - Demonstrate accessing compression metrics from response
    - Show usage information alongside compression data
    CLEMENTINATOR committed Feb 4, 2026
    Configuration menu
    Copy the full SHA
    ea3c909 View commit details
    Browse the repository at this point in the history
  7. docs: update compression example with larger input context

    - Add substantial AI history document as context (~3000+ chars)
    - Demonstrate meaningful compression on large input
    - Show percentage of tokens saved
    - Explain that compression works on input tokens
    CLEMENTINATOR committed Feb 4, 2026
    Configuration menu
    Copy the full SHA
    a608583 View commit details
    Browse the repository at this point in the history
  8. fix: move large context to user message in compression example

    - Only USER messages are compressed, not system messages
    - Update example to put context in user message
    - Add clarifying comment about compression behavior
    CLEMENTINATOR committed Feb 4, 2026
    Configuration menu
    Copy the full SHA
    0cdb016 View commit details
    Browse the repository at this point in the history
  9. ruff

    CLEMENTINATOR committed Feb 4, 2026
    Configuration menu
    Copy the full SHA
    f4e9f2b View commit details
    Browse the repository at this point in the history
Loading