/harness-drift-from-history
One-command drift detection: run a fresh metaharness audit, diff it against the latest stored audit by ADR-152 similarity, and alert when the distance crosses `--threshold`. Use when checking whether a harness has drifted since its last audit.
Claude Code
$ npx -y skills add ruvnet/ruflo --skill harness-drift-from-history --agent claude-code
Codex
$ npx skills add ruvnet/ruflo --skill harness-drift-from-history -a codex -y
Cursor
$ npx skills add ruvnet/ruflo --skill harness-drift-from-history -a cursor -y
Gemini CLI
$ npx skills add ruvnet/ruflo --skill harness-drift-from-history -a gemini-cli -y
GitHub Copilot
$ npx skills add ruvnet/ruflo --skill harness-drift-from-history -a github-copilot -y
OpenCode
$ npx skills add ruvnet/ruflo --skill harness-drift-from-history -a opencode -y
Windsurf
$ npx skills add ruvnet/ruflo --skill harness-drift-from-history -a windsurf -y
SKILL.md
harness-drift-from-history.SKILL.mdname: harness-drift-from-history
description: "One-command drift detection: run a fresh metaharness audit, diff it against the latest stored audit by ADR-152 similarity, and alert when the distance crosses `--threshold`. Use when checking whether a harness has drifted since its last audit."
argument-hint: "[--path .] [--baseline-since 7d] [--threshold 0.95] [--dry-run] [--format json|table]"
allowed-tools: Bash
The natural ops question after running `oia-audit` weekly is "did anything drift?" Before this skill, the answer required a three-step sequence:
npx ruflo metaharness audit-list --format json # → pick a key by hand
npx ruflo metaharness oia-audit --format json > /tmp/curr.json
npx ruflo metaharness audit-trend \
--baseline-key <picked-key> --current /tmp/curr.json \
--alert-on-distance-below 0.95
This skill collapses it into one command:
npx ruflo metaharness drift-from-history --threshold 0.95
What it does
1. Lists records from `metaharness-audit` namespace via audit-list.mjs 2. Picks the most recent record by `startedAt` (or `--baseline-since 7d` skips anything newer than 7 days) 3. Runs a fresh `oia-audit` against the current path 4. Diffs the two via audit-trend, applying `--alert-on-distance-below ${threshold}` 5. Returns the structured drift report
Architectural constraint inheritance (ADR-150)
| Constraint | How drift-from-history satisfies it | |---|---| | Removable | Pure subprocess composition over existing scripts — no new `@metaharness/*` import | | Optional | If oia-audit reports `degraded:true`, this skill exits 3 with a degraded payload | | Graceful | Empty audit history → exit 2 with hint to seed it; never crashes | | CI-gate | Smoke step 17z16 anchors the dispatcher entry + subcommand listing |
Exit codes
- 0 — similarity ≥ threshold (or threshold not crossed)
- 1 — drift detected: similarity < threshold (alert fired)
- 2 — config error (no history, audit-list failed)
- 3 — upstream metaharness absent (degraded payload returned)
Example
$ npx ruflo metaharness drift-from-history --threshold 0.95
# drift-from-history
Baseline: audit-2026-06-16T22-58-47-840Z
Current: 2026-06-16T23:05:02.231Z
Structural similarity: 1 (near-identical)
Distance: 0
✓ similarity ≥ 0.95 — OK
Implementation
[`scripts/drift-from-history.mjs`](../../scripts/drift-from-history.mjs)
Read more
name: harness-drift-from-history description: "One-command drift detection: run a fresh metaharness audit, diff it against the latest stored audit by ADR-152 similarity, and alert when the distance crosses `--threshold`. Use when checking whether a harness has drifted since its last audit." argument-hint: "[--path .] [--baseline-since 7d] [--threshold 0.95] [--dry-run] [--format json|table]" allowed-tools: Bash
The natural ops question after running `oia-audit` weekly is "did anything drift?" Before this skill, the answer required a three-step sequence:
npx ruflo metaharness audit-list --format json # → pick a key by hand npx ruflo metaharness oia-audit --format json > /tmp/curr.json npx ruflo metaharness audit-trend \ --baseline-key <picked-key> --current /tmp/curr.json \ --alert-on-distance-below 0.95
This skill collapses it into one command:
npx ruflo metaharness drift-from-history --threshold 0.95
What it does
1. Lists records from `metaharness-audit` namespace via audit-list.mjs 2. Picks the most recent record by `startedAt` (or `--baseline-since 7d` skips anything newer than 7 days) 3. Runs a fresh `oia-audit` against the current path 4. Diffs the two via audit-trend, applying `--alert-on-distance-below ${threshold}` 5. Returns the structured drift report
Architectural constraint inheritance (ADR-150)
| Constraint | How drift-from-history satisfies it | |---|---| | Removable | Pure subprocess composition over existing scripts — no new `@metaharness/*` import | | Optional | If oia-audit reports `degraded:true`, this skill exits 3 with a degraded payload | | Graceful | Empty audit history → exit 2 with hint to seed it; never crashes | | CI-gate | Smoke step 17z16 anchors the dispatcher entry + subcommand listing |
Exit codes
- 0 — similarity ≥ threshold (or threshold not crossed)
- 1 — drift detected: similarity < threshold (alert fired)
- 2 — config error (no history, audit-list failed)
- 3 — upstream metaharness absent (degraded payload returned)
Example
$ npx ruflo metaharness drift-from-history --threshold 0.95 # drift-from-history Baseline: audit-2026-06-16T22-58-47-840Z Current: 2026-06-16T23:05:02.231Z Structural similarity: 1 (near-identical) Distance: 0 ✓ similarity ≥ 0.95 — OK
Implementation
[`scripts/drift-from-history.mjs`](../../scripts/drift-from-history.mjs)
📖 RuFlo Explained — Build an AI Team That Plans, Remembers, Tests, and Improves A 14-chapter guide: from the basic idea to a first useful task, then memory, agent teams, plugins, cost and verification. Agent = Model + Harness.
Other skills on ruflo.
More skills from other plugins.
agentmail
Use your assigned AgentMail inbox to read email tasks, explicitly send or reply, and check delivery. Provided automatically by…
bmad
Answers BMad questions and recommends the next skill from what is installed. Use when the user asks bmad for help, what to do…
Questions about harness-drift-from-history.
- Which coding agents can use harness-drift-from-history?
- harness-drift-from-history installs in Claude Code, Codex, Cursor, Gemini CLI, GitHub Copilot, OpenCode and Windsurf with the skills CLI, using each agent's flag shown on this page. Flowy's auto-invocation, which fires a skill when your prompt matches, runs in Claude Code only.

