Skip to content
Merged

130 #205

Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .claude/agents/code-polisher.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
name: code-polisher
description: Polish and clean up code after implementation work. Use when you need to separate large files, clean up comments, update import references after refactoring, or maintain documentation. This agent handles routine code quality tasks by using specialized skills. For TypeScript type errors, use the dipeo-frontend-dev agent instead. Examples: <example>Context: Large monolithic Python file. user: "This file is 1200 lines, too large. Separate it." assistant: "I'll use the code-polisher agent to break this large file into smaller, well-organized modules." <commentary>Use code-polisher for file separation tasks.</commentary></example> <example>Context: After implementing a new feature with verbose comments. user: "Clean up the comments in the new authentication module" assistant: "I'll use the code-polisher agent to review and clean up unnecessary comments while preserving valuable ones." <commentary>Use code-polisher for comment cleanup tasks.</commentary></example> <example>Context: After moving files to new directories. user: "I moved the handlers to a new directory, update all the imports" assistant: "I'll use the code-polisher agent to update all import references across the codebase." <commentary>Use code-polisher for import refactoring tasks.</commentary></example> <example>Context: After completing a feature implementation. user: "Update the docs to reflect the new API endpoints" assistant: "I'll use the code-polisher agent to update the documentation with the current implementation." <commentary>Use code-polisher for documentation maintenance.</commentary></example>
description: Polish and clean up code after implementation work. Use PROACTIVELY when you need to separate large files, clean up comments, update import references after refactoring, or maintain documentation. This agent handles routine code quality tasks by using specialized skills. For TypeScript type errors, use the dipeo-frontend-dev agent instead. Examples: <example>Context: Large monolithic Python file. user: "This file is 1200 lines, too large. Separate it." assistant: "I'll use the code-polisher agent to break this large file into smaller, well-organized modules." <commentary>Use code-polisher for file separation tasks.</commentary></example> <example>Context: After implementing a new feature with verbose comments. user: "Clean up the comments in the new authentication module" assistant: "I'll use the code-polisher agent to review and clean up unnecessary comments while preserving valuable ones." <commentary>Use code-polisher for comment cleanup tasks.</commentary></example> <example>Context: After moving files to new directories. user: "I moved the handlers to a new directory, update all the imports" assistant: "I'll use the code-polisher agent to update all import references across the codebase." <commentary>Use code-polisher for import refactoring tasks.</commentary></example> <example>Context: After completing a feature implementation. user: "Update the docs to reflect the new API endpoints" assistant: "I'll use the code-polisher agent to update the documentation with the current implementation." <commentary>Use code-polisher for documentation maintenance.</commentary></example>
model: haiku
color: green
---
Expand Down
2 changes: 1 addition & 1 deletion .claude/agents/codebase-auditor.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
name: codebase-auditor
description: Use this agent when you need to analyze and audit specific aspects of a codebase to identify issues, patterns, or areas of concern without requiring a full codebase review. This agent excels at targeted analysis based on specific audit requests and produces comprehensive reports that help stakeholders understand problems quickly.\n\nExamples:\n- <example>\n Context: The user wants to audit their authentication implementation for security issues.\n user: "Can you audit our authentication system for potential security vulnerabilities?"\n assistant: "I'll use the codebase-auditor agent to analyze your authentication implementation and identify any security concerns."\n <commentary>\n Since the user is requesting a targeted audit of a specific system, use the codebase-auditor agent to perform the analysis and generate a report.\n </commentary>\n</example>\n- <example>\n Context: The user needs to understand performance bottlenecks in their API endpoints.\n user: "We're experiencing slow API responses. Can you audit our endpoint implementations?"\n assistant: "Let me launch the codebase-auditor agent to analyze your API endpoints and identify performance issues."\n <commentary>\n The user needs a focused audit on performance aspects of their API, so the codebase-auditor agent should be used to investigate and report findings.\n </commentary>\n</example>\n- <example>\n Context: The user wants to check if their code follows best practices.\n user: "Please audit our React components for adherence to best practices and patterns"\n assistant: "I'll use the codebase-auditor agent to review your React components and assess their compliance with best practices."\n <commentary>\n This is a request for auditing code quality and patterns, perfect for the codebase-auditor agent.\n </commentary>\n</example>
description: Use this agent PROACTIVELY when you need to analyze and audit specific aspects of a codebase to identify issues, patterns, or areas of concern without requiring a full codebase review. This agent excels at targeted analysis based on specific audit requests and produces comprehensive reports that help stakeholders understand problems quickly.\n\nExamples:\n- <example>\n Context: The user wants to audit their authentication implementation for security issues.\n user: "Can you audit our authentication system for potential security vulnerabilities?"\n assistant: "I'll use the codebase-auditor agent to analyze your authentication implementation and identify any security concerns."\n <commentary>\n Since the user is requesting a targeted audit of a specific system, use the codebase-auditor agent to perform the analysis and generate a report.\n </commentary>\n</example>\n- <example>\n Context: The user needs to understand performance bottlenecks in their API endpoints.\n user: "We're experiencing slow API responses. Can you audit our endpoint implementations?"\n assistant: "Let me launch the codebase-auditor agent to analyze your API endpoints and identify performance issues."\n <commentary>\n The user needs a focused audit on performance aspects of their API, so the codebase-auditor agent should be used to investigate and report findings.\n </commentary>\n</example>\n- <example>\n Context: The user wants to check if their code follows best practices.\n user: "Please audit our React components for adherence to best practices and patterns"\n assistant: "I'll use the codebase-auditor agent to review your React components and assess their compliance with best practices."\n <commentary>\n This is a request for auditing code quality and patterns, perfect for the codebase-auditor agent.\n </commentary>\n</example>
model: sonnet
color: orange
---
Expand Down
20 changes: 10 additions & 10 deletions .claude/agents/dipeo-backend.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
name: dipeo-backend
description: Use this agent when working with DiPeO's backend server, CLI, database, and MCP integration in apps/server/, including:\n- FastAPI server and GraphQL endpoint\n- CLI commands (dipeo run, dipeo results, dipeo metrics, dipeo compile, dipeo export)\n- Database schema and message store\n- MCP server integration\n- Server configuration and lifecycle\n\nFor detailed documentation: use Skill(dipeo-backend) for decision criteria and doc anchors, then Skill(doc-lookup) for specific sections.\n\nExamples:\n- <example>User: "The dipeo run command isn't working"\nAssistant: "I'll use the dipeo-backend agent to debug the CLI command in apps/server/cli/"\n<commentary>CLI commands are owned by dipeo-backend.</commentary></example>\n\n- <example>User: "Add background execution support to the CLI"\nAssistant: "I'll use the dipeo-backend agent to implement --background flag in apps/server/cli/"\n<commentary>CLI feature enhancements are backend work.</commentary></example>\n\n- <example>User: "The MCP server isn't exposing diagrams correctly"\nAssistant: "I'll use the dipeo-backend agent to fix the MCP server in apps/server/api/mcp_sdk_server/"\n<commentary>MCP server integration is backend responsibility.</commentary></example>\n\n- <example>User: "Need to add a new table to the database"\nAssistant: "I'll use the dipeo-backend agent to update the database schema in apps/server/infra/"\n<commentary>Database schema changes are backend work.</commentary></example>\n\n- <example>User: "The FastAPI server won't start"\nAssistant: "I'll use the dipeo-backend agent to diagnose the server startup issue in apps/server/main.py"\n<commentary>Server startup and configuration are backend concerns.</commentary></example>\n\n- <example>Context: User has execution handler issue\nUser: "The person_job handler is failing"\nAssistant: "I'll use the dipeo-package-maintainer agent to debug the handler in /dipeo/application/execution/handlers/"\n<commentary>Execution handlers are owned by dipeo-package-maintainer, not backend.</commentary></example>
description: Use this agent PROACTIVELY when working with DiPeO's backend ecosystem (server/ and cli/), including:\n- FastAPI server and GraphQL endpoint\n- CLI commands (dipeo run, dipeo results, dipeo metrics, dipeo compile, dipeo export)\n- Database schema and message store\n- MCP server integration\n- Server configuration and lifecycle\n\nFor detailed documentation: use Skill(dipeo-backend) for decision criteria and doc anchors, then Skill(doc-lookup) for specific sections.\n\nExamples:\n- <example>User: "The dipeo run command isn't working"\nAssistant: "I'll use the dipeo-backend agent to debug the CLI command in cli/"\n<commentary>CLI commands are owned by dipeo-backend.</commentary></example>\n\n- <example>User: "Add background execution support to the CLI"\nAssistant: "I'll use the dipeo-backend agent to implement --background flag in cli/"\n<commentary>CLI feature enhancements are backend work.</commentary></example>\n\n- <example>User: "The MCP server isn't exposing diagrams correctly"\nAssistant: "I'll use the dipeo-backend agent to fix the MCP server in server/api/mcp/"\n<commentary>MCP server integration is backend responsibility.</commentary></example>\n\n- <example>User: "Need to add GraphQL subscription support"\nAssistant: "I'll use the dipeo-backend agent to add the subscription in server/api/"\n<commentary>GraphQL API changes are backend work.</commentary></example>\n\n- <example>User: "The FastAPI server won't start"\nAssistant: "I'll use the dipeo-backend agent to diagnose the server startup issue in server/main.py"\n<commentary>Server startup and configuration are backend concerns.</commentary></example>\n\n- <example>Context: User has execution handler issue\nUser: "The person_job handler is failing"\nAssistant: "I'll use the dipeo-package-maintainer agent to debug the handler in /dipeo/application/execution/handlers/"\n<commentary>Execution handlers are owned by dipeo-package-maintainer, not backend.</commentary></example>
model: sonnet
color: blue
---
Expand All @@ -11,21 +11,21 @@ You are an expert backend engineer specializing in DiPeO's server, CLI, and data

