Consider combining get_response and get_streaming_response methods into one, using a stream parameter. Also consider using a generic TypedDict for provider-specific parameters.
File: python/packages/core/agent_framework/_clients.py
Location: ChatClientProtocol protocol, get_response method (Lines ~93-96)
Proposal:
- Use stream: bool parameter to combine both methods (while keeping agent.run and agent.run_stream separate)
- Use a generic TypedDict as kwargs to allow provider-specific parameters
- This could support type checking and IDE autocompletion
- Users could provide their own TypedDict
Extracted from #3096
Parent issue: #3575