mirror of
https://github.com/anomalyco/opencode.git
synced 2026-11-29 11:42:17 +00:00
Tools take validating or render-only JSON Schemas (the Rust form of Effect Schemas and the reference's JsonSchema), render byte-identical TypeScript signatures, and report InvalidToolInput and InvalidToolOutput. Namespaces, freeform tools, the catalog, toolExpression, searchSignature and the BM25 search built-in follow tool-runtime.ts; conformance/catalog.ts regenerates the expectations from the reference. Tools and extension globals may return futures. execute_async runs on any executor; execute drives it with a small built-in block_on, and a shared timer thread enforces timeouts while host work is pending. Dropping a run cancels its calls, which after hooks see as interrupted. Extensions cross values as copies both ways, including functions in results, errors, maps and sets, and programs load them with import, require and import() by Node module name. Runtime::program adds the reference's program API with run ids. |
||
|---|---|---|
| .. | ||
| cases | ||
| catalog.json | ||
| catalog.ts | ||
| generate.ts | ||