chore: generate

This commit is contained in:
opencode-agent[bot] 2026-06-09 18:30:51 +00:00
commit cc52dc396c
20 changed files with 221 additions and 169 deletions

View file

@ -91,9 +91,7 @@ console.log("--- Search service (warm) ---")
for (const q of FILE_QUERIES) {
const t = performance.now()
const r = await run(Search.Service.use((svc) => svc.file({ cwd: dir, query: q, limit: FILE_LIMIT })))
console.log(
`[Search.file] "${q}": ${(performance.now() - t).toFixed(1)}ms (${r.length} results)`,
)
console.log(`[Search.file] "${q}": ${(performance.now() - t).toFixed(1)}ms (${r.length} results)`)
}
for (const q of GREP_QUERIES) {

View file

@ -38,9 +38,7 @@ const FileReadCommand = effectCmd({
description: "File path to read",
}),
handler: Effect.fn("Cli.debug.file.read")(function* (args) {
const content = yield* filesystem(
FileSystem.Service.use((svc) => svc.read({ path: RelativePath.make(args.path) })),
)
const content = yield* filesystem(FileSystem.Service.use((svc) => svc.read({ path: RelativePath.make(args.path) })))
process.stdout.write(JSON.stringify(content, null, 2) + EOL)
}),
})
@ -55,9 +53,7 @@ const FileListCommand = effectCmd({
description: "File path to list",
}),
handler: Effect.fn("Cli.debug.file.list")(function* (args) {
const files = yield* filesystem(
FileSystem.Service.use((svc) => svc.list({ path: RelativePath.make(args.path) })),
)
const files = yield* filesystem(FileSystem.Service.use((svc) => svc.list({ path: RelativePath.make(args.path) })))
process.stdout.write(JSON.stringify(files, null, 2) + EOL)
}),
})

View file

@ -595,13 +595,14 @@ export const layer = Layer.effect(
const assistantMessageID = yield* requireV2AssistantMessage(toolCall?.call)
const content = [
{ type: "text" as const, text: output.output },
...(output.attachments?.map((item: SessionV1.FilePart) =>
({
type: "file",
uri: item.url,
mime: item.mime,
name: item.filename,
}) as const,
...(output.attachments?.map(
(item: SessionV1.FilePart) =>
({
type: "file",
uri: item.url,
mime: item.mime,
name: item.filename,
}) as const,
) ?? []),
]
const unsupported = content.find((item) => item.type === "file" && !item.uri.startsWith("data:"))