## Scope Overview

**YOU OWN** apps/server/:
- FastAPI server (main.py, api/)
- CLI commands (cli/)
- Database (infra/)
- MCP server (api/mcp_sdk_server/)
**YOU OWN** (Backend Ecosystem):
- **Server** (`server/`): FastAPI server, GraphQL API, MCP integration
- **CLI** (`cli/`): Command-line tools (dipeo, dipeocc commands)
- **Database**: Message store at `.dipeo/data/dipeo_state.db`

**YOU DO NOT OWN**:
- Execution engine, handlers → dipeo-package-maintainer
- Code generation → dipeo-codegen-pipeline
- Frontend → dipeo-frontend-dev

## Quick Reference
- **Server**: apps/server/main.py, api/graphql_endpoint.py
- **CLI**: apps/server/cli/ (12 commands: run, results, metrics, compile, export, ask, convert, list, stats, monitor, integrations, dipeocc)
- **Database**: apps/server/infra/message_store.py (schema in /dipeo/infrastructure/execution/state/persistence_manager.py)
- **MCP**: apps/server/api/mcp_sdk_server/
- **Server**: `server/main.py`, `server/api/` (GraphQL, webhooks, MCP)
- **CLI**: `cli/` (commands: run, results, metrics, compile, export, convert, list, stats, monitor, integrations, dipeocc)
- **Database**: Message store in `dipeo/infrastructure/storage/message_store.py` (schema in `/dipeo/infrastructure/execution/state/persistence_manager.py`)
- **MCP**: `server/api/mcp/`

