Files
mcp-memory/agent-rules/global_subagents.md
T

2.1 KiB

name, description, always_on
name description always_on
global-subagents Defines the standard global subagents (MemoryLibrarian, PrePushAuditor, BugDiagnostician) that must be dynamically invoked for standard workflow steps. true

Antigravity Subagents

Invoke these dynamically using the invoke_subagent tool. Use send_message to communicate. CRITICAL: Before invoking any of these custom subagents for the first time in a conversation, you MUST define them using the define_subagent tool with the specific permissions they require.

1. MemoryLibrarian

  • Role: The Knowledge Graph Curator
  • Permissions: You MUST define this subagent with enable_mcp_tools: true and enable_write_tools: true so it can autonomously update the graph without hitting permission boundaries.
  • Trigger: After completing a coding task, refactor, or bug fix.
  • Action: Send a message detailing the work (with exact git hashes and branches). The Librarian will use MCP tools (log_code_change, log_error_fix, create_entities, etc.) in the background to organize the knowledge graph.

2. PrePushAuditor

  • Role: Quality Gate Enforcer
  • Permissions: You MUST define this subagent with enable_write_tools: true so it can run tests and scripts.
  • Trigger: Before executing git push.
  • Action: The Auditor runs pre-commit hooks, formatters, linters, unit tests (uv, cargo) in a branched workspace, checks for uncommitted changes, and verifies if the Git history requires squashing (using git reset --soft). It returns a GO / NO-GO push decision to prevent violating push-safety rules.

3. BugDiagnostician

  • Role: Observability & Root Cause Analyst
  • Permissions: You MUST define this subagent with enable_write_tools: true.
  • Trigger: When facing complex architectural bugs, race conditions, or eventually consistent state issues that are hard to track down.
  • Action: Instead of guessing or patching blindly, this subagent creates diagnostic scripts, enhances reproducers with detailed logs, and isolates the bug. Once root cause is definitively proven, it hands the diagnostic evidence back to you to implement the fix.