feat: agent tool parity, Tools panel and the tools-per-module rule (CLEAN-109) - #101
Merged
Merged
Conversation
…N-109) Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Every @tool declares topic, title and a starter template; the registry refuses to boot without them, and a destructive tool must take a boolean confirm. All 59 existing tools annotated; shared tool helpers in mcp/tooling.ts. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
…ogue (CLEAN-109) GET /agents/:id/tools lists what the agent runtime would receive, grouped by topic, with a per-tool "present in the running pod" flag from a new AgentToolListing snapshot written on tools/list. The admin composer gets a Tools button: accordions per topic, search, one-click starter templates, "after restart" markers with a restart button. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
docs/agent-tools.md is the canonical rule (a module ships its agent tools with tests); CLAUDE.md states it; the graft skill carries a fenced pointer that scripts/ensure-agent-tools-rule.mjs re-inserts after graft init; the PR template asks for the parity check. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
93 new tools across 20 slices, each beside the controller it mirrors and calling the same services: agents, workspace, templates, skills, LLM credentials, MCP servers and OAuth, knowledge bases and sources, settings (with a key catalogue), paddock, users, API keys, chats, usage, integrations, upgrade and Rancher status. Operator-only tools are hidden from plain agents, destructive ones require confirm: true, and a cross-cutting spec proves no result carries a secret. A boot-equivalent spec validates every tool file the way the registry does at start. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
…underlines (CLEAN-109) An untouched sheet opens the first topic; once the person collapses it, the empty choice stays instead of reopening. The hover underline no longer runs under the count and the after-restart badge. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
…LEAN-109) The button moves out of the composer: on the agent page it sits in the header action row, on the Rancher page in the chat card header. The sheet stays with the composer, which owns the draft; the store carries which agent has it open. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
…' into feat/CLEAN-109-agent-tool-parity
…plate (CLEAN-109) Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Restores the Ranch philosophy that the console is a window and the chat is the hands: everything the admin console can do, the Ranch admin agent can now do through a tool, and a person can see those tools from the chat.
Ticket: CLEAN-109
Three parts (spec, plan and audit in
specs/016-agent-tool-parity/):GET /agents/:id/toolsreturns exactly what that agent's runtime would receive (one shared listing implementation with MCPtools/list). A newAgentToolListingrow records what each pod was last told, so tools added after a pod started show "after restart" with a restart button.@Toolnow requirestopic,titleandtemplate, and a destructive tool a booleanconfirm; the API refuses to boot otherwise.docs/agent-tools.mdis the canonical rule,CLAUDE.mdstates it, the graft skill carries a pointer thatscripts/ensure-agent-tools-rule.mjsre-inserts aftergraft init, and the new PR template asks for the parity check.Decisions from the ticket discussion: full parity including users, keys and deletes (operator-only,
confirm: trueon 30 destructive tools); the panel shows the live per-agent list; existing tool names unchanged.Test plan
cd api && NODE_OPTIONS=--experimental-vm-modules npx jest— 121 suites, 1592 tests green. Includesmcp/tool-metadata.spec.ts(loads every tool file and runs the boot-time validation) andmcp/tool-secrets.spec.ts(feeds every credential-taking tool a sentinel and asserts it never comes back;create_api_keyis the documented exception).cd api && bun run buildclean;bun run generate:swagger→cd admin && bun run build:apiregenerated the SDK.cd admin && bun test slices(13 new util tests) andnpx nuxt typecheckclean.specs/016-agent-tool-parity/quickstart.md§3–§6 (needs a running stack with a deployed Rancher agent). Please run it as part of review; §4 (after-restart marker) and §6 (parity prompts) are the two to watch.api/prisma/migrations/20260922120000_agent_tool_listing(additive).Checklist
CLEAN-<n>iddocs/agent-tools.md)confirm; no secret is echoed in any tool resultappstrings went throughen.json;adminstays English-onlydocs/state.md(one entity, one store, render by id)🤖 Generated with Claude Code