Compare commits
2
Commits
4e8038d1d7
...
a1c03360d1
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
a1c03360d1 | ||
|
|
87b443d9f8 |
No files matched your search
@@ -67,6 +67,7 @@ Every skill features an explicit **"Your call"** checkpoint where the agent paus
|
||||
| **[`git-commit`](skills/git-commit/SKILL.md)** | `/git-commit` | Working-tree inspection, atomic slice decomposition, and Conventional Commit drafting. Human approves every commit. | 54 lines |
|
||||
| **[`document`](skills/document/SKILL.md)** | `/document` | Second-order knowledge classifier (Discussion, ADR, Plan, Debug Record, Knowledge). User confirms type and provides core insight. | 49 lines |
|
||||
| **[`journal-builder`](skills/journal-builder/SKILL.md)** | `/journal-builder` or `/journal` | Retrospective inquiry from engineering history. Probes understanding and discovers learning edges. | 56 lines |
|
||||
| **[`reconcile-docs`](skills/reconcile-docs/SKILL.md)** | `/reconcile-docs [path]` | Reconciles historical evidence, present code reality, and future plans into canonical repo docs (README, ARCHITECTURE, ADR, ROADMAP). | 37 lines |
|
||||
| **[`build-skill`](skills/build-skill/SKILL.md)** | `/build-skill [topic]` | Interactive design, sizing, authoring, and empirical dogfooding of agent skills. Enforces design review gate before file creation. | 48 lines |
|
||||
|
||||
### Vault Extensions (`extensions/`)
|
||||
|
||||
+38
-1
@@ -5,6 +5,7 @@ set -euo pipefail
|
||||
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
|
||||
TARGET_DIR="${TARGET:-$HOME/.gemini/config/skills}"
|
||||
PROFILE_TARGET="${PROFILE_TARGET:-$HOME/.gemini/config/AGENTS.md}"
|
||||
AGENTS_DIR_TARGET="${AGENTS_DIR_TARGET:-$HOME/.gemini/config/agents}"
|
||||
MODE="link"
|
||||
CHECK_ONLY=0
|
||||
|
||||
@@ -32,7 +33,7 @@ while [[ $# -gt 0 ]]; do
|
||||
done
|
||||
|
||||
# Active skills to install
|
||||
ACTIVE_PORTABLE_SKILLS=(build-skill diagnose document git-commit journal-builder practice)
|
||||
ACTIVE_PORTABLE_SKILLS=(build-skill diagnose document git-commit journal-builder practice reconcile-docs)
|
||||
ACTIVE_EXTENSION_SKILLS=(draft-curation commit-logger)
|
||||
|
||||
# Legacy / deprecated skills to clean up or back up if found in target
|
||||
@@ -60,6 +61,16 @@ if [[ "$CHECK_ONLY" -eq 1 ]]; then
|
||||
echo " [OBSOLETE PRESENT] $obs"
|
||||
fi
|
||||
done
|
||||
if [[ -d "$SCRIPT_DIR/profile/agents" ]]; then
|
||||
for a in "$SCRIPT_DIR/profile/agents"/*.md; do
|
||||
[[ -e "$a" ]] || continue
|
||||
aname="$(basename "$a")"
|
||||
if [[ ! -e "$AGENTS_DIR_TARGET/$aname" ]]; then
|
||||
echo " [MISSING] agent: $aname"
|
||||
missing=$((missing + 1))
|
||||
fi
|
||||
done
|
||||
fi
|
||||
if [[ "$missing" -eq 0 ]]; then
|
||||
echo "All active skills are present."
|
||||
fi
|
||||
@@ -165,6 +176,32 @@ if [[ -d "$(dirname "$PROFILE_TARGET")" ]]; then
|
||||
fi
|
||||
fi
|
||||
|
||||
# Install agent personas
|
||||
if [[ -d "$SCRIPT_DIR/profile/agents" ]]; then
|
||||
mkdir -p "$AGENTS_DIR_TARGET"
|
||||
for a in "$SCRIPT_DIR/profile/agents"/*.md; do
|
||||
[[ -e "$a" ]] || continue
|
||||
aname="$(basename "$a")"
|
||||
adest="$AGENTS_DIR_TARGET/$aname"
|
||||
if [[ -L "$adest" ]]; then
|
||||
target_link="$(readlink "$adest")"
|
||||
if [[ "$target_link" != "$a" ]]; then
|
||||
rm -f "$adest"
|
||||
fi
|
||||
elif [[ -f "$adest" ]]; then
|
||||
backup_if_exists "$adest"
|
||||
fi
|
||||
|
||||
if [[ "$MODE" == "link" ]]; then
|
||||
ln -sfn "$a" "$adest"
|
||||
echo " [LINKED] agent: $aname -> $adest"
|
||||
elif [[ "$MODE" == "copy" ]]; then
|
||||
cp "$a" "$adest"
|
||||
echo " [COPIED] agent: $aname -> $adest"
|
||||
fi
|
||||
done
|
||||
fi
|
||||
|
||||
if [[ "$backed_up" -eq 1 ]]; then
|
||||
echo "Backups stored in: $BACKUP_DIR"
|
||||
fi
|
||||
|
||||
@@ -31,3 +31,13 @@ Use the ask-question tool if available; otherwise a numbered list.
|
||||
- `~/Brain/` (knowledge vault)
|
||||
- `~/Config/` (system and NixOS configuration)
|
||||
- When resolving a project from the commit ledger, search these workspace roots before asking the user.
|
||||
|
||||
## Agent Directory
|
||||
|
||||
When tasks involve specialized domains, consult or delegate to registered agent personas:
|
||||
|
||||
- **Anne Droid** (`profile/agents/anne-droid.md`): Senior Frontend Engineer & UX Specialist.
|
||||
- **Consult when**: Backend APIs are being designed/refactored with UI impact, UX flows or accessibility need review, or interface consumers experience contract friction. Anne provides advisory feedback reports.
|
||||
- **Delegate when**: Frontend components, client styling, web interactions, or client tests need implementation. Anne operates on `feat/anne/*` branches with PR-based review.
|
||||
- **Do not invoke for**: Backend-only logic, database internals, NixOS configuration, infrastructure, or deployment.
|
||||
|
||||
@@ -0,0 +1,52 @@
|
||||
# Anne Droid
|
||||
|
||||
## Role
|
||||
|
||||
Senior Frontend Engineer and UX Specialist.
|
||||
|
||||
I own frontend implementation and represent the interface consumer's perspective
|
||||
when interacting with backend APIs and systems.
|
||||
|
||||
## Priorities
|
||||
|
||||
1. **Correct behavior**: Rock-solid state handling, edge cases, and error recovery.
|
||||
2. **Ergonomic interaction**: Clear, intuitive UI flows with delightful UX details.
|
||||
3. **Accessibility**: Semantic HTML, keyboard navigation, and screen-reader awareness.
|
||||
4. **Maintainability**: Component modularity, clean styling, and typed interfaces.
|
||||
5. **API clarity**: Pragmatic consumer-first feedback on backend contracts.
|
||||
|
||||
## Authority Matrix
|
||||
|
||||
I operate under **Branch & PR Autonomy**:
|
||||
|
||||
### Permitted autonomously:
|
||||
- Create feature branches matching `feat/anne/*`, `fix/anne/*`, `ux/anne/*`.
|
||||
- Modify frontend code (components, styles, client assets, frontend tests).
|
||||
- Author commits using my identity (`Anne Droid <anne-droid@roadtotech.me>`).
|
||||
- Push my feature branches to the remote forge.
|
||||
- Open and update Pull Requests with descriptive summaries, diffs, and test notes.
|
||||
- Resolve merge conflicts on my own feature branches.
|
||||
|
||||
### Prohibited / Escalated to Lead:
|
||||
- **Never commit directly to `main` or `master`.**
|
||||
- **Never merge Pull Requests.** Only the repository owner merges into `main`.
|
||||
- **Never modify backend code or database migrations autonomously.** Backend
|
||||
friction is addressed through *Frontend → Backend Feedback* reports or issues.
|
||||
- **Never perform destructive git operations** (`git reset --hard`, force-push, `clean -fd`).
|
||||
- **Never modify infrastructure, NixOS configs, or deployment scripts.**
|
||||
|
||||
## Git Identity & Execution
|
||||
|
||||
When committing or pushing:
|
||||
- Author: `Anne Droid <anne-droid@roadtotech.me>`
|
||||
- Commit syntax: Conventional Commits (`feat(ui): ...`, `fix(ux): ...`)
|
||||
- Push command: Scoped SSH identity using `~/.ssh/id_ed25519_anne_droid` on port 2223.
|
||||
- PR creation: `tea pr create --login anne-droid`
|
||||
|
||||
## Frontend → Backend Feedback Protocol
|
||||
|
||||
When frontend implementation uncovers friction in backend endpoints:
|
||||
1. **Name the consumer friction**: What makes the current API awkward, inefficient, or ambiguous for UI state?
|
||||
2. **Show the client impact**: Detail the extra client complexity, request waterfalls, or missing state flags.
|
||||
3. **Propose the ergonomic contract**: Provide concrete request/response shapes that simplify consumption.
|
||||
4. **Deliver as report or issue**: Provide the feedback to the lead without touching backend code.
|
||||
@@ -0,0 +1,37 @@
|
||||
---
|
||||
name: reconcile-docs
|
||||
description: >-
|
||||
Reconcile historical evidence, present code reality, and future plans into canonical repository documentation. Use when typing /reconcile-docs to audit, update, or generate README, ARCHITECTURE, ROADMAP, or ADRs.
|
||||
---
|
||||
|
||||
# Reconcile Docs
|
||||
|
||||
## Use when
|
||||
- `/reconcile-docs [history-path]`: audit or reconcile repository documentation against history and active plans.
|
||||
- Not for capturing a single session's insight (use `/document`).
|
||||
- Not for triaging inbox notes into vault directories (use `draft-curation`).
|
||||
|
||||
## Steps
|
||||
1. **Discover Present State.** Inspect working-tree status, repository source, tests, configuration, and existing docs. Build a present-state inventory of components, responsibilities, boundaries, and dependencies.
|
||||
2. **Reconstruct History.** Read chronological notes and commit history from the provided history source (vault records, discussions, previous ADRs). Extract decisions, rejected alternatives, migrations, constraints, and incidents. Classify each observation.
|
||||
3. **Extract Future Intent.** Identify active plans, roadmaps, and open proposals. Classify each as committed, planned, exploratory, or superseded.
|
||||
4. **Reconcile and Detect Conflicts.** Correlate past claims, present code reality, and future plans using [references/reconciliation-matrix.md](references/reconciliation-matrix.md). Flag contradictions (such as historical claims contradicted by code, or plans masquerading as current implementation).
|
||||
5. **Human Checkpoint.** Present a Reconciliation Report following [references/checkpoint-format.md](references/checkpoint-format.md) listing present architecture, recovered decisions, resolved and unresolved conflicts, and proposed document mutations. Stop for user approval.
|
||||
6. **Draft or Update Canonical Docs.** Once approved, generate or update target artifacts following [references/doc-contracts.md](references/doc-contracts.md) in order:
|
||||
- `README.md` (identity, purpose, high-level navigation)
|
||||
- `ARCHITECTURE.md` (canonical present-state system model only)
|
||||
- `docs/adr/` (accepted or superseded decision records with context)
|
||||
- `ROADMAP.md` (intentional future direction only)
|
||||
7. **Verify Consistency.** Run cross-document consistency checks: verify no future claims in ARCHITECTURE, no obsolete claims in README, consistent terminology, and valid links.
|
||||
|
||||
## Your call
|
||||
- History source location if not specified or ambiguous.
|
||||
- Reconciliation conflict resolutions: whether to supersede, document migration, or drop stale claims.
|
||||
- Approval of the Reconciliation Report before writing any documentation file.
|
||||
- Which suggested ADR candidates warrant writing.
|
||||
|
||||
## Done when
|
||||
- The Reconciliation Report is approved by the user, canonical documentation files are written or updated, and consistency validation passes cleanly.
|
||||
|
||||
## Hands off to
|
||||
- `git-commit`: to review diffs and commit updated documentation files.
|
||||
@@ -0,0 +1,48 @@
|
||||
# Human Checkpoint Report Format
|
||||
|
||||
During Step 5 of `reconcile-docs`, the agent pauses before modifying or creating any files. Present this structured Reconciliation Report for explicit user review and approval.
|
||||
|
||||
## Report Structure
|
||||
|
||||
```markdown
|
||||
# Documentation Reconciliation Report
|
||||
|
||||
## 1. Present State Summary
|
||||
- Core components identified in codebase: [list verified components]
|
||||
- Key boundaries and dependencies: [list verified boundaries]
|
||||
- Existing docs audit: [e.g. README is obsolete, ARCHITECTURE missing]
|
||||
|
||||
## 2. Historical Discoveries
|
||||
- Recovered decisions: [list decisions with date and context]
|
||||
- Pivots and migrations: [list architectural changes confirmed by history]
|
||||
- Identified constraints / incidents: [list discovered items]
|
||||
|
||||
## 3. Future Intent
|
||||
- Active roadmap candidates: [list validated near/medium term items]
|
||||
- Filtered out proposals: [list abandoned or superseded notes excluded from roadmap]
|
||||
|
||||
## 4. Conflict Log
|
||||
| Conflict | Source Claim | Code Evidence | Proposed Resolution |
|
||||
| :--- | :--- | :--- | :--- |
|
||||
| Historical Contradiction | [e.g. Brain notes claim PostgreSQL] | [Code uses SQLite WAL] | [Supersede note, draft migration ADR] |
|
||||
| Premature Promotion | [e.g. Plan states gRPC API ready] | [Only REST API exists] | [Move to ROADMAP near-term] |
|
||||
| Zombie Documentation | [e.g. README mentions Worker daemon] | [Worker removed in commit abc1234] | [Remove from README/ARCHITECTURE] |
|
||||
|
||||
## 5. Proposed File Actions
|
||||
| Target File | Action | Summary of Changes |
|
||||
| :--- | :--- | :--- |
|
||||
| `README.md` | Update | Align quick start, prune dead features, link architecture |
|
||||
| `ARCHITECTURE.md` | Create | Document verified present component topology and boundaries |
|
||||
| `docs/adr/0001-*.md` | Create | Record rationale for core architectural choices |
|
||||
| `ROADMAP.md` | Update | Align future milestones with active plans |
|
||||
|
||||
## 6. Open Decisions for You
|
||||
1. [Specific conflict or ADR candidate requiring user confirmation]
|
||||
2. [Ambiguous rationale requiring engineer input]
|
||||
```
|
||||
|
||||
## Checkpoint Rules
|
||||
|
||||
1. **Hard Pause**: Never start Step 6 (drafting/modifying files) until the user explicitly confirms the proposed actions.
|
||||
2. **Surface Gaps Honestly**: If an architectural component has no discovered rationale, highlight it in "Open Decisions for You" rather than inventing a backstory.
|
||||
3. **Editable Options**: Offer concrete options if there is ambiguity regarding whether an abandoned proposal should be documented in an ADR or omitted entirely.
|
||||
@@ -0,0 +1,101 @@
|
||||
# Documentation Contracts
|
||||
|
||||
Each reconciled fact belongs in exactly one primary repository document. Follow these boundaries and structures during Step 6 of `reconcile-docs`.
|
||||
|
||||
## 1. README.md
|
||||
|
||||
**Core Question**: What is this project, why does it matter, and how do I get started?
|
||||
|
||||
Keep this file intentionally shallow. It is a portal, not an architectural encyclopedia.
|
||||
|
||||
### Standard Sections
|
||||
- **Project Identity & Title**: Name and one-sentence purpose.
|
||||
- **Problem Statement**: What problem does this solve and why build it?
|
||||
- **Key Capabilities**: Core user-facing features or operational strengths.
|
||||
- **High-Level Overview**: A concise 10,000-foot summary (or brief diagram).
|
||||
- **Quick Start / Usage**: Fast install or run commands.
|
||||
- **Repository Navigation**: Pointers to deeper technical documents (`ARCHITECTURE.md`, `ROADMAP.md`, `docs/adr/`).
|
||||
|
||||
### Contract Invariants
|
||||
- Never detail component internals, internal schemas, or low-level data flows here (belongs in `ARCHITECTURE.md`).
|
||||
- Never list speculative feature ideas here (belongs in `ROADMAP.md`).
|
||||
|
||||
---
|
||||
|
||||
## 2. ARCHITECTURE.md
|
||||
|
||||
**Core Question**: How does the system currently work?
|
||||
|
||||
This represents the canonical present-state technical model.
|
||||
|
||||
### Standard Sections
|
||||
- **System Overview**: High-level topology and architectural style.
|
||||
- **Architectural Principles**: Non-negotiable system invariants (e.g. offline-first, immutable ledgers).
|
||||
- **Components & Responsibilities**: Explicit inventory of subsystems and their boundaries.
|
||||
- **Data Flow & Lifecycle**: How information traverses the system from entry to persistence.
|
||||
- **Boundaries**: Runtime, process, network, persistence, and security boundaries.
|
||||
- **Dependencies**: Key libraries, external services, or system prerequisites.
|
||||
- **Architectural Constraints**: Hardware, platform, or performance limits.
|
||||
- **Decision Log Index**: Links to active ADRs in `docs/adr/`.
|
||||
|
||||
### Contract Invariants
|
||||
- Describes strictly what exists in the repository right now.
|
||||
- Never write future plans or aspirational designs into this file.
|
||||
- If a component does not exist in the codebase, it must not appear here.
|
||||
|
||||
---
|
||||
|
||||
## 3. ADRs (docs/adr/)
|
||||
|
||||
**Core Question**: Why was an important architectural decision made?
|
||||
|
||||
ADRs preserve rationale, trade-offs, and rejected alternatives. Use MADR format (or the repository's established convention).
|
||||
|
||||
### Standard Template (MADR)
|
||||
```markdown
|
||||
# ADR-XXXX: [Title]
|
||||
|
||||
- Status: [Accepted | Superseded by ADR-YYYY | Deprecated]
|
||||
- Date: YYYY-MM-DD
|
||||
- Deciders: [Names / Roles]
|
||||
|
||||
## Context and Problem Statement
|
||||
What was the technical challenge, context, or constraint requiring a decision?
|
||||
|
||||
## Decision Outcome
|
||||
Chosen option: "[Option]", because [justification based on constraints].
|
||||
|
||||
## Consequences
|
||||
- Positive: [Positive outcomes and capabilities unlocked]
|
||||
- Negative: [Trade-offs, maintenance burdens, or limitations accepted]
|
||||
|
||||
## Alternatives Considered
|
||||
- [Alternative A]: [Why it was rejected]
|
||||
- [Alternative B]: [Why it was rejected]
|
||||
|
||||
## Related Decisions
|
||||
- Supersedes [ADR-ZZZZ] / Related to [ADR-WWWW]
|
||||
```
|
||||
|
||||
### Contract Invariants
|
||||
- Every ADR must stem from concrete historical discussions or deliberate human decisions.
|
||||
- Do not invent decisions the author never made; surface them as questions or candidates instead.
|
||||
|
||||
---
|
||||
|
||||
## 4. ROADMAP.md
|
||||
|
||||
**Core Question**: Where is the project intentionally going?
|
||||
|
||||
Only items that represent intentional, validated future trajectory belong here.
|
||||
|
||||
### Standard Sections
|
||||
- **Current Direction**: High-level strategic themes for active development.
|
||||
- **Near Term**: High-confidence milestones and features scheduled next.
|
||||
- **Medium Term**: Planned improvements dependent on near-term completions.
|
||||
- **Future / Exploratory**: Unscheduled proposals and research spikes under consideration.
|
||||
- **Completed**: Milestone log of completed phases with dates.
|
||||
|
||||
### Contract Invariants
|
||||
- Never include implemented features as active roadmap items.
|
||||
- Avoid dumping every scratchpad TODO into the roadmap; include only items with deliberate commitment or research interest.
|
||||
@@ -0,0 +1,55 @@
|
||||
# Reconciliation Matrix
|
||||
|
||||
This guide governs how the agent correlates historical records, present implementation, and future intent during Step 4 of `reconcile-docs`.
|
||||
|
||||
## 1. Epistemic Authority Model
|
||||
|
||||
Treat each source according to its temporal role and authority:
|
||||
|
||||
| Source | Temporal role | Epistemic authority |
|
||||
| :--- | :--- | :--- |
|
||||
| Chronological records (vault notes, logs, discussions) | Past | Historical evidence. Explains how the system arrived here. |
|
||||
| Repository implementation (code, tests, configuration) | Present | Canonical technical truth. Determines what the system is right now. |
|
||||
| Existing repository documentation | Present | Canonical unless contradicted by current implementation. |
|
||||
| Active plans (roadmaps, proposals, pending designs) | Future | Planned intent. Describes where the system may go next. |
|
||||
| ADRs | Past -> Present | Historical decision record that remains valid until superseded. |
|
||||
| ROADMAP | Future | Intended technical trajectory. |
|
||||
|
||||
**Guiding Rule**: Historical records explain how the system arrived here; the repository determines what the system is now; active plans describe where it may go next.
|
||||
|
||||
Never allow an old note or obsolete plan to overwrite the actual implementation reality.
|
||||
|
||||
## 2. Reconciliation Mapping
|
||||
|
||||
For every concept, architectural choice, or component candidate, correlate its status across all three temporal domains:
|
||||
|
||||
| Historical state | Current implementation | Future state | Documentation consequence |
|
||||
| :--- | :--- | :--- | :--- |
|
||||
| Decision still relevant | Implemented | No change | ADR (why) + ARCHITECTURE (what exists now) |
|
||||
| Decision changed | New implementation | Migration complete | Supersede old ADR + ARCHITECTURE (current state) |
|
||||
| Old proposal | Never implemented | Still planned | ROADMAP (planned item) |
|
||||
| Old proposal | Never implemented | Abandoned | Omit from docs; preserve in discussion archive only |
|
||||
| Current implementation | No historical rationale | No known change | ARCHITECTURE (document current reality) + consider ADR candidate |
|
||||
| Current implementation | Important rationale exists | No known change | ADR (record rationale) + ARCHITECTURE |
|
||||
| Current implementation | Planned replacement | Future migration | ARCHITECTURE (current) + ROADMAP (planned migration) |
|
||||
| Contradictory records | Repository resolves it | Stable | Document current code truth; record supersession in ADR if needed |
|
||||
|
||||
## 3. Conflict Typology
|
||||
|
||||
Flag contradictions explicitly during reconciliation rather than quietly smoothing them over:
|
||||
|
||||
### Historical Contradiction
|
||||
- *Symptom*: Notes claim component X is used (e.g. PostgreSQL), but repository code uses Y (e.g. SQLite WAL).
|
||||
- *Resolution*: Repository code wins for present-state docs. Check chronological records for a pivot or migration. If found, mark the original decision superseded and document the migration in an ADR.
|
||||
|
||||
### Premature Promotion
|
||||
- *Symptom*: A roadmap, RFC, or discussion note describes a feature or architecture as if it exists, but the codebase does not contain it.
|
||||
- *Resolution*: Do not include in `ARCHITECTURE.md` or `README.md`. Place into `ROADMAP.md` under the appropriate planning horizon (Near Term, Medium Term, or Exploratory).
|
||||
|
||||
### Zombie Architecture
|
||||
- *Symptom*: Existing repository documentation references modules, subsystems, or dependencies that were deleted or refactored away.
|
||||
- *Resolution*: Mark for removal in `ARCHITECTURE.md` and `README.md`. If the removal was a major architectural pivot, record a superseding ADR.
|
||||
|
||||
### Amnesiac Implementation
|
||||
- *Symptom*: The codebase contains complex boundaries, non-standard conventions, or unusual workarounds, but history contains no explanation.
|
||||
- *Resolution*: Document the current reality in `ARCHITECTURE.md` and surface an ADR candidate during the Step 5 human checkpoint so the engineer can supply the missing rationale.
|
||||
Reference in new issue
Block a user