

Also from Kynth Studios


Also from Kynth Studios


Also from Kynth Studios
1# Core Tool Architecture23This folder owns Core's one local tool representation, process and Location registration, effective lookup, and settlement.45## Representations67- `tool.ts` defines the opaque canonical `Tool.make({ description, input, output, execute, toModelOutput })` value. Application tools and shipped built-ins use the same type.8- `application-tools.ts` stores process-scoped application registrations.9- `tools.ts` exposes the registration-only `Tools.Service` view used by Location producers.10- `registry.ts` stores only canonical tools, overlays Location registrations over application registrations, derives definitions, invokes tools, and applies generic output bounding.1112Do not add a second executable entry type, registry-owned executor, authorization callback, output-path callback, or legacy normalization path.1314## Construction1516Tool schemas and projection use `input` and `output` terminology. A tool value is opaque: its codecs, executor, definition derivation, and catalog permission declaration are private runtime details.1718Location-scoped built-in layers acquire `PermissionV2.Service` and every other required Location service while the layer is constructed. The executor captures those services. Permission sources are always constructed from the canonical invocation context:1920```ts21const source = {22 type: "tool" as const,23 messageID: context.assistantMessageID,24 callID: context.toolCallID,25}26```2728Leaves own resolution, permission, and side-effect ordering. Translate only expected typed errors into `ToolFailure`; do not use `catchCause`, because interruption and defects must survive.2930## Registration3132Built-ins register through `Tools.Service.register({ [name]: tool })`. Application tools register through `ApplicationTools.Service.register(...)`, exposed publicly as `opencode.tools.register(...)`.3334Both are scoped:3536- The latest active same-placement registration wins.37- Closing any registration removes only that registration and reveals the next active one.38- Location registrations take precedence over application registrations.39- An invocation captures the effective tool once settlement starts.4041`ApplicationTools.Service` is process-scoped and shared by all Locations. `ToolRegistry.Service` is Location-scoped. Do not make the registry process-global or construct a separate application-tool service for each Location.4243## Permissions4445The registry has no `PermissionV2.Service` dependency and performs no execution authorization. An internal built-in-only operation attaches a permission action solely to preserve whole-tool definition filtering; it is not part of public `Tool.make`. Most tools default to their registered name; `edit`, `write`, and `apply_patch` declare the shared `edit` action.4647Definition filtering is catalog visibility, not execution authorization. A call still executes the captured leaf policy if it reaches settlement.4849## Output5051Built-ins return complete validated domain output. `ToolRegistry.Materialization.settle` is the only execution and generic model-output bounding boundary and owns managed retention paths.5253Producer capture limits are separate. For example, Bash keeps `AppProcess.maxOutputBytes` and accurately reports stdout/stderr capture loss, but it does not run model-output truncation or return a managed `outputPath`.5455## Current Gaps5657- Plugin boot has not been redesigned to register canonical tools through `Tools.Service`; do not redesign it as part of leaf migrations.58- MCP and future Session-scoped registrations still need an explicit canonical registration design.59- The public Session result shape currently exposes managed `outputPaths`; full storage encapsulation requires a future opaque managed-output reference design.60
One repository carrying more than one format is the comparison this product exists for: does anyone actually write different content in each file, or is one a copy of the other?
| Repository | Format | Stack | Covers | Score | Changed |
|---|---|---|---|---|---|
| anomalyco/opencodeAGENTS.md · 195k | AGENTS.md | testlint-formatstyletypes+3 | 80/100 | 14 days ago | |
| anomalyco/opencodepackages/app/AGENTS.md · 195k | AGENTS.md | style | 60/100 | 8 days ago | |
| anomalyco/opencodepackages/app/e2e/AGENTS.md · 195k | AGENTS.md | teststyledo-not | 54/100 | 9 days ago | |
| anomalyco/opencodepackages/app/e2e/performance/AGENTS.md · 195k | AGENTS.md | no sections | 16/100 | 14 days ago | |
| anomalyco/opencodepackages/codemode/AGENTS.md · 195k | AGENTS.md | api | 43/100 | 14 days ago | |
| anomalyco/opencodepackages/desktop/AGENTS.md · 195k | AGENTS.md | style | 34/100 | 8 days ago | |
| anomalyco/opencodepackages/effect-drizzle-sqlite/AGENTS.md · 195k | AGENTS.md | database | 38/100 | 14 days ago | |
| anomalyco/opencodepackages/llm/AGENTS.md · 195k | AGENTS.md | stylearchtesting-strategygit+1 | 57/100 | 14 days ago | |
| anomalyco/opencodepackages/opencode/src/server/routes/instance/httpapi/AGENTS.md · 195k | AGENTS.md | styleapi | 40/100 | 14 days ago | |
| anomalyco/opencodepackages/opencode/test/AGENTS.md · 195k | AGENTS.md | teststylearchtesting-strategy+1 | 81/100 | 14 days ago | |
| anomalyco/opencodepackages/opencode/test/server/AGENTS.md · 195k | AGENTS.md | teststyleapi | 38/100 | 14 days ago | |
| anomalyco/opencodepackages/schema/AGENTS.md · 195k | AGENTS.md | styletypesdatabaseapi+1 | 65/100 | 14 days ago | |
| anomalyco/opencodepackages/session-ui/AGENTS.md · 195k | AGENTS.md | no sections | 30/100 | 11 days ago | |
| anomalyco/opencodepackages/ui/AGENTS.md · 195k | AGENTS.md | style | 34/100 | 8 days ago | |
| anomalyco/opencodepackages/opencode/AGENTS.md · 195k | AGENTS.md | styledatabaseapido-not | 81/100 | 14 days ago | |
| anomalyco/opencodepackages/opencode/src/session/llm/AGENTS.md · 195k | AGENTS.md | arch | 61/100 | 14 days ago |
Same format, overlapping stack, ranked by quality.
| Repository | Format | Stack | Covers | Score | Changed |
|---|---|---|---|---|---|
| elastic/elasticsearchx-pack/plugin/inference/AGENTS.md · 78k | AGENTS.md | buildtestlint-formatstyle+3 | 100/100 | 14 days ago | |
| code-yeongyu/oh-my-openagentpackages/web/AGENTS.md · 67k | AGENTS.md | setupbuildtestlint-format+6 | 100/100 | 13 days ago | |
| TryGhost/Ghoste2e/AGENTS.md · 55k | AGENTS.md | setupteststylearch+2 | 100/100 | 14 days ago | |
| n8n-io/n8npackages/@n8n/agents/AGENTS.md · 200k | AGENTS.md | buildteststylearch+3 | 100/100 | 14 days ago | |
| bagisto/bagistoAGENTS.md · 28k | AGENTS.md | setupbuildteststyle+7 | 100/100 | 7 days ago | |
| duckduckgo/content-scope-scriptsspecial-pages/AGENTS.md · 70 | AGENTS.md | buildteststylearch+3 | 100/100 | 14 days ago | |
| aaif-goose/gooseAGENTS.md · 53k | AGENTS.md | setupbuildtestlint-format+7 | 100/100 | 8 days ago | |
| trick77/agents-md-syncAGENTS.md · 2 | AGENTS.md | setupbuildteststyle+5 | 100/100 | 14 days ago |
A badge carrying the measured quality of the strongest agent config file in this repository, out of 100. It reads from this index every time somebody loads your page, so it changes when the measurement changes and there is nothing to keep up to date. Free, no account, and the value is not something you or we can set by hand.
[](https://rulestack.kynth.studio/configs/anomalyco-opencode-packages-core-src-tool-agents)Would rather not hotlink us? Every badge is also served in shields.io’s endpoint schema, so shields renders the image and your readers never talk to our domain:
Published by Toolproof, the masthead over this index and eight others. The method behind the number is at toolproof.kynth.studio/methodology, and the whole thing is readable as JSON with no key at /api.