skill-brain 2.1.0__py3-none-any.whl

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.
Files changed (97) hide show
  1. skill_brain/__init__.py +3 -0
  2. skill_brain/cli.py +185 -0
  3. skill_brain/data/brain/config.json +3 -0
  4. skill_brain/data/brain/decisions/anti-ai-sop.md +22 -0
  5. skill_brain/data/brain/decisions/architecture.md +35 -0
  6. skill_brain/data/brain/decisions/backend.md +27 -0
  7. skill_brain/data/brain/decisions/debugging.md +45 -0
  8. skill_brain/data/brain/decisions/frontend.md +38 -0
  9. skill_brain/data/brain/decisions/git.md +59 -0
  10. skill_brain/data/brain/decisions/memory.md +48 -0
  11. skill_brain/data/brain/index.json +630 -0
  12. skill_brain/data/skills/animation-auditor/SKILL.md +89 -0
  13. skill_brain/data/skills/animation-builder/SKILL.md +108 -0
  14. skill_brain/data/skills/animation-opportunities/SKILL.md +102 -0
  15. skill_brain/data/skills/animation-performance/SKILL.md +108 -0
  16. skill_brain/data/skills/animation-reviewer/SKILL.md +82 -0
  17. skill_brain/data/skills/anti-ai-sop-agent/SKILL.md +76 -0
  18. skill_brain/data/skills/anti-slop-enforcer/SKILL.md +98 -0
  19. skill_brain/data/skills/anti-slop-planner/SKILL.md +70 -0
  20. skill_brain/data/skills/apple-feel/SKILL.md +137 -0
  21. skill_brain/data/skills/architecture-improver/SKILL.md +90 -0
  22. skill_brain/data/skills/architecture-master/SKILL.md +67 -0
  23. skill_brain/data/skills/backend-master/SKILL.md +43 -0
  24. skill_brain/data/skills/backend-planner/SKILL.md +70 -0
  25. skill_brain/data/skills/bug-diagnoser/SKILL.md +119 -0
  26. skill_brain/data/skills/canvas-art/SKILL.md +53 -0
  27. skill_brain/data/skills/code-reviewer/SKILL.md +87 -0
  28. skill_brain/data/skills/codebase-designer/SKILL.md +87 -0
  29. skill_brain/data/skills/context-handoff/SKILL.md +77 -0
  30. skill_brain/data/skills/debug-master/SKILL.md +38 -0
  31. skill_brain/data/skills/debug-planner/SKILL.md +65 -0
  32. skill_brain/data/skills/design-engineering/SKILL.md +121 -0
  33. skill_brain/data/skills/design-taste-frontend/SKILL.md +68 -0
  34. skill_brain/data/skills/design-taste-frontend/references/app-screens.md +30 -0
  35. skill_brain/data/skills/design-taste-frontend/references/building-and-composition.md +85 -0
  36. skill_brain/data/skills/design-taste-frontend/references/direction-draw.md +56 -0
  37. skill_brain/data/skills/design-taste-frontend/references/house-rules.md +44 -0
  38. skill_brain/data/skills/design-taste-frontend/references/laws-of-the-craft.md +54 -0
  39. skill_brain/data/skills/design-taste-frontend/references/special-cases.md +46 -0
  40. skill_brain/data/skills/desktop-ui-architect/SKILL.md +106 -0
  41. skill_brain/data/skills/domain-modeler/SKILL.md +89 -0
  42. skill_brain/data/skills/dynamic-ui-engine/SKILL.md +85 -0
  43. skill_brain/data/skills/frontend-baseline/SKILL.md +41 -0
  44. skill_brain/data/skills/frontend-master/SKILL.md +51 -0
  45. skill_brain/data/skills/frontend-planner/SKILL.md +85 -0
  46. skill_brain/data/skills/git-atomic-committer/SKILL.md +157 -0
  47. skill_brain/data/skills/git-branch-manager/SKILL.md +130 -0
  48. skill_brain/data/skills/git-isolator/SKILL.md +91 -0
  49. skill_brain/data/skills/git-master/SKILL.md +50 -0
  50. skill_brain/data/skills/git-phase-committer/SKILL.md +112 -0
  51. skill_brain/data/skills/implementation-planner/SKILL.md +89 -0
  52. skill_brain/data/skills/issue-triager/SKILL.md +92 -0
  53. skill_brain/data/skills/karpathy-coder/SKILL.md +71 -0
  54. skill_brain/data/skills/large-task-mapper/SKILL.md +85 -0
  55. skill_brain/data/skills/mcp-builder/SKILL.md +113 -0
  56. skill_brain/data/skills/memory-master/SKILL.md +69 -0
  57. skill_brain/data/skills/mobile-native-feel/SKILL.md +194 -0
  58. skill_brain/data/skills/phase-planner/SKILL.md +139 -0
  59. skill_brain/data/skills/phone-layout-master/SKILL.md +126 -0
  60. skill_brain/data/skills/pr-writer/SKILL.md +69 -0
  61. skill_brain/data/skills/research-agent/SKILL.md +77 -0
  62. skill_brain/data/skills/responsive-contract-enforcer/SKILL.md +77 -0
  63. skill_brain/data/skills/root-cause-debugger/SKILL.md +110 -0
  64. skill_brain/data/skills/session-continuity/SKILL.md +61 -0
  65. skill_brain/data/skills/setup-wizard/SKILL.md +79 -0
  66. skill_brain/data/skills/skill-creator/SKILL.md +77 -0
  67. skill_brain/data/skills/spec-implementer/SKILL.md +76 -0
  68. skill_brain/data/skills/spec-writer/SKILL.md +84 -0
  69. skill_brain/data/skills/subagent-executor/SKILL.md +76 -0
  70. skill_brain/data/skills/supreme-orchestrator/SKILL.md +90 -0
  71. skill_brain/data/skills/svg-icon-craftsman/SKILL.md +126 -0
  72. skill_brain/data/skills/swift-writer/SKILL.md +78 -0
  73. skill_brain/data/skills/tdd-implementer/SKILL.md +108 -0
  74. skill_brain/data/skills/test-verifier/SKILL.md +94 -0
  75. skill_brain/data/skills/text-tone-enforcer/SKILL.md +56 -0
  76. skill_brain/data/skills/theme-system/SKILL.md +67 -0
  77. skill_brain/data/skills/ticket-breaker/SKILL.md +75 -0
  78. skill_brain/data/skills/typography-master/SKILL.md +100 -0
  79. skill_brain/data/skills/ui-design-principles/SKILL.md +114 -0
  80. skill_brain/data/skills/ui-library-picker/SKILL.md +61 -0
  81. skill_brain/data/skills/ui-prototyper/SKILL.md +69 -0
  82. skill_brain/data/skills/ui-stress-tester/SKILL.md +112 -0
  83. skill_brain/data/skills/ui-taste-enforcer/SKILL.md +158 -0
  84. skill_brain/data/skills/ui-tells-eliminator/SKILL.md +119 -0
  85. skill_brain/data/skills/web-artifact-builder/SKILL.md +82 -0
  86. skill_brain/data/skills/webapp-tester/SKILL.md +111 -0
  87. skill_brain/data/templates/AGENTS.md +47 -0
  88. skill_brain/data/templates/CLAUDE.md +9 -0
  89. skill_brain/data/templates/GEMINI.md +14 -0
  90. skill_brain/doctor.py +172 -0
  91. skill_brain/indexer.py +160 -0
  92. skill_brain/installer.py +432 -0
  93. skill_brain-2.1.0.dist-info/METADATA +144 -0
  94. skill_brain-2.1.0.dist-info/RECORD +97 -0
  95. skill_brain-2.1.0.dist-info/WHEEL +4 -0
  96. skill_brain-2.1.0.dist-info/entry_points.txt +2 -0
  97. skill_brain-2.1.0.dist-info/licenses/LICENSE +21 -0
@@ -0,0 +1,3 @@
1
+ """skill-brain -- Multi-agent engineering skill system."""
2
+
3
+ __version__ = "2.1.0"
skill_brain/cli.py ADDED
@@ -0,0 +1,185 @@
1
+ """Entry point: skill-brain CLI -- dispatches to subcommands."""
2
+
3
+ import argparse
4
+ import sys
5
+
6
+ from skill_brain import __version__
7
+ from skill_brain import installer, doctor as doctor_mod, indexer
8
+
9
+
10
+ def main() -> None:
11
+ parser = argparse.ArgumentParser(
12
+ prog="skill-brain",
13
+ description="Multi-agent engineering skill system CLI",
14
+ )
15
+ parser.add_argument(
16
+ "--version", action="version", version=f"skill-brain {__version__}"
17
+ )
18
+
19
+ sub = parser.add_subparsers(dest="command", metavar="<command>")
20
+
21
+ # --- init ---
22
+ p_init = sub.add_parser("init", help="Install skill-brain into current project")
23
+ p_init.add_argument(
24
+ "--agents",
25
+ default="all",
26
+ help="Comma-separated agents: all|claude,codex,antigravity,gemini,cursor",
27
+ )
28
+ p_init.add_argument(
29
+ "--legacy-agent-dir",
30
+ action="store_true",
31
+ help="Also write .agent/skills/ (legacy single-agent dir)",
32
+ )
33
+
34
+ # --- update ---
35
+ sub.add_parser("update", help="Update skill files (preserves user edits)")
36
+
37
+ # --- add ---
38
+ p_add = sub.add_parser("add", help="Add a local skill to .agents/skills/")
39
+ p_add.add_argument("path", help="Path to skill directory")
40
+
41
+ # --- list ---
42
+ sub.add_parser("list", help="List all installed skills")
43
+
44
+ # --- show ---
45
+ p_show = sub.add_parser("show", help="Show a skill's SKILL.md")
46
+ p_show.add_argument("name", help="Skill name")
47
+
48
+ # --- search ---
49
+ p_search = sub.add_parser("search", help="Search skills by keyword")
50
+ p_search.add_argument("query", help="Search query")
51
+
52
+ # --- doctor ---
53
+ sub.add_parser("doctor", help="Validate skill directory health")
54
+
55
+ # --- uninstall ---
56
+ sub.add_parser("uninstall", help="Remove files installed by skill-brain")
57
+
58
+ args = parser.parse_args()
59
+
60
+ if args.command is None:
61
+ parser.print_help()
62
+ sys.exit(0)
63
+
64
+ if args.command == "init":
65
+ agents_arg = args.agents
66
+ if agents_arg == "all":
67
+ agents = ["claude", "codex", "antigravity", "gemini", "cursor"]
68
+ else:
69
+ agents = [a.strip() for a in agents_arg.split(",")]
70
+ installer.init(agents=agents, legacy_agent_dir=args.legacy_agent_dir)
71
+
72
+ elif args.command == "update":
73
+ installer.update()
74
+
75
+ elif args.command == "add":
76
+ installer.add_skill(args.path)
77
+
78
+ elif args.command == "list":
79
+ _cmd_list()
80
+
81
+ elif args.command == "show":
82
+ _cmd_show(args.name)
83
+
84
+ elif args.command == "search":
85
+ _cmd_search(args.query)
86
+
87
+ elif args.command == "doctor":
88
+ errors = doctor_mod.run()
89
+ sys.exit(1 if errors else 0)
90
+
91
+ elif args.command == "uninstall":
92
+ installer.uninstall()
93
+
94
+
95
+ # ---------------------------------------------------------------------------
96
+ # list / show / search -- thin wrappers that read index.json
97
+ # ---------------------------------------------------------------------------
98
+
99
+ def _cmd_list() -> None:
100
+ import json
101
+ from pathlib import Path
102
+
103
+ index_path = Path.cwd() / ".agents" / "brain" / "index.json"
104
+ if not index_path.exists():
105
+ print("ERROR: .agents/brain/index.json not found. Run `skill-brain init` first.")
106
+ sys.exit(1)
107
+
108
+ index = json.loads(index_path.read_text(encoding="utf-8"))
109
+ by_cat: dict[str, list] = {}
110
+ for skill in index.values():
111
+ cat = skill.get("category", "uncategorized")
112
+ by_cat.setdefault(cat, []).append(skill)
113
+
114
+ total = 0
115
+ for cat in sorted(by_cat):
116
+ skills = sorted(by_cat[cat], key=lambda s: s["name"])
117
+ print(f"\n [{cat.upper()}]")
118
+ for s in skills:
119
+ aliases = ", ".join(s.get("aliases", [])[:2])
120
+ print(f" {s['name']:<32} {aliases}")
121
+ total += 1
122
+ print(f"\n Total: {total} skills")
123
+
124
+
125
+ def _cmd_show(name: str) -> None:
126
+ import json
127
+ from pathlib import Path
128
+
129
+ index_path = Path.cwd() / ".agents" / "brain" / "index.json"
130
+ if not index_path.exists():
131
+ print("ERROR: .agents/brain/index.json not found. Run `skill-brain init` first.")
132
+ sys.exit(1)
133
+
134
+ index = json.loads(index_path.read_text(encoding="utf-8"))
135
+ skill = index.get(name)
136
+ if not skill:
137
+ print(f"ERROR: Skill '{name}' not found.")
138
+ sys.exit(1)
139
+
140
+ skill_path = Path.cwd() / skill["path"]
141
+ if not skill_path.exists():
142
+ print(f"ERROR: SKILL.md not found at {skill_path}")
143
+ sys.exit(1)
144
+
145
+ print(skill_path.read_text(encoding="utf-8"))
146
+
147
+
148
+ def _cmd_search(query: str) -> None:
149
+ import json
150
+ from pathlib import Path
151
+
152
+ index_path = Path.cwd() / ".agents" / "brain" / "index.json"
153
+ if not index_path.exists():
154
+ print("ERROR: .agents/brain/index.json not found. Run `skill-brain init` first.")
155
+ sys.exit(1)
156
+
157
+ index = json.loads(index_path.read_text(encoding="utf-8"))
158
+ terms = query.lower().split()
159
+
160
+ scored: list[tuple[int, dict]] = []
161
+ for skill in index.values():
162
+ score = 0
163
+ name_l = skill["name"].lower()
164
+ desc_l = skill.get("description", "").lower()
165
+ aliases_l = " ".join(skill.get("aliases", [])).lower()
166
+ for term in terms:
167
+ if term in name_l:
168
+ score += 4
169
+ if term in aliases_l:
170
+ score += 2
171
+ if term in desc_l:
172
+ score += 1
173
+ if score > 0:
174
+ scored.append((score, skill))
175
+
176
+ scored.sort(key=lambda x: -x[0])
177
+ if not scored:
178
+ print("No skills matched your query.")
179
+ return
180
+
181
+ print(f"\n Results for '{query}':\n")
182
+ for score, skill in scored:
183
+ print(f" {skill['name']:<32} (score: {score})")
184
+ print(f" {skill.get('description', '')[:100]}...")
185
+ print()
@@ -0,0 +1,3 @@
1
+ {
2
+ "confirm": "always"
3
+ }
@@ -0,0 +1,22 @@
1
+ # Anti-AI SOP Skills — Decision Making Matrix
2
+
3
+ This document dictates how the agent monitors, purges, and audits AI tells across prose, visual design, vectors, and code.
4
+
5
+ ---
6
+
7
+ ## 1. Zero Tolerance Mandate
8
+
9
+ Before ANY response, code snippet, SVG, or UI is returned to the user, run the anti-slop check.
10
+ If an output contains synthetic tells, rewrite it before sending.
11
+
12
+ ---
13
+
14
+ ## 2. Specialized Skill Selection Matrix
15
+
16
+ | Content Being Produced | Selected Skills | Enforced Restrictions |
17
+ |---|---|---|
18
+ | **Plan an Anti-AI audit before fixing** | `anti-slop-planner` (`$plan-anti-slop`) | Catalogs all AI tells across 6 dimensions with file:line citations; drafts surgical remediation plan. |
19
+ | **Formal quality gate audit of repo/PR** | `agents/anti-ai-sop-agent` (`$anti-slop`) | Produces formal 6-category scorecard (PASS / WARN / FAIL) with concrete citations and optional `--fix` mode. |
20
+ | **Text, explanations, answers, PRs** | `text-tone-enforcer` + `anti-slop-enforcer` | No sycophantic openers, no filler transitions ("Furthermore"), no bullet-point abuse; direct senior engineer cadence. |
21
+ | **Frontend UI (CSS, Tailwind, JSX, HTML)** | `ui-tells-eliminator` + `anti-slop-enforcer` | No cream/terracotta Anthropic clone, no pill badges above headlines, no tracked uppercase eyebrows, no 3-card centered icon grids. |
22
+ | **SVG Icons and Vector Graphics** | `svg-icon-craftsman` (`$icon`) | No wandering bezier curves, standard 24×24 viewBox, uniform 1.5px/2.0px stroke, integral pixel snapping. |
@@ -0,0 +1,35 @@
1
+ # Architecture Skills — Decision Making Matrix
2
+
3
+ This document dictates how the agent handles system design, workspace isolation, sub-agent dispatch, and large project planning.
4
+
5
+ ---
6
+
7
+ ## 1. Mandatory Baseline
8
+
9
+ Before structural or multi-module changes:
10
+ - Evaluate workspace isolation: if a feature branch or worktree is appropriate, activate `git-isolator`.
11
+ - Keep the main branch clean and unpolluted with in-progress experiments.
12
+
13
+ ---
14
+
15
+ ## 2. Specialized Skill Selection Matrix
16
+
17
+ | Architectural Goal | Selected Skills | Why This Combination |
18
+ |---|---|---|
19
+ | **Isolate workspace for feature work** | `git-isolator` | Creates native worktree (`git worktree add -b feature/...`), verifies isolation, keeps main tree clean. |
20
+ | **Dispatch parallel task execution** | `subagent-executor` | Dispatches fresh sub-agents with isolated prompts per task; reviews each task output before merging. |
21
+ | **Map huge project spanning sessions** | `large-task-mapper` | Deconstructs big goals into decision tickets (blocking forks in the road) before implementation tickets. |
22
+ | **Research API / library from sources** | `research-agent` | Restricts investigation strictly to primary sources (official docs, repo source); cites URLs and file lines. |
23
+ | **Human credential / dashboard setup** | `setup-wizard` | Generates idempotent, color-coded interactive bash wizard for human-only secrets, dashboards, or DNS steps. |
24
+ | **Author or optimize an agent skill** | `skill-creator` | Benchmarks trigger descriptions, runs eval matrices, refines procedural instructions. |
25
+
26
+ ---
27
+
28
+ ## 3. Sub-Agent vs. Single Pass Decision
29
+
30
+ - **Use `subagent-executor` when:**
31
+ - Tasks are embarrassingly parallel (e.g. 5 independent UI components or 4 separate API endpoints).
32
+ - Context window would be overwhelmed by reviewing all implementations at once.
33
+ - **Use single pass when:**
34
+ - Tasks are tightly coupled sequentially (e.g. database schema change followed immediately by dependent query update).
35
+
@@ -0,0 +1,27 @@
1
+ # Backend Skills — Decision Making Matrix
2
+
3
+ This document dictates how the agent selects, combines, and sequences backend skills.
4
+
5
+ ---
6
+
7
+ ## 1. Mandatory Baseline (Always Active in Backend)
8
+
9
+ Every backend implementation task **must** honor:
10
+ 1. `karpathy-coder` (minimal blast radius, zero speculative code, no unrequested abstractions).
11
+ 2. `tdd-implementer` (write test first, watch it fail, write minimal code to pass).
12
+ 3. `responsive-contract-enforcer` (all endpoints serving UI must declare responsive aspect ratios, multi-res srcsets, and zero fixed pixel widths).
13
+
14
+ ---
15
+
16
+ ## 2. Specialized Skill Selection Matrix
17
+
18
+ | User Goal | Selected Skills | Why This Combination |
19
+ |---|---|---|
20
+ | **Plan backend architecture before coding** | `backend-planner` (`$plan-backend`) | Defines domain models, responsive API contracts, tracer-bullet ticket graph, and TDD plan. |
21
+ | **Surgical bugfix or minimal tweak** | `karpathy-coder` + `tdd-implementer` | Touches only failing lines, adds a targeted regression test, leaves surrounding code pristine. |
22
+ | **Build new feature from spec** | `spec-implementer` | Follows ticket dependency graph in strict order, committing after each ticket. |
23
+ | **Design deep module / API boundary** | `codebase-designer` + `domain-modeler` | Maximizes information hiding (Ousterhout deep modules) and aligns naming to GLOSSARY.md. |
24
+ | **Enforce responsive UI API contract** | `responsive-contract-enforcer` | Validates that payloads contain responsive layout hints, aspect ratios, and zero hardcoded pixel widths. |
25
+ | **Modern Swift 6 / Apple backend** | `swift-writer` | Strict concurrency (@MainActor, actors, Sendable), value-type modeling, Swift Testing. |
26
+ | **Build MCP tool server** | `mcp-builder` | FastMCP or TypeScript MCP SDK; clean tool schemas, error handling, deterministic outputs. |
27
+ | **Write pull request description** | `pr-writer` | Generates summary, testing steps, before/after evidence, and reviewer checklist. |
@@ -0,0 +1,45 @@
1
+ # Debugging Skills — Decision Making Matrix
2
+
3
+ This document dictates how the agent handles bugs, test failures, crashes, and regressions.
4
+
5
+ ---
6
+
7
+ ## 1. The Debugging Iron Law (Planning First)
8
+
9
+ **When the user says "debug", NEVER edit code immediately.**
10
+ 1. Formulate a systematic diagnostic plan using debugging skills.
11
+ 2. State the observed symptom, reproduction steps, and candidate hypotheses.
12
+ 3. Ask the user for confirmation: *"Here is my diagnostic plan. Shall I proceed with isolating the root cause?"*
13
+ 4. Only after finding the root cause with verifiable evidence may a fix be designed.
14
+
15
+ ---
16
+
17
+ ## 2. Specialized Skill Selection Matrix
18
+
19
+ | Problem Type | Selected Skills | Why This Combination |
20
+ |---|---|---|
21
+ | **Exception, crash, or clear error** | `root-cause-debugger` | Enforces the 5-step protocol: state symptom, gather evidence, form ONE falsifiable hypothesis, test hypothesis, isolate cause. |
22
+ | **Intermittent bug / "works on my machine"** | `bug-diagnoser` | Systematically bisects problem space, instruments minimal logging, and isolates minimal reproduction. |
23
+ | **Performance regression / slow API** | `bug-diagnoser` (perf mode) | Measures CPU/memory bottlenecks, queries profilers, identifies O(n²) or N+1 query patterns. |
24
+ | **Validating a fix or claiming "done"** | `test-verifier` | Evidence before claims: runs actual test/lint commands and pastes raw terminal output before declaring success. |
25
+ | **Reviewing branch / PR for flaws** | `code-reviewer` | Runs parallel reviews: Standards compliance (clean code) vs. Spec compliance (did we build what was asked?). |
26
+ | **Triaging bug reports from users** | `issue-triager` | Moves issues through triage state machine (RAW → VERIFYING → CATEGORIZED → READY) and produces agent-ready briefs. |
27
+
28
+ ---
29
+
30
+ ## 3. Diagnostic Plan Template
31
+
32
+ Before touching code, present this plan to the user:
33
+
34
+ ```markdown
35
+ ### 🔍 Diagnostic Plan
36
+ 1. **Symptom:** [Exact error message or unexpected behavior observed]
37
+ 2. **Reproduction:** [Exact command or steps to reproduce]
38
+ 3. **Hypothesis:** [What mechanism is suspected of causing this]
39
+ 4. **Investigation Steps:**
40
+ - [ ] Inspect stack trace / logs at [file:line]
41
+ - [ ] Run isolated regression test
42
+ - [ ] Verify root cause before proposing edits
43
+ 5. **Next Step:** Confirm to begin investigation.
44
+ ```
45
+
@@ -0,0 +1,38 @@
1
+ # Frontend Skills — Decision Making Matrix
2
+
3
+ This document dictates how the agent selects, combines, and sequences frontend skills.
4
+
5
+ ---
6
+
7
+ ## 1. Mandatory Baseline Bundle (`frontend-baseline`)
8
+
9
+ Every frontend task **must** load `frontend-baseline` (≤ 4 KB), which condenses:
10
+ 1. **Art Direction:** `design-taste-frontend` + `ui-taste-enforcer` (Taste Kill v2, 247-site study, subject palette).
11
+ 2. **Anti-AI SOP:** `ui-tells-eliminator` + `anti-slop-enforcer` (kills pill badges, eyebrows, 3-card grids).
12
+ 3. **Dynamic Responsive Sizing:** `phone-layout-master` + `desktop-ui-architect` + `dynamic-ui-engine` (flawless adaptation from 320px phone to 2560px desktop).
13
+
14
+ Full skills can be loaded on demand from references when deeper guidance is required.
15
+
16
+ ---
17
+
18
+ ## 2. Specialized Skill Selection Matrix
19
+
20
+ | User Goal | Selected Skills | Why This Combination |
21
+ |---|---|---|
22
+ | **Plan UI architecture before building** | `frontend-planner` (`$plan-frontend`) | Creates complete blueprint: subject inventory, fluid tokens, phone layout, desktop layout, anti-slop check. |
23
+ | **Build new component or page** | `design-taste-frontend` + `dynamic-ui-engine` + `typography-master` | Directs composition, token ratios, fluid clamp scales, and tailored typography. |
24
+ | **Phone / Mobile layout perfection** | `phone-layout-master` + `mobile-native-feel` | 320px–480px optimization: 100svh, 44px touch targets, bottom sheets, safe-area insets. |
25
+ | **Desktop / Wide-screen UI workstation** | `desktop-ui-architect` + `design-engineering` | 768px–2560px optimization: multi-pane hierarchy, container queries (`@container`), max-width bounds. |
26
+ | **Typography & font archetype selection**| `typography-master` (`$typography`) | Selects Swiss, Editorial, Mono, or Humanist font stacks; establishes mathematical clamp scales. |
27
+ | **Craft SVG icons or glyphs** | `svg-icon-craftsman` (`$icon`) | Snaps vector paths to 24×24 grid, 1.5px/2.0px stroke, eliminates AI curve spaghetti. |
28
+ | **Add micro-interactions & polish** | `design-engineering` + `animation-builder` | Emil Kowalski polish standard: 9 interactive states, physical spring curves. |
29
+ | **Fix dropped frames or janky UI** | `animation-performance` | Keeps animations on composite-only GPU properties (transform, opacity); 16.6ms frame budget. |
30
+ | **Stress-test layout breaks** | `ui-stress-tester` | Feeds extreme strings, non-Latin text, negative numbers, empty arrays behind a demo toggle. |
31
+ | **Compare multiple UI directions** | `ui-prototyper` | Generates 3 genuinely different compositions behind a live switcher. |
32
+
33
+ ---
34
+
35
+ ## 3. The Baseline Bundle + 3 Task Skills Rule
36
+
37
+ - Rule 7 standard: Load `frontend-baseline` plus up to **3 specialized task skills** at the same time (e.g. `svg-icon-craftsman`, `animation-builder`, `webapp-tester`).
38
+ - Respect `.agents/brain/config.json` confirmation settings before executing.
@@ -0,0 +1,59 @@
1
+ # Git Skills — Decision Making Matrix
2
+
3
+ This document dictates how the agent handles version control operations, atomic commits, branch lifecycle management, and virtual memory phase commit synchronization.
4
+
5
+ ---
6
+
7
+ ## 1. Mandatory Baseline
8
+
9
+ Before executing any git operations:
10
+ - Never commit broken code, syntax errors, or unverified changes.
11
+ - Never dump massive, unrelated multi-domain changes into a single generic commit.
12
+ - Inspect `git status --porcelain` and `git diff --stat` before staging files.
13
+ - Enforce Conventional Commits standard: `<type>(<scope>): <imperative summary>` (<= 72 chars), followed by a concise body and verification evidence footer.
14
+ - When working within Virtual Memory (`.agents/memory/phases/`), every phase transition to `FINISHED` must trigger an atomic phase commit.
15
+
16
+ ---
17
+
18
+ ## 2. Specialized Skill Selection Matrix
19
+
20
+ | Git Operational Goal | Selected Skills | Why This Combination |
21
+ |---|---|---|
22
+ | **User commands: `$commit`, `commit:`, or code ready to commit** | `git-atomic-committer` | Analyzes staged/unstaged changes, evaluates domain blast radius, splits into 2 or more atomic commits if changes span multiple domains, crafts Conventional Commit message with verification evidence. |
23
+ | **User commands: `$branch`, `branch:`, or creating/syncing branches** | `git-branch-manager` | Enforces strict naming conventions (`feat/`, `fix/`, `phase/`, `refactor/`, `chore/`), checks working tree hygiene, performs rebase sync (`git pull --rebase origin main`), and handles branch cleanup. |
24
+ | **A Virtual Memory Phase completes (`[VERIFY]` → `[FINISH]`)** | `git-phase-committer` | Hooks into Step 4 of `phase-planner`. Stages and splits phase code, test fixtures, and memory updates into atomic phase commits, recording verification proof in the commit body. |
25
+ | **Feature isolation in separate workspace** | `git-branch-manager` + `git-isolator` | Creates an isolated worktree branch (`git worktree add ../feature-work -b feature/...`), keeping main branch unpolluted. |
26
+ | **Preparing Pull Request / Merge readiness** | `git-atomic-committer` + `pr-writer` | Validates clean atomic commit history and synthesizes high-fidelity PR description from the commit log. |
27
+
28
+ ---
29
+
30
+ ## 3. Commit Splitting Decision Rule
31
+
32
+ When analyzing workspace diffs:
33
+
34
+ ```
35
+ Total Changed Files & Domains?
36
+ │
37
+ ├── 1 domain, <= 3 tightly coupled files ──► SINGLE ATOMIC COMMIT
38
+ │ └── Example: feat(auth): implement token refresh rotation
39
+ │
40
+ └── Multiple domains OR > 3 loosely coupled files ──► SPLIT INTO 2+ ATOMIC COMMITS
41
+ ├── Commit 1 (Core Domain / Backend): feat(...) or fix(...)
42
+ ├── Commit 2 (Tests & Verification Fixtures): test(...)
43
+ ├── Commit 3 (UI / Styling / Components): feat(ui) or style(...)
44
+ └── Commit 4 (Memory Phases / Config / Docs): chore(phase-N) or docs(...)
45
+ ```
46
+
47
+ ---
48
+
49
+ ## 4. Anti-AI SOP Commit Standard
50
+
51
+ - **FORBIDDEN:**
52
+ - ❌ "Update files"
53
+ - ❌ "WIP" / "misc fixes" / "make code better"
54
+ - ❌ "Refactor code for improved readability and maintainability" (AI fluff)
55
+ - ❌ Monolithic 500-line commits combining UI, backend, tests, and config together.
56
+ - **MANDATORY:**
57
+ - ✅ Imperative present tense in header ("add", "fix", "refactor", not "added" or "adds").
58
+ - ✅ Explicit scope in header: `feat(api): ...`, `fix(layout): ...`, `test(auth): ...`.
59
+ - ✅ Verification evidence in footer: `Verified: pytest passed (14 tests)`.
@@ -0,0 +1,48 @@
1
+ # Memory Skills — Decision Making Matrix
2
+
3
+ This document dictates how the Virtual Memory system is invoked, controlled, and cleaned.
4
+
5
+ ---
6
+
7
+ ## 1. The User Control Gate (Strict Policy)
8
+
9
+ **The agent does NOT write every casual turn or trivial task into memory.**
10
+ - Virtual memory is disk-backed and persistent (`.agents/memory/plans/` and `.agents/memory/phases/`).
11
+ - **Trigger Condition:** The agent activates `phase-planner` ONLY when:
12
+ 1. The user explicitly requests: *"add to memory"*, *"save this in memory"*, or *"make a plan for this"*.
13
+ 2. The user initiates a large multi-phase feature and explicitly approves creating a master plan and phase breakdown.
14
+ - If the user has NOT requested memory tracking, execute in-context without cluttering memory folders.
15
+
16
+ ---
17
+
18
+ ## 2. Specialized Skill Selection Matrix
19
+
20
+ | Memory Need | Selected Skills | Why This Combination |
21
+ |---|---|---|
22
+ | **User commands: "add to memory" / multi-phase plan** | `phase-planner` | Creates `.agents/memory/plans/main-plan.md`, breaks it into `.agents/memory/phases/phase-NN-[name].md`, pre-assigns skills, and prints chat dashboard. |
23
+ | **User resumes session: "where were we?"** | `session-continuity` | Inspects `.agents/memory/plans/` and `phases/`, reconstructs active phase status, and renders the dashboard. |
24
+ | **Context window near limit / session handoff** | `context-handoff` | Compacts session deltas, decisions, open blockers, and git diff states into `.agents/memory/handoff-[date].md`. |
25
+ | **Phase completed & verified** | `git-phase-committer` (`$phase-commit`) | Automatically stages and commits phase code, tests, and memory phase files in atomic sequence with verification evidence. |
26
+ | **Task completed & verified** | `phase-planner` (cleanup mode) | Moves `main-plan.md` and all phase files to `.agents/memory/archive/[Date]-[Task]/`, clearing active phase folder. |
27
+
28
+ ---
29
+
30
+ ## 3. The Live Chat Status Dashboard Protocol
31
+
32
+ When memory mode is active, the agent **must** prepend the live status widget at the top of every response:
33
+
34
+ ```markdown
35
+ ┌─────────────────────────────────────────────────────────────┐
36
+ │ 🚀 PHASE STATUS DASHBOARD │
37
+ ├─────────────────────────────────────────────────────────────┤
38
+ │ Task: [Feature Name] │
39
+ │ Phase 1: [Scaffold] -> [FINISHED ✓] │
40
+ │ Phase 2: [Core Logic] -> [IN PROGRESS ⚙️] │
41
+ │ Phase 3: [UI & Polish] -> [PENDING ⏳] │
42
+ ├─────────────────────────────────────────────────────────────┤
43
+ │ Active Phase: Phase 2 │
44
+ │ Active Skills: [skill-a] + [skill-b] │
45
+ │ Stage: [APPLY] -> [EXECUTE 👈] -> [VERIFY] -> [FINISH] │
46
+ └─────────────────────────────────────────────────────────────┘
47
+ ```
48
+