corrections
CI / CI configuration security checks (push) Successful in 6s
CI / Python tests and compilation (push) Failing after 12s
CI / QMD unit tests (push) Skipped
CI / Capabilities and shell quality (push) Successful in 1m50s
CI / Build and inspect generated packages (push) Skipped
CI / Bash integration and installation guards (push) Skipped
CI / Installed client configuration smoke tests (push) Skipped
CI / PowerShell tests on Ubuntu (push) Failing after 7m24s

This commit is contained in:
Julian Lechner committed 2026-11-19 10:30:43 +01:00
1 parent b35e2254b3
commit c3e22eb902
39 files changed
+244 -149

No files matched your search

+6 -6
View File
@@ -1,6 +1,6 @@
role tools role tools skills
architect Read,Grep,Glob,WebFetch,WebSearch,__SHELL_TOOL__ architect Read,Grep,Glob,WebFetch,WebSearch,__SHELL_TOOL__,Skill rules-orchestration
researcher Read,Grep,Glob,WebFetch,WebSearch,__SHELL_TOOL__ researcher Read,Grep,Glob,WebFetch,WebSearch,__SHELL_TOOL__,Skill rules-orchestration,research
reviewer Read,Grep,Glob,__SHELL_TOOL__ reviewer Read,Grep,Glob,__SHELL_TOOL__,Skill rules-orchestration,review-pull-request
verifier Read,Grep,Glob,__SHELL_TOOL__ verifier Read,Grep,Glob,__SHELL_TOOL__,Skill rules-orchestration
implementer Read,Grep,Glob,Edit,Write,__SHELL_TOOL__ implementer Read,Grep,Glob,Edit,Write,__SHELL_TOOL__,Skill rules-orchestration
1 role tools skills
2 architect Read,Grep,Glob,WebFetch,WebSearch,__SHELL_TOOL__ Read,Grep,Glob,WebFetch,WebSearch,__SHELL_TOOL__,Skill rules-orchestration
3 researcher Read,Grep,Glob,WebFetch,WebSearch,__SHELL_TOOL__ Read,Grep,Glob,WebFetch,WebSearch,__SHELL_TOOL__,Skill rules-orchestration,research
4 reviewer Read,Grep,Glob,__SHELL_TOOL__ Read,Grep,Glob,__SHELL_TOOL__,Skill rules-orchestration,review-pull-request
5 verifier Read,Grep,Glob,__SHELL_TOOL__ Read,Grep,Glob,__SHELL_TOOL__,Skill rules-orchestration
6 implementer Read,Grep,Glob,Edit,Write,__SHELL_TOOL__ Read,Grep,Glob,Edit,Write,__SHELL_TOOL__,Skill rules-orchestration
+1 -1
View File
@@ -17,7 +17,7 @@
"hooks": { "hooks": {
"PreToolUse": [ "PreToolUse": [
{"matcher": "Bash|PowerShell", "hooks": [{"type": "command", "command": "__HOOK_COMMAND__ \"__AI_CONFIG_ROOT__/hooks/scripts/__COMMAND_SAFETY_SCRIPT__\"", "timeout": 6}]}, {"matcher": "Bash|PowerShell", "hooks": [{"type": "command", "command": "__HOOK_COMMAND__ \"__AI_CONFIG_ROOT__/hooks/scripts/__COMMAND_SAFETY_SCRIPT__\"", "timeout": 6}]},
{"matcher": "Grep|Glob|Bash|PowerShell", "hooks": [{"type": "command", "command": "__HOOK_COMMAND__ \"__AI_CONFIG_ROOT__/hooks/scripts/__SEARCH_REMINDER_SCRIPT__\"", "timeout": 4}]} {"matcher": "Grep|Glob", "hooks": [{"type": "command", "command": "__HOOK_COMMAND__ \"__AI_CONFIG_ROOT__/hooks/scripts/__SEARCH_REMINDER_SCRIPT__\"", "timeout": 4}]}
], ],
"PreCompact": [{"hooks": [{"type": "command", "command": "__HOOK_COMMAND__ \"__AI_CONFIG_ROOT__/hooks/scripts/__COMPACT_SCRIPT__\"", "timeout": 4}]}], "PreCompact": [{"hooks": [{"type": "command", "command": "__HOOK_COMMAND__ \"__AI_CONFIG_ROOT__/hooks/scripts/__COMPACT_SCRIPT__\"", "timeout": 4}]}],
"SessionStart": [ "SessionStart": [
+1 -1
View File
@@ -1 +1 @@
Read skills/rules-orchestration/SKILL.md from your installed configuration before acting as a subagent. Follow the preloaded `rules-orchestration` skill as a subagent; if it is not in your context, read skills/rules-orchestration/SKILL.md from your installed configuration first.
+1 -9
View File
@@ -65,6 +65,7 @@ command_windows = '__POWERSHELL_HOOK_COMMAND__ "__AI_CONFIG_ROOT__/hooks/scripts
timeout = 4 timeout = 4
# Codex reports every shell command as Bash; on Windows it is PowerShell text, so check both dialects there. # Codex reports every shell command as Bash; on Windows it is PowerShell text, so check both dialects there.
# The same hook process also reminds to run semantic-search before open shell searches; a no-op without QMD.
[[hooks.PreToolUse]] [[hooks.PreToolUse]]
matcher = "Bash" matcher = "Bash"
[[hooks.PreToolUse.hooks]] [[hooks.PreToolUse.hooks]]
@@ -73,15 +74,6 @@ command = '__HOOK_COMMAND__ "__AI_CONFIG_ROOT__/hooks/scripts/__COMMAND_SAFETY_S
command_windows = '__POWERSHELL_HOOK_COMMAND__ "__AI_CONFIG_ROOT__/hooks/scripts/__COMMAND_SAFETY_SCRIPT__" -Shell unknown' command_windows = '__POWERSHELL_HOOK_COMMAND__ "__AI_CONFIG_ROOT__/hooks/scripts/__COMMAND_SAFETY_SCRIPT__" -Shell unknown'
timeout = 6 timeout = 6
# Reminds to run semantic-search before open shell searches and again after every 10 searches without it; a no-op without QMD.
[[hooks.PreToolUse]]
matcher = "Bash"
[[hooks.PreToolUse.hooks]]
type = "command"
command = '__HOOK_COMMAND__ "__AI_CONFIG_ROOT__/hooks/scripts/__SEARCH_REMINDER_SCRIPT__"'
command_windows = '__POWERSHELL_HOOK_COMMAND__ "__AI_CONFIG_ROOT__/hooks/scripts/__SEARCH_REMINDER_SCRIPT__"'
timeout = 4
# Impeccable's design detector; the wrapper is a no-op unless the Impeccable Codex skill is installed. # Impeccable's design detector; the wrapper is a no-op unless the Impeccable Codex skill is installed.
[[hooks.PostToolUse]] [[hooks.PostToolUse]]
matcher = "Edit|Write|apply_patch" matcher = "Edit|Write|apply_patch"
+1 -1
View File
@@ -12,7 +12,7 @@ Use only the roles that are likely to improve the outcome. Choose `researcher`,
## Research tools ## Research tools
Claude's [capability manifest](../adapters/claude/capabilities.tsv) gives `architect` and `researcher` file inspection, web research, and the package's shell tool (`PowerShell` or `Bash`). Shell access supports mandatory semantic search and Context7 research through MCPorter. Their role instructions scope shell use to inspection and research; this is an instruction-level boundary, not a read-only shell sandbox. Claude's [capability manifest](../adapters/claude/capabilities.tsv) gives `architect` and `researcher` file inspection, web research, and the package's shell tool (`PowerShell` or `Bash`). Every role also gets the `Skill` tool, so it can load `technical-research`, `semantic-search`, and the `rules-*` skills its instructions require. The manifest's optional `skills` column lists skills Claude preloads into the agent at startup: `rules-orchestration` for every role, plus `research` for `researcher` and `review-pull-request` for `reviewer`. The build fails if a preloaded skill is missing from the package. Subagents skip `plugin-workflow`; the parent passes the constraints that apply. Shell access supports mandatory semantic search and Context7 research through MCPorter. Their role instructions scope shell use to inspection and research; this is an instruction-level boundary, not a read-only shell sandbox.
The `reviewer` may inspect Git diffs and run required research commands through its shell tool. Tests, builds, and behavior reproduction belong to the `verifier` or parent. Missing execution evidence remains an explicit review gap. Codex receives the same role instructions; the Claude tool manifest is client-specific. The `reviewer` may inspect Git diffs and run required research commands through its shell tool. Tests, builds, and behavior reproduction belong to the `verifier` or parent. Missing execution evidence remains an explicit review gap. Codex receives the same role instructions; the Claude tool manifest is client-specific.
+1 -1
View File
@@ -89,7 +89,7 @@ They stop a running QMD daemon first, so the next search uses the new scripts an
the setup installed is reinstalled at the tested version; a foreign installation of another version is kept the setup installed is reinstalled at the tested version; a foreign installation of another version is kept
and reported. `doctor` checks the runtime scripts, the QMD version, the model files, and the daemon. and reported. `doctor` checks the runtime scripts, the QMD version, the model files, and the daemon.
Repository indexes skip git-ignored files, npm and pnpm lockfiles, and minified `*.min.js` bundles. Repository indexes skip git-ignored files, npm and pnpm lockfiles, and minified `*.min.js` bundles.
They cover source, web templates and styles, .NET and WPF markup and project files, and JVM build files; the They cover source, web templates and styles, .NET and WPF markup and project files; the
file mask lives in `MASK` in `shared/qmd/qmd-lib.mjs` and is reapplied to existing repository collections. file mask lives in `MASK` in `shared/qmd/qmd-lib.mjs` and is reapplied to existing repository collections.
Where the Claude sandbox is enabled (macOS, Linux, WSL2), the exact search command is listed in Where the Claude sandbox is enabled (macOS, Linux, WSL2), the exact search command is listed in
`sandbox.excludedCommands`, because the sandbox blocks the localhost daemon and the index under the home directory. `sandbox.excludedCommands`, because the sandbox blocks the localhost daemon and the index under the home directory.
+1 -1
View File
@@ -7,7 +7,7 @@ The adapters register these events:
| Client | Event | Action | | Client | Event | Action |
| --- | --- | --- | | --- | --- | --- |
| Codex and Claude | `PreToolUse` | Block clearly destructive shell commands (`Validate-CommandSafety`/`validate-command-safety.sh`); Claude matches the `Bash` and `PowerShell` tools, Codex matches `Bash` and on Windows checks both dialects (`-Shell unknown`), because Codex reports PowerShell script text as `Bash`. | | Codex and Claude | `PreToolUse` | Block clearly destructive shell commands (`Validate-CommandSafety`/`validate-command-safety.sh`); Claude matches the `Bash` and `PowerShell` tools, Codex matches `Bash` and on Windows checks both dialects (`-Shell unknown`), because Codex reports PowerShell script text as `Bash`. |
| Codex and Claude | `PreToolUse` | Remind the agent to run `semantic-search` before the first open search and again after every 10 open searches without it (`Show-SearchReminder`/`show-search-reminder.sh`); a no-op unless QMD's `qmd-search.mjs` is installed. Claude matches `Grep`, `Glob`, `Bash`, and `PowerShell`; Codex matches `Bash`. | | Codex and Claude | `PreToolUse` | Remind the agent to run `semantic-search` before the first open search and again after every 10 open searches without it; a no-op unless QMD's `qmd-search.mjs` is installed. Shell commands are checked inside the command-safety hook process, so each shell call starts one hook process. Claude adds a separate hook for `Grep` and `Glob` (`Show-SearchReminder`/`show-search-reminder.sh`). |
| Codex and Claude | `Stop` | Run the finish notification (`flashbang`). | | Codex and Claude | `Stop` | Run the finish notification (`flashbang`). |
| Codex and Claude | `Stop` | Push back once on an unbacked completion claim (`Check-CompletionEvidence`/`check-completion-evidence.sh`). | | Codex and Claude | `Stop` | Push back once on an unbacked completion claim (`Check-CompletionEvidence`/`check-completion-evidence.sh`). |
| Codex and Claude | `UserPromptSubmit` | Ask the agent to propose a durable rule when a prompt looks like a correction (`Show-CorrectionPrompt`/`show-correction-prompt.sh`). | | Codex and Claude | `UserPromptSubmit` | Ask the agent to propose a durable rule when a prompt looks like a correction (`Show-CorrectionPrompt`/`show-correction-prompt.sh`). |
+2 -2
View File
@@ -6,9 +6,9 @@ The current baseline includes Ponytail, i-have-adhd, Superpowers, Context7, Cave
### Automatic workflow integration ### Automatic workflow integration
The always-loaded general rules require both clients to load the shared `plugin-workflow` skill at the start of every session and task, including questions and prose-only work, and again after resume, compaction, and phase changes. Each plugin layer inside it applies only at its own triggers, so development-only layers stay idle for questions and prose. The policy requires Superpowers at development phase boundaries, Ponytail for implementation and review, Impeccable for UI planning through verification, Modern Web Guidance before HTML, CSS, client-side script, or browser-extension changes, and i-have-adhd response structure with Caveman's concise style when available. Superpowers owns process; Ponytail constrains implementation to the smallest complete, verified change; Impeccable owns UI decisions; Modern Web Guidance picks web platform APIs and patterns. Modern Web Guidance fetches its guides through `npx`, so it needs npm registry access. The general rules themselves also require Humanizer when writing or substantially rewriting prose read outside the chat (documentation, comments, commit or PR bodies, UI copy, messages). Chat replies and small fixes such as typos skip it. User authorization, research gates, and proportionate checks retain precedence. The always-loaded general rules require both clients to load the shared `plugin-workflow` skill at the start of every session, including questions and prose-only work, and again after resume and compaction. UI work additionally loads the shared `ui-workflow` skill, which runs Impeccable and Apple Design as one design loop. Each plugin layer inside it applies only at its own triggers, so development-only layers stay idle for questions and prose. The policy requires Superpowers at development phase boundaries, Ponytail for implementation and review, Impeccable for UI planning through verification, Modern Web Guidance before HTML, CSS, client-side script, or browser-extension changes, and i-have-adhd response structure with Caveman's concise style when available. Superpowers owns process; Ponytail constrains implementation to the smallest complete, verified change; Impeccable owns UI decisions; Modern Web Guidance picks web platform APIs and patterns. Modern Web Guidance fetches its guides through `npx`, so it needs npm registry access. The general rules themselves also require Humanizer when writing or substantially rewriting prose read outside the chat (documentation, comments, commit or PR bodies, UI copy, messages). Chat replies and small fixes such as typos skip it. User authorization, research gates, and proportionate checks retain precedence.
The installed i-have-adhd 0.4.1 skill declares `disable-model-invocation: true`. The shared policy therefore supplies automatic response guidance without forcing a manual-only skill invocation. In addition, when i-have-adhd is selected, install and update create its opt-in flag `.i-have-adhd-always` in the Claude configuration directory (`CLAUDE_CONFIG_DIR`, default `~/.claude`), so the plugin's SessionStart hook injects the full ruleset into every session. Deselecting the plugin leaves the flag in place; it has no effect without the plugin, and deleting it turns always-on off. It does not diagnose the user. Style stop commands persist through task changes and resume; `normal mode` disables i-have-adhd, Caveman, and Ponytail for the session. Ponytail runs at `ultra` by default: when Ponytail is selected, install and update set `defaultMode` to `ultra` in Ponytail's config file (`%APPDATA%\ponytail\config.json` on Windows, `~/.config/ponytail/config.json` elsewhere, or under `$XDG_CONFIG_HOME`) and keep its other keys. `PONYTAIL_DEFAULT_MODE` still takes precedence. Besides `ponytail-review`, the workflow routes whole-repository quality audits to `ponytail-audit` and questions about deferred `shortcut:` comments to `ponytail-debt`; both also run on demand as `/ponytail-audit` and `/ponytail-debt` and change nothing. Caveman contributes only its response style: its process skills (such as `surgical-patch`, `safe-refactor`, `verify-and-stop`, and `caveman-explore`) overlap Superpowers, Ponytail, and the research skills, so the workflow does not route to them. Impeccable starts its own review and documentation agents. Explicit mode levels override defaults. Missing plugins are reported once and do not trigger installation. These are instruction-level requirements, not runtime interception or a guarantee of model compliance. Existing installations receive them through the normal configuration update; builds do not modify local plugin caches or hook trust. The installed i-have-adhd 0.4.1 skill declares `disable-model-invocation: true`. The shared policy therefore supplies automatic response guidance without forcing a manual-only skill invocation. Install and update do not create the plugin's opt-in flag `.i-have-adhd-always` in the Claude configuration directory (`CLAUDE_CONFIG_DIR`, default `~/.claude`): its SessionStart hook would inject the full ruleset into every session and duplicate the shared guidance. A flag left by an older setup stays in place; delete it to turn always-on off. It does not diagnose the user. Style stop commands persist through task changes and resume; `normal mode` disables i-have-adhd, Caveman, and Ponytail for the session. Ponytail runs at `ultra` by default: when Ponytail is selected, install and update set `defaultMode` to `ultra` in Ponytail's config file (`%APPDATA%\ponytail\config.json` on Windows, `~/.config/ponytail/config.json` elsewhere, or under `$XDG_CONFIG_HOME`) and keep its other keys. `PONYTAIL_DEFAULT_MODE` still takes precedence. Besides `ponytail-review`, the workflow routes whole-repository quality audits to `ponytail-audit` and questions about deferred `shortcut:` comments to `ponytail-debt`; both also run on demand as `/ponytail-audit` and `/ponytail-debt` and change nothing. Caveman contributes only its response style: its process skills (such as `surgical-patch`, `safe-refactor`, `verify-and-stop`, and `caveman-explore`) overlap Superpowers, Ponytail, and the research skills, so the workflow does not route to them. Impeccable starts its own review and documentation agents. Explicit mode levels override defaults. Missing plugins are reported once and do not trigger installation. These are instruction-level requirements, not runtime interception or a guarantee of model compliance. Existing installations receive them through the normal configuration update; builds do not modify local plugin caches or hook trust.
### REA (Reverse Engineer Anything) ### REA (Reverse Engineer Anything)
+1 -1
View File
@@ -15,7 +15,7 @@ The current structure is organized by purpose:
General planning, debugging, code review, and completion verification workflows come from Superpowers, so the catalog does not duplicate their triggers. The remaining skills cover focused domains Superpowers does not. General planning, debugging, code review, and completion verification workflows come from Superpowers, so the catalog does not duplicate their triggers. The remaining skills cover focused domains Superpowers does not.
The shared `plugin-workflow` skill coordinates automatic plugin use: Superpowers for process, Ponytail for implementation and review, Impeccable and Apple Design together for UI (Impeccable leads direction and edits, Apple Design supplies cited platform and accessibility constraints and a merged review), REA for reverse engineering, and i-have-adhd with Caveman for responses. Global instructions require loading it for every session and task, including questions and prose, and again after resume, compaction, and phase changes; each plugin layer inside it applies only at its own triggers. It routes to installed skills, preserves explicit opt-outs, and handles missing or manual-only plugins without replacing upstream workflows. The shared `plugin-workflow` skill coordinates automatic plugin use: Superpowers for process, Ponytail for implementation and review, the shared `ui-workflow` skill for UI (Impeccable leads direction and edits, Apple Design supplies cited platform and accessibility constraints and a merged review), REA for reverse engineering, and i-have-adhd with Caveman for responses. Global instructions require loading it at the start of every session, including questions and prose, and again after resume and compaction; each plugin layer inside it applies only at its own triggers. It routes to installed skills, preserves explicit opt-outs, and handles missing or manual-only plugins without replacing upstream workflows.
Each skill defines a focused workflow with the investigation, decision points, and output expected for that task. Each skill also has an `evals/evals.json` with test prompts and checkable assertions derived from its instructions, including negative and near-miss cases; some assertions about tool use or skill loading can only be graded from a session transcript. Keep guidance specific to the skill; shared repository constraints belong in the rules. Each skill defines a focused workflow with the investigation, decision points, and output expected for that task. Each skill also has an `evals/evals.json` with test prompts and checkable assertions derived from its instructions, including negative and near-miss cases; some assertions about tool use or skill loading can only be graded from a session transcript. Keep guidance specific to the skill; shared repository constraints belong in the rules.
+9 -1
View File
@@ -18,7 +18,7 @@ CLAUDE_SANDBOX_EXCLUDED = ['node "$HOME/.my-ai-configuration/qmd/qmd-search.mjs"
CLAUDE_STATUS_LINE_KEYS = {"type", "command"} CLAUDE_STATUS_LINE_KEYS = {"type", "command"}
CLAUDE_HOOK_KEYS = {"type", "command", "timeout"} CLAUDE_HOOK_KEYS = {"type", "command", "timeout"}
CLAUDE_PERMISSION_MODES = {"acceptEdits", "auto", "bypassPermissions", "default", "dontAsk", "plan"} CLAUDE_PERMISSION_MODES = {"acceptEdits", "auto", "bypassPermissions", "default", "dontAsk", "plan"}
CLAUDE_VALID_TOOLS = {"Read", "Grep", "Glob", "Edit", "Write", "Bash", "PowerShell", "WebFetch", "WebSearch"} CLAUDE_VALID_TOOLS = {"Read", "Grep", "Glob", "Edit", "Write", "Bash", "PowerShell", "WebFetch", "WebSearch", "Skill"}
def fail(message: str) -> None: def fail(message: str) -> None:
@@ -91,6 +91,14 @@ def validate_agent_tools(package: Path) -> None:
unknown = [tool for tool in tools if tool not in CLAUDE_VALID_TOOLS] unknown = [tool for tool in tools if tool not in CLAUDE_VALID_TOOLS]
if unknown: if unknown:
fail(f"{path}: unknown Claude tool name(s): {', '.join(unknown)}") fail(f"{path}: unknown Claude tool name(s): {', '.join(unknown)}")
# Claude skips a missing preloaded skill silently, so check the names against the package.
if "skills:" in lines:
for line in lines[lines.index("skills:") + 1:]:
if not line.startswith(" - "):
break
skill = line.removeprefix(" - ").strip()
if not (package / "skills" / skill / "SKILL.md").is_file():
fail(f"{path}: preloads missing skill {skill}")
RULE_PATH = re.compile(r"`(rules/[A-Za-z0-9_./-]+\.md)`") RULE_PATH = re.compile(r"`(rules/[A-Za-z0-9_./-]+\.md)`")
+11
View File
@@ -51,9 +51,12 @@ foreach ($pluginEntry in $pluginEntries) {
if (-not (Test-Path -LiteralPath $capabilityManifest)) { throw "Missing capability manifest: $capabilityManifest" } if (-not (Test-Path -LiteralPath $capabilityManifest)) { throw "Missing capability manifest: $capabilityManifest" }
$agentTools = @{} $agentTools = @{}
$agentSkills = @{}
foreach ($entry in @(Import-Csv -LiteralPath $capabilityManifest -Delimiter ([char]9))) { foreach ($entry in @(Import-Csv -LiteralPath $capabilityManifest -Delimiter ([char]9))) {
if ([string]::IsNullOrWhiteSpace($entry.role) -or [string]::IsNullOrWhiteSpace($entry.tools)) { throw 'Invalid capability manifest row.' } if ([string]::IsNullOrWhiteSpace($entry.role) -or [string]::IsNullOrWhiteSpace($entry.tools)) { throw 'Invalid capability manifest row.' }
$agentTools[$entry.role] = $entry.tools $agentTools[$entry.role] = $entry.tools
# Optional: skills whose full content Claude preloads into the subagent at startup.
$agentSkills[$entry.role] = @(([string]$entry.skills).Split(',') | ForEach-Object { $_.Trim() } | Where-Object { $_ })
} }
# Build into a private sibling directory and swap it into place only after validation, so a failed # Build into a private sibling directory and swap it into place only after validation, so a failed
@@ -171,7 +174,14 @@ foreach ($shell in @('powershell','bash')) {
$ruleContent = Get-Content $ruleSkill.Body -Raw $ruleContent = Get-Content $ruleSkill.Body -Raw
$ruleTitle = (Get-Content $ruleSkill.Body | Where-Object { $_ -match '^#+\s+' } | Select-Object -First 1) -replace '^#+\s+', '' $ruleTitle = (Get-Content $ruleSkill.Body | Where-Object { $_ -match '^#+\s+' } | Select-Object -First 1) -replace '^#+\s+', ''
if ([string]::IsNullOrWhiteSpace($ruleTitle)) { throw "Missing rule title in $($ruleSkill.Body)" } if ([string]::IsNullOrWhiteSpace($ruleTitle)) { throw "Missing rule title in $($ruleSkill.Body)" }
# The rule's opening "Apply ..."/"For ..." sentence states when it applies; it is a better trigger than the title.
$ruleLead = Get-Content $ruleSkill.Body | Where-Object { $_.Trim() -and $_ -notmatch '^#' } | Select-Object -First 1
if ($ruleLead -match '^(Apply|For)\s') {
$sentenceEnd = $ruleLead.IndexOf('. ')
$ruleDescription = if ($sentenceEnd -ge 0) { $ruleLead.Substring(0, $sentenceEnd + 1) } else { $ruleLead.TrimEnd() }
} else {
$ruleDescription = "Use when the task concerns $ruleTitle." $ruleDescription = "Use when the task concerns $ruleTitle."
}
$skillBody = "---`r`nname: $($ruleSkill.Name)`r`ndescription: $(Quote-Toml $ruleDescription)`r`n---`r`n`r`n$ruleContent" $skillBody = "---`r`nname: $($ruleSkill.Name)`r`ndescription: $(Quote-Toml $ruleDescription)`r`n---`r`n`r`n$ruleContent"
Set-Content (Join-Path $skillDir 'SKILL.md') $skillBody -Encoding UTF8 Set-Content (Join-Path $skillDir 'SKILL.md') $skillBody -Encoding UTF8
if ($ruleSkill.References -and (Test-Path -LiteralPath $ruleSkill.References)) { if ($ruleSkill.References -and (Test-Path -LiteralPath $ruleSkill.References)) {
@@ -206,6 +216,7 @@ foreach ($shell in @('powershell','bash')) {
if ($tools) { $tools = Expand-ShellPlaceholders $tools $shell } if ($tools) { $tools = Expand-ShellPlaceholders $tools $shell }
$frontmatter = "---`r`nname: $name`r`ndescription: $description`r`n" $frontmatter = "---`r`nname: $name`r`ndescription: $description`r`n"
if ($tools) { $frontmatter += "tools: $tools`r`n" } if ($tools) { $frontmatter += "tools: $tools`r`n" }
if ($agentSkills[$name]) { $frontmatter += "skills:`r`n" + (($agentSkills[$name] | ForEach-Object { " - $_`r`n" }) -join '') }
Set-Content (Join-Path $agentsOutput "$name.md") ($frontmatter + "---`r`n`r`n$instructions") -Encoding UTF8 Set-Content (Join-Path $agentsOutput "$name.md") ($frontmatter + "---`r`n`r`n$instructions") -Encoding UTF8
} }
} }
+24 -4
View File
@@ -65,11 +65,13 @@ expand_shell_placeholders() {
[ -f "$plugin_manifest" ] || { printf 'Missing plugin manifest: %s\n' "$plugin_manifest" >&2; exit 1; } [ -f "$plugin_manifest" ] || { printf 'Missing plugin manifest: %s\n' "$plugin_manifest" >&2; exit 1; }
awk -F '\t' 'NR == 1 { next } NF == 0 { next } $1 == "" || $3 == "" || $6 == "" { print "Invalid plugin manifest row." > "/dev/stderr"; exit 1 } seen[$1]++ { print "Duplicate plugin name in manifest: " $1 > "/dev/stderr"; exit 1 }' "$plugin_manifest" awk -F '\t' 'NR == 1 { next } NF == 0 { next } $1 == "" || $3 == "" || $6 == "" { print "Invalid plugin manifest row." > "/dev/stderr"; exit 1 } seen[$1]++ { print "Duplicate plugin name in manifest: " $1 > "/dev/stderr"; exit 1 }' "$plugin_manifest"
[ -f "$capability_manifest" ] || { printf 'Missing capability manifest: %s\n' "$capability_manifest" >&2; exit 1; } [ -f "$capability_manifest" ] || { printf 'Missing capability manifest: %s\n' "$capability_manifest" >&2; exit 1; }
declare -A agent_tools declare -A agent_tools agent_skills
while IFS=$'\t' read -r role tools; do while IFS=$'\t' read -r role tools skills; do
[ "$role" != role ] || continue [ "$role" != role ] || continue
[ -n "$role" ] && [ -n "$tools" ] || { printf 'Invalid capability manifest row.\n' >&2; exit 1; } [ -n "$role" ] && [ -n "$tools" ] || { printf 'Invalid capability manifest row.\n' >&2; exit 1; }
agent_tools[$role]="$tools" agent_tools[$role]="$tools"
# Optional: skills whose full content Claude preloads into the subagent at startup.
agent_skills[$role]="${skills:-}"
done < "$capability_manifest" done < "$capability_manifest"
copy_directory() { copy_directory() {
@@ -178,7 +180,16 @@ while IFS= read -r rule_path; do
mkdir -p "$skill_dir" mkdir -p "$skill_dir"
rule_title=$(sed -n 's/^#\{1,6\} *//p' "$rule_body" | head -n 1) rule_title=$(sed -n 's/^#\{1,6\} *//p' "$rule_body" | head -n 1)
if [ -z "$rule_title" ]; then printf 'Missing rule title in %s\n' "$rule_body" >&2; exit 1; fi if [ -z "$rule_title" ]; then printf 'Missing rule title in %s\n' "$rule_body" >&2; exit 1; fi
rule_description="Use when the task concerns $rule_title." # The rule's opening "Apply ..."/"For ..." sentence states when it applies; it is a better trigger than the title.
rule_lead=$(grep -v -e '^#' -e '^[[:space:]]*$' "$rule_body" | head -n 1 | tr -d '\r')
case "$rule_lead" in
'Apply '*|'For '*)
rule_description=${rule_lead%%. *}
if [ "$rule_description" != "$rule_lead" ]; then rule_description="$rule_description."; fi
rule_description=${rule_description%"${rule_description##*[![:space:]]}"}
;;
*) rule_description="Use when the task concerns $rule_title." ;;
esac
{ printf -- '---\nname: %s\ndescription: %s\n---\n\n' "$skill_name" "$(quote_toml "$rule_description")"; cat "$rule_body"; } > "$skill_dir/SKILL.md" { printf -- '---\nname: %s\ndescription: %s\n---\n\n' "$skill_name" "$(quote_toml "$rule_description")"; cat "$rule_body"; } > "$skill_dir/SKILL.md"
if [ -n "$references_dir" ] && [ -d "$references_dir" ]; then if [ -n "$references_dir" ] && [ -d "$references_dir" ]; then
copy_directory "$references_dir" "$skill_dir/references" copy_directory "$references_dir" "$skill_dir/references"
@@ -207,7 +218,16 @@ for client in codex claude; do
printf 'name = %s\ndescription = %s\ndeveloper_instructions = %s\n' "$(quote_toml "$name")" "$(quote_toml "$description")" "$(quote_toml "$instructions")" > "$agents_output/$name.toml" printf 'name = %s\ndescription = %s\ndeveloper_instructions = %s\n' "$(quote_toml "$name")" "$(quote_toml "$description")" "$(quote_toml "$instructions")" > "$agents_output/$name.toml"
else else
tools=$(expand_shell_placeholders "${agent_tools[$name]:-}" "$shell") tools=$(expand_shell_placeholders "${agent_tools[$name]:-}" "$shell")
if [ -n "$tools" ]; then printf '%s\nname: %s\ndescription: %s\ntools: %s\n%s\n\n%s\n' '---' "$name" "$description" "$tools" '---' "$instructions" > "$agents_output/$name.md"; else printf '%s\nname: %s\ndescription: %s\n%s\n\n%s\n' '---' "$name" "$description" '---' "$instructions" > "$agents_output/$name.md"; fi {
printf -- '---\nname: %s\ndescription: %s\n' "$name" "$description"
if [ -n "$tools" ]; then printf 'tools: %s\n' "$tools"; fi
if [ -n "${agent_skills[$name]:-}" ]; then
printf 'skills:\n'
IFS=',' read -r -a preload <<<"${agent_skills[$name]}"
for skill in "${preload[@]}"; do skill=${skill//[[:space:]]/}; [ -z "$skill" ] || printf ' - %s\n' "$skill"; done
fi
printf -- '---\n\n%s\n' "$instructions"
} > "$agents_output/$name.md"
fi fi
done done
done done
-15
View File
@@ -526,19 +526,6 @@ class Manager:
config['defaultMode'] = PONYTAIL_MODE config['defaultMode'] = PONYTAIL_MODE
atomic_write(path, (json.dumps(config, indent=2) + '\n').encode('utf-8')) atomic_write(path, (json.dumps(config, indent=2) + '\n').encode('utf-8'))
def ensure_adhd_always_on(self):
# i-have-adhd's SessionStart hook injects its full ruleset only while this opt-in flag exists.
path = Path(os.environ.get('CLAUDE_CONFIG_DIR') or self.home / '.claude') / '.i-have-adhd-always'
if path.is_file() and not linked(path):
return
if self.dry_run:
if not self.summary:
print('DRYRUN enable i-have-adhd always-on mode')
return
if linked(path) or path.exists():
raise ValueError('i-have-adhd always-on flag path is a link or not a file.')
atomic_write(path, b'')
def ensure_mcporter(self, entry, clients): def ensure_mcporter(self, entry, clients):
server, url = entry['mcporter_name'], entry['mcporter_url'] server, url = entry['mcporter_name'], entry['mcporter_url']
if not re.fullmatch(r'[a-z0-9-]+', server) or not re.fullmatch(r'https://[^\s]+', url): if not re.fullmatch(r'[a-z0-9-]+', server) or not re.fullmatch(r'https://[^\s]+', url):
@@ -677,8 +664,6 @@ class Manager:
self.ensure(client, entry) self.ensure(client, entry)
if 'Ponytail' in direct_entries: if 'Ponytail' in direct_entries:
self.ensure_ponytail_mode() self.ensure_ponytail_mode()
if 'i-have-adhd' in direct_entries:
self.ensure_adhd_always_on()
for entry in mcporter_entries.values(): for entry in mcporter_entries.values():
self.ensure_mcporter(entry, clients) self.ensure_mcporter(entry, clients)
print('EXTENSIONS: reconciliation complete' + (' (dry run)' if self.dry_run else '')) print('EXTENSIONS: reconciliation complete' + (' (dry run)' if self.dry_run else ''))
+7
View File
@@ -70,6 +70,13 @@ Test-BuildFails 'unknown Claude tool name in capability manifest' {
Set-Content $manifest $lines Set-Content $manifest $lines
} }
Test-BuildFails 'missing preloaded skill in capability manifest' {
param($copy)
$manifest = Join-Path $copy 'adapters/claude/capabilities.tsv'
$lines = Get-Content $manifest | ForEach-Object { if ($_ -match '^architect\t') { $_ + ',no-such-skill' } else { $_ } }
Set-Content $manifest $lines
}
Test-BuildFails 'duplicate plugin name' { Test-BuildFails 'duplicate plugin name' {
param($copy) param($copy)
$manifest = Join-Path $copy 'adapters/plugins.tsv' $manifest = Join-Path $copy 'adapters/plugins.tsv'
+5
View File
@@ -71,6 +71,11 @@ mutate_invalid_tool_name() {
} }
test_build_fails 'unknown Claude tool name in capability manifest' mutate_invalid_tool_name test_build_fails 'unknown Claude tool name in capability manifest' mutate_invalid_tool_name
mutate_missing_preloaded_skill() {
sed -i 's/^\(architect\t.*\)$/\1,no-such-skill/' "$1/adapters/claude/capabilities.tsv"
}
test_build_fails 'missing preloaded skill in capability manifest' mutate_missing_preloaded_skill
mutate_duplicate_plugin() { mutate_duplicate_plugin() {
local manifest="$1/adapters/plugins.tsv" local manifest="$1/adapters/plugins.tsv"
sed -n '2p' "$manifest" >> "$manifest" sed -n '2p' "$manifest" >> "$manifest"
+20
View File
@@ -113,6 +113,26 @@ class HookTests(unittest.TestCase):
self.assertBlocked('rm -r build', 'shell') self.assertBlocked('rm -r build', 'shell')
self.assertBlocked('rm -rf build', 'shell') self.assertBlocked('rm -rf build', 'shell')
def test_allowed_shell_search_gets_the_search_reminder_in_the_same_process(self):
with tempfile.TemporaryDirectory() as directory:
home = Path(directory)
(home / '.my-ai-configuration/qmd').mkdir(parents=True)
(home / '.my-ai-configuration/qmd/qmd-search.mjs').write_text('')
env = dict(os.environ, HOME=str(home), USERPROFILE=str(home))
def run(command, session='s1'):
payload = json.dumps({'session_id': session, 'tool_name': 'Bash', 'tool_input': {'command': command}})
return subprocess.run([sys.executable, str(SAFETY), '--hook'], input=payload, capture_output=True,
encoding='utf-8', timeout=20, env=env)
result = run('rg Tile')
self.assertEqual(result.returncode, 0, result.stderr)
self.assertIn('additionalContext', result.stdout)
self.assertEqual('', run('git status', 's2').stdout)
blocked = run('rm -rf build && rg x', 's3')
self.assertEqual(blocked.returncode, 2)
self.assertEqual('', blocked.stdout)
def test_fails_open_on_unusable_input(self): def test_fails_open_on_unusable_input(self):
for payload in ('', 'not json', '[]', '{"tool_input": "rm -rf /"}', '{"tool_input": {"command": 5}}'): for payload in ('', 'not json', '[]', '{"tool_input": "rm -rf /"}', '{"tool_input": {"command": 5}}'):
with self.subTest(payload=payload): with self.subTest(payload=payload):
+2 -7
View File
@@ -365,17 +365,12 @@ class ManagedExtensionTests(unittest.TestCase):
with self.assertRaisesRegex(ValueError, 'Another install or update is running'): with self.assertRaisesRegex(ValueError, 'Another install or update is running'):
extensions.acquire_lock(lock) extensions.acquire_lock(lock)
def test_selected_adhd_enables_always_on_flag_once(self): def test_selected_adhd_does_not_enable_always_on_flag(self):
# plugin-workflow carries the response structure; the full always-on ruleset would duplicate it.
config = self.home / '.claude' config = self.home / '.claude'
flag = config / '.i-have-adhd-always' flag = config / '.i-have-adhd-always'
with patch.dict(os.environ, {'CLAUDE_CONFIG_DIR': str(config)}): with patch.dict(os.environ, {'CLAUDE_CONFIG_DIR': str(config)}):
self.manager(dry_run=True).sync([plugin('i-have-adhd')], ['claude'], {'i-have-adhd'})
self.assertFalse(flag.exists())
for _ in range(2):
self.manager().sync([plugin('i-have-adhd')], ['claude'], {'i-have-adhd'}) self.manager().sync([plugin('i-have-adhd')], ['claude'], {'i-have-adhd'})
self.assertTrue(flag.is_file())
flag.unlink()
self.manager().sync([plugin('Example')], ['claude'], {'Example'})
self.assertFalse(flag.exists()) self.assertFalse(flag.exists())
def test_dry_run_summary_has_one_line(self): def test_dry_run_summary_has_one_line(self):
+1 -1
View File
@@ -4,6 +4,6 @@ Provide static and semantic correctness review using the acceptance criteria and
Use shell commands to inspect diffs and run required research tools, including semantic search (when installed) and MCPorter. Do not run tests, builds, or runtime checks; reuse supplied execution evidence and report gaps to the parent or verifier. Use shell commands to inspect diffs and run required research tools, including semantic search (when installed) and MCPorter. Do not run tests, builds, or runtime checks; reuse supplied execution evidence and report gaps to the parent or verifier.
For each finding, report SEVERITY (blocking, important, or minor), LOCATION, IMPACT, EVIDENCE, and SCOPE (introduced, pre-existing, or uncertain). Do not report stylistic preferences or pre-existing issues unless they materially affect the requested change. Prioritize actionable correctness defects, keep unrelated cleanup out of scope, and use blocking only for security, data-loss, broken contracts, or deterministic failures. Run the review through `review-pull-request`: it owns the specialist list, severity scale, finding schema, and dedup rules. Do not report stylistic preferences, and keep unrelated cleanup out of scope.
Check logic, regressions, architecture, maintainability, security, and contract consistency. Follow the shared orchestration handoff protocol. Do not modify implementation code unless assigned. Check logic, regressions, architecture, maintainability, security, and contract consistency. Follow the shared orchestration handoff protocol. Do not modify implementation code unless assigned.
+1 -1
View File
@@ -4,7 +4,7 @@ This directory contains registered hooks and optional utilities. They do not byp
When Flashbang is enabled, both clients register `Stop` (`flashbang`) for finish notifications. Both clients also register `PreCompact` (`Record-Compact`/`record-compact.sh`) and `SessionStart` (`Show-SessionStatePointer`/`show-session-state-pointer.sh`). Codex additionally registers `SessionStart` (`Show-CavemanMode`/`show-caveman-mode.sh`), which prints the installed Caveman skill so caveman style is always on, as the Claude plugin's own hook does. PreCompact records its timestamp under the installed configuration root. Both session hooks point to an existing workspace `.ai-session/state.json`, using event `cwd` or the process working directory. The main agent owns that state; hooks never write it or print its contents. Missing state is a successful no-op. When Flashbang is enabled, both clients register `Stop` (`flashbang`) for finish notifications. Both clients also register `PreCompact` (`Record-Compact`/`record-compact.sh`) and `SessionStart` (`Show-SessionStatePointer`/`show-session-state-pointer.sh`). Codex additionally registers `SessionStart` (`Show-CavemanMode`/`show-caveman-mode.sh`), which prints the installed Caveman skill so caveman style is always on, as the Claude plugin's own hook does. PreCompact records its timestamp under the installed configuration root. Both session hooks point to an existing workspace `.ai-session/state.json`, using event `cwd` or the process working directory. The main agent owns that state; hooks never write it or print its contents. Missing state is a successful no-op.
Both clients register `PreToolUse` (`Validate-CommandSafety`/`validate-command-safety.sh`), which blocks clearly destructive shell commands by exiting 2; it parses command text, so it is a guard rail rather than a security boundary, and it fails open. Both clients also register `Stop` (`Check-CompletionEvidence`/`check-completion-evidence.sh`) and `UserPromptSubmit` (`Show-CorrectionPrompt`/`show-correction-prompt.sh`). Both call `agent-guards.py`, store nothing, and fail open. The first pushes back once on a completion claim without a named check while non-prose changes exist; the second asks the agent to propose a durable rule after a likely correction. A second `PreToolUse` hook (`Show-SearchReminder`/`show-search-reminder.sh`, also through `agent-guards.py`) reminds the agent to run `semantic-search` before the first open search and again after every 10 open searches without `qmd-search.mjs`, which also covers context lost to compaction; it never blocks, stays silent while the session keeps using `qmd-search.mjs`, does nothing unless QMD is installed, and keeps only hashed per-session markers under `~/.my-ai-configuration/state/search-reminder/`. Both clients register `PreToolUse` (`Validate-CommandSafety`/`validate-command-safety.sh`), which blocks clearly destructive shell commands by exiting 2; it parses command text, so it is a guard rail rather than a security boundary, and it fails open. Both clients also register `Stop` (`Check-CompletionEvidence`/`check-completion-evidence.sh`) and `UserPromptSubmit` (`Show-CorrectionPrompt`/`show-correction-prompt.sh`). Both call `agent-guards.py`, store nothing, and fail open. The first pushes back once on a completion claim without a named check while non-prose changes exist; the second asks the agent to propose a durable rule after a likely correction. The command-safety hook also runs the search reminder from `agent-guards.py` in the same process for shell commands, and Claude registers a second `PreToolUse` hook (`Show-SearchReminder`/`show-search-reminder.sh`) for `Grep` and `Glob`. The reminder the agent to run `semantic-search` before the first open search and again after every 10 open searches without `qmd-search.mjs`, which also covers context lost to compaction; it never blocks, stays silent while the session keeps using `qmd-search.mjs`, does nothing unless QMD is installed, and keeps only hashed per-session markers under `~/.my-ai-configuration/state/search-reminder/`.
`Invoke-PostChangeVerification`/`invoke-post-change-verification.sh` is not registered or invoked automatically; it runs the repository build only when explicitly invoked. Python-based hooks resolve their interpreter through `Resolve-Python.ps1`/`resolve-python.sh` and are silently skipped without Python 3.11+. `Test-SessionConfig`/`test-session-config.sh` checks repository inputs during a build. `Invoke-PostChangeVerification`/`invoke-post-change-verification.sh` is not registered or invoked automatically; it runs the repository build only when explicitly invoked. Python-based hooks resolve their interpreter through `Resolve-Python.ps1`/`resolve-python.sh` and are silently skipped without Python 3.11+. `Test-SessionConfig`/`test-session-config.sh` checks repository inputs during a build.
+14
View File
@@ -8,6 +8,7 @@ command text and cannot see what scripts, aliases, or variables expand to at run
""" """
import argparse import argparse
import importlib.util
import json import json
import ntpath import ntpath
import os import os
@@ -250,9 +251,22 @@ def run_hook(data, shell_override=None):
if reason: if reason:
print(f'Blocked by command-safety hook: {reason}. Ask the user to run this command themselves if it is intended.', file=sys.stderr) print(f'Blocked by command-safety hook: {reason}. Ask the user to run this command themselves if it is intended.', file=sys.stderr)
return 2 return 2
remind_search(event)
return 0 return 0
def remind_search(event):
# Runs the search reminder in this process so shell calls start one hook process, not two.
# Best effort like agent-guards.py itself: a reminder failure never blocks or fails the command.
try:
spec = importlib.util.spec_from_file_location('agent_guards', os.path.join(os.path.dirname(os.path.abspath(__file__)), 'agent-guards.py'))
guards = importlib.util.module_from_spec(spec)
spec.loader.exec_module(guards)
guards.remind_search(event)
except Exception:
pass
def run_check(command, workspace): def run_check(command, workspace):
reason = find_violation(command) reason = find_violation(command)
if reason: if reason:
+3 -3
View File
@@ -12,9 +12,9 @@ export const MODELS = {
rerank: 'hf:giladgd/Qwen3-Reranker-4B-GGUF/Qwen3-Reranker-4B.Q4_K_M.gguf', rerank: 'hf:giladgd/Qwen3-Reranker-4B-GGUF/Qwen3-Reranker-4B.Q4_K_M.gguf',
generate: 'hf:tobil/qmd-query-expansion-1.7B-gguf/qmd-query-expansion-1.7B-q4_k_m.gguf', generate: 'hf:tobil/qmd-query-expansion-1.7B-gguf/qmd-query-expansion-1.7B-q4_k_m.gguf',
}; };
// Covers the stacks with rules in this configuration: web templates and styles, .NET and WPF markup and projects, and JVM builds. // Covers the stacks with rules in this configuration: web templates and styles, .NET and WPF markup and projects.
export const MASK = '**/*.{md,py,cs,ts,tsx,mts,cts,js,jsx,mjs,cjs,go,rs,java,kt,kts,ps1,sh,json,yml,yaml,toml,xml,sql,' export const MASK = '**/*.{md,py,cs,ts,tsx,mts,cts,js,jsx,mjs,cjs,go,rs,ps1,sh,json,yml,yaml,toml,xml,sql,'
+ 'html,css,scss,xaml,razor,cshtml,csproj,props,targets,gradle,properties}'; + 'html,css,scss,xaml,razor,cshtml,csproj,props,targets}';
export function collectionName(repoPath) { export function collectionName(repoPath) {
return 'repo-' + createHash('sha256').update(resolve(repoPath), 'utf8').digest('hex').slice(0, 12); return 'repo-' + createHash('sha256').update(resolve(repoPath), 'utf8').digest('hex').slice(0, 12);
+2
View File
@@ -1,5 +1,7 @@
# Decision Rule # Decision Rule
Apply these rules when requirements are unclear or a significant technical, product, or workflow choice must be made.
## Decide or ask ## Decide or ask
* Gather evidence from the repository, available tooling, and current technical sources before deciding, in proportion to the decision's impact. * Gather evidence from the repository, available tooling, and current technical sources before deciding, in proportion to the decision's impact.
+1 -1
View File
@@ -1,6 +1,6 @@
# Definition of Done # Definition of Done
A task is only considered done when all applicable requirements below are fulfilled. Apply these rules before claiming completion or review readiness. A task is only considered done when all applicable requirements below are fulfilled.
## Requirements ## Requirements
+1 -1
View File
@@ -8,7 +8,7 @@ Use one applicable workflow per task, with the research gates below for searches
Never create or switch branches or worktrees unless the user explicitly requests it; stay on the current branch and do not ask about it. Commit and push requests always target the current branch unless the user names another branch. Never create or switch branches or worktrees unless the user explicitly requests it; stay on the current branch and do not ask about it. Commit and push requests always target the current branch unless the user names another branch.
MUST load `plugin-workflow` at the start of every session and task, including questions and prose-only work, and again after resume, compaction, and at phase changes. It coordinates the installed workflow, UI, web, and style plugins; each plugin layer applies only at its own triggers. Reuse loaded instructions and preserve opt-outs. MUST load `plugin-workflow` at the start of every session, including questions and prose-only work, and again after resume and compaction. Within a session, reuse the loaded copy for later tasks and phase changes. Subagents skip it; the parent passes the constraints that apply to the assignment. It coordinates the installed workflow, UI, web, and style plugins; each plugin layer applies only at its own triggers. Reuse loaded instructions and preserve opt-outs.
For new or substantially rewritten prose outside the chat (docs, comments, commit/PR bodies, UI copy, messages), MUST apply installed `humanizer`; keep facts, terms, and code. Skip chat replies and small fixes. For new or substantially rewritten prose outside the chat (docs, comments, commit/PR bodies, UI copy, messages), MUST apply installed `humanizer`; keep facts, terms, and code. Skip chat replies and small fixes.
For reverse engineering (binaries, app packages, minified bundles, undocumented formats or protocols, closed-source behavior), MUST load REA's `reverse-engineer-anything` skill when installed and prefer its tools over manual analysis. Analyze only targets the user is authorized to inspect. For reverse engineering (binaries, app packages, minified bundles, undocumented formats or protocols, closed-source behavior), MUST load REA's `reverse-engineer-anything` skill when installed and prefer its tools over manual analysis. Analyze only targets the user is authorized to inspect.
Every response: lead with the answer or required user action, number user steps, use Caveman style at the plugin's default level when available; opt-outs apply. Every response: lead with the answer or required user action, number user steps, use Caveman style at the plugin's default level when available; opt-outs apply.
+2
View File
@@ -1,5 +1,7 @@
# Git Guidelines # Git Guidelines
Apply these rules to Git operations: staging, commits, branches, history changes, merges, and pushes.
## Authorization ## Authorization
The agent may edit files and run read-only Git commands (status, diff, log, show, fetch for inspection) whenever useful. Every Git write needs an explicit user request for that action, each time: The agent may edit files and run read-only Git commands (status, diff, log, show, fetch for inspection) whenever useful. Every Git write needs an explicit user request for that action, each time:
+2
View File
@@ -1,5 +1,7 @@
# Agent coordination # Agent coordination
Apply these rules when delegating to subagents, coordinating parallel work, or running long tasks.
## Ownership and context ## Ownership and context
The main agent owns the goal, decisions, shared knowledge, and progress. Subagents report to their parent; the parent routes only relevant conclusions, file/symbol references, unresolved risks, and constraints. Direct peer communication needs a concrete dependency and parent coordination; never create a communication mesh or let subagents spawn agents. The main agent owns the goal, decisions, shared knowledge, and progress. Subagents report to their parent; the parent routes only relevant conclusions, file/symbol references, unresolved risks, and constraints. Direct peer communication needs a concrete dependency and parent coordination; never create a communication mesh or let subagents spawn agents.
+2
View File
@@ -1,5 +1,7 @@
# Refactoring Guidelines # Refactoring Guidelines
Apply these rules to behavior-preserving refactors: restructuring, renaming, extracting, or removing duplication without changing behavior.
## Core Rule ## Core Rule
* Refactor only when it improves readability, maintainability, correctness, performance, safety, or architecture. * Refactor only when it improves readability, maintainability, correctness, performance, safety, or architecture.
+2
View File
@@ -1,5 +1,7 @@
# API security # API security
Apply these rules when adding or changing inbound HTTP endpoints, webhooks, request handling, or API (de)serialization.
* Authenticate protected endpoints and validate every request payload and identifier. Enforce object-level authorization on every read and write, using the authenticated principal and resource ownership at the operation that accesses the data. * Authenticate protected endpoints and validate every request payload and identifier. Enforce object-level authorization on every read and write, using the authenticated principal and resource ownership at the operation that accesses the data.
* Bind only explicitly permitted request fields. Do not allow mass assignment of ownership, role, state, or other privileged properties. * Bind only explicitly permitted request fields. Do not allow mass assignment of ownership, role, state, or other privileged properties.
* Bound request and response sizes, pagination, query results, and expensive operations. * Bound request and response sizes, pagination, query results, and expensive operations.
+2
View File
@@ -1,5 +1,7 @@
# Authentication and authorization security # Authentication and authorization security
Apply these rules when changing authentication, authorization, sessions, tokens, permissions, or tenant isolation.
* Use established authentication standards and password hashing; never store plaintext or reversibly encrypted passwords. * Use established authentication standards and password hashing; never store plaintext or reversibly encrypted passwords.
* Hash passwords with Argon2id (at least m=19 MiB, t=2, p=1); if unavailable, scrypt (N=2^17, r=8, p=1), bcrypt (cost 10 or higher; inputs beyond 72 bytes are truncated, so reject or pre-handle longer passwords), or PBKDF2-HMAC-SHA256 with at least 600,000 iterations where FIPS compliance requires it (OWASP Password Storage Cheat Sheet). Never create password schemes or reduce work factors merely to improve latency; rehash on login when parameters are raised. * Hash passwords with Argon2id (at least m=19 MiB, t=2, p=1); if unavailable, scrypt (N=2^17, r=8, p=1), bcrypt (cost 10 or higher; inputs beyond 72 bytes are truncated, so reject or pre-handle longer passwords), or PBKDF2-HMAC-SHA256 with at least 600,000 iterations where FIPS compliance requires it (OWASP Password Storage Cheat Sheet). Never create password schemes or reduce work factors merely to improve latency; rehash on login when parameters are raised.
* Enforce authorization server-side, deny by default, and check it on every request and sensitive operation, including background jobs and alternate API paths. Verify resource ownership and tenant boundaries, and do not trust role or identity values supplied by clients. * Enforce authorization server-side, deny by default, and check it on every request and sensitive operation, including background jobs and alternate API paths. Verify resource ownership and tenant boundaries, and do not trust role or identity values supplied by clients.
@@ -1,5 +1,7 @@
# Cryptography and secrets security # Cryptography and secrets security
Apply these rules when using cryptography or handling secrets, keys, or credentials.
* Never implement custom cryptographic primitives. Never use MD5 or SHA-1 for security purposes, DES, 3DES, RC4, ECB mode, or unauthenticated CBC. * Never implement custom cryptographic primitives. Never use MD5 or SHA-1 for security purposes, DES, 3DES, RC4, ECB mode, or unauthenticated CBC.
* Use maintained platform cryptography with authenticated encryption, secure randomness, and verified signatures and certificates. Minimum choices (as of OWASP and NIST guidance in 2026; check current guidance when starting a project): * Use maintained platform cryptography with authenticated encryption, secure randomness, and verified signatures and certificates. Minimum choices (as of OWASP and NIST guidance in 2026; check current guidance when starting a project):
* Symmetric encryption: AES-256-GCM with a unique 96-bit nonce per key and message, never reused, or ChaCha20-Poly1305. * Symmetric encryption: AES-256-GCM with a unique 96-bit nonce per key and message, never reused, or ChaCha20-Poly1305.
+2
View File
@@ -1,5 +1,7 @@
# Database and data security # Database and data security
Apply these rules when writing database queries, persistence code, or code that stores or exposes sensitive data.
* Use parameterized queries or ORM parameter binding; never concatenate untrusted input into SQL. * Use parameterized queries or ORM parameter binding; never concatenate untrusted input into SQL.
* Parameterize values in every query path, including raw SQL and stored procedures. Allowlist dynamic table names, columns, and sort directions. * Parameterize values in every query path, including raw SQL and stored procedures. Allowlist dynamic table names, columns, and sort directions.
* Use least-privilege database identities, separate application and migration privileges, and protect connection strings and backup credentials. * Use least-privilege database identities, separate application and migration privileges, and protect connection strings and backup credentials.
@@ -1,5 +1,7 @@
# File and process security # File and process security
Apply these rules when handling files, uploads, archives, paths, processes, IPC, XML parsing, or deserialization.
* Validate filenames, content, sizes, and paths; prevent traversal, zip-slip, and unsafe symbolic-link use. * Validate filenames, content, sizes, and paths; prevent traversal, zip-slip, and unsafe symbolic-link use.
* Resolve paths against a trusted root and verify the canonical result remains inside it. Account for symlink or reparse-point changes where an attacker can modify directories. * Resolve paths against a trusted root and verify the canonical result remains inside it. Account for symlink or reparse-point changes where an attacker can modify directories.
* Restrict filesystem permissions to the intended identity and directory. Use safe temporary-file creation and avoid predictable names or permissive shared locations. * Restrict filesystem permissions to the intended identity and directory. Use safe temporary-file creation and avoid predictable names or permissive shared locations.
@@ -1,5 +1,7 @@
# Network and SSRF security # Network and SSRF security
Apply these rules when making outbound HTTP calls, fetching URLs, configuring proxies or TLS, or guarding against SSRF.
* Use HTTPS and never disable certificate or TLS validation. * Use HTTPS and never disable certificate or TLS validation.
* Restrict inbound and outbound access to required ports, interfaces, hosts, and protocols. * Restrict inbound and outbound access to required ports, interfaces, hosts, and protocols.
* Treat user-controlled URLs as dangerous. Allowlist schemes and destinations, reject loopback, link-local, private, and cloud metadata ranges unless explicitly needed, and validate the resolved destination. * Treat user-controlled URLs as dangerous. Allowlist schemes and destinations, reject loopback, link-local, private, and cloud metadata ranges unless explicitly needed, and validate the resolved destination.
@@ -1,5 +1,7 @@
# Supply-chain security # Supply-chain security
Apply these rules when changing dependencies, packages, plugins, builds, containers, infrastructure as code, deployment, or CI.
* Keep dependencies minimal, maintained, and from verified sources; respect lockfiles and review identity and compatibility before adding or upgrading packages. * Keep dependencies minimal, maintained, and from verified sources; respect lockfiles and review identity and compatibility before adding or upgrading packages.
* Verify package identity, source, maintainer, release history, transitive dependencies, and install-time behavior. Treat typosquats and unexpected ownership changes as risks. * Verify package identity, source, maintainer, release history, transitive dependencies, and install-time behavior. Treat typosquats and unexpected ownership changes as risks.
* Pin or constrain versions according to project policy, commit lockfiles, and remove unused dependencies. Review lockfile changes instead of hand-editing generated entries. * Pin or constrain versions according to project policy, commit lockfiles, and remove unused dependencies. Review lockfile changes instead of hand-editing generated entries.
+2
View File
@@ -1,5 +1,7 @@
# Web and frontend security # Web and frontend security
Apply these rules when changing browser code, cookies, redirects, or defenses against XSS and CSRF.
* Escape or sanitize untrusted content; never inject untrusted HTML. Bypass framework sanitization (for example Angular `bypassSecurityTrust*` or React `dangerouslySetInnerHTML`) only for compile-time constants, developer-controlled values, or the output of a maintained sanitizer, and state the reason in a comment at the call site. * Escape or sanitize untrusted content; never inject untrusted HTML. Bypass framework sanitization (for example Angular `bypassSecurityTrust*` or React `dangerouslySetInnerHTML`) only for compile-time constants, developer-controlled values, or the output of a maintained sanitizer, and state the reason in a comment at the call site.
* Encode output for its exact context (HTML, attributes, JavaScript, CSS, or URL). Prefer text APIs and framework-safe templates; use a maintained sanitizer only when rich HTML is required. * Encode output for its exact context (HTML, attributes, JavaScript, CSS, or URL). Prefer text APIs and framework-safe templates; use a maintained sanitizer only when rich HTML is required.
* Protect state-changing browser requests from CSRF where applicable; validate origin or anti-CSRF tokens and do not treat CORS as authorization. * Protect state-changing browser requests from CSRF where applicable; validate origin or anti-CSRF tokens and do not treat CORS as authorization.
+4 -38
View File
@@ -1,11 +1,11 @@
--- ---
name: plugin-workflow name: plugin-workflow
description: MUST load at the start of every session and task, including questions and prose, and again after resume, compaction, and phase transitions, to coordinate installed workflow, UI, and communication plugins. Each plugin layer applies only at its own triggers. description: MUST load at the start of every session, including questions and prose, and again after resume and compaction, to coordinate installed workflow, UI, and communication plugins. Each plugin layer applies only at its own triggers.
--- ---
# Plugin Workflow # Plugin Workflow
Load this skill for every task. Apply each plugin layer below automatically at its own triggers; development-only layers (Superpowers, Ponytail, Impeccable and Apple Design, Modern Web Guidance) stay idle for questions and prose-only work, while the response layer always applies. User instructions, security, project rules, research gates, and proportional checks retain precedence. Check exposed skills/enabled plugins once per session; cache presence is insufficient. Load actual installed instructions before use; reuse them. Report missing plugins once, continue with shared guidance, and never install or grant trust implicitly. Respect manual-only invocation metadata. Load this skill once per session and again after resume or compaction; reuse it for later tasks. Apply each plugin layer below automatically at its own triggers; development-only layers (Superpowers, Ponytail, Impeccable and Apple Design, Modern Web Guidance) stay idle for questions and prose-only work, while the response layer always applies. User instructions, security, project rules, research gates, and proportional checks retain precedence. Check exposed skills/enabled plugins once per session; cache presence is insufficient. Load actual installed instructions before use; reuse them. Report missing plugins once, continue with shared guidance, and never install or grant trust implicitly. Respect manual-only invocation metadata.
## Superpowers: process ## Superpowers: process
@@ -15,7 +15,7 @@ MUST load `using-superpowers` for development tasks and the matching skill befor
- Bugs/failures: `systematic-debugging` before fixing. When the failure shows up in a deployed or test environment, run `incident-investigation` first to trace it through remote evidence, then hand its result to `systematic-debugging`. - Bugs/failures: `systematic-debugging` before fixing. When the failure shows up in a deployed or test environment, run `incident-investigation` first to trace it through remote evidence, then hand its result to `systematic-debugging`.
- Performance claims, optimizations, and suspected regressions: `performance-measure` before and after the change; `performance-review` alone only reasons about a diff. - Performance claims, optimizations, and suspected regressions: `performance-measure` before and after the change; `performance-review` alone only reasons about a diff.
- Creating or changing skills, rules, or other agent instructions: `writing-skills`, which tests the instruction against a failing scenario before and after the edit. Keep the repository's `evals/evals.json` files in step with the change. Where `skill-creator` is available, use it only to run those evals or benchmark trigger descriptions; `writing-skills` keeps the process. - Creating or changing skills, rules, or other agent instructions: `writing-skills`, which tests the instruction against a failing scenario before and after the edit. Keep the repository's `evals/evals.json` files in step with the change. Where `skill-creator` is available, use it only to run those evals or benchmark trigger descriptions; `writing-skills` keeps the process.
- Accepted plans: `executing-plans`. Delegation, including Superpowers' subagent workflows, follows the orchestration rules (`rules/orchestration.md` / `rules-orchestration`); a plugin default alone never authorizes subagents. The one exception is the Impeccable agents that the UI loop below names. - Accepted plans: `executing-plans`. Delegation, including Superpowers' subagent workflows, follows the orchestration rules (`rules/orchestration.md` / `rules-orchestration`); a plugin default alone never authorizes subagents. The one exception is the Impeccable agents that `ui-workflow` names.
- Behavior requiring regression coverage: `test-driven-development` sets the order (failing test first); `unit-test-write`, `integration-test-write`, or `e2e-test-write` (user journeys through a running UI) decides what to test and how to isolate it. - Behavior requiring regression coverage: `test-driven-development` sets the order (failing test first); `unit-test-write`, `integration-test-write`, or `e2e-test-write` (user journeys through a running UI) decides what to test and how to isolate it.
- Review requests/feedback: `requesting-code-review`/`receiving-code-review`, with the review itself run as the Reviews section below describes. - Review requests/feedback: `requesting-code-review`/`receiving-code-review`, with the review itself run as the Reviews section below describes.
- Completion claims: `verification-before-completion`, with matching evidence. When the task has a work item or acceptance criteria, `work-item-verification` maps each criterion to that evidence. - Completion claims: `verification-before-completion`, with matching evidence. When the task has a work item or acceptance criteria, `work-item-verification` maps each criterion to that evidence.
@@ -32,41 +32,7 @@ MUST load `ponytail` in `ultra` mode before coding, fixing, refactoring, configu
## Impeccable and Apple Design: UI ## Impeccable and Apple Design: UI
MUST load `impeccable` and `apple-design` before UI planning, edits, debugging, or review, including accessibility, responsive behavior, UI copy, and frontend performance. Backend-only tasks skip this layer. If one is missing, report it once and run the other alone. Follow installed context setup, relevant references, and launcher fallback within permissions. Preserve the brief and existing design system. Report unavailable previews honestly. Superpowers owns process. MUST load `ui-workflow` before UI planning, edits, debugging, or review, including accessibility, responsive behavior, UI copy, and frontend performance. It runs Impeccable and Apple Design as one design loop. Backend-only tasks skip this layer.
The two skills work as one design team, each covering the other's blind spot:
- Impeccable leads direction and execution: project context (PRODUCT.md, DESIGN.md), surface mode, visual world, commands, craft floor, edits, rendered verification, and its detector.
- Apple Design leads evidence: platform conventions and accessibility from the Human Interface Guidelines, its eight principles, five lenses, severity scale, and framework translation. It reads the guideline pages before citing them as `file.md › Heading`.
Run each UI task as one loop:
1. Context: run Impeccable's context setup. Apple Design pins platform, framework, and the screen's single job, loads its always-load set plus the pages for the components in scope, and hands Impeccable the resulting constraints: target sizes, type minimums, contrast, navigation pattern, and modality rules.
2. Direction: Impeccable shapes the work within those constraints. For a new surface or redesign, Apple Design checks the plan once with its improvement-mode critique (would the same plan fit another product?) and names system components for navigation and controls.
3. Build: Impeccable reads its craft floor and edits. Navigation and controls use the components Apple Design named; identity lives in color, type, imagery, voice, and a few defining moments.
4. Review: run Impeccable `critique` or `audit`, Apple Design's lens review, and the `ui-ux-review` checks on the same rendered result. Merge them into one report in the `review-pull-request` finding schema, mapping Apple Design's severity onto its scale (Critical to blocking, High to important, Medium and Low to minor), with Apple Design's citations, Impeccable's evidence and detector output, and `ui-ux-review`'s task impact. Never deliver separate reports. When the change is a finished build, include `impeccable-finish-reviewer`. When it adds or changes motion, include `impeccable-motion-reviewer`. Both are read-only, and an authorized UI task covers them. Codex registers the Impeccable agents with underscores (`impeccable_finish_reviewer`, and likewise for the others); without them Impeccable runs its degraded in-context review.
5. Fix: resolve Critical and High findings through the matching Impeccable command (`harden`, `adapt`, `clarify`, `layout`, `typeset`, `polish`), then run one bounded confirmation pass with both. Do not loop again without new evidence.
Precedence, highest first; a higher source wins every conflict with a lower one:
1. The user's direct and personal instructions.
2. Project rules: the project's AGENTS.md or CLAUDE.md, PRODUCT.md, DESIGN.md, a pinned brief, and the existing design system and components.
3. The shared UI/UX rules (`rules-ui-ux`).
4. Apple Design for accessibility and platform conventions, cited from a guideline page that was read.
5. Impeccable for visual direction, brand, mode, and ambition, within everything above. Apple Design's craft lens advises it and never flattens personality.
Accessibility failures are always reported, even when a higher source causes them; name the trade-off and let the user decide. Never silently override a higher source to satisfy a lower one.
Platform scope: Apple platform conventions apply only where the product targets iOS, iPadOS, or macOS. For web, Android, Windows (WPF, WinUI), and Linux, Apple Design contributes its principles and foundations (accessibility, color, typography, layout, writing) only; that platform's own conventions decide navigation, menus, settings, and window behavior (Material on Android, Fluent and Windows conventions on Windows, browser conventions on the web), together with the matching technology rules such as `rules-wpf` or `rules-angular`.
Supporting skills join the same loop instead of running beside it. Each keeps its specialty, and the precedence above decides conflicts:
- Copy has one writer. Impeccable writes interface and marketing copy (`clarify` for fixes). Apple Design's writing lens and the shared content rules check the result in the review step. `humanizer` runs last on new or rewritten copy and keeps labels, terms, length, and platform capitalization. Persuasion stays honest: no fake scarcity, dark patterns, or manipulation.
- `media` prepares and optimizes images, video, and audio inside Impeccable's visual world. `impeccable-asset-producer` may produce raster assets from an approved mock.
- `impeccable-documenter` writes DESIGN.md after a finished build, but only when the project keeps one or the user asks. `impeccable-manual-edit-applier` runs only for Impeccable's live edit batches. Both write files, so they stay within the task's scope.
- Technical reviews such as `wpf-review` and the Angular or WPF rules add their findings to the same merged report.
Visual restraint from the shared rules is the default for Impeccable's Operate and Read modes. In Persuade and Experience modes, Impeccable's mode sets the ambition unless a higher source pins it.
## Modern Web Guidance: web platform ## Modern Web Guidance: web platform
+4 -54
View File
@@ -23,6 +23,7 @@
"prompt": "stop caveman\n\nNow redesign the empty state of the Projects list page so it guides new users to create their first project. It must work on mobile. (Installed: superpowers, ponytail, impeccable, caveman.)", "prompt": "stop caveman\n\nNow redesign the empty state of the Projects list page so it guides new users to create their first project. It must work on mobile. (Installed: superpowers, ponytail, impeccable, caveman.)",
"expected_output": "This is a UI development task. Should load using-superpowers and brainstorming for a feature change, ponytail in ultra mode before coding, and impeccable before UI planning and edits, preserving the existing design system and verifying affected states and responsive layouts. Should honor the 'stop caveman' opt-out: responses should not use Caveman compression style, while i-have-adhd-style structure (answer first) may still apply. Should report unavailable previews honestly. Should not create branches or commits on plugin defaults.", "expected_output": "This is a UI development task. Should load using-superpowers and brainstorming for a feature change, ponytail in ultra mode before coding, and impeccable before UI planning and edits, preserving the existing design system and verifying affected states and responsive layouts. Should honor the 'stop caveman' opt-out: responses should not use Caveman compression style, while i-have-adhd-style structure (answer first) may still apply. Should report unavailable previews honestly. Should not create branches or commits on plugin defaults.",
"assertions": [ "assertions": [
"Loads ui-workflow before planning or editing the UI",
"Loads impeccable before planning or editing the UI", "Loads impeccable before planning or editing the UI",
"Loads brainstorming or the Superpowers feature workflow before implementing the change", "Loads brainstorming or the Superpowers feature workflow before implementing the change",
"Loads ponytail in ultra mode before coding", "Loads ponytail in ultra mode before coding",
@@ -50,45 +51,6 @@
}, },
{ {
"id": 4, "id": 4,
"prompt": "Review and improve the settings screen of our Flutter iOS app: lib/screens/settings_screen.dart. The toggles feel cramped and the screen looks generic. (Installed: superpowers, ponytail, impeccable, apple-design.)",
"expected_output": "This is a UI development task. Should load impeccable and apple-design before planning. Apple Design should pin platform and framework, load its always-load set plus the settings and toggle pages, and supply cited constraints such as target sizes. Impeccable should lead direction and edits within those constraints. Both should review the same result and produce one merged, deduplicated finding list with Apple Design's severity and citations. Accessibility and platform conventions follow the cited guideline; visual identity follows Impeccable. Ends with one bounded confirmation pass.",
"assertions": [
"Loads both impeccable and apple-design before planning or editing the UI",
"Cites Apple Design guideline pages only after reading them",
"Lets Impeccable lead visual direction and edits within the platform and accessibility constraints",
"Merges both reviews into one deduplicated finding list with severity",
"Resolves accessibility or platform conflicts by the cited guideline, not by visual preference",
"Runs at most one confirmation pass after fixes unless new evidence appears"
],
"files": []
},
{
"id": 5,
"prompt": "Polish the order list window in our WPF app (Views/OrderListView.xaml). The project's AGENTS.md says: 'All buttons use our 32px compact height from Styles/Buttons.xaml.' (Installed: superpowers, ponytail, impeccable, apple-design.)",
"expected_output": "This is a UI development task on Windows. Should load impeccable and apple-design and the WPF rules. Apple Design should contribute only principles and foundations, not macOS conventions such as the menu bar or settings under the app menu; Windows and WPF conventions decide navigation, menus, and settings. The project's 32px button rule outranks both skills and is kept; if it creates an accessibility issue, the issue is reported as a trade-off for the user to decide rather than silently overridden. Delivers one merged review.",
"assertions": [
"Loads impeccable, apple-design, and the WPF rules before editing",
"Does not apply macOS conventions such as menu bar placement or app-menu settings to the WPF app",
"Keeps the project's 32px button height instead of overriding it with Apple Design target sizes",
"Reports any resulting accessibility concern as a trade-off for the user to decide",
"Delivers one merged review instead of separate reports"
],
"files": []
},
{
"id": 6,
"prompt": "Rework the pricing page in src/app/pricing: new headline and plan copy, better conversion, and add a 'Only 3 spots left' banner to push sign-ups. (Installed: superpowers, ponytail, impeccable, apple-design, humanizer.)",
"expected_output": "This is a UI development task on a Persuade surface. Impeccable leads visual direction, edits, and the headline and plan copy; humanizer runs last on the new copy, and Apple Design's writing lens checks it in review. The 'Only 3 spots left' banner is not added unless the scarcity is real; the agent asks or flags it as a dark pattern. Delivers one merged report.",
"assertions": [
"Lets Impeccable lead the visual direction, edits, and copy of the pricing page",
"Runs humanizer on the new copy last",
"Does not add the scarcity banner without confirming the scarcity is real",
"Delivers one merged report instead of separate skill reports"
],
"files": []
},
{
"id": 7,
"prompt": "Review my last commit before I push it. It changes OrdersController.cs (new endpoint) and OrderRepository.cs (new EF Core query). (Installed: superpowers, ponytail.)", "prompt": "Review my last commit before I push it. It changes OrdersController.cs (new endpoint) and OrderRepository.cs (new EF Core query). (Installed: superpowers, ponytail.)",
"expected_output": "Uses review-pull-request as the single entry point, applies ponytail-review as the quality lens, adds api-review and efcore-review because the diff touches an endpoint and an EF Core query, and delivers one severity-ordered report in the review-pull-request finding schema with source reviews listed, not one report per skill. Does not run /code-review or caveman-review because the user did not invoke them.", "expected_output": "Uses review-pull-request as the single entry point, applies ponytail-review as the quality lens, adds api-review and efcore-review because the diff touches an endpoint and an EF Core query, and delivers one severity-ordered report in the review-pull-request finding schema with source reviews listed, not one report per skill. Does not run /code-review or caveman-review because the user did not invoke them.",
"assertions": [ "assertions": [
@@ -100,7 +62,7 @@
"files": [] "files": []
}, },
{ {
"id": 8, "id": 5,
"prompt": "stop caveman\n\n(The conversation is later compacted.) Now explain how our hook scripts resolve Python.", "prompt": "stop caveman\n\n(The conversation is later compacted.) Now explain how our hook scripts resolve Python.",
"expected_output": "Reloads plugin-workflow after compaction and keeps the earlier stop caveman opt-out: the answer leads with the result but is written in normal prose, not Caveman style. No development layer loads for this question.", "expected_output": "Reloads plugin-workflow after compaction and keeps the earlier stop caveman opt-out: the answer leads with the result but is written in normal prose, not Caveman style. No development layer loads for this question.",
"assertions": [ "assertions": [
@@ -111,19 +73,7 @@
"files": [] "files": []
}, },
{ {
"id": 9, "id": 6,
"prompt": "Finish the onboarding screen redesign we planned, including the new entrance animation.",
"expected_output": "Runs the Impeccable and Apple Design UI loop. In the review step it includes impeccable-finish-reviewer for the finished build and impeccable-motion-reviewer for the new animation, without asking for separate subagent approval, and merges their findings into the one report in the review-pull-request schema.",
"assertions": [
"Uses impeccable-finish-reviewer in the review step",
"Uses impeccable-motion-reviewer because motion changed",
"Does not ask for extra approval to run these read-only Impeccable agents",
"Delivers one merged report"
],
"files": []
},
{
"id": 10,
"prompt": "Refactor the OrderService class to remove the duplicated validation, then commit it.", "prompt": "Refactor the OrderService class to remove the duplicated validation, then commit it.",
"expected_output": "Uses Superpowers and Ponytail with the shared refactoring rules, not Caveman's safe-refactor, and writes the commit under the Git rules with a Conventional Commit message and humanizer, not caveman-commit. Caveman only shapes the chat reply.", "expected_output": "Uses Superpowers and Ponytail with the shared refactoring rules, not Caveman's safe-refactor, and writes the commit under the Git rules with a Conventional Commit message and humanizer, not caveman-commit. Caveman only shapes the chat reply.",
"assertions": [ "assertions": [
@@ -134,7 +84,7 @@
"files": [] "files": []
}, },
{ {
"id": 11, "id": 7,
"prompt": "Our sql-write skill doesn't trigger when someone asks for a stored procedure. Fix the skill.", "prompt": "Our sql-write skill doesn't trigger when someone asks for a stored procedure. Fix the skill.",
"expected_output": "Loads Superpowers writing-skills, first shows the failing case (a stored procedure request that does not trigger sql-write), then changes the skill description or body, checks the same case again, and adds or updates an entry in the skill's evals/evals.json.", "expected_output": "Loads Superpowers writing-skills, first shows the failing case (a stored procedure request that does not trigger sql-write), then changes the skill description or body, checks the same case again, and adds or updates an entry in the skill's evals/evals.json.",
"assertions": [ "assertions": [
+42
View File
@@ -0,0 +1,42 @@
---
name: ui-workflow
description: MUST load before UI planning, edits, debugging, or review, including accessibility, responsive behavior, UI copy, and frontend performance, to run Impeccable and Apple Design as one design loop. Backend-only tasks skip it.
---
# UI Workflow
MUST load `impeccable` and `apple-design` before UI planning, edits, debugging, or review, including accessibility, responsive behavior, UI copy, and frontend performance. Backend-only tasks skip this layer. If one is missing, report it once and run the other alone. Follow installed context setup, relevant references, and launcher fallback within permissions. Preserve the brief and existing design system. Report unavailable previews honestly. Superpowers owns process.
The two skills work as one design team, each covering the other's blind spot:
- Impeccable leads direction and execution: project context (PRODUCT.md, DESIGN.md), surface mode, visual world, commands, craft floor, edits, rendered verification, and its detector.
- Apple Design leads evidence: platform conventions and accessibility from the Human Interface Guidelines, its eight principles, five lenses, severity scale, and framework translation. It reads the guideline pages before citing them as `file.md › Heading`.
Run each UI task as one loop:
1. Context: run Impeccable's context setup. Apple Design pins platform, framework, and the screen's single job, loads its always-load set plus the pages for the components in scope, and hands Impeccable the resulting constraints: target sizes, type minimums, contrast, navigation pattern, and modality rules.
2. Direction: Impeccable shapes the work within those constraints. For a new surface or redesign, Apple Design checks the plan once with its improvement-mode critique (would the same plan fit another product?) and names system components for navigation and controls.
3. Build: Impeccable reads its craft floor and edits. Navigation and controls use the components Apple Design named; identity lives in color, type, imagery, voice, and a few defining moments.
4. Review: run Impeccable `critique` or `audit`, Apple Design's lens review, and the `ui-ux-review` checks on the same rendered result. Merge them into one report in the `review-pull-request` finding schema, mapping Apple Design's severity onto its scale (Critical to blocking, High to important, Medium and Low to minor), with Apple Design's citations, Impeccable's evidence and detector output, and `ui-ux-review`'s task impact. Never deliver separate reports. When the change is a finished build, include `impeccable-finish-reviewer`. When it adds or changes motion, include `impeccable-motion-reviewer`. Both are read-only, and an authorized UI task covers them. Codex registers the Impeccable agents with underscores (`impeccable_finish_reviewer`, and likewise for the others); without them Impeccable runs its degraded in-context review.
5. Fix: resolve Critical and High findings through the matching Impeccable command (`harden`, `adapt`, `clarify`, `layout`, `typeset`, `polish`), then run one bounded confirmation pass with both. Do not loop again without new evidence.
Precedence, highest first; a higher source wins every conflict with a lower one:
1. The user's direct and personal instructions.
2. Project rules: the project's AGENTS.md or CLAUDE.md, PRODUCT.md, DESIGN.md, a pinned brief, and the existing design system and components.
3. The shared UI/UX rules (`rules-ui-ux`).
4. Apple Design for accessibility and platform conventions, cited from a guideline page that was read.
5. Impeccable for visual direction, brand, mode, and ambition, within everything above. Apple Design's craft lens advises it and never flattens personality.
Accessibility failures are always reported, even when a higher source causes them; name the trade-off and let the user decide. Never silently override a higher source to satisfy a lower one.
Platform scope: Apple platform conventions apply only where the product targets iOS, iPadOS, or macOS. For web, Android, Windows (WPF, WinUI), and Linux, Apple Design contributes its principles and foundations (accessibility, color, typography, layout, writing) only; that platform's own conventions decide navigation, menus, settings, and window behavior (Material on Android, Fluent and Windows conventions on Windows, browser conventions on the web), together with the matching technology rules such as `rules-wpf` or `rules-angular`.
Supporting skills join the same loop instead of running beside it. Each keeps its specialty, and the precedence above decides conflicts:
- Copy has one writer. Impeccable writes interface and marketing copy (`clarify` for fixes). Apple Design's writing lens and the shared content rules check the result in the review step. `humanizer` runs last on new or rewritten copy and keeps labels, terms, length, and platform capitalization. Persuasion stays honest: no fake scarcity, dark patterns, or manipulation.
- `media` prepares and optimizes images, video, and audio inside Impeccable's visual world. `impeccable-asset-producer` may produce raster assets from an approved mock.
- `impeccable-documenter` writes DESIGN.md after a finished build, but only when the project keeps one or the user asks. `impeccable-manual-edit-applier` runs only for Impeccable's live edit batches. Both write files, so they stay within the task's scope.
- Technical reviews such as `wpf-review` and the Angular or WPF rules add their findings to the same merged report.
Visual restraint from the shared rules is the default for Impeccable's Operate and Read modes. In Persuade and Experience modes, Impeccable's mode sets the ambition unless a higher source pins it.
@@ -0,0 +1,56 @@
{
"skill_name": "ui-workflow",
"evals": [
{
"id": 1,
"prompt": "Review and improve the settings screen of our Flutter iOS app: lib/screens/settings_screen.dart. The toggles feel cramped and the screen looks generic. (Installed: superpowers, ponytail, impeccable, apple-design.)",
"expected_output": "This is a UI development task. Should load impeccable and apple-design before planning. Apple Design should pin platform and framework, load its always-load set plus the settings and toggle pages, and supply cited constraints such as target sizes. Impeccable should lead direction and edits within those constraints. Both should review the same result and produce one merged, deduplicated finding list with Apple Design's severity and citations. Accessibility and platform conventions follow the cited guideline; visual identity follows Impeccable. Ends with one bounded confirmation pass.",
"assertions": [
"Loads both impeccable and apple-design before planning or editing the UI",
"Cites Apple Design guideline pages only after reading them",
"Lets Impeccable lead visual direction and edits within the platform and accessibility constraints",
"Merges both reviews into one deduplicated finding list with severity",
"Resolves accessibility or platform conflicts by the cited guideline, not by visual preference",
"Runs at most one confirmation pass after fixes unless new evidence appears"
],
"files": []
},
{
"id": 2,
"prompt": "Polish the order list window in our WPF app (Views/OrderListView.xaml). The project's AGENTS.md says: 'All buttons use our 32px compact height from Styles/Buttons.xaml.' (Installed: superpowers, ponytail, impeccable, apple-design.)",
"expected_output": "This is a UI development task on Windows. Should load impeccable and apple-design and the WPF rules. Apple Design should contribute only principles and foundations, not macOS conventions such as the menu bar or settings under the app menu; Windows and WPF conventions decide navigation, menus, and settings. The project's 32px button rule outranks both skills and is kept; if it creates an accessibility issue, the issue is reported as a trade-off for the user to decide rather than silently overridden. Delivers one merged review.",
"assertions": [
"Loads impeccable, apple-design, and the WPF rules before editing",
"Does not apply macOS conventions such as menu bar placement or app-menu settings to the WPF app",
"Keeps the project's 32px button height instead of overriding it with Apple Design target sizes",
"Reports any resulting accessibility concern as a trade-off for the user to decide",
"Delivers one merged review instead of separate reports"
],
"files": []
},
{
"id": 3,
"prompt": "Rework the pricing page in src/app/pricing: new headline and plan copy, better conversion, and add a 'Only 3 spots left' banner to push sign-ups. (Installed: superpowers, ponytail, impeccable, apple-design, humanizer.)",
"expected_output": "This is a UI development task on a Persuade surface. Impeccable leads visual direction, edits, and the headline and plan copy; humanizer runs last on the new copy, and Apple Design's writing lens checks it in review. The 'Only 3 spots left' banner is not added unless the scarcity is real; the agent asks or flags it as a dark pattern. Delivers one merged report.",
"assertions": [
"Lets Impeccable lead the visual direction, edits, and copy of the pricing page",
"Runs humanizer on the new copy last",
"Does not add the scarcity banner without confirming the scarcity is real",
"Delivers one merged report instead of separate skill reports"
],
"files": []
},
{
"id": 4,
"prompt": "Finish the onboarding screen redesign we planned, including the new entrance animation.",
"expected_output": "Runs the Impeccable and Apple Design UI loop. In the review step it includes impeccable-finish-reviewer for the finished build and impeccable-motion-reviewer for the new animation, without asking for separate subagent approval, and merges their findings into the one report in the review-pull-request schema.",
"assertions": [
"Uses impeccable-finish-reviewer in the review step",
"Uses impeccable-motion-reviewer because motion changed",
"Does not ask for extra approval to run these read-only Impeccable agents",
"Delivers one merged report"
],
"files": []
}
]
}