Daniel's Agents
Dynamic agent registry and the ask_agent dispatcher for specialized AI subagents.
Overview
Daniel's Agents is a system for registering, managing, and invoking specialized AI agents. Unlike Claude Code's built-in Task tool (which has fixed, predefined subagent types), this system allows you to:
- Register custom agents with their own MCP tools and personalities
- Route requests dynamically to any registered agent via
ask_agent - Configure agents as data - system prompts, tools, and models stored in PostgreSQL
The key insight: agents are configuration, not code. Each agent is a row in a database with its MCP servers, system prompt, and model preference. The ask_agent tool looks up the config and invokes the Claude Agent SDK.
The Agent Registry
Agents are stored in the argus.agents table:
| Field | Description |
|---|---|
id | Unique identifier (e.g., venus, sentinel) |
name | Display name |
description | What the agent does |
category | Agent type: design, qa, research, etc. |
command | CLI command for the agent |
model | Claude model to use |
config | JSONB with mcp_servers, system_prompt, permission_mode |
is_active | Whether the agent is available |
Built-in Agents
Two agents are seeded by default:
Venus (Design Specialist)
{
"mcp_servers": {
"magic": {"command": "npx", "args": ["-y", "@anthropic/magic-mcp"]},
"context7": {"command": "npx", "args": ["-y", "@upstash/context7-mcp@latest"]}
},
"system_prompt": "You are Venus, a design specialist. Help users create beautiful, accessible, and responsive UI components.",
"permission_mode": "bypassPermissions"
}
Venus has access to:
- magic-mcp: 21st.dev component library for finding UI components
- context7: Documentation lookup for frameworks
Sentinel (QA Specialist)
{
"mcp_servers": {
"playwright": {"command": "npx", "args": ["-y", "@anthropic/mcp-playwright"]},
"context7": {"command": "npx", "args": ["-y", "@upstash/context7-mcp@latest"]}
},
"system_prompt": "You are Sentinel, a QA specialist. Be skeptical. Verify everything works. Use TodoWrite to create checklists.",
"permission_mode": "bypassPermissions"
}
Sentinel has access to:
- playwright-mcp: Browser automation for E2E testing
- context7: Documentation lookup
The ask_agent Tool
The core dispatcher tool that routes requests to any registered agent:
ask_agent(agent_id="venus", request="Design a login form with email and password")
How It Works
┌─────────────────────────────────────────────────────────────┐
│ Claude Code (Main Agent) │
│ │
│ "I need a React component for user settings" │
│ │
└──────────────────────────┬────────────────────────────────────┘
│ ask_agent(agent_id="venus", request="...")
▼
┌─────────────────────────────────────────────────────────────┐
│ Janus MCP Server │
│ │
│ 1. Fetch agent config from argus.agents │
│ 2. Build ClaudeAgentOptions from stored config │
│ 3. Invoke Claude Agent SDK with config │
│ 4. Stream response back │
│ │
└──────────────────────────┬────────────────────────────────────┘
│ Agent SDK invocation
▼
┌─────────────────────────────────────────────────────────────┐
│ Venus Subagent │
│ │
│ Brain: Claude Sonnet │
│ Tools: magic-mcp, context7 │
│ Prompt: "You are Venus, a design specialist..." │
│ │
│ Returns: Component code, usage examples, dependencies │
│ │
└─────────────────────────────────────────────────────────────┘
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
agent_id | string | Yes | Agent ID to invoke (e.g., venus, sentinel) |
request | string | Yes | The task or question for the agent |
context | string | No | Additional context to include |
Example Response
{
"agent_id": "venus",
"agent_name": "Venus",
"response": "Here's a login form component using shadcn/ui..."
}
Agent Management Tools
List Agents
janus_agent_list(category="design", include_inactive=false)
Returns all registered agents, optionally filtered by category.
Get Agent Details
janus_agent_get(agent_id="venus")
Returns full agent configuration including MCP servers and system prompt.
Register New Agent
janus_agent_register(
agent_id="athena",
name="Athena",
command="athena",
description="Research specialist - documentation and best practices",
category="research",
model="claude-sonnet-4-20250514",
config={
"mcp_servers": {
"context7": {"command": "npx", "args": ["-y", "@upstash/context7-mcp@latest"]}
},
"system_prompt": "You are Athena, a research specialist. Find documentation, cite sources, distinguish facts from opinions.",
"permission_mode": "bypassPermissions"
}
)
Update Agent
janus_agent_update(
agent_id="venus",
model="claude-opus-4-20250514",
is_active=true
)
Delete Agent
janus_agent_delete(agent_id="athena")
Reeves Personas
The agent registry is also the foundation for Reeves, Daniel's personal life management system. Reeves uses personas - specialized agents for different domains:
| Persona | Role | Domain |
|---|---|---|
| Reeves | Chief of Staff | Task management, scheduling |
| Penn | Historian | Journals, reflections, mood tracking |
| Finch | Retriever | Read-only search across all domains |
| Hartley | Trainer | Fitness metrics, health logs |
| Sterling | CFO | Financial advice (reads Tally data) |
| Tally | Bookkeeper | Double-entry accounting ledger |
These personas share the same PostgreSQL backend as infrastructure agents but operate on personal data:
service_id = djs-personalfor personal tasksjournalstable for Pennhealth_logstable for Hartleytally.*schema for financial ledger
The architecture principle: personas are configuration, not separate codebases. One unified system, specialized behaviors.
API Endpoints
The agent registry is also accessible via REST API:
| Method | Endpoint | Description |
|---|---|---|
GET | /api/v1/agents | List all agents |
GET | /api/v1/agents/{id} | Get agent details |
POST | /api/v1/agents | Register new agent |
PATCH | /api/v1/agents/{id} | Update agent |
PATCH | /api/v1/agents/{id}/config | Update agent config section |
DELETE | /api/v1/agents/{id} | Delete agent |
POST | /api/v1/agents/init | Initialize table with defaults |
Comparison: Task Tool vs ask_agent
| Capability | Claude Code Task Tool | ask_agent |
|---|---|---|
| Spawn subagents | Yes | Yes |
| Custom MCP servers | No (fixed types) | Yes (any) |
| Custom system prompt | No | Yes |
| Model selection | Limited | Full |
| Tool restrictions | No | Via config |
| Agent as data | No (hardcoded) | Yes (database) |
| Dynamic registration | No | Yes |
When to Use Each
Use Task Tool when:
- You need basic exploration (
Explore) - You want implementation planning (
Plan) - The predefined types fit your needs
Use ask_agent when:
- You need custom MCP tools (magic-mcp, playwright, etc.)
- You want specialized personalities (Venus, Sentinel, etc.)
- You're building reusable agent patterns
- You need the agent configuration to be dynamic
Creating Your Own Agent
Step 1: Define the Specialty
What does this agent do better than a general-purpose agent?
| Agent | Specialty | Key Tools |
|---|---|---|
| Venus | UI/UX design | magic-mcp, context7 |
| Sentinel | QA testing | playwright, context7 |
| Athena | Research | context7, web search |
| Hermes | API integration | HTTP tools |
Step 2: Choose MCP Tools
Select tools that match the specialty. Keep it focused - fewer tools = more focused agent.
Step 3: Write the System Prompt
Define personality and constraints:
You are [Name], a [specialty] specialist.
Your role:
1. [Primary responsibility]
2. [Secondary responsibility]
You do NOT:
- [Constraint 1]
- [Constraint 2]
Return [expected output format].
Step 4: Register the Agent
janus_agent_register(
agent_id="my-agent",
name="My Agent",
command="my-agent",
description="What this agent does",
category="category",
config={
"mcp_servers": {...},
"system_prompt": "...",
"permission_mode": "bypassPermissions"
}
)
Step 5: Invoke It
ask_agent(agent_id="my-agent", request="Do the thing")
See Also
- Custom Agents - The ClaudeBox subagent pattern
- Agent HTTP API - Running agents programmatically
- Janus - Infrastructure MCP tools