Skip to main content
skill CX Codex

unharness — Claude Code skill: remove Citadel

unharness is a Claude Code skill that plans Citadel removal from a project and keeps a portable archive. It runs on requests to remove Citadel or clean up the harness.

MIT ★ 937 updated 2026-10-29

Install into Claude Code · Plugin marketplace All methods and platforms ↓
/plugin marketplace add SethGammon/Citadel
/plugin install citadel@citadel-local
Open on GitHub

What unharness does

unharness checks the Citadel adoption receipt and creates an exit plan without changing the project. The plan lists files to remove or restore, altered items that will stay, the archive location, and runtime registrations whose removal status is unknown.

After explicit approval, the skill applies the saved plan with its exact confirmation token and runs a check. Node.js and the Citadel scripts are required. Older installs need an import first; modified files and registrations with unknown status are not removed or reported as confirmed removals.

What it helps with

  • plan Citadel removal without changing project files
  • keep a portable archive before leaving Citadel
  • retain altered or ambiguous files
  • check whether external registrations were actually removed

Example prompts for the agent

  • Remove Citadel from this project and show me the plan before making changes.
  • Clean the harness out of this project, keep an archive, and list what will remain.
  • Export a readable Citadel archive without removing files.

How to install unharness

1Plugin marketplace

/plugin marketplace add SethGammon/Citadel
/plugin install citadel@citadel-local

This installs the whole citadel plugin with all its skills

2Skills CLI (Vercel)

npx skills add SethGammon/Citadel --skill unharness -a claude-code

3Manually: put the files in place

~/.claude/skills/unharness/SKILL.md

Copy the whole skill folder; for one project use .claude/skills/unharness/

Step by step, with commands for each platform: How to install skills in Claude Code: five ways

Questions about unharness

How do I install unharness in Claude Code?

Run /plugin marketplace add SethGammon/Citadel, then /plugin install citadel@citadel-local.

What does unharness do?

It prepares a Citadel exit plan, preserves a portable archive, and applies the plan after explicit approval. Modified files and removals with unknown status stay flagged in the report.

What does unharness need to run?

It needs Node.js, the Citadel scripts, and a valid adoption receipt. Older installs must be imported first; applying a plan requires explicit approval and its exact confirmation token.

Source text

SKILL.md · MIT
---
name: unharness
license: MIT
description: >-
  Safely leave Citadel using the active adoption receipt. Produces a no-write,
  reviewable plan, preserves a portable archive, removes only exact owned
  material, and reports modified or externally registered surfaces as retained
  or unknown. Legacy installs must be imported before exact leave is claimed.
user-invocable: true
auto-trigger: false
trigger_keywords:
  - unharness
  - remove citadel
  - uninstall citadel
  - clean up citadel
  - remove harness
  - uninstall harness
last-updated: 2026-07-30
---

# /unharness - Receipt-owned exit from Citadel

## Orientation

Use this skill when the user wants Citadel removed from a project. Exit is a
two-step, receipt-owned operation. A plan never mutates the project. Apply
requires the exact saved plan and its confirmation token.

Do not infer ownership from familiar paths. Do not delete `.planning/`,
`.citadel/`, runtime settings, hooks, skills, or registrations merely because
they look Citadel-related.

## Protocol

### 1. Locate Citadel and inspect adoption authority

Read `.citadel/plugin-root.txt` when present. Otherwise use the directory
containing this skill. Check for `.citadel/adoption/active.json`; the adoption
planner also checks the private recovery ledger.

### 2. Create a no-write leave plan

Choose a plan path inside the project, such as
`.planning/adoption/leave.plan.json`, and run:

```bash
node {citadelRoot}/scripts/adopt.js leave plan \
  --target {projectRoot} \
  --out {planPath} \
  --json
```

Show the user:

- exact files that will be removed or restored;
- modified or ambiguous footprint entries that will be retained;
- portable archive path;
- runtime registrations whose removal evidence is `unknown`;
- the plan digest and confirmation token.

If the result is `NOT_ADOPTED`, stop. Create a conservative legacy inventory:

```bash
node {citadelRoot}/scripts/adopt.js import plan {citadelRoot} \
  --target {projectRoot} \
  --out {importPlanPath} \
  --json
```

Apply that import only after its own explicit approval. Then create a new leave
plan from the resulting receipt. Never describe legacy cleanup as exact
removal.

### 3. Obtain explicit approval

Leaving is destructive. Ask the user to approve the displayed plan and exact
confirmation token. Do not apply from an unsaved or regenerated plan.

### 4. Apply and verify

After approval:

```bash
node {citadelRoot}/scripts/adopt.js leave apply {planPath} \
  --confirm {confirmationToken} \
  --json

node {citadelRoot}/scripts/adopt.js doctor \
  --target {projectRoot} \
  --json
```

