Skip to content

Conversation

Ddper
Copy link
Contributor

@Ddper Ddper commented Apr 10, 2025

fix issue #442

below is an example to overwrite include_usage

    result = Runner.run_streamed(
        agent,
        "Write a haiku about recursion in programming.",
        run_config=RunConfig(
            model_provider=CUSTOM_MODEL_PROVIDER,
            model_settings=ModelSettings(include_usage=True)
        ),
    )

@Ddper Ddper force-pushed the overwrite-mechanism-for-stream-options branch from 12ac796 to 4197582 Compare April 10, 2025 03:01
@rm-openai rm-openai merged commit 8ded8a9 into openai:main Apr 10, 2025
5 checks passed
Lightblues pushed a commit to Lightblues/openai-agents-python that referenced this pull request Apr 13, 2025
fix issue openai#442

below is an example to overwrite include_usage


```
    result = Runner.run_streamed(
        agent,
        "Write a haiku about recursion in programming.",
        run_config=RunConfig(
            model_provider=CUSTOM_MODEL_PROVIDER,
            model_settings=ModelSettings(include_usage=True)
        ),
    )
```
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants