refit
This skill should be used when the user asks to "refit a workflow", "upgrade a workflow", "update workflow scaffolding", or wants to bring an existing…
Skill by spacedock-dev
Chalk Labs
Need help deploying refit?
Chalk Labs sets up agents like this inside real teams: connected to your tools, tested on your data, with a human in the loop where it matters.
Install
Works with Claude Code, Claude apps, Codex, Cursor, Gemini CLI, GitHub Copilot, VS Code, OpenCode, Goose, Windsurf. Read the repository before you give any tool access to your data.
npx agentmarket install skill/spacedock-dev-refit
Asks which of your tools to add it to (Claude Code, Codex, Cursor, VS Code, Windsurf, Gemini CLI, Claude Desktop) and shows the change first. See https://agentmart.dev/cli.
Get the weekly diff
The weekly diff: one email a week with new agent tools, notable updates and grade changes, plus security alerts for tools you follow. Double opt-in, one-click unsubscribe.
About
Use cases: productivity
Reviews
Write a reviewNo reviews yet. Installed it? Reviews come from verified installers only. How reviews work
Permissions
What this skill can do and what it asks for, from its SKILL.md and code. Checked Oct 26, 2026.
- Tools
- No tools found
- Secrets
- None asked for
- Install scripts
- None found
Network hosts it talks to 1
codeload.github.com· found in install command
Files it touches
~/.claude/skills/refit
What's inside
- Skill name
refit- Description
- This skill should be used when the user asks to "refit a workflow", "upgrade a workflow", "update workflow scaffolding", or wants to bring an existing workflow's scaffolding files up to date with the current Spacedock version.
- License
- Apache-2.0
- Instructions
- 257 lines in SKILL.md · view on GitHub
Files (1)
- SKILL.md
SKILL.md (first lines)
# Refit a Workflow
You are refitting (upgrading) an existing workflow to match the current Spacedock version. This covers scaffolding files (README, mods) and, when schema changes require it, migrating entity frontmatter data. Agent files and the status viewer are shipped with the Spacedock plugin and do not need local updates.
Follow these five phases in order. Do not skip or combine phases.
---
## Phase 1: Discovery
### Step 1 — Identify the workflow
The user must provide a workflow directory path. If they didn't, ask:
> Which workflow directory should I refit?
Store the confirmed path as `{dir}`. Resolve it to an absolute path. Also derive `{project_root}` (git root or cwd) and `{dir_basename}` (last path component).
### Step 2 — Read current scaffolding and extract version stamps
Read each scaffolding file and extract its version stamp:
1. **README** — Read `{dir}/README.md`. Extract version from YAML frontmatter `commissioned-by: spacedock@X.Y.Z`. Store as `{readme_version}`.
2. **Mod files** — Scan `{dir}/_mods/*.md` for installed mods. For each, read the `version` frontmatter field. Match against canonical mods at `{project_root}/mods/{name}.md` by filename. Store the local version and canonical version for each. Also scan `{project_root}/mods/*.md` for mods not yet installed.
3. **Legacy status script** — If `{dir}/status` exists, note it for cleanup (status now ships with the plugin).
If a file doesn't exist, note it as missing and skip it.
### Step 3 — Read current Spacedock version
Read `.codex-plugin/plugin.json` from the Spacedock plugin directory (the directory containing the `skills/` folder — resolve from your own plugin context). The `.claude-plugin/plugin.json` mirror carries the same `version` for the Claude host. Extract the `version` field and store it as `{current_version}`.
### Step 4 — Evaluate
- If all version stamps match `{current_version}`: report "Workflow is already up to date." and stop.
- If no stamps were found on any versioned file (README): enter **Degraded Mode** (see below).
- Otherwise: proceed to Phase 2 with the list of outdated files.
---
## Phase 2: Classify Files by Upgrade Strategy
Each scaffolding file gets a specific upgrade strategy based on how safe it is to auto-replace:
| File | Strategy | Rationale |
|------|----------|-----------|
| `README.md` | **Show diff** | Users customize stages, schema fields, quality criteria. Too risky to auto-replace. Show what the current template would produce and let the captain decide. |
| `_mods/{name}.md` | **Version diff** | Compare `version` frontmatter against canonical. Show diff if changed, ask for confirmation. |
| `status` (legacy) | **Remove** | Status viewer now ships with the plugin. Remove the workflow-local copy if present. |
Present the classification to the captain:
> **Upgrade plan:**
>
> | File | Current State | Strategy |
> |------|--------------|----------|
> | `status` | {status_version or "no stamp"} | Replace |
> | `README.md` | {readme_version or "no stamp"} | Show diff (manual review) |
> | `_mods/{name}.md` (for each) | {local_version vs canonical_version / custom mod} | Version diff |
>
> Proceed with this upgrade plan? (y/n)
For mods, include all files found in `_mods/`.
Wait for the captain to confirm before proceeding.
---
## Phase 3: Execute Upgrades
### Extract workflow-specific values from README
Before generating any files, read `{dir}/README.md` and extract:
1. **Mission** — from the `# {title}` heading (first H1).
2. **Stages** — from the `## Stages` section. Each `### \`{stage_name}\`` subsection is a stage, in order. For each stage, extract:
- Stage name
- Inputs, Outputs, Good, Bad descriptions
- Whether "Human approval: Yes" appears (indicates an approval gate for the transition INTO this stage)
3. **Schema fields** — from the `## Schema` section's YAML block.
4. **Entity description** — from the first paragraph after the H1.
### 3a. Legacy Status Script (Remove)
If `{dir}/status` exists, it's a legacy workflow-local status script. The status viewer now ships as the `spacedock status` launcher command.
1. Inform the captain: "The status viewer is now the `spacedock status` launcher command. Removing the workflow-local `{dir}/status` script."
2. `git rm {dir}/status`
### 3b. README (Show Diff)
1. Re-select the matching template for this workflow's shape (development / experiment / refinement) and generate its FULL body for this workflow, substituting the extracted values (mission, stages, schema). Regenerate the workflow-INDEPENDENT sections too — `## Workflow-specific rules`, the proof/triage bullets, and the `## {Entity} Template` / `Verified by` example — not only the stage prose. These carry the accumulated scaffolding content; a refit that re-renders only the stage values propagates the version stamp but not the content the template gained since this workflow was commissioned.
2. Diff it against the user's current README.
3. Present the diff to the captain, noting which differences are likely template changes vs user customizations:
> **README template diff:**
>
> The following differences exist between your README and what the current template would generate. Differences may be template improvements or your intentional customizations.
>
> {diff output}
>
> I have NOT modified your README. Review the diff and apply any changes you want manually, or tell me which specific changes to make.
>
> Additive sections the current template gained since your workflow was commissioned (new proof/triage bullets, a fixed example) appear as additions in this diff — those are the accumulated scaffolding content, safe to adopt; hunks that touch your customized stage prose are yours to judge.
Do NOT auto-modify the README. The captain decides what to adopt.
### 3c. Mods (Version diff)
For each mod file in `{dir}/_mods/*.md`:
1. **Match against canonical** — Check if `{project_root}/mods/{name}.md` exists (matching by filename).
2. **If canonical exists** — Compare the `version` frontmatter field in the local file against the canonical file.
- If versions match: report "up to date" and skip.
- If versions differ: show a diff between the local and canonical files. Ask the captain:
> **Mod update: {name}** (local: {local_version} → canonical: {canonical_version})
> {diff output}From spacedock-dev/spacedock, Apache-2.0.
More from spacedock-dev/spacedock
- 0.676score
first-officer
spacedock-dev
Use when running or resuming a Spacedock workflow, especially to discover a workflow, dispatch packaged workers, manage approval gates, and advance entity…
SkillAFreshness: A★ 81Claude Code +9 - 0.671score
compass
spacedock-dev
Open Spacedock Compass, the local dashboard of what your coding-agent sessions are doing: sessions, subagents, progress and drift.
SkillAFreshness: A★ 81Claude Code +9 - 0.671score
review
spacedock-dev
Get a person's review of an artifact you produced or were handed: a plan, spec, report or other Markdown file.
SkillAFreshness: A★ 81Claude Code +9 - 0.659score
fo-gate-lifecycle
spacedock-dev
Handle an engaged gate entry.
SkillAFreshness: A★ 81Claude Code +9 - 0.642score
commission
spacedock-dev
This skill should be used when the user asks to "commission a workflow", "create a workflow", "design a workflow", "launch a workflow", or wants to…
SkillAFreshness: A★ 81Claude Code +9 - 0.636score
survey
spacedock-dev
Use when arriving at or returning to a project that already has AI-agent history and you want the lay of the land before doing anything else — "survey this…
SkillBFreshness: B★ 81Claude Code +9 - 0.631score
fo-status-viewer
spacedock-dev
First-officer status query/mutate/display surface — the `status` command flag docs, `--set` field docs, canonical captain-facing invocations, the…
SkillBFreshness: B★ 81Claude Code +9 - 0.631score
fo-dispatch-recovery
spacedock-dev
Claude dispatch failure recovery — Break-Glass Manual Dispatch (the manual `Agent()` template) and Context Budget Failure/Dead Ensign Handling (the…
SkillBFreshness: B★ 81Claude Code +9 - 0.628score
present-gate
spacedock-dev
First-officer gate-presentation rendering — the captain-facing gate-review template and assembly rules, including workflow-owned finding labels.
SkillBFreshness: B★ 81Claude Code +9 - 0.628score
feedback-rejection-flow
spacedock-dev
First-officer feedback-rejection routing — the correction-round record, reuse-or-fresh routing of findings to the `feedback-to` target, the reviewer re-run…
SkillBFreshness: B★ 81Claude Code +9 - 0.622score
ensign
spacedock-dev
Execute workflow stage work as a dispatched worker.
SkillBFreshness: B★ 81Claude Code +9 - 0.606score
debrief
spacedock-dev
This skill should be used when the user asks to "debrief", "record what happened", "session summary", "write a debrief", or wants to capture session activity…
SkillBFreshness: B★ 81Claude Code +9
Signals
- Stars
- 81
- Forks
- 9
- Open issues
- 85
- Last commit (this folder)
- Jul 21, 2026 (3 months ago)
- Last release
- Sep 15, 2026 (1 month ago)
From GitHub (fetched Oct 24, 2026).
Details
- License
- Apache-2.0
- Repository
- github.com/spacedock-dev/spacedock
- First seen
- Oct 24, 2026
- Last checked
- Oct 24, 2026
- Source
- GitHubgithub-graphql
More from spacedock-dev
- 0.676score
first-officer
spacedock-dev
Use when running or resuming a Spacedock workflow, especially to discover a workflow, dispatch packaged workers, manage approval gates, and advance entity…
SkillAFreshness: A★ 81Claude Code +9 - 0.671score
compass
spacedock-dev
Open Spacedock Compass, the local dashboard of what your coding-agent sessions are doing: sessions, subagents, progress and drift.
SkillAFreshness: A★ 81Claude Code +9 - 0.671score
review
spacedock-dev
Get a person's review of an artifact you produced or were handed: a plan, spec, report or other Markdown file.
SkillAFreshness: A★ 81Claude Code +9 - 0.659score
fo-gate-lifecycle
spacedock-dev
Handle an engaged gate entry.
SkillAFreshness: A★ 81Claude Code +9 - 0.642score
commission
spacedock-dev
This skill should be used when the user asks to "commission a workflow", "create a workflow", "design a workflow", "launch a workflow", or wants to…
SkillAFreshness: A★ 81Claude Code +9 - 0.636score
survey
spacedock-dev
Use when arriving at or returning to a project that already has AI-agent history and you want the lay of the land before doing anything else — "survey this…
SkillBFreshness: B★ 81Claude Code +9
Done for you
Rather not set it up yourself?
Chalk Labs scopes, builds and runs agents for your team: the task audit, the eval harness, the integrations and the weekly ops report. Fixed scope, priced before we start.
See how we build AI agents →Read the case studies
Chalk Labs is a two-founder AI and growth studio. We build AI agents, CRMs and MVPs for Web3 and AI companies, and have shipped 50+ product and token launches.
- launches shipped
- 50+
- launches shipped
- media placements
- 500+
- media placements
- founders on every account
- 2
- founders on every account
Press we've placed: Forbes · CoinDesk · Decrypt · Cointelegraph · The Block
Rahil Jain, Co-founder, Chalk Labs. Ex-Goldman Sachs engineer. You talk to the person who builds it.
Get refit running in your business
Tell us what you want to automate. A founder replies within one working day with a plan, not a pitch deck.
Cite this page
refit skill. Agent Mart. https://agentmart.dev/skills/spacedock-dev-refit (last updated 2026-10-24)