Doctor may report `not_adopted` after a clean leave. Report the leave receipt,
archive path, removed entries, retained conflicts, and every `unknown`
unregistration observation. “Citadel removed” is permitted only when the
receipt proves every required local and external removal.

## Export-only compatibility

When the user explicitly wants a human-readable export without leaving:

```bash
node {citadelRoot}/scripts/unharness.js {projectRoot} --export-only
```

This writes the legacy Markdown archive but does not remove harness material.

## Fringe Cases

- If `.planning/` does not exist, treat it as an empty portable-state set and
  show the setup/import hint; do not create it merely to leave.
- Missing or invalid adoption authority blocks leave. Use `import plan` or
  private-ledger recovery; never guess ownership.
- A changed saved plan, source, target, or pre-image requires a fresh plan.
- An unavailable runtime unregister API stays `unknown`; report the manual
  observation required.
- If the Citadel root cannot be located, stop with the exact missing path.

## Quality gates

- Planning is read-only unless the user explicitly requests `--out`.
- Apply consumes the exact saved plan and revalidates source, target, and
  pre-images.
- Modified owned material is retained with an explicit conflict.
- Shared runtime files restore exact pre-images only while installed bytes
  remain exact.
- Missing receipts, malformed receipts, and unenumerable registrations are
  `unknown` or blocked, never successful.
- The portable archive and private receipt ledger remain available for restore
  and recovery.

## Exit Protocol

Return the leave operation ID and receipt digest, portable archive path, exact
removed/restored counts, retained conflicts, and unknown external removals.
State plainly whether exact exit was proved. Do not claim success from a
completed command when required removal evidence is missing.

© SethGammon · MIT · SethGammon/Citadel

Similar skills

All skills for Agent setup: memory, context, orchestration →
uninstall official anthropics uninstall is a Claude Code skill that removes community skills installed through the hub. It activates for a full removal request, not when someone only wants to disable a skill. CX Codex +1 616installs coding-agent-rollout Alireza Rezvani coding-agent-rollout audits Claude settings before a team rollout: lints permissions across scopes, inventories MCP servers and plugins, and turns local session data into adoption counts. CX Codex +1 1installs crossing-the-chasm wondelai crossing-the-chasm is a Claude Code skill for planning a technical product’s move into the mainstream market. It activates during go-to-market planning and segment selection. CX Codex +1 5,600installs gtm-enterprise-onboarding official Smit Patel (https://linkedin.com/in/smitkpatel) gtm-enterprise-onboarding — a four-phase skill for moving enterprise customers from contract to sustained adoption. Use it to prepare onboarding and address churn risks after go-live. CX Codex +1 1,600installs champion-kit official Anthropic champion-kit — a plugin for Claude Code aids internal AI adoption. Runs hack days, schedules office hours, extracts repo patterns into skills, and builds an AI maturity report. ★ 47,914repo stars customer-success-manager VoltAgent customer-success-manager — a subagent for mapping support patterns and adoption risks based on engineering data. Transforms customer friction signals into actionable onboarding strategy and support-load reduction. CX Codex ★ 6,505repo stars

From the same set55

The whole set →
arch-reviewer arch-reviewer inspects project files for layer boundary violations, circular dependencies, and dead imports without modifying code. CX Codex ★ 937repo stars knowledge-extractor The knowledge-extractor subagent saves reusable patterns, pitfalls, and decisions from finished work for a project wiki. Run it after completing a substantial piece of work. CX Codex ★ 937repo stars session-handoff session-handoff turns the current session into a structured HANDOFF block so the next session can pick up work without re-auditing the project. CX Codex +1 ★ 937repo stars verify verify — a skill to self-test the Citadel hook pipeline during a live session. Exercises real tool calls (Write, Edit, Bash, Read), verifies that hooks fire, telemetry accumulates, and no errors occur. CX Codex +1 ★ 937repo stars grill grill turns a vague plan into a sharp technical spec through one-question-at-a-time interview, each with a default answer you edit. CX Codex +1 ★ 937repo stars autopilot autopilot processes queued tickets from .planning/intake/ through automated research, implementation, and verification. CX Codex +1 ★ 937repo stars doc-gen doc-gen generates function comments, directory READMEs, and API references while following the project’s existing conventions. Use it when docs should explain code behavior rather than repeat signatures. CX Codex +1 ★ 937repo stars policy-enforcer policy-enforcer is a Claude Code subagent that checks proposed actions against Citadel’s rules and returns an allow-or-block verdict. Archon and Fleet spawn it before actions with low reversibility. CX Codex ★ 937repo stars

Project sponsors

Companies that keep this analytics open