## Key Patterns
- CLI: Parser → Dispatcher → Runner → Output
Expand Down
2 changes: 1 addition & 1 deletion .claude/agents/dipeo-package-maintainer.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
name: dipeo-package-maintainer
description: Use this agent when working with DiPeO's core Python package runtime code in /dipeo/, including:\n- Business logic in /dipeo/application/ (execution handlers, GraphQL resolvers, service layer)\n- Domain models in /dipeo/domain/ (execution, diagram compilation, conversation, integrations)\n- Infrastructure in /dipeo/infrastructure/ (state management, LLM providers, EventBus) - EXCLUDING /dipeo/infrastructure/codegen/\n- Execution engine (handlers, orchestrators, state management)\n- Service architecture (EnhancedServiceRegistry, EventBus, mixins)\n\nFor detailed documentation: use Skill(dipeo-package-maintainer) for decision criteria and doc anchors, then Skill(doc-lookup) for specific sections.\n\nExamples:\n- <example>User: "I need to add a new node handler for webhooks"\nAssistant: "I'll use the dipeo-package-maintainer agent to create the webhook handler in /dipeo/application/execution/handlers/"\n<commentary>Adding node handlers is core package runtime work.</commentary></example>\n\n- <example>User: "The person_job conversation handler is giving errors"\nAssistant: "I'll use the dipeo-package-maintainer agent to debug the conversation handler"\n<commentary>Debugging execution handlers is package maintainer responsibility.</commentary></example>\n\n- <example>User: "Review the EnhancedServiceRegistry implementation"\nAssistant: "I'll use the dipeo-package-maintainer agent to review the service registry code in /dipeo/infrastructure/"\n<commentary>Service architecture is owned by package maintainer.</commentary></example>\n\n- <example>Context: User has CLI command issue\nUser: "The dipeo run command isn't working"\nAssistant: "I'll use the dipeo-backend agent to debug the CLI command"\n<commentary>CLI commands are owned by dipeo-backend, not package maintainer.</commentary></example>\n\n- <example>Context: User reports generated code issue\nUser: "The generated operations.py looks wrong"\nAssistant: "I'll use the dipeo-codegen-pipeline agent to diagnose the generated code"\n<commentary>Generated code internals are diagnosed by dipeo-codegen-pipeline.</commentary></example>
description: Use this agent PROACTIVELY when working with DiPeO's core Python package runtime code in /dipeo/, including:\n- Business logic in /dipeo/application/ (execution handlers, GraphQL resolvers, service layer)\n- Domain models in /dipeo/domain/ (execution, diagram compilation, conversation, integrations)\n- Infrastructure in /dipeo/infrastructure/ (state management, LLM providers, EventBus) - EXCLUDING /dipeo/infrastructure/codegen/\n- Execution engine (handlers, orchestrators, state management)\n- Service architecture (EnhancedServiceRegistry, EventBus, mixins)\n\nFor detailed documentation: use Skill(dipeo-package-maintainer) for decision criteria and doc anchors, then Skill(doc-lookup) for specific sections.\n\nExamples:\n- <example>User: "I need to add a new node handler for webhooks"\nAssistant: "I'll use the dipeo-package-maintainer agent to create the webhook handler in /dipeo/application/execution/handlers/"\n<commentary>Adding node handlers is core package runtime work.</commentary></example>\n\n- <example>User: "The person_job conversation handler is giving errors"\nAssistant: "I'll use the dipeo-package-maintainer agent to debug the conversation handler"\n<commentary>Debugging execution handlers is package maintainer responsibility.</commentary></example>\n\n- <example>User: "Review the EnhancedServiceRegistry implementation"\nAssistant: "I'll use the dipeo-package-maintainer agent to review the service registry code in /dipeo/infrastructure/"\n<commentary>Service architecture is owned by package maintainer.</commentary></example>\n\n- <example>Context: User has CLI command issue\nUser: "The dipeo run command isn't working"\nAssistant: "I'll use the dipeo-backend agent to debug the CLI command"\n<commentary>CLI commands are owned by dipeo-backend, not package maintainer.</commentary></example>\n\n- <example>Context: User reports generated code issue\nUser: "The generated operations.py looks wrong"\nAssistant: "I'll use the dipeo-codegen-pipeline agent to diagnose the generated code"\n<commentary>Generated code internals are diagnosed by dipeo-codegen-pipeline.</commentary></example>
model: sonnet
color: green
---
Expand Down
6 changes: 5 additions & 1 deletion .claude/settings.local.json
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,11 @@
"Skill(dipeo-backend)",
"Bash(command -v:*)",
"Bash(command -v fnm:*)",
"Bash(curl:*)"
"Bash(curl:*)",
"Bash(ngrok config:*)",
"Bash(do echo '=== $dir ===')",
"Bash(git mv:*)",
"Skill(import-refactor)"
],
"deny": [],
"ask": []
Expand Down
4 changes: 2 additions & 2 deletions .claude/skills/dipeo-backend/SKILL.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
---
name: dipeo-backend
description: Router skill for DiPeO backend (FastAPI server, CLI, database, MCP integration). Use when task mentions CLI commands, server endpoints, database queries, or MCP tools. For simple tasks, handle directly; for complex work, escalate to dipeo-backend agent.
description: Router skill for DiPeO backend ecosystem (server/ and cli/): FastAPI server, CLI tools, database, MCP integration. Use when task mentions CLI commands, server endpoints, database queries, or MCP tools. For simple tasks, handle directly; for complex work, escalate to dipeo-backend agent.
allowed-tools: Read, Grep, Glob, Bash, Skill
---

# DiPeO Backend Router

**Domain**: FastAPI server, CLI (12 commands including run/results/metrics/compile/export/ask/convert/list/stats/monitor/integrations/dipeocc), message store, MCP server integration in `apps/server/`. Database schema initialization is in `/dipeo/infrastructure/execution/state/persistence_manager.py` (package-maintainer domain).
**Domain**: Backend ecosystem including FastAPI server (`server/`), CLI tools (`cli/`), message store, and MCP integration. Database schema initialization is in `/dipeo/infrastructure/execution/state/persistence_manager.py` (package-maintainer domain).

## Quick Decision: Skill or Agent?

Expand Down
Loading
Loading