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: openai/openai-python
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: main
Choose a base ref
...
head repository: aimlapi/aimlapi-sdk-python
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: main
Choose a head ref
Checking mergeability… Don’t worry, you can still create the pull request.
  • 18 commits
  • 1,016 files changed
  • 3 contributors

Commits on Nov 25, 2025

  1. Configuration menu
    Copy the full SHA
    ff4558b View commit details
    Browse the repository at this point in the history
  2. feat: AIMLAPI module defaults and chat overrides

    Improve AIMLAPI module defaults and chat overrides
    
    Set Azure default base URL
    D1m7asis committed Nov 25, 2025
    Configuration menu
    Copy the full SHA
    6cf9ad4 View commit details
    Browse the repository at this point in the history
  3. fix: Enhance completion logic for AI/ML API

    Allow dict chat stream payloads
    
    Default chat completions stream flag
    
    Allow chat parse dict messages
    D1m7asis committed Nov 25, 2025
    Configuration menu
    Copy the full SHA
    1a21530 View commit details
    Browse the repository at this point in the history
  4. Migrate examples from OpenAI to AIMLAPI

    Replaced all OpenAI imports and usage with AIMLAPI equivalents across example scripts, updated model names and endpoints, and refactored code to match AIMLAPI's API. Also removed obsolete enums and improved streaming/image handling logic. Deleted the unused responses_input_tokens.py example.
    D1m7asis committed Nov 25, 2025
    Configuration menu
    Copy the full SHA
    09136c5 View commit details
    Browse the repository at this point in the history
  5. feat: Handle AIMLAPI audio STT/TTS overrides

    Handle streamed binary response in TTS payload
    
    Adds a short-circuit to return StreamedBinaryAPIResponse directly in _finalize_sync_tts_payload, improving handling of streamed audio responses. Also adds a debug print statement in _coerce_mapping for error cases.
    
    Handle AsyncStreamedBinaryAPIResponse in TTS payload
    
    Adds a short-circuit to return the payload directly if it is an instance of AsyncStreamedBinaryAPIResponse in the _finalize_async_tts_payload function. This prevents unnecessary processing for streamed binary responses.
    
    Add AIML audio STT/TTS overrides
    D1m7asis committed Nov 25, 2025
    Configuration menu
    Copy the full SHA
    3e929e6 View commit details
    Browse the repository at this point in the history
  6. Migrate examples from OpenAI to AIMLAPI

    Replaces all OpenAI imports and usage with AIMLAPI equivalents across example scripts. Updates model names, API key environment variables, and endpoint usage to match AIMLAPI conventions. Adjusts audio, Azure, and streaming examples for compatibility with AIMLAPI, and removes or comments out unsupported features.
    
    Remove realtime audio example files
    
    Deleted the examples/realtime directory including audio_util.py, azure_realtime.py, push_to_talk_app.py, and realtime.py. Updated background.py to use AIMLAPI instead of OpenAI. This streamlines the examples and updates the response client usage.
    D1m7asis committed Nov 25, 2025
    Configuration menu
    Copy the full SHA
    3046948 View commit details
    Browse the repository at this point in the history
  7. Add AIMLAPI client test suite

    Introduce comprehensive tests for AIMLAPI client covering chat, completions, embeddings, error handling, image generation and editing, responses (basic, background, streaming), structured tool output, TTS, and chunked uploads. These tests use pytest and respx to mock HTTP interactions and validate request/response payloads and client behavior.
    D1m7asis committed Nov 25, 2025
    Configuration menu
    Copy the full SHA
    78308e3 View commit details
    Browse the repository at this point in the history
  8. Disable audio translations and improve audio payload extraction

    Audio translations are now explicitly unsupported in AIMLAPI, raising NotImplementedError with guidance for alternatives. Audio payload extraction logic in speech.py is enhanced to better handle various audio field formats and URLs, improving robustness and compatibility.
    D1m7asis committed Nov 25, 2025
    Configuration menu
    Copy the full SHA
    6e8e4ce View commit details
    Browse the repository at this point in the history
  9. Configuration menu
    Copy the full SHA
    d6ef2c4 View commit details
    Browse the repository at this point in the history
  10. Configuration menu
    Copy the full SHA
    5088774 View commit details
    Browse the repository at this point in the history
  11. Inline streaming fallback into responses resource

    Update examples to use AIMLAPI client
    
    Replaced OpenAI client imports and usage with AIMLAPI equivalents in async and streaming response examples. Also updated event type checks and removed a TODO comment for consistency.
    
    Fix background JSON resume handling
    D1m7asis committed Nov 25, 2025
    Configuration menu
    Copy the full SHA
    a0c2892 View commit details
    Browse the repository at this point in the history
  12. Update image_stream.py

    Update image_stream.py
    
    Update image_stream.py
    D1m7asis committed Nov 25, 2025
    Configuration menu
    Copy the full SHA
    b60f08f View commit details
    Browse the repository at this point in the history
  13. Add default headers for AIMLAPI client requests

    Introduces AIMLAPI_HEADERS with referer and title for identification. These headers are merged into default_headers in _apply_default_client_options to ensure all requests include them.
    D1m7asis committed Nov 25, 2025
    Configuration menu
    Copy the full SHA
    ae78000 View commit details
    Browse the repository at this point in the history
  14. Add image streaming and b64_json support

    Introduces image streaming and base64-encoded image response support to the AIMLAPI client. Adds Images and AsyncImages resources with b64_json hydration, patches response models for compatibility, and updates examples to demonstrate both URL and base64 image outputs. Removes the obsolete image_stream.py example.
    D1m7asis committed Nov 25, 2025
    Configuration menu
    Copy the full SHA
    b20499b View commit details
    Browse the repository at this point in the history
  15. Add uploads resource to AIMLAPI client

    Introduces the uploads resource to AIMLAPI and AzureAIMLAPI clients, including async variants. Implements Uploads and AsyncUploads classes to route upload requests to the files endpoint, ensuring compatibility with the API structure. Updates imports and __all__ in the uploads resource package for proper exposure.
    D1m7asis committed Nov 25, 2025
    Configuration menu
    Copy the full SHA
    2e7055f View commit details
    Browse the repository at this point in the history

Commits on Nov 27, 2025

  1. Align docs with AIML examples and update release config

    Refactored comments in _version.py to clarify versioning scheme and added release automation marker. Cleaned up release-please-config.json by removing prerelease and extra file settings for improved configuration clarity.
    
    Apply code style and formatting improvements
    
    This commit updates code style for consistency, including quote normalization, line wrapping, and formatting in examples, source, and test files. It also updates pyproject.toml with new author information and adds 'ruff' as a dependency. No functional changes were made.
    
    Update pyproject.toml
    D1m7asis committed Nov 27, 2025
    Configuration menu
    Copy the full SHA
    12b9ab9 View commit details
    Browse the repository at this point in the history

Commits on Nov 28, 2025

  1. Refactor for AIMLAPI repo and update version to 2.8.1-beta.1

    Updated repository references from 'api-sdk-python' to 'aimlapi-sdk-python' throughout the codebase and workflows. Changed version to 2.8.1-beta.1 in pyproject.toml, .release-please-manifest.json, and _version.py. Added a manual version bump workflow, removed OpenAI-specific release workflows, and adjusted CI and PyPI publishing logic for AIMLAPI. Cleaned up imports and ordering in several modules, improved README with example capabilities, and removed deprecated uploads example and test files.
    D1m7asis committed Nov 28, 2025
    Configuration menu
    Copy the full SHA
    c8ddd5b View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    52ea5e2 View commit details
    Browse the repository at this point in the history
Loading