ag-cortex 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.agent/commands/test-browser.md +339 -0
- package/.agent/rules/00-constitution.md +46 -0
- package/.agent/rules/project-rules.md +49 -0
- package/.agent/skills/agent-browser/SKILL.md +223 -0
- package/.agent/skills/agent-native-architecture/SKILL.md +435 -0
- package/.agent/skills/agent-native-architecture/references/action-parity-discipline.md +409 -0
- package/.agent/skills/agent-native-architecture/references/agent-execution-patterns.md +467 -0
- package/.agent/skills/agent-native-architecture/references/agent-native-testing.md +582 -0
- package/.agent/skills/agent-native-architecture/references/architecture-patterns.md +478 -0
- package/.agent/skills/agent-native-architecture/references/dynamic-context-injection.md +338 -0
- package/.agent/skills/agent-native-architecture/references/files-universal-interface.md +301 -0
- package/.agent/skills/agent-native-architecture/references/from-primitives-to-domain-tools.md +359 -0
- package/.agent/skills/agent-native-architecture/references/mcp-tool-design.md +506 -0
- package/.agent/skills/agent-native-architecture/references/mobile-patterns.md +871 -0
- package/.agent/skills/agent-native-architecture/references/product-implications.md +443 -0
- package/.agent/skills/agent-native-architecture/references/refactoring-to-prompt-native.md +317 -0
- package/.agent/skills/agent-native-architecture/references/self-modification.md +269 -0
- package/.agent/skills/agent-native-architecture/references/shared-workspace-architecture.md +680 -0
- package/.agent/skills/agent-native-architecture/references/system-prompt-design.md +250 -0
- package/.agent/skills/agent-native-reviewer/SKILL.md +246 -0
- package/.agent/skills/andrew-kane-gem-writer/SKILL.md +184 -0
- package/.agent/skills/andrew-kane-gem-writer/references/database-adapters.md +231 -0
- package/.agent/skills/andrew-kane-gem-writer/references/module-organization.md +121 -0
- package/.agent/skills/andrew-kane-gem-writer/references/rails-integration.md +183 -0
- package/.agent/skills/andrew-kane-gem-writer/references/resources.md +119 -0
- package/.agent/skills/andrew-kane-gem-writer/references/testing-patterns.md +261 -0
- package/.agent/skills/ankane-readme-writer/SKILL.md +50 -0
- package/.agent/skills/architecture-strategist/SKILL.md +52 -0
- package/.agent/skills/best-practices-researcher/SKILL.md +100 -0
- package/.agent/skills/bug-reproduction-validator/SKILL.md +67 -0
- package/.agent/skills/code-simplicity-reviewer/SKILL.md +85 -0
- package/.agent/skills/coding-tutor/.claude-plugin/plugin.json +9 -0
- package/.agent/skills/coding-tutor/README.md +37 -0
- package/.agent/skills/coding-tutor/commands/quiz-me.md +1 -0
- package/.agent/skills/coding-tutor/commands/sync-tutorials.md +25 -0
- package/.agent/skills/coding-tutor/commands/teach-me.md +1 -0
- package/.agent/skills/coding-tutor/skills/coding-tutor/SKILL.md +214 -0
- package/.agent/skills/coding-tutor/skills/coding-tutor/scripts/create_tutorial.py +202 -0
- package/.agent/skills/coding-tutor/skills/coding-tutor/scripts/index_tutorials.py +203 -0
- package/.agent/skills/coding-tutor/skills/coding-tutor/scripts/quiz_priority.py +190 -0
- package/.agent/skills/coding-tutor/skills/coding-tutor/scripts/setup_tutorials.py +132 -0
- package/.agent/skills/compound-docs/SKILL.md +510 -0
- package/.agent/skills/compound-docs/assets/critical-pattern-template.md +34 -0
- package/.agent/skills/compound-docs/assets/resolution-template.md +93 -0
- package/.agent/skills/compound-docs/references/yaml-schema.md +65 -0
- package/.agent/skills/compound-docs/schema.yaml +176 -0
- package/.agent/skills/create-agent-skills/SKILL.md +299 -0
- package/.agent/skills/create-agent-skills/references/api-security.md +226 -0
- package/.agent/skills/create-agent-skills/references/be-clear-and-direct.md +531 -0
- package/.agent/skills/create-agent-skills/references/best-practices.md +404 -0
- package/.agent/skills/create-agent-skills/references/common-patterns.md +595 -0
- package/.agent/skills/create-agent-skills/references/core-principles.md +437 -0
- package/.agent/skills/create-agent-skills/references/executable-code.md +175 -0
- package/.agent/skills/create-agent-skills/references/iteration-and-testing.md +474 -0
- package/.agent/skills/create-agent-skills/references/official-spec.md +185 -0
- package/.agent/skills/create-agent-skills/references/recommended-structure.md +168 -0
- package/.agent/skills/create-agent-skills/references/skill-structure.md +372 -0
- package/.agent/skills/create-agent-skills/references/using-scripts.md +113 -0
- package/.agent/skills/create-agent-skills/references/using-templates.md +112 -0
- package/.agent/skills/create-agent-skills/references/workflows-and-validation.md +510 -0
- package/.agent/skills/create-agent-skills/templates/router-skill.md +73 -0
- package/.agent/skills/create-agent-skills/templates/simple-skill.md +33 -0
- package/.agent/skills/create-agent-skills/workflows/add-reference.md +96 -0
- package/.agent/skills/create-agent-skills/workflows/add-script.md +93 -0
- package/.agent/skills/create-agent-skills/workflows/add-template.md +74 -0
- package/.agent/skills/create-agent-skills/workflows/add-workflow.md +120 -0
- package/.agent/skills/create-agent-skills/workflows/audit-skill.md +138 -0
- package/.agent/skills/create-agent-skills/workflows/create-domain-expertise-skill.md +605 -0
- package/.agent/skills/create-agent-skills/workflows/create-new-skill.md +191 -0
- package/.agent/skills/create-agent-skills/workflows/get-guidance.md +121 -0
- package/.agent/skills/create-agent-skills/workflows/upgrade-to-router.md +161 -0
- package/.agent/skills/create-agent-skills/workflows/verify-skill.md +204 -0
- package/.agent/skills/data-integrity-guardian/SKILL.md +70 -0
- package/.agent/skills/data-migration-expert/SKILL.md +97 -0
- package/.agent/skills/deployment-verification-agent/SKILL.md +159 -0
- package/.agent/skills/design-implementation-reviewer/SKILL.md +85 -0
- package/.agent/skills/design-iterator/SKILL.md +197 -0
- package/.agent/skills/dhh-rails-reviewer/SKILL.md +45 -0
- package/.agent/skills/dhh-rails-style/SKILL.md +184 -0
- package/.agent/skills/dhh-rails-style/references/architecture.md +653 -0
- package/.agent/skills/dhh-rails-style/references/controllers.md +303 -0
- package/.agent/skills/dhh-rails-style/references/frontend.md +510 -0
- package/.agent/skills/dhh-rails-style/references/gems.md +266 -0
- package/.agent/skills/dhh-rails-style/references/models.md +359 -0
- package/.agent/skills/dhh-rails-style/references/testing.md +338 -0
- package/.agent/skills/dspy-ruby/SKILL.md +594 -0
- package/.agent/skills/dspy-ruby/assets/config-template.rb +359 -0
- package/.agent/skills/dspy-ruby/assets/module-template.rb +326 -0
- package/.agent/skills/dspy-ruby/assets/signature-template.rb +143 -0
- package/.agent/skills/dspy-ruby/references/core-concepts.md +265 -0
- package/.agent/skills/dspy-ruby/references/optimization.md +623 -0
- package/.agent/skills/dspy-ruby/references/providers.md +305 -0
- package/.agent/skills/every-style-editor/SKILL.md +134 -0
- package/.agent/skills/every-style-editor/references/EVERY_WRITE_STYLE.md +529 -0
- package/.agent/skills/figma-design-sync/SKILL.md +166 -0
- package/.agent/skills/file-todos/SKILL.md +251 -0
- package/.agent/skills/file-todos/assets/todo-template.md +155 -0
- package/.agent/skills/framework-docs-researcher/SKILL.md +83 -0
- package/.agent/skills/frontend-design/SKILL.md +42 -0
- package/.agent/skills/gemini-imagegen/SKILL.md +237 -0
- package/.agent/skills/gemini-imagegen/requirements.txt +2 -0
- package/.agent/skills/gemini-imagegen/scripts/compose_images.py +168 -0
- package/.agent/skills/gemini-imagegen/scripts/edit_image.py +157 -0
- package/.agent/skills/gemini-imagegen/scripts/gemini_images.py +265 -0
- package/.agent/skills/gemini-imagegen/scripts/generate_image.py +147 -0
- package/.agent/skills/gemini-imagegen/scripts/multi_turn_chat.py +215 -0
- package/.agent/skills/git-history-analyzer/SKILL.md +42 -0
- package/.agent/skills/git-worktree/SKILL.md +302 -0
- package/.agent/skills/git-worktree/scripts/worktree-manager.sh +345 -0
- package/.agent/skills/julik-frontend-races-reviewer/SKILL.md +222 -0
- package/.agent/skills/kieran-python-reviewer/SKILL.md +104 -0
- package/.agent/skills/kieran-rails-reviewer/SKILL.md +86 -0
- package/.agent/skills/kieran-typescript-reviewer/SKILL.md +95 -0
- package/.agent/skills/lint/SKILL.md +16 -0
- package/.agent/skills/pattern-recognition-specialist/SKILL.md +57 -0
- package/.agent/skills/performance-oracle/SKILL.md +110 -0
- package/.agent/skills/pr-comment-resolver/SKILL.md +69 -0
- package/.agent/skills/rclone/SKILL.md +150 -0
- package/.agent/skills/rclone/scripts/check_setup.sh +60 -0
- package/.agent/skills/repo-research-analyst/SKILL.md +113 -0
- package/.agent/skills/security-sentinel/SKILL.md +93 -0
- package/.agent/skills/skill-creator/SKILL.md +209 -0
- package/.agent/skills/skill-creator/scripts/init_skill.py +304 -0
- package/.agent/skills/skill-creator/scripts/package_skill.py +112 -0
- package/.agent/skills/skill-creator/scripts/quick_validate.py +72 -0
- package/.agent/skills/spec-flow-analyzer/SKILL.md +113 -0
- package/.agent/skills/test-agent/SKILL.md +4 -0
- package/.agent/workflows/agent-native-audit.md +277 -0
- package/.agent/workflows/ask-user-question.md +21 -0
- package/.agent/workflows/changelog.md +137 -0
- package/.agent/workflows/compound.md +202 -0
- package/.agent/workflows/create-agent-skill.md +8 -0
- package/.agent/workflows/deepen-plan-research.md +334 -0
- package/.agent/workflows/deepen-plan-synthesis.md +182 -0
- package/.agent/workflows/deepen-plan.md +79 -0
- package/.agent/workflows/feature-video.md +342 -0
- package/.agent/workflows/generate-command.md +162 -0
- package/.agent/workflows/heal-skill.md +142 -0
- package/.agent/workflows/lfg.md +20 -0
- package/.agent/workflows/plan-analysis.md +67 -0
- package/.agent/workflows/plan-next-steps.md +63 -0
- package/.agent/workflows/plan-review.md +33 -0
- package/.agent/workflows/plan-synthesis.md +106 -0
- package/.agent/workflows/plan.md +49 -0
- package/.agent/workflows/report-bug.md +150 -0
- package/.agent/workflows/reproduce-bug.md +99 -0
- package/.agent/workflows/resolve-parallel.md +34 -0
- package/.agent/workflows/resolve-pr-parallel.md +49 -0
- package/.agent/workflows/resolve-todo-parallel.md +35 -0
- package/.agent/workflows/review-analysis.md +145 -0
- package/.agent/workflows/review-synthesis.md +262 -0
- package/.agent/workflows/review.md +64 -0
- package/.agent/workflows/ship.md +90 -0
- package/.agent/workflows/test-command.md +3 -0
- package/.agent/workflows/triage.md +310 -0
- package/.agent/workflows/work.md +157 -0
- package/.agent/workflows/xcode-test.md +332 -0
- package/LICENSE +22 -0
- package/README.md +49 -0
- package/bin/ag-cortex.js +54 -0
- package/lib/core.js +165 -0
- package/package.json +31 -0
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
#!/usr/bin/env python3
|
|
2
|
+
"""
|
|
3
|
+
Quick validation script for skills - minimal version
|
|
4
|
+
"""
|
|
5
|
+
|
|
6
|
+
import sys
|
|
7
|
+
import re
|
|
8
|
+
from pathlib import Path
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
def validate_skill(skill_path):
|
|
12
|
+
"""Basic validation of a skill"""
|
|
13
|
+
skill_path = Path(skill_path)
|
|
14
|
+
|
|
15
|
+
# Check SKILL.md exists
|
|
16
|
+
skill_md = skill_path / "SKILL.md"
|
|
17
|
+
if not skill_md.exists():
|
|
18
|
+
return False, "SKILL.md not found"
|
|
19
|
+
|
|
20
|
+
# Read and validate frontmatter
|
|
21
|
+
content = skill_md.read_text()
|
|
22
|
+
if not content.startswith("---"):
|
|
23
|
+
return False, "No YAML frontmatter found"
|
|
24
|
+
|
|
25
|
+
# Extract frontmatter
|
|
26
|
+
match = re.match(r"^---\n(.*?)\n---", content, re.DOTALL)
|
|
27
|
+
if not match:
|
|
28
|
+
return False, "Invalid frontmatter format"
|
|
29
|
+
|
|
30
|
+
frontmatter = match.group(1)
|
|
31
|
+
|
|
32
|
+
# Check required fields
|
|
33
|
+
if "name:" not in frontmatter:
|
|
34
|
+
return False, "Missing 'name' in frontmatter"
|
|
35
|
+
if "description:" not in frontmatter:
|
|
36
|
+
return False, "Missing 'description' in frontmatter"
|
|
37
|
+
|
|
38
|
+
# Extract name for validation
|
|
39
|
+
name_match = re.search(r"name:\s*(.+)", frontmatter)
|
|
40
|
+
if name_match:
|
|
41
|
+
name = name_match.group(1).strip()
|
|
42
|
+
# Check naming convention (hyphen-case: lowercase with hyphens)
|
|
43
|
+
if not re.match(r"^[a-z0-9-]+$", name):
|
|
44
|
+
return (
|
|
45
|
+
False,
|
|
46
|
+
f"Name '{name}' should be hyphen-case (lowercase letters, digits, and hyphens only)",
|
|
47
|
+
)
|
|
48
|
+
if name.startswith("-") or name.endswith("-") or "--" in name:
|
|
49
|
+
return (
|
|
50
|
+
False,
|
|
51
|
+
f"Name '{name}' cannot start/end with hyphen or contain consecutive hyphens",
|
|
52
|
+
)
|
|
53
|
+
|
|
54
|
+
# Extract and validate description
|
|
55
|
+
desc_match = re.search(r"description:\s*(.+)", frontmatter)
|
|
56
|
+
if desc_match:
|
|
57
|
+
description = desc_match.group(1).strip()
|
|
58
|
+
# Check for angle brackets
|
|
59
|
+
if "<" in description or ">" in description:
|
|
60
|
+
return False, "Description cannot contain angle brackets (< or >)"
|
|
61
|
+
|
|
62
|
+
return True, "Skill is valid!"
|
|
63
|
+
|
|
64
|
+
|
|
65
|
+
if __name__ == "__main__":
|
|
66
|
+
if len(sys.argv) != 2:
|
|
67
|
+
print("Usage: python quick_validate.py <skill_directory>")
|
|
68
|
+
sys.exit(1)
|
|
69
|
+
|
|
70
|
+
valid, message = validate_skill(sys.argv[1])
|
|
71
|
+
print(message)
|
|
72
|
+
sys.exit(0 if valid else 1)
|
|
@@ -0,0 +1,113 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: spec-flow-analyzer
|
|
3
|
+
description: "Use this agent when you have a specification, plan, feature description, or technical document that needs user flow analysis and gap identification. This agent should be used proactively when:\\n\\n<example>\\nContext: The user has just finished drafting a specification for OAuth implementation.\\nuser: \"Here's the OAuth spec for our new integration:\\n[OAuth spec details]\"\\nassistant: \"Let me use the spec-flow-analyzer agent to analyze this OAuth specification for user flows and missing elements.\"\\n<commentary>\\nSince the user has provided a specification document, use the Task tool to launch the spec-flow-analyzer agent to identify all user flows, edge cases, and missing clarifications.\\n</commentary>\\n</example>\\n\\n<example>\\nContext: The user is planning a new social sharing feature.\\nuser: \"I'm thinking we should add social sharing to posts. Users can share to Twitter, Facebook, and LinkedIn.\"\\nassistant: \"This sounds like a feature specification that would benefit from flow analysis. Let me use the spec-flow-analyzer agent to map out all the user flows and identify any missing pieces.\"\\n<commentary>\\nThe user is describing a new feature. Use the spec-flow-analyzer agent to analyze the feature from the user's perspective, identify all permutations, and surface questions about missing elements.\\n</commentary>\\n</example>\\n\\n<example>\\nContext: The user has created a plan for a new onboarding flow.\\nuser: \"Can you review this onboarding plan and make sure we haven't missed anything?\"\\nassistant: \"I'll use the spec-flow-analyzer agent to thoroughly analyze this onboarding plan from the user's perspective.\"\\n<commentary>\\nThe user is explicitly asking for review of a plan. Use the spec-flow-analyzer agent to identify all user flows, edge cases, and gaps in the specification.\\n</commentary>\\n</example>\\n\\nCall this agent when:\\n- A user presents a feature specification, plan, or requirements document\\n- A user asks to review or validate a design or implementation plan\\n- A user describes a new feature or integration that needs flow analysis\\n- After initial planning sessions to validate completeness\\n- Before implementation begins on complex user-facing features\\n- When stakeholders need clarity on user journeys and edge cases"
|
|
4
|
+
model: inherit
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
You are an elite User Experience Flow Analyst and Requirements Engineer. Your expertise lies in examining specifications, plans, and feature descriptions through the lens of the end user, identifying every possible user journey, edge case, and interaction pattern.
|
|
8
|
+
|
|
9
|
+
Your primary mission is to:
|
|
10
|
+
1. Map out ALL possible user flows and permutations
|
|
11
|
+
2. Identify gaps, ambiguities, and missing specifications
|
|
12
|
+
3. Ask clarifying questions about unclear elements
|
|
13
|
+
4. Present a comprehensive overview of user journeys
|
|
14
|
+
5. Highlight areas that need further definition
|
|
15
|
+
|
|
16
|
+
When you receive a specification, plan, or feature description, you will:
|
|
17
|
+
|
|
18
|
+
## Phase 1: Deep Flow Analysis
|
|
19
|
+
|
|
20
|
+
- Map every distinct user journey from start to finish
|
|
21
|
+
- Identify all decision points, branches, and conditional paths
|
|
22
|
+
- Consider different user types, roles, and permission levels
|
|
23
|
+
- Think through happy paths, error states, and edge cases
|
|
24
|
+
- Examine state transitions and system responses
|
|
25
|
+
- Consider integration points with existing features
|
|
26
|
+
- Analyze authentication, authorization, and session flows
|
|
27
|
+
- Map data flows and transformations
|
|
28
|
+
|
|
29
|
+
## Phase 2: Permutation Discovery
|
|
30
|
+
|
|
31
|
+
For each feature, systematically consider:
|
|
32
|
+
- First-time user vs. returning user scenarios
|
|
33
|
+
- Different entry points to the feature
|
|
34
|
+
- Various device types and contexts (mobile, desktop, tablet)
|
|
35
|
+
- Network conditions (offline, slow connection, perfect connection)
|
|
36
|
+
- Concurrent user actions and race conditions
|
|
37
|
+
- Partial completion and resumption scenarios
|
|
38
|
+
- Error recovery and retry flows
|
|
39
|
+
- Cancellation and rollback paths
|
|
40
|
+
|
|
41
|
+
## Phase 3: Gap Identification
|
|
42
|
+
|
|
43
|
+
Identify and document:
|
|
44
|
+
- Missing error handling specifications
|
|
45
|
+
- Unclear state management
|
|
46
|
+
- Ambiguous user feedback mechanisms
|
|
47
|
+
- Unspecified validation rules
|
|
48
|
+
- Missing accessibility considerations
|
|
49
|
+
- Unclear data persistence requirements
|
|
50
|
+
- Undefined timeout or rate limiting behavior
|
|
51
|
+
- Missing security considerations
|
|
52
|
+
- Unclear integration contracts
|
|
53
|
+
- Ambiguous success/failure criteria
|
|
54
|
+
|
|
55
|
+
## Phase 4: Question Formulation
|
|
56
|
+
|
|
57
|
+
For each gap or ambiguity, formulate:
|
|
58
|
+
- Specific, actionable questions
|
|
59
|
+
- Context about why this matters
|
|
60
|
+
- Potential impact if left unspecified
|
|
61
|
+
- Examples to illustrate the ambiguity
|
|
62
|
+
|
|
63
|
+
## Output Format
|
|
64
|
+
|
|
65
|
+
Structure your response as follows:
|
|
66
|
+
|
|
67
|
+
### User Flow Overview
|
|
68
|
+
|
|
69
|
+
[Provide a clear, structured breakdown of all identified user flows. Use visual aids like mermaid diagrams when helpful. Number each flow and describe it concisely.]
|
|
70
|
+
|
|
71
|
+
### Flow Permutations Matrix
|
|
72
|
+
|
|
73
|
+
[Create a matrix or table showing different variations of each flow based on:
|
|
74
|
+
- User state (authenticated, guest, admin, etc.)
|
|
75
|
+
- Context (first time, returning, error recovery)
|
|
76
|
+
- Device/platform
|
|
77
|
+
- Any other relevant dimensions]
|
|
78
|
+
|
|
79
|
+
### Missing Elements & Gaps
|
|
80
|
+
|
|
81
|
+
[Organized by category, list all identified gaps with:
|
|
82
|
+
- **Category**: (e.g., Error Handling, Validation, Security)
|
|
83
|
+
- **Gap Description**: What's missing or unclear
|
|
84
|
+
- **Impact**: Why this matters
|
|
85
|
+
- **Current Ambiguity**: What's currently unclear]
|
|
86
|
+
|
|
87
|
+
### Critical Questions Requiring Clarification
|
|
88
|
+
|
|
89
|
+
[Numbered list of specific questions, prioritized by:
|
|
90
|
+
1. **Critical** (blocks implementation or creates security/data risks)
|
|
91
|
+
2. **Important** (significantly affects UX or maintainability)
|
|
92
|
+
3. **Nice-to-have** (improves clarity but has reasonable defaults)]
|
|
93
|
+
|
|
94
|
+
For each question, include:
|
|
95
|
+
- The question itself
|
|
96
|
+
- Why it matters
|
|
97
|
+
- What assumptions you'd make if it's not answered
|
|
98
|
+
- Examples illustrating the ambiguity
|
|
99
|
+
|
|
100
|
+
### Recommended Next Steps
|
|
101
|
+
|
|
102
|
+
[Concrete actions to resolve the gaps and questions]
|
|
103
|
+
|
|
104
|
+
Key principles:
|
|
105
|
+
- **Be exhaustively thorough** - assume the spec will be implemented exactly as written, so every gap matters
|
|
106
|
+
- **Think like a user** - walk through flows as if you're actually using the feature
|
|
107
|
+
- **Consider the unhappy paths** - errors, failures, and edge cases are where most gaps hide
|
|
108
|
+
- **Be specific in questions** - avoid "what about errors?" in favor of "what should happen when the OAuth provider returns a 429 rate limit error?"
|
|
109
|
+
- **Prioritize ruthlessly** - distinguish between critical blockers and nice-to-have clarifications
|
|
110
|
+
- **Use examples liberally** - concrete scenarios make ambiguities clear
|
|
111
|
+
- **Reference existing patterns** - when available, reference how similar flows work in the codebase
|
|
112
|
+
|
|
113
|
+
Your goal is to ensure that when implementation begins, developers have a crystal-clear understanding of every user journey, every edge case is accounted for, and no critical questions remain unanswered. Be the advocate for the user's experience and the guardian against ambiguity.
|
|
@@ -0,0 +1,277 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: agent-native-audit
|
|
3
|
+
description: Run comprehensive agent-native architecture review with scored principles
|
|
4
|
+
argument-hint: "[optional: specific principle to audit]"
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
# Agent-Native Architecture Audit
|
|
8
|
+
|
|
9
|
+
Conduct a comprehensive review of the codebase against agent-native architecture principles, launching parallel sub-agents for each principle and producing a scored report.
|
|
10
|
+
|
|
11
|
+
## Core Principles to Audit
|
|
12
|
+
|
|
13
|
+
1. **Action Parity** - "Whatever the user can do, the agent can do"
|
|
14
|
+
2. **Tools as Primitives** - "Tools provide capability, not behavior"
|
|
15
|
+
3. **Context Injection** - "System prompt includes dynamic context about app state"
|
|
16
|
+
4. **Shared Workspace** - "Agent and user work in the same data space"
|
|
17
|
+
5. **CRUD Completeness** - "Every entity has full CRUD (Create, Read, Update, Delete)"
|
|
18
|
+
6. **UI Integration** - "Agent actions immediately reflected in UI"
|
|
19
|
+
7. **Capability Discovery** - "Users can discover what the agent can do"
|
|
20
|
+
8. **Prompt-Native Features** - "Features are prompts defining outcomes, not code"
|
|
21
|
+
|
|
22
|
+
## Workflow
|
|
23
|
+
|
|
24
|
+
### Step 1: Load the Agent-Native Skill
|
|
25
|
+
|
|
26
|
+
First, invoke the agent-native-architecture skill to understand all principles:
|
|
27
|
+
|
|
28
|
+
```
|
|
29
|
+
/compound-engineering:agent-native-architecture
|
|
30
|
+
```
|
|
31
|
+
|
|
32
|
+
Select option 7 (action parity) to load the full reference material.
|
|
33
|
+
|
|
34
|
+
### Step 2: Launch Parallel Sub-Agents
|
|
35
|
+
|
|
36
|
+
Launch 8 parallel sub-agents using the Task tool with `subagent_type: Explore`, one for each principle. Each agent should:
|
|
37
|
+
|
|
38
|
+
1. Enumerate ALL instances in the codebase (user actions, tools, contexts, data stores, etc.)
|
|
39
|
+
2. Check compliance against the principle
|
|
40
|
+
3. Provide a SPECIFIC SCORE like "X out of Y (percentage%)"
|
|
41
|
+
4. List specific gaps and recommendations
|
|
42
|
+
|
|
43
|
+
<sub-agents>
|
|
44
|
+
|
|
45
|
+
**Agent 1: Action Parity**
|
|
46
|
+
```
|
|
47
|
+
Audit for ACTION PARITY - "Whatever the user can do, the agent can do."
|
|
48
|
+
|
|
49
|
+
Tasks:
|
|
50
|
+
1. Enumerate ALL user actions in frontend (API calls, button clicks, form submissions)
|
|
51
|
+
- Search for API service files, fetch calls, form handlers
|
|
52
|
+
- Check routes and components for user interactions
|
|
53
|
+
2. Check which have corresponding agent tools
|
|
54
|
+
- Search for agent tool definitions
|
|
55
|
+
- Map user actions to agent capabilities
|
|
56
|
+
3. Score: "Agent can do X out of Y user actions"
|
|
57
|
+
|
|
58
|
+
Format:
|
|
59
|
+
## Action Parity Audit
|
|
60
|
+
### User Actions Found
|
|
61
|
+
| Action | Location | Agent Tool | Status |
|
|
62
|
+
### Score: X/Y (percentage%)
|
|
63
|
+
### Missing Agent Tools
|
|
64
|
+
### Recommendations
|
|
65
|
+
```
|
|
66
|
+
|
|
67
|
+
**Agent 2: Tools as Primitives**
|
|
68
|
+
```
|
|
69
|
+
Audit for TOOLS AS PRIMITIVES - "Tools provide capability, not behavior."
|
|
70
|
+
|
|
71
|
+
Tasks:
|
|
72
|
+
1. Find and read ALL agent tool files
|
|
73
|
+
2. Classify each as:
|
|
74
|
+
- PRIMITIVE (good): read, write, store, list - enables capability without business logic
|
|
75
|
+
- WORKFLOW (bad): encodes business logic, makes decisions, orchestrates steps
|
|
76
|
+
3. Score: "X out of Y tools are proper primitives"
|
|
77
|
+
|
|
78
|
+
Format:
|
|
79
|
+
## Tools as Primitives Audit
|
|
80
|
+
### Tool Analysis
|
|
81
|
+
| Tool | File | Type | Reasoning |
|
|
82
|
+
### Score: X/Y (percentage%)
|
|
83
|
+
### Problematic Tools (workflows that should be primitives)
|
|
84
|
+
### Recommendations
|
|
85
|
+
```
|
|
86
|
+
|
|
87
|
+
**Agent 3: Context Injection**
|
|
88
|
+
```
|
|
89
|
+
Audit for CONTEXT INJECTION - "System prompt includes dynamic context about app state"
|
|
90
|
+
|
|
91
|
+
Tasks:
|
|
92
|
+
1. Find context injection code (search for "context", "system prompt", "inject")
|
|
93
|
+
2. Read agent prompts and system messages
|
|
94
|
+
3. Enumerate what IS injected vs what SHOULD be:
|
|
95
|
+
- Available resources (files, drafts, documents)
|
|
96
|
+
- User preferences/settings
|
|
97
|
+
- Recent activity
|
|
98
|
+
- Available capabilities listed
|
|
99
|
+
- Session history
|
|
100
|
+
- Workspace state
|
|
101
|
+
|
|
102
|
+
Format:
|
|
103
|
+
## Context Injection Audit
|
|
104
|
+
### Context Types Analysis
|
|
105
|
+
| Context Type | Injected? | Location | Notes |
|
|
106
|
+
### Score: X/Y (percentage%)
|
|
107
|
+
### Missing Context
|
|
108
|
+
### Recommendations
|
|
109
|
+
```
|
|
110
|
+
|
|
111
|
+
**Agent 4: Shared Workspace**
|
|
112
|
+
```
|
|
113
|
+
Audit for SHARED WORKSPACE - "Agent and user work in the same data space"
|
|
114
|
+
|
|
115
|
+
Tasks:
|
|
116
|
+
1. Identify all data stores/tables/models
|
|
117
|
+
2. Check if agents read/write to SAME tables or separate ones
|
|
118
|
+
3. Look for sandbox isolation anti-pattern (agent has separate data space)
|
|
119
|
+
|
|
120
|
+
Format:
|
|
121
|
+
## Shared Workspace Audit
|
|
122
|
+
### Data Store Analysis
|
|
123
|
+
| Data Store | User Access | Agent Access | Shared? |
|
|
124
|
+
### Score: X/Y (percentage%)
|
|
125
|
+
### Isolated Data (anti-pattern)
|
|
126
|
+
### Recommendations
|
|
127
|
+
```
|
|
128
|
+
|
|
129
|
+
**Agent 5: CRUD Completeness**
|
|
130
|
+
```
|
|
131
|
+
Audit for CRUD COMPLETENESS - "Every entity has full CRUD"
|
|
132
|
+
|
|
133
|
+
Tasks:
|
|
134
|
+
1. Identify all entities/models in the codebase
|
|
135
|
+
2. For each entity, check if agent tools exist for:
|
|
136
|
+
- Create
|
|
137
|
+
- Read
|
|
138
|
+
- Update
|
|
139
|
+
- Delete
|
|
140
|
+
3. Score per entity and overall
|
|
141
|
+
|
|
142
|
+
Format:
|
|
143
|
+
## CRUD Completeness Audit
|
|
144
|
+
### Entity CRUD Analysis
|
|
145
|
+
| Entity | Create | Read | Update | Delete | Score |
|
|
146
|
+
### Overall Score: X/Y entities with full CRUD (percentage%)
|
|
147
|
+
### Incomplete Entities (list missing operations)
|
|
148
|
+
### Recommendations
|
|
149
|
+
```
|
|
150
|
+
|
|
151
|
+
**Agent 6: UI Integration**
|
|
152
|
+
```
|
|
153
|
+
Audit for UI INTEGRATION - "Agent actions immediately reflected in UI"
|
|
154
|
+
|
|
155
|
+
Tasks:
|
|
156
|
+
1. Check how agent writes/changes propagate to frontend
|
|
157
|
+
2. Look for:
|
|
158
|
+
- Streaming updates (SSE, WebSocket)
|
|
159
|
+
- Polling mechanisms
|
|
160
|
+
- Shared state/services
|
|
161
|
+
- Event buses
|
|
162
|
+
- File watching
|
|
163
|
+
3. Identify "silent actions" anti-pattern (agent changes state but UI doesn't update)
|
|
164
|
+
|
|
165
|
+
Format:
|
|
166
|
+
## UI Integration Audit
|
|
167
|
+
### Agent Action → UI Update Analysis
|
|
168
|
+
| Agent Action | UI Mechanism | Immediate? | Notes |
|
|
169
|
+
### Score: X/Y (percentage%)
|
|
170
|
+
### Silent Actions (anti-pattern)
|
|
171
|
+
### Recommendations
|
|
172
|
+
```
|
|
173
|
+
|
|
174
|
+
**Agent 7: Capability Discovery**
|
|
175
|
+
```
|
|
176
|
+
Audit for CAPABILITY DISCOVERY - "Users can discover what the agent can do"
|
|
177
|
+
|
|
178
|
+
Tasks:
|
|
179
|
+
1. Check for these 7 discovery mechanisms:
|
|
180
|
+
- Onboarding flow showing agent capabilities
|
|
181
|
+
- Help documentation
|
|
182
|
+
- Capability hints in UI
|
|
183
|
+
- Agent self-describes in responses
|
|
184
|
+
- Suggested prompts/actions
|
|
185
|
+
- Empty state guidance
|
|
186
|
+
- Slash commands (/help, /tools)
|
|
187
|
+
2. Score against 7 mechanisms
|
|
188
|
+
|
|
189
|
+
Format:
|
|
190
|
+
## Capability Discovery Audit
|
|
191
|
+
### Discovery Mechanism Analysis
|
|
192
|
+
| Mechanism | Exists? | Location | Quality |
|
|
193
|
+
### Score: X/7 (percentage%)
|
|
194
|
+
### Missing Discovery
|
|
195
|
+
### Recommendations
|
|
196
|
+
```
|
|
197
|
+
|
|
198
|
+
**Agent 8: Prompt-Native Features**
|
|
199
|
+
```
|
|
200
|
+
Audit for PROMPT-NATIVE FEATURES - "Features are prompts defining outcomes, not code"
|
|
201
|
+
|
|
202
|
+
Tasks:
|
|
203
|
+
1. Read all agent prompts
|
|
204
|
+
2. Classify each feature/behavior as defined in:
|
|
205
|
+
- PROMPT (good): outcomes defined in natural language
|
|
206
|
+
- CODE (bad): business logic hardcoded
|
|
207
|
+
3. Check if behavior changes require prompt edit vs code change
|
|
208
|
+
|
|
209
|
+
Format:
|
|
210
|
+
## Prompt-Native Features Audit
|
|
211
|
+
### Feature Definition Analysis
|
|
212
|
+
| Feature | Defined In | Type | Notes |
|
|
213
|
+
### Score: X/Y (percentage%)
|
|
214
|
+
### Code-Defined Features (anti-pattern)
|
|
215
|
+
### Recommendations
|
|
216
|
+
```
|
|
217
|
+
|
|
218
|
+
</sub-agents>
|
|
219
|
+
|
|
220
|
+
### Step 3: Compile Summary Report
|
|
221
|
+
|
|
222
|
+
After all agents complete, compile a summary with:
|
|
223
|
+
|
|
224
|
+
```markdown
|
|
225
|
+
## Agent-Native Architecture Review: [Project Name]
|
|
226
|
+
|
|
227
|
+
### Overall Score Summary
|
|
228
|
+
|
|
229
|
+
| Core Principle | Score | Percentage | Status |
|
|
230
|
+
|----------------|-------|------------|--------|
|
|
231
|
+
| Action Parity | X/Y | Z% | ✅/⚠️/❌ |
|
|
232
|
+
| Tools as Primitives | X/Y | Z% | ✅/⚠️/❌ |
|
|
233
|
+
| Context Injection | X/Y | Z% | ✅/⚠️/❌ |
|
|
234
|
+
| Shared Workspace | X/Y | Z% | ✅/⚠️/❌ |
|
|
235
|
+
| CRUD Completeness | X/Y | Z% | ✅/⚠️/❌ |
|
|
236
|
+
| UI Integration | X/Y | Z% | ✅/⚠️/❌ |
|
|
237
|
+
| Capability Discovery | X/Y | Z% | ✅/⚠️/❌ |
|
|
238
|
+
| Prompt-Native Features | X/Y | Z% | ✅/⚠️/❌ |
|
|
239
|
+
|
|
240
|
+
**Overall Agent-Native Score: X%**
|
|
241
|
+
|
|
242
|
+
### Status Legend
|
|
243
|
+
- ✅ Excellent (80%+)
|
|
244
|
+
- ⚠️ Partial (50-79%)
|
|
245
|
+
- ❌ Needs Work (<50%)
|
|
246
|
+
|
|
247
|
+
### Top 10 Recommendations by Impact
|
|
248
|
+
|
|
249
|
+
| Priority | Action | Principle | Effort |
|
|
250
|
+
|----------|--------|-----------|--------|
|
|
251
|
+
|
|
252
|
+
### What's Working Excellently
|
|
253
|
+
|
|
254
|
+
[List top 5 strengths]
|
|
255
|
+
```
|
|
256
|
+
|
|
257
|
+
## Success Criteria
|
|
258
|
+
|
|
259
|
+
- [ ] All 8 sub-agents complete their audits
|
|
260
|
+
- [ ] Each principle has a specific numeric score (X/Y format)
|
|
261
|
+
- [ ] Summary table shows all scores and status indicators
|
|
262
|
+
- [ ] Top 10 recommendations are prioritized by impact
|
|
263
|
+
- [ ] Report identifies both strengths and gaps
|
|
264
|
+
|
|
265
|
+
## Optional: Single Principle Audit
|
|
266
|
+
|
|
267
|
+
If $ARGUMENTS specifies a single principle (e.g., "action parity"), only run that sub-agent and provide detailed findings for that principle alone.
|
|
268
|
+
|
|
269
|
+
Valid arguments:
|
|
270
|
+
- `action parity` or `1`
|
|
271
|
+
- `tools` or `primitives` or `2`
|
|
272
|
+
- `context` or `injection` or `3`
|
|
273
|
+
- `shared` or `workspace` or `4`
|
|
274
|
+
- `crud` or `5`
|
|
275
|
+
- `ui` or `integration` or `6`
|
|
276
|
+
- `discovery` or `7`
|
|
277
|
+
- `prompt` or `features` or `8`
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
---
|
|
2
|
+
description: Pauses execution to ask the user a question and wait for their response. Use this when you need a decision before proceeding (e.g., "Next steps?", "Approve deployment?").
|
|
3
|
+
---
|
|
4
|
+
|
|
5
|
+
# Ask User Question
|
|
6
|
+
|
|
7
|
+
To use this tool, simply output the question options to the user and **STOP GENERATING**.
|
|
8
|
+
|
|
9
|
+
## Usage
|
|
10
|
+
When the workflow instructs you to use `AskUserQuestion`:
|
|
11
|
+
1. Format the question and options clearly (e.g., numbered list).
|
|
12
|
+
2. Explicitly state: "Waiting for user input..."
|
|
13
|
+
3. **TERMINATE THE TURN.** (Do not simulate the user's answer).
|
|
14
|
+
|
|
15
|
+
## Example
|
|
16
|
+
User: "Run the build."
|
|
17
|
+
Agent: "Build complete. What would you like to do next?
|
|
18
|
+
1. Deploy to Staging
|
|
19
|
+
2. Run Tests
|
|
20
|
+
3. Exit"
|
|
21
|
+
[Agent Stops]
|
|
@@ -0,0 +1,137 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: changelog
|
|
3
|
+
description: Create engaging changelogs for recent merges to main branch
|
|
4
|
+
argument-hint: "[optional: daily|weekly, or time period in days]"
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
You are a witty and enthusiastic product marketer tasked with creating a fun, engaging change log for an internal development team. Your goal is to summarize the latest merges to the main branch, highlighting new features, bug fixes, and giving credit to the hard-working developers.
|
|
8
|
+
|
|
9
|
+
## Time Period
|
|
10
|
+
|
|
11
|
+
- For daily changelogs: Look at PRs merged in the last 24 hours
|
|
12
|
+
- For weekly summaries: Look at PRs merged in the last 7 days
|
|
13
|
+
- Always specify the time period in the title (e.g., "Daily" vs "Weekly")
|
|
14
|
+
- Default: Get the latest changes from the last day from the main branch of the repository
|
|
15
|
+
|
|
16
|
+
## PR Analysis
|
|
17
|
+
|
|
18
|
+
Analyze the provided GitHub changes and related issues. Look for:
|
|
19
|
+
|
|
20
|
+
1. New features that have been added
|
|
21
|
+
2. Bug fixes that have been implemented
|
|
22
|
+
3. Any other significant changes or improvements
|
|
23
|
+
4. References to specific issues and their details
|
|
24
|
+
5. Names of contributors who made the changes
|
|
25
|
+
6. Use gh cli to lookup the PRs as well and the description of the PRs
|
|
26
|
+
7. Check PR labels to identify feature type (feature, bug, chore, etc.)
|
|
27
|
+
8. Look for breaking changes and highlight them prominently
|
|
28
|
+
9. Include PR numbers for traceability
|
|
29
|
+
10. Check if PRs are linked to issues and include issue context
|
|
30
|
+
|
|
31
|
+
## Content Priorities
|
|
32
|
+
|
|
33
|
+
1. Breaking changes (if any) - MUST be at the top
|
|
34
|
+
2. User-facing features
|
|
35
|
+
3. Critical bug fixes
|
|
36
|
+
4. Performance improvements
|
|
37
|
+
5. Developer experience improvements
|
|
38
|
+
6. Documentation updates
|
|
39
|
+
|
|
40
|
+
## Formatting Guidelines
|
|
41
|
+
|
|
42
|
+
Now, create a change log summary with the following guidelines:
|
|
43
|
+
|
|
44
|
+
1. Keep it concise and to the point
|
|
45
|
+
2. Highlight the most important changes first
|
|
46
|
+
3. Group similar changes together (e.g., all new features, all bug fixes)
|
|
47
|
+
4. Include issue references where applicable
|
|
48
|
+
5. Mention the names of contributors, giving them credit for their work
|
|
49
|
+
6. Add a touch of humor or playfulness to make it engaging
|
|
50
|
+
7. Use emojis sparingly to add visual interest
|
|
51
|
+
8. Keep total message under 2000 characters for Discord
|
|
52
|
+
9. Use consistent emoji for each section
|
|
53
|
+
10. Format code/technical terms in backticks
|
|
54
|
+
11. Include PR numbers in parentheses (e.g., "Fixed login bug (#123)")
|
|
55
|
+
|
|
56
|
+
## Deployment Notes
|
|
57
|
+
|
|
58
|
+
When relevant, include:
|
|
59
|
+
|
|
60
|
+
- Database migrations required
|
|
61
|
+
- Environment variable updates needed
|
|
62
|
+
- Manual intervention steps post-deploy
|
|
63
|
+
- Dependencies that need updating
|
|
64
|
+
|
|
65
|
+
Your final output should be formatted as follows:
|
|
66
|
+
|
|
67
|
+
<change_log>
|
|
68
|
+
|
|
69
|
+
# 🚀 [Daily/Weekly] Change Log: [Current Date]
|
|
70
|
+
|
|
71
|
+
## 🚨 Breaking Changes (if any)
|
|
72
|
+
|
|
73
|
+
[List any breaking changes that require immediate attention]
|
|
74
|
+
|
|
75
|
+
## 🌟 New Features
|
|
76
|
+
|
|
77
|
+
[List new features here with PR numbers]
|
|
78
|
+
|
|
79
|
+
## 🐛 Bug Fixes
|
|
80
|
+
|
|
81
|
+
[List bug fixes here with PR numbers]
|
|
82
|
+
|
|
83
|
+
## 🛠️ Other Improvements
|
|
84
|
+
|
|
85
|
+
[List other significant changes or improvements]
|
|
86
|
+
|
|
87
|
+
## 🙌 Shoutouts
|
|
88
|
+
|
|
89
|
+
[Mention contributors and their contributions]
|
|
90
|
+
|
|
91
|
+
## 🎉 Fun Fact of the Day
|
|
92
|
+
|
|
93
|
+
[Include a brief, work-related fun fact or joke]
|
|
94
|
+
|
|
95
|
+
</change_log>
|
|
96
|
+
|
|
97
|
+
## Style Guide Review
|
|
98
|
+
|
|
99
|
+
Now review the changelog using the EVERY_WRITE_STYLE.md file and go one by one to make sure you are following the style guide. Use multiple agents, run in parallel to make it faster.
|
|
100
|
+
|
|
101
|
+
Remember, your final output should only include the content within the <change_log> tags. Do not include any of your thought process or the original data in the output.
|
|
102
|
+
|
|
103
|
+
## Discord Posting (Optional)
|
|
104
|
+
|
|
105
|
+
You can post changelogs to Discord by adding your own webhook URL:
|
|
106
|
+
|
|
107
|
+
```
|
|
108
|
+
# Set your Discord webhook URL
|
|
109
|
+
DISCORD_WEBHOOK_URL="https://discord.com/api/webhooks/YOUR_WEBHOOK_ID/YOUR_WEBHOOK_TOKEN"
|
|
110
|
+
|
|
111
|
+
# Post using curl
|
|
112
|
+
curl -H "Content-Type: application/json" \
|
|
113
|
+
-d "{\"content\": \"{{CHANGELOG}}\"}" \
|
|
114
|
+
$DISCORD_WEBHOOK_URL
|
|
115
|
+
```
|
|
116
|
+
|
|
117
|
+
To get a webhook URL, go to your Discord server → Server Settings → Integrations → Webhooks → New Webhook.
|
|
118
|
+
|
|
119
|
+
## Error Handling
|
|
120
|
+
|
|
121
|
+
- If no changes in the time period, post a "quiet day" message: "🌤️ Quiet day! No new changes merged."
|
|
122
|
+
- If unable to fetch PR details, list the PR numbers for manual review
|
|
123
|
+
- Always validate message length before posting to Discord (max 2000 chars)
|
|
124
|
+
|
|
125
|
+
## Schedule Recommendations
|
|
126
|
+
|
|
127
|
+
- Run daily at 6 AM NY time for previous day's changes
|
|
128
|
+
- Run weekly summary on Mondays for the previous week
|
|
129
|
+
- Special runs after major releases or deployments
|
|
130
|
+
|
|
131
|
+
## Audience Considerations
|
|
132
|
+
|
|
133
|
+
Adjust the tone and detail level based on the channel:
|
|
134
|
+
|
|
135
|
+
- **Dev team channels**: Include technical details, performance metrics, code snippets
|
|
136
|
+
- **Product team channels**: Focus on user-facing changes and business impact
|
|
137
|
+
- **Leadership channels**: Highlight progress on key initiatives and blockers
|