fix(llm): restore OpenAI reasoning streams (#28552)

This commit is contained in:
Kit Langton
2026-05-20 21:02:59 -04:00
committed by GitHub
parent 93131b6e4c
commit 16fb6dac8d
9 changed files with 172 additions and 15 deletions
+3 -2
View File
@@ -1,5 +1,5 @@
import type { HttpRecorder } from "@opencode-ai/http-recorder"
import { describe, type TestOptions } from "bun:test"
import { describe } from "bun:test"
import { Effect } from "effect"
import type { Model } from "../src"
import { goldenScenarioTags, runGoldenScenario, type GoldenScenarioID } from "./recorded-scenarios"
@@ -17,7 +17,7 @@ type ScenarioInput =
readonly tags?: ReadonlyArray<string>
readonly maxTokens?: number
readonly temperature?: number | false
readonly timeout?: number | TestOptions
readonly timeout?: number
}
type TargetInput = {
@@ -38,6 +38,7 @@ const scenarioInput = (input: ScenarioInput) => (typeof input === "string" ? { i
const scenarioTitle = (id: GoldenScenarioID) => {
if (id === "text") return "streams text"
if (id === "tool-call") return "streams tool call"
if (id === "reasoning") return "uses reasoning"
if (id === "image") return "reads image text"
return "drives a tool loop"
}