Skip to main content

thoughtful-commitment

Git commits that capture context and intent

Informações da origem

Repositório
SimHacker/moollm
Última atividade na origem
7 de fevereiro de 2026 às 14:40
Idioma detectado do SKILL.md
inglês
Estrelas
60
Forks
5

Opções de instalação

Por padrão, está selecionado o prompt que primeiro revisa a origem. Você pode mudar para um comando direto ou baixar uma cópia local.

Revise os arquivos de origem

Leia o SKILL.md e os arquivos complementares exibidos pelo SkillsMP antes de decidir se vai instalar.

Explorador de arquivos
8 arquivos

Exibindo SKILL.md

SKILL.md
Instruções da origem · Visualização somente leitura
name
thoughtful-commitment
description
Git commits that capture context and intent
license
MIT
tier
2
allowed-tools
["read_file","write_file","list_dir","run_terminal_cmd","grep"]
protocol
THOUGHTFUL-COMMITMENT
related
["cursor-mirror","session-log","plain-text","yaml-jazz","git-workflow"]
tags
["git","commits","provenance","introspection"]
# Thoughtful Commitment > *Commits that capture context, not just changes.* ## Purpose Git commits with traceability: - What changed (git diff) - Why it changed (cursor-mirror thinking) - Who asked for it (user request) - Session link for full context ## The Core Insight Git and cursor-mirror are **two introspection systems** that mesh via commit IDs: ``` Git: "What changed?" → abc123 Cursor-Mirror: "Why?" → events 140-148 Thoughtful Commitment: Links them together ``` ## Protocol: THOUGHTFUL-COMMITMENT ### Commit Message Format ``` <type>: <summary> (imperative, <50 chars) <narrative> What happened, from whose perspective, and why it matters. Focus on intent and motivation, not just mechanics. <changes> - Bullet list of mechanical changes - For quick scanning <thinking-ref> Thinking: cursor-mirror://<composer>/<event-range> ``` ### Types | Type | Use | |------|-----| | `feat` | New feature or capability | | `fix` | Bug fix | | `refactor` | Code restructuring (no behavior change) | | `docs` | Documentation only | | `style` | Formatting (no code change) | | `test` | Adding or updating tests | | `chore` | Maintenance tasks | | *narrative* | Story beat, character change, world evolution | For MOOLLM narratives, the type can be the story beat: ``` Incarnation Ceremony: Kittens receive emoji souls Midnight Prowl: Cats explore the moonlit garden Cat Council: Biscuit accepted into family ``` ### Context Gathering Before writing commits or PRs, gather existing messages to match style and avoid repetition: ```bash # Recent commit messages (style reference) git log --oneline -20 git log origin/main..HEAD --format='%s%n%b%n---' # PR descriptions gh pr view --json title,body gh pr list --state merged -L 10 --json number,title # Combined context git log origin/main..HEAD --oneline && \ git diff origin/main --stat | tail -5 ``` See `examples/git-commands.yml` → `context_gathering` for complete reference. ## Method Specifications --- ## Primary Introspection — Start Here These are the entry points. Get the timeline, then drill down. ### TIMELINE **The master view.** Shows all events with timestamps, types, and IDs. **Input:** ```yaml method: TIMELINE parameters: composer: string # Composer ID (@1, name fragment, hash) limit: int # How many events (default: 50) filter: string # Event type filter (thinking, tool, user, all) since: string # Time filter ("1 hour ago", event ID) ``` **Process:** ```bash cursor-mirror timeline <composer> --limit <n> ``` **Output:** ``` 🤔💭 ⏱️ Session Timeline — e8587ace #141 16:46:12 📍 user "Refactor auth module" #142 16:46:15 🪟 context 3 files, ~4.2k tokens #143 16:46:18 🧠 thinking "Need to check for race conditions..." #144 16:46:22 🔧 tool Read auth/session.ts #145 16:46:25 📤 result 247 lines loaded #146 16:46:30 🧠 thinking "Found race condition on line 47..." #147 16:46:35 💡 insight "Adding await fixes sequencing" #148 16:46:40 🔧 tool Write auth/session.ts #149 16:46:45 📝 change +3 -1 lines → Drill down: CONTEXT-FOCUS #142 | THINKING #143 | TOOLS #144 ``` **Drill-down commands:** - `CONTEXT-FOCUS #142` — What went into context at that point? - `THINKING #143` — Full text of that thinking block - `TOOLS #144-148` — Tool calls in that range - `EXPLAIN #149` — Why was that change made? The timeline is the **map**. Everything else is **zooming in**. --- ### CONTEXT-FOCUS Analyze what went into the context window for a specific call. Shows the cursor state — what files, snippets, conversation, and rules were assembled. **Input:** ```yaml method: CONTEXT-FOCUS parameters: composer: string # Composer ID event_id: string # Optional: specific event (default: latest) ``` **Process:** ```bash # Get context sources for a composer cursor-mirror context-sources <composer> # Analyze what was in context at a specific event cursor-mirror timeline <composer> --before <event_id> --type context ``` **Output:** ``` 🤔💭 🪟 Context Window Analysis — event #142 Files read into context: auth/session.ts 247 lines ████████████░░░░ 58% auth/types.ts 89 lines ████░░░░░░░░░░░░ 21% tests/auth.test.ts 156 lines ██████░░░░░░░░░░ 37% Snippets: session.ts:45-67 (highlighted by user) Conversation turns: 12 Rules loaded: .cursorrules, workspace rules Estimated tokens: ~4,200 Focus: auth module, session handling ``` The 🪟 tag marks context window analysis — showing what the LLM "saw" for this call. --- ### THINKING Show reasoning blocks for an event or range. **Input:** ```yaml method: THINKING parameters: composer: string event_id: string # Specific event range: string # Or range like "143-146" ``` **Process:** ```bash cursor-mirror thinking <composer> --event <id> ``` **Output:** ``` 🤔💭 🧠 Thinking Block #143 "I need to understand the current structure of the auth module before making changes. Let me read the session handling code first. The user mentioned a race condition — I should look for any async operations that might not be properly awaited. Common patterns to check: cookie operations, token refresh, database calls..." (247 chars, 16:46:18) ``` --- ### TOOLS Show tool calls for an event or session. **Input:** ```yaml method: TOOLS parameters: composer: string event_id: string # Specific event, or omit for all tool_filter: string # Filter by tool name (Read, Write, Shell, etc.) ``` **Process:** ```bash cursor-mirror tools <composer> cursor-mirror tools <composer> --filter Read ``` **Output:** ``` 🤔💭 🔧 Tool Calls — session e8587ace #144 Read auth/session.ts 247 lines #148 Write auth/session.ts +3 -1 #150 Read auth/types.ts 89 lines #152 Shell git diff --staged +3 -1 lines #153 Write tests/auth.test.ts +45 new Distribution: Read 42% | Write 28% | Shell 18% | Grep 12% ``` --- ## Commit Operations ### COMMIT Create a thoughtful commit. **Input:** ```yaml method: COMMIT parameters: files: [string] # Files to commit (or '.' for all) summary: string # What changed (auto-detect if omitted) include_thinking: bool # Link to cursor-mirror (default: true) style: enum # technical (default) | changelog | pr | burke ``` **Styles:** | Style | Use | Output | |-------|-----|--------| | `technical` | **Default.** Concise, factual | `fix: race condition in auth` + bullets | | `changelog` | Release notes | User-facing changes grouped by type | | `pr` | Pull request body | Summary, changes, test plan | | `burke` | James Burke storytelling | Facet-to-facet connections, disco ball | **Process:** 1. Stage specified files (`git add`) 2. Gather context from conversation 3. If `include_thinking`, query cursor-mirror for recent events 4. Generate commit message per protocol 5. Create commit (`git commit -m "..."`) 6. Return commit ID and message **Output:** ```yaml commit_id: "abc123" message: "Full commit message..." thinking_link: "cursor-mirror://def456/events/140-148" ``` ### EXPLAIN Find the thinking that led to an existing commit. **Input:** ```yaml method: EXPLAIN parameters: commit: string # Commit hash (full or abbreviated) ``` **Process:** 1. Get commit details (`git show --format=...`) 2. Extract timestamp 3. Search cursor-mirror for events around that time 4. Find the git commit tool call 5. Trace back to thinking blocks and user request **Output:** ```yaml commit_message: "Incarnation Ceremony: ..." timestamp: "2026-01-15T19:30:00Z" author: "Coherence Engine" user_request: "Incarnate the kittens with emoji souls" thinking_blocks: - event_id: 141 content: "I need to invoke INCARNATION protocol..." - event_id: 142 content: "Myrcene's terpene is sedating..." tool_calls: - event_id: 144 tool: write_file args: {path: "kitten-myrcene/CHARACTER.yml"} - event_id: 148 tool: git_commit args: {message: "..."} ``` ### MESSAGE Generate a commit message from current context. **Input:** ```yaml method: MESSAGE parameters: diff_summary: string? # Optional (auto-detect from staged) style: enum # technical (default) | changelog | pr | burke detail: int # 1-5 (default: 3) ``` **Process:** 1. If no diff_summary, run `git diff --staged --stat` 2. Analyze conversation context for intent 3. Generate message per perspective and protocol **Output:** ```yaml message: "Full commit message..." sections: title: "Incarnation Ceremony: Kittens receive emoji souls" body: "The Cat Cave family gathered..." changes: ["Added emoji_identity...", "Added pronouns..."] ``` ### LINK Manually link a commit to cursor-mirror events. **Input:** ```yaml method: LINK parameters: commit: string # Commit hash events: [string] # Event IDs from cursor-mirror ``` **Process:** 1. Validate commit exists 2. Validate events exist in cursor-mirror 3. Store link in `.moollm/skills/thoughtful-commitment/commit-links.yml` **Output:** ```yaml linked: true reference: "cursor-mirror://abc123/events/140-148" ``` ### HISTORY Get narrative history of a file or directory. **Input:** ```yaml method: HISTORY parameters: path: string # File or directory depth: int # Number of commits (default: 10) include_thinking: bool # Include cursor-mirror links (default: true) ``` **Process:** 1. Get git log for path (`git log -n <depth> --format=... -- <path>`) 2. For each commit, attempt to find cursor-mirror link 3. Build narrative timeline **Output:** ```yaml timeline: - commit: "abc123" date: "2026-01-15" message: "Incarnation Ceremony: ..." thinking_link: "cursor-mirror://..." summary: "Kittens received emoji souls" - commit: "def456" date: "2026-01-14" message: "Initial character creation" thinking_link: null summary: "Created basic character files" ``` ### DEEP-COMMIT Technical analytics mining — extract quantitative metrics from cursor-mirror and git. **When to use:** - PR descriptions needing detailed appendices - Post-mortem analysis of development sessions - Documenting complex multi-hour sessions - Generating reproducible verification commands **Process:** ~~~bash # 1. Raw metrics extraction TRANSCRIPT="path/to/transcript.txt" wc -l "$TRANSCRIPT" # line count wc -c "$TRANSCRIPT" # byte count grep -c "^\[Tool call\]" "$TRANSCRIPT" # tool calls grep -c "^\[Thinking\]" "$TRANSCRIPT" # thinking blocks grep -c "^user:" "$TRANSCRIPT" # user turns # 2. Tool distribution grep "^\[Tool call\]" "$TRANSCRIPT" | cut -d' ' -f3 | sort | uniq -c | sort -rn # 3. Thinking block analysis grep "^\[Thinking\]" "$TRANSCRIPT" | while read l; do echo ${#l}; done | \ sort -n | awk 'BEGIN{sum=0} {a[NR]=$1; sum+=$1} END{ printf "Count: %d\nMin: %d\nMax: %d\nAvg: %.0f\nMedian: %d\n", NR, a[1], a[NR], sum/NR, a[int(NR/2)] }' # 4. Activity bursts cursor-mirror timeline <composer> 2>&1 | \ grep -E "^[0-9]{4}-" | cut -d: -f1-2 | uniq -c # 5. Git commit metrics git log --oneline <range> git diff --numstat <range> | awk '{ins+=$1; del+=$2} END{print ins, del}' # 6. Word frequency in thinking grep "^\[Thinking\]" "$TRANSCRIPT" | tr '[:upper:]' '[:lower:]' | \ tr -cs '[:alpha:]' '\n' | sort | uniq -c | sort -rn | head -20 ~~~
Ver no GitHub
Este SKILL.md e muito grande, entao o SkillsMP mostra aqui apenas a primeira secao. Ver no GitHub