Research-backed evolution advice for your knowledge system. Analyzes health reports, friction patterns, and derivation history to propose specific changes with research justification. Never auto-implements — proposals require your approval.
Instrucciones de origen · Vista previa de solo lectura
name
architect
description
Research-backed evolution advice for your knowledge system. Analyzes health reports, friction patterns, and derivation history to propose specific changes with research justification. Never auto-implements — proposals require your approval.
ops/derivation.md — original derivation record (the design intent baseline)
If these files don't exist, use universal defaults and warn the user.
EXECUTE NOW
Target: $ARGUMENTS
Parse immediately:
If target names a specific area (e.g., "schema", "processing", "MOC structure"): focus analysis on that area
If target is empty: run full-system analysis across all dimensions
If target is --dry-run: run analysis but do not offer implementation
Execute these phases sequentially:
Locate system files and detect platform
Read derivation record for design intent
Analyze health data (recent report or live check)
Scan for friction patterns across operational surfaces
Consult research to ground evidence in specific claims
Generate 3-5 ranked recommendations with full evidence chains
Present to user and implement on approval
START NOW. Reference below defines the seven-phase workflow.
Philosophy
Evidence beats intuition. Research beats habit.
Every rule in the context file was a hypothesis. Every skill workflow was a design choice. Hypotheses need testing against operational reality. This skill connects three evidence streams — health data, friction patterns, and research claims — to produce specific, actionable recommendations.
You are not guessing what might help. You are diagnosing what IS happening (health + friction) and prescribing what research says SHOULD happen. Every recommendation traces to specific evidence. "I think this would be better" is not a recommendation. "Health shows 12 orphans, friction log shows repeated orphan complaints, research claim [[orphan notes decay faster than connected ones]] supports adding a condition-triggered reweave pass" — THAT is a recommendation.
The 25% meta-work budget: In a 60-minute session, at most 15 minutes should be spent on system evolution. If a recommendation estimates >15 minutes to implement, the recommendation should be "defer to next session." The system serves the work, not the other way around.
INVARIANT: Architect NEVER auto-implements. Every recommendation requires explicit user approval before any files are modified. This prevents the cognitive outsourcing failure mode — the human must remain in the judgment loop for system evolution.
PHASE 1: Locate
Automated. No user interaction needed.
Detect the platform and find the system's key files:
{vocabulary.notes}/ (may be domain-named: reflections/, concepts/, etc.)
Queue system
Pipeline state
ops/queue/queue.yaml or ops/queue/queue.json
Templates
Note schemas
ops/templates/ or templates/
Methodology
Learned patterns
ops/methodology/
If ops/derivation.md does not exist: Warn the user: "No derivation record found. Recommendations will be based on current state analysis only, without historical context of design decisions."
If ops/config.yaml does not exist: Warn: "No config file found. Using observed behavior to infer current configuration."
Record all file locations for use in subsequent phases.
PHASE 2: Read Derivation
Read ops/derivation.md to understand the system's original design intent. This is the baseline against which drift is measured.
Extract from derivation:
Element
What To Look For
Why It Matters
Dimension positions
The 8 configuration dimensions and their derived values
Also read ops/config.yaml — this is the live operational config that may have drifted from derivation. Compare dimension positions between derivation and config:
For each of the 8 dimensions:
derivation_value = [from ops/derivation.md]
config_value = [from ops/config.yaml]
drifted = derivation_value != config_value
Record any drift for Phase 6. Drift is not inherently bad — it may represent healthy evolution. But UNRECOGNIZED drift creates incoherence.
If a specific focus area was requested ($ARGUMENTS), note which dimensions and failure modes are most relevant to that area and prioritize them in subsequent phases.
PHASE 3: Health Analysis
Check for a recent health report in ops/health/:
# Find health reports from the last 7 days
find ops/health/ -name "*.md" -mtime -7 2>/dev/null | sort -r | head -1
If a recent report exists: Read it fully. Extract every FAIL and WARN item as structured evidence:
For each FAIL/WARN:
category: [schema | orphan | link | description | stale | moc | boundary | throughput]
severity: [FAIL | WARN]
detail: [specific finding — which notes, which fields, which links]
count: [how many instances]
If no recent report exists: Run a live health assessment. Check each category:
Category
How to Check
FAIL Threshold
WARN Threshold
Schema compliance
grep -rL '^description:' {vocabulary.notes}/*.md
N/A
Any note missing required fields
Orphan detection
Notes with zero incoming wiki-links (scan for [[filename]] across all notes)
N/A
Any orphan
Link health
Wiki-links pointing to non-existent files
Any dangling link
N/A
Three-space boundaries
Content in wrong space (notes in ops/, operational files in notes/)
N/A
Any violation
Processing throughput
Count inbox items vs notes count
>3:1 ratio
>2:1 ratio
Stale notes
Notes with <2 incoming links AND not modified in last 30 days
N/A
>15% of notes
MOC coherence
Note count per MOC
N/A
>40 notes (split candidate) or <5 (merge candidate)
Description quality
Descriptions that restate the title without adding information
Patterns in what the agent does vs what the system recommends
Error patterns or tool failures
4d. Self Space
If self/ exists, read:
self/methodology.md — how the agent describes its own process
self/goals.md — whether current priorities align with system capabilities
self/memory/ — any notes about workflow frustrations
4e. Build Friction Inventory
Compile all friction evidence into a structured inventory:
Friction Inventory:
1. [category]: [description]
Frequency: [N observations across M sessions]
Sources: [filenames]
Impact: [what breaks or degrades]
System area: [which dimension/skill/workflow affected]
2. [category]: [description]
...
Rank by frequency * impact. The most frequent, highest-impact friction patterns get priority in Phase 6.
PHASE 5: Consult Research
Ground the evidence in research. This is what separates /architect from ad-hoc troubleshooting — every recommendation connects to specific research claims, not general intuition.
For each friction pattern or health issue identified in Phases 3-4:
Step 1: Check dimension-claim-map.md
Which research claims relate to this issue?
What dimension positions do those claims support?
Does the current configuration conflict with what research recommends?
Step 2: Check interaction-constraints.md
Is this friction a CASCADE effect from a dimension mismatch?
Would changing one dimension to fix this create pressure on another?
Are there compensating mechanisms documented?
Step 3: Check failure-modes.md
Does this match a known failure mode pattern?
Was this failure mode flagged as HIGH risk during derivation?
What does the failure mode document say about mitigation?
Step 4: Search the knowledge graph
Use mcp__qmd__deep_search to find claims that address the specific friction
Fall back to mcp__qmd__vector_search if hybrid search is unavailable
If MCP is unavailable, fall back to qmd CLI (qmd query then qmd vsearch)
Fall back to reading bundled reference files directly only if both MCP and qmd CLI are unavailable
Search for the friction pattern described in natural language
Search for the system area affected
Search for proposed solution concepts
mcp__qmd__deep_search query="[friction description in natural language]" limit=10
Read the top results. For each relevant claim:
Note the claim title (for citation in recommendations)
Note what the claim argues
Note how it applies to the current friction
The goal is to connect EVERY recommendation to specific research, not general intuition.
PHASE 6: Generate Recommendations
Synthesize evidence from Phases 2-5 into 3-5 concrete recommendations, ranked by impact-to-effort ratio.
Ranking Criteria
Criterion
Scale
What It Measures
Impact
high / medium / low
How much does this improve the system?
Effort
minutes / hours / days
How much work to implement?
Risk
reversible / partially reversible / irreversible
What could go wrong?
Evidence strength
strong (5+ data points) / moderate (3-4) / speculative (1-2)
How much supporting evidence?
Limit to 3-5 recommendations. More than 5 creates decision paralysis. If you found more issues, prioritize ruthlessly — the rest can wait for the next /architect pass.
Priority Ordering
FAIL items from health — these are broken, fix first
High-frequency friction patterns — recurring pain, address next
Drift corrections — config diverged from derivation without rationale
Research-backed optimizations — improvements supported by strong evidence
Speculative improvements — interesting ideas with thin evidence (include at most 1)
Implementation Time Estimation
Every recommendation MUST include a concrete time estimate:
Effort Level
Typical Changes
Estimated Time
minutes
Config value change, template field addition, single file edit
5-15 minutes
hours
Skill regeneration, MOC restructuring, schema migration
30-120 minutes
days
Full reseed, architecture change, multi-skill redesign
Multiple sessions
Apply the 25% budget rule: If the estimated implementation time exceeds 25% of a typical session (>15 minutes for a 60-minute session), recommend deferring to next session unless the issue is a FAIL-level health problem.
Recommendation Format
For each recommendation, construct the full analysis:
### [N]. [Specific change title]
**What:** [Concrete change — specific enough to implement without further clarification.
Name the exact file, section, and value that changes.]
**Why:** [Evidence chain from health analysis + friction patterns]
- Health: [specific FAIL/WARN from Phase 3, with note names/counts]
- Friction: [specific patterns from Phase 4, with observation filenames]
**Research:** [Specific claims supporting this change]
- From dimension-claim-map: [claim title and what it argues]
- From knowledge graph: [related claims found via search, with titles]
- From failure-modes: [if this matches a documented failure mode]
**Interaction effects:** [Cascade analysis from interaction-constraints.md]
- Changing [dimension X] from [current] to [proposed] creates pressure on [dimension Y]
- Compensating mechanism: [how to handle the cascade, or "none needed"]
- If no interaction effects: "No cascade effects detected for this change."
**Impact:** [effort] effort / [benefit] benefit / [risk] risk
**Estimated implementation time:** ~X minutes
**Expected benefit:** [Measurable outcome the user can verify]
**Recommendation:** implement now / defer to next session
**Reversible:** [yes / no / partially — with explanation]
**Steps:**
1. [First concrete step — exact file and change]
2. [Second concrete step]
3. [Update ops/derivation.md with change rationale]
4. [Run validation to confirm nothing broke]
Quality Gates for Recommendations
Every recommendation MUST have:
Specific file references — not "update the context file" but "update CLAUDE.md, section 'Processing Pipeline', line ~150"
Evidence backing — at least 2 data points (health finding + friction observation, or 2+ friction observations)
Research citation — at least 1 specific claim from the knowledge base
Risk awareness — what could go wrong, stated explicitly
Reversibility assessment — can this be undone if it makes things worse?
Time estimate — concrete, not vague
Implementation steps — ordered, each step references exact files
Reject recommendations that fail any of these gates. Thin recommendations erode trust. Better to present 2 strong recommendations than 5 weak ones.
PHASE 7: Present to User
Present the ranked recommendations. Use the user's domain vocabulary (from derivation.md vocabulary mapping) throughout — never expose universal terms to a domain user.
Output Format
=== ARCHITECT REPORT ===
System: [domain name from derivation]
Platform: [detected platform]
Focus: [specific area if requested, or "full system"]
Date: [YYYY-MM-DD]
Evidence Summary:
Health: [N FAIL, N WARN, N PASS — from Phase 3]
Friction: [top 3 friction patterns with frequency counts]
Drift: [dimensions that shifted from derivation, if any, or "none detected"]
Failure modes: [HIGH-risk modes from derivation that show activity, or "none active"]
--- Recommendations (ranked by impact-to-effort) ---
[Recommendation 1 — full format from Phase 6]
[Recommendation 2 — full format from Phase 6]
[Recommendation 3 — full format from Phase 6]
[Optional: Recommendations 4-5]
--- Next Steps ---
Which recommendations would you like to implement? I will execute the steps
and update ops/derivation.md with the rationale.
Options:
- "all" — implement all recommendations
- "1, 3" — implement specific recommendations
- "none" — defer all to next session
- "explain 2" — get more detail on a specific recommendation
=== END REPORT ===
On User Approval
Implement the selected recommendations following the steps listed. For each implementation:
Make the change — edit the specific files as described in Steps
Show before/after for non-trivial changes (section replacements, config changes)
Update ops/derivation.md with:
What changed
Why (evidence summary — health findings + friction patterns)
Research backing (claim references from knowledge base)
Date of change
Interaction effects noted (if any)
Log to ops/changelog.md (create if missing):
## YYYY-MM-DD: [change title]**Source:** /architect — [evidence summary]
**Change:** [what was modified, which files]
**Research:** [supporting claims]
**Risk:** [risk assessment]
Run post-change validation:
All wiki links still resolve
All notes still have required schema fields
MOC hierarchy intact
No three-space boundary violations introduced
Session orient still loads correctly
Report validation results:
Implementation complete.
Changed: [list of files modified]
Validation: [N]/[N] checks PASS
[Any warnings or issues]
On Rejection
Do not re-propose the same change without new evidence
Optionally ask why — capture the reasoning as a new observation if it reveals design philosophy
Mark the recommendation as "considered and deferred" — do not keep re-surfacing it
When Evidence Suggests /reseed
If analysis reveals:
Dimension incoherence across >3 dimensions
Vocabulary no longer matches user's actual language
Three-space boundaries dissolved
Template divergence >40%
Then recommend /reseed instead of incremental patches:
NOTICE: The evidence suggests systemic drift across multiple dimensions.
Incremental patching may create more incoherence. Consider running /reseed
for a principled re-derivation from first principles.
Drift detected in: [list dimensions]
Evidence: [key observations]
Edge Cases
No ops/derivation.md
Recommendations based on current state analysis only. Note in report: "Without derivation history, recommendations cannot assess drift or design intent. Consider running /reseed to establish a derivation baseline."
No ops/observations/ or ops/sessions/
Friction analysis is limited. Note: "No operational friction data available. Recommendations based on health analysis and research only. Begin capturing observations during work to enable friction-based evolution."
Small Vault (<10 notes)
Graph analysis metrics (density, orphans, clusters) are less meaningful at small scale. Note: "Vault is early-stage. Graph health metrics will become more meaningful as the knowledge graph grows. Focus on capture and processing rather than structural optimization."
No Research Results
If MCP tools fail and bundled reference files are the only source:
Read all relevant reference files directly
Note in report: "Research grounding from bundled references only. Semantic search unavailable."
Recommendations are still valid — reference files contain the core research
Focus Area Requested
If $ARGUMENTS names a specific area:
Run all phases but weight findings toward the focus area
Still report other FAIL-level health issues even if outside focus
Note: "Focused on [area]. Other findings noted but not prioritized."
Quality Standards
Ground every recommendation in specific evidence (health data + friction patterns + research claims) — no intuition-only recommendations
Use domain vocabulary throughout — never expose universal terms to a domain user
Be opinionated — the research has positions, share them — but explain your reasoning
Acknowledge when evidence is thin: "This is speculative based on limited friction data" is honest
Distinguish between urgent fixes (FAIL items) and strategic improvements (optimization opportunities)
Never recommend more infrastructure than the system's maturity warrants — check the current automation level
Every time estimate should be honest — underestimating erodes trust more than overestimating
The 25% budget rule is a guideline, not a straitjacket — FAIL-level issues justify exceeding it