refactor(core): move v1 schemas into core (#30473)

This commit is contained in:
Dax
2026-06-02 22:42:13 -04:00
committed by GitHub
parent 0543fd29c8
commit 83452558f7
129 changed files with 1578 additions and 1227 deletions

View File

@@ -1,4 +1,4 @@
import type { SessionLegacy } from "@opencode-ai/core/session/legacy"
import type { SessionV1 } from "@opencode-ai/core/v1/session"
export { parseGitHubRemote } from "@/util/repository"
@@ -7,7 +7,7 @@ export { parseGitHubRemote } from "@/util/repository"
* Returns null for non-text responses (signals summary needed).
* Throws only for truly empty responses.
*/
export function extractResponseText(parts: SessionLegacy.Part[]): string | null {
export function extractResponseText(parts: SessionV1.Part[]): string | null {
const textPart = parts.findLast((p) => p.type === "text")
if (textPart) return textPart.text