Document invocation observation and cost reporting
This commit is contained in:
@@ -142,6 +142,14 @@ known. Strictly decoded usage can still be observed if later choice/content
|
||||
checks fail; invalid framing or a non-success error body contributes none.
|
||||
Existing successful-result accounting remains value-based.
|
||||
|
||||
The captured provider selects additional response details and authentication
|
||||
diagnostic defaults. Optional new reasoning, cache-write, and OpenRouter cost
|
||||
fields are decoded independently, without relaxing common-field or framing
|
||||
validation. Cost remains an optional raw amount at this boundary; shared
|
||||
accounting applies configured-zero fallback after dispatch. The integration
|
||||
contract specifies the [wire mappings](../integrations/openai-compatible-chat.md#response-handling)
|
||||
and [probe recognition](../integrations/openai-compatible-chat.md#explicit-smoke-diagnostics).
|
||||
|
||||
For a non-success response, `ProviderHTTPError` retains the HTTP status and
|
||||
only normalized detail from the bounded recognized envelope. It retains
|
||||
`ErrUnexpectedStatus` through unwrapping. The client owns response closure;
|
||||
|
||||
Reference in New Issue
Block a user