Phase 12: Tool registry — governed business actions for AI agents

- ToolRegistry: named tools with parameter validation and audit logging
- 6 built-in staffing tools:
  search_candidates (skills, city, state, experience, availability)
  get_candidate (by ID)
  revenue_by_client (top N by billed revenue)
  recruiter_performance (placements, revenue per recruiter)
  cold_leads (called N+ times, never placed)
  open_jobs (by vertical, city)
- Each tool: name, description, params, permission level (read/write/admin)
- SQL template with validated parameter substitution
- Full audit trail: every invocation logged with agent, params, result
- Endpoints: GET /tools (list), GET /tools/{name} (schema),
  POST /tools/{name}/call (execute), GET /tools/audit (log)
- Per ADR-015: governed interface before raw SQL for agents

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
root
2026-03-27 09:31:42 -05:00
co-authored by Claude Opus 4.6
parent 6cd1daeb51
commit 6f0f92a9e4
6 changed files with 484 additions and 2 deletions
Generated
+2
View File
@@ -2373,8 +2373,10 @@ name = "gateway"
version = "0.1.0"
dependencies = [
"aibridge",
"arrow",
"axum",
"catalogd",
"chrono",
"ingestd",
"journald",
"object_store",