Parent tracking issue: #4904
Desired Behavior
LLM streaming wrappers, provider messages, tokenizer outputs, optional transformer loading, and response events should be represented by explicit protocols or adapter functions. Core LLM logic should consume those typed contracts with direct access instead of probing provider objects dynamically.
The fix in #4772 remains authoritative for the yielded-versus-wrapper completed-response bug; this work should build on or avoid conflicting with it.
Scope
- Streaming/event and tokenizer access in
llm.py
- Provider message normalization in
message.py and mixins/non_native_fc.py
- OpenAI auth capability access
- Excludes telemetry normalization and retry metadata
Acceptance Criteria
This issue was created by an AI agent (OpenHands) on behalf of the user.
Parent tracking issue: #4904
Desired Behavior
LLM streaming wrappers, provider messages, tokenizer outputs, optional transformer loading, and response events should be represented by explicit protocols or adapter functions. Core LLM logic should consume those typed contracts with direct access instead of probing provider objects dynamically.
The fix in #4772 remains authoritative for the yielded-versus-wrapper completed-response bug; this work should build on or avoid conflicting with it.
Scope
llm.pymessage.pyandmixins/non_native_fc.pyAcceptance Criteria
This issue was created by an AI agent (OpenHands) on behalf of the user.