mirror of
https://github.com/anomalyco/opencode.git
synced 2026-05-25 14:55:28 +00:00
Aligns the escape-hatch field name with `LLMEvent.providerMetadata` used
elsewhere in this package (and with AI SDK / pydantic-ai / LangChain
conventions for the same idea). Two parallel escape hatches having
different names was a wart.
The raw payload is now wrapped under the provider key — `{ openai: ... }`,
`{ anthropic: ... }`, `{ google: ... }`, `{ bedrock: ... }` — using the
existing `ProviderMetadata = Record<string, Record<string, unknown>>`
schema rather than a flat record. Same shape as
`LLMEvent.providerMetadata`, so consumers downstream can read both with
the same code.
Anthropic's `mergeUsage` merges the per-provider sub-record across
`message_start` and `message_delta` instead of spreading at the top level.
|
||
|---|---|---|
| .. | ||
| app | ||
| console | ||
| containers | ||
| core | ||
| desktop | ||
| docs | ||
| enterprise | ||
| extensions/zed | ||
| function | ||
| http-recorder | ||
| identity | ||
| llm | ||
| opencode | ||
| plugin | ||
| script | ||
| sdk | ||
| slack | ||
| storybook | ||
| ui | ||
| web | ||