MCPcopy Index your code
hub / github.com/anomalyco/opencode / decodeBody

Function decodeBody

packages/llm/test/generate-object.test.ts:27–27  ·  view source on GitHub ↗
(text: string)

Source from the content-addressed store, hash-verified

25const Json = Schema.fromJsonString(Schema.Unknown)
26const decodeJson = Schema.decodeUnknownSync(Json)
27const decodeBody = (text: string): OpenAIChatBody => decodeJson(text) as OpenAIChatBody
28
29describe("Tool.make (dynamic JSON Schema)", () => {
30 test("forwards JSON Schema and description through toDefinitions", () => {

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected