Thanks to visit codestin.com
Credit goes to github.com

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-agents-python
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: main
Choose a base ref
...
head repository: scotthamilton77/openai-agents-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.
  • 10 commits
  • 12 files changed
  • 2 contributors

Commits on May 25, 2025

  1. Added ability for agents to carry their own TTS settings and have the…

    … pipeline activate it prior to streaming results.
    scotthamilton77 committed May 25, 2025
    Configuration menu
    Copy the full SHA
    04df256 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    bda9cb3 View commit details
    Browse the repository at this point in the history

Commits on May 26, 2025

  1. Configuration menu
    Copy the full SHA
    3d72426 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    168464f View commit details
    Browse the repository at this point in the history
  3. Test: Update and extend tests for voice configuration handling. (#1)

    This commit updates the test suite to ensure comprehensive coverage for the recent changes to how voice configurations (TTS model, settings) are managed and resolved within the voice agent system.
    
    Key changes:
    
    - **`tests/voice/test_pipeline.py`**:
        - Added tests for `VoicePipeline.get_effective_voice_configuration` to verify correct prioritization of workflow-provided vs. pipeline-default configurations.
        - Updated existing pipeline run tests (`run_single_turn`, `run_multi_turn`) to ensure they correctly use `VoiceConfiguration` provided by the workflow. This involved enhancing `FakeTTS` and `FakeWorkflow`.
        - Added new tests for pipeline-workflow interaction scenarios, covering cases where model name and settings are mixed and matched between workflow and pipeline configurations. A `MockModelProvider` was introduced for better control over TTS model resolution in tests.
    
    - **`tests/voice/test_workflow.py`**:
        - Added tests for `VoiceWorkflowBase.get_voice_configuration` to ensure it correctly fetches configurations from its `current_agent`.
        - For `SingleAgentVoiceWorkflow`:
            - Tested retrieval of `VoiceConfiguration` from its agent.
            - Tested that `current_agent` is correctly updated after a simulated handoff.
            - Verified that `on_run` and `on_agent_change` callbacks are invoked as expected. Mocked `RunResultStreaming` for handoff simulation.
    
    - **`tests/voice/test_voiceagent.py` (New file)**:
        - Created to test components from `src/agents/voice/voiceagent.py`.
        - Added tests for `VoiceAgentMixin` to ensure proper storage and retrieval of `VoiceConfiguration`.
        - Added tests for `with_voice_configuration` and `with_voice_config` helper functions, verifying they correctly create new agent instances with the specified voice configurations and preserve original agent details.
    
    - **`tests/voice/test_model.py` (New file)**:
        - Created to test components from `src/agents/voice/model.py`.
        - Added tests for `VoiceConfiguration.get_effective_model()`, covering scenarios for model resolution (name vs. instance) and caching behavior.
    
    - **`tests/voice/fake_models.py`**:
        - Enhanced `FakeTTS` to store `last_run_settings` and accept a `name` for easier instance identification in tests.
    
    The existing tests in `tests/voice/test_openai_tts.py`, `tests/voice/test_input.py`, and `tests/voice/test_openai_stt.py` were reviewed and found not to require changes for this specific set of refactorings.
    
    Co-authored-by: google-labs-jules[bot] <161369871+google-labs-jules[bot]@users.noreply.github.com>
    scotthamilton77 and google-labs-jules[bot] authored May 26, 2025
    Configuration menu
    Copy the full SHA
    d5bebd5 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    610150f View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    2f0f6cc View commit details
    Browse the repository at this point in the history
  6. Configuration menu
    Copy the full SHA
    8d877af View commit details
    Browse the repository at this point in the history
  7. Configuration menu
    Copy the full SHA
    5d282f9 View commit details
    Browse the repository at this point in the history
  8. Configuration menu
    Copy the full SHA
    0e6e9bd View commit details
    Browse the repository at this point in the history
Loading