Système de Points de Contrôle pour Workflows

VérifiéSûr

Cette compétence fournit un système de points de contrôle pour les workflows, qui suit les phases de progression (configuration, recherche, implémentation, révision, finalisation) et enregistre les actions et les commits. Elle utilise des commandes CLI via `pnpm checkpoint workflow` pour créer, trouver, mettre à jour et reprendre des workflows. Utile pour maintenir le contexte entre les sessions et permettre la reprise après une compaction du contexte de l'agent.

Spar Skills Guide Bot
DeveloppementIntermédiaire
10002/06/2026
Claude Code
#checkpoint#workflow#resume#cli#issue-tracking

Recommandé pour

Notre avis

Ce skill permet de gérer un système de points de contrôle pour les workflows de résolution d'issues, facilitant la reprise après une compression de contexte.

Points forts

  • Structure le travail en phases claires (setup, research, implement, review, finalize)
  • Permet de reprendre le travail exactement là où on s'est arrêté
  • Journalise les actions et les commits pour un suivi complet

Limites

  • Nécessite une base de données SQLite locale qui peut être perdue
  • Les commandes CLI doivent être exécutées exactement, sans variables shell
  • Ne fonctionne que pour les workflows gérés via ce système spécifique
Quand l'utiliser

À utiliser lorsque vous travaillez sur une issue complexe nécessitant plusieurs sessions ou une reprise après un nettoyage de contexte.

Quand l'éviter

Évitez de l'utiliser pour des tâches très simples ou ponctuelles qui ne nécessitent pas de suivi d'état.

Analyse de sécurité

Sûr
Score qualité90/100

The skill describes internal CLI commands for a workflow checkpoint system. No external scripts, destructive operations, or exfiltration are instructed. It does not introduce any realistic security risk.

Aucun point d'attention détecté

Exemples

Create a new workflow for an issue
Create a new checkpoint workflow for issue 42 on branch 'fix/42-null-pointer'.
Find an existing workflow by issue number
Check if there is an existing workflow for issue 15 and show its status.
Log a commit after creating it
Log the latest commit (SHA from git rev-parse HEAD) with message 'fix: resolve null pointer' into the current workflow.

Checkpoint Workflow Skill

Reference for agents working with the workflow checkpoint system.

Purpose

The checkpoint system enables workflow resume after context compaction. Each /work-on-issue session creates a workflow that tracks:

  • Current phase (setup → research → implement → review → finalize)
  • Actions taken (plan created, PR opened, etc.)
  • Commits made during the workflow

Database Location

Checkpoint state is stored in .claude/execution-state.db (gitignored).

CLI Commands

All commands use pnpm checkpoint workflow <action>.

Create Workflow

pnpm checkpoint workflow create <issue_number> "<branch_name>"

Output: JSON with id, issue_number, branch_name, status, current_phase

Example:

pnpm checkpoint workflow create 12 "feat/12-add-parser"

Find Workflow by Issue

pnpm checkpoint workflow find <issue_number>

Output: JSON workflow or null

Use case: Check if workflow exists before creating a new one.

Get Workflow Summary

pnpm checkpoint workflow get <workflow_id>

Output: JSON with workflow, actions, commits

Use case: Full context for resuming work.

List Workflows

pnpm checkpoint workflow list [--status=running|completed|failed] [--limit=N]

Output: JSON array of workflows

Set Phase

pnpm checkpoint workflow set-phase <workflow_id> <phase>

Phases: setup, research, implement, review, finalize

Set Status

pnpm checkpoint workflow set-status <workflow_id> <status>

Statuses: running, paused, completed, failed

Log Action

pnpm checkpoint workflow log-action <workflow_id> <action_type> <status> [details]

Status values: success, failed, skipped

Common action types:

  • workflow_started
  • dev_plan_created
  • implementation_complete
  • pr_created

Log Commit

pnpm checkpoint workflow log-commit <workflow_id> <sha> "<message>"

CRITICAL: Commit logging pattern

Always log commits in two separate commands:

# 1. Get SHA (separate command)
git rev-parse HEAD

# 2. Log to checkpoint (use literal SHA, not variable)
pnpm checkpoint workflow log-commit "abc123" "a1b2c3d" "feat: add feature"

NEVER combine with && or use shell variables. This prevents errors if the git command fails.

Delete Workflow

pnpm checkpoint workflow delete <workflow_id>

Integration Patterns

At Workflow Start (setup-agent)

# Check for existing workflow
pnpm checkpoint workflow find {issue_number}

# If found with status=running, offer to resume
# If not found, create new workflow
pnpm checkpoint workflow create {issue_number} "{branch_name}"

After Plan Creation (issue-researcher)

pnpm checkpoint workflow set-phase "{workflow_id}" research
pnpm checkpoint workflow log-action "{workflow_id}" "dev_plan_created" success

After Each Commit (atomic-developer)

# Get SHA first
git rev-parse HEAD
# Then log (with actual SHA value)
pnpm checkpoint workflow log-commit "{workflow_id}" "{sha}" "{message}"

After PR Creation (finalize-agent)

pnpm checkpoint workflow log-action "{workflow_id}" "pr_created" success
pnpm checkpoint workflow set-status "{workflow_id}" completed

Resume Flow

When starting /work-on-issue:

  1. Check for existing workflow: pnpm checkpoint workflow find {issue_number}
  2. If found with status=running:
    • Show current phase and recent actions
    • Ask: "Resume from {phase}?" or "Start fresh?"
  3. If resuming, skip to the saved phase
  4. If starting fresh, delete old workflow and create new one

Error Handling

If a checkpoint command fails:

  1. Log the error
  2. Continue with the workflow (checkpoints are advisory, not blocking)
  3. The work can still be done, just without resume capability
Skills similaires