feat(core): render CodeMode catalog deltas from structured snapshots (#38183)

This commit is contained in:
Aiden Cline 2026-07-24 10:20:26 -05:00 committed by GitHub
commit 4605308be2
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
19 changed files with 565 additions and 431 deletions

View file

@ -1,6 +1,7 @@
export * as CodeMode from "./codemode"
import { Context, Effect, Layer, Scope } from "effect"
import { CodeModeCatalog } from "./codemode/catalog"
import { makeLocationNode } from "@opencode-ai/util/effect/app-node"
import { PermissionV2 } from "./permission"
import { ExecuteTool } from "./tool/execute"
@ -9,7 +10,7 @@ import { Wildcard } from "./util/wildcard"
export interface Materialization {
readonly tool?: Any
readonly instructions?: string
readonly catalog?: ReadonlyArray<CodeModeCatalog.Entry>
}
export interface Interface {
@ -67,7 +68,7 @@ const layer = Layer.effect(
if (executeRule?.resource === "*" && executeRule.effect === "deny") return {}
return {
tool: ExecuteTool.create(registrations),
instructions: ExecuteTool.instructions(registrations),
catalog: ExecuteTool.catalog(registrations),
}
}),
})