
Drift Detection from History
FreeSimplify drift detection with a single command.
Free · Opens the source repo
What Drift Detection from History does
The Drift Detection from History skill streamlines the process of monitoring changes in your codebase by condensing multiple commands into a single, efficient operation. This skill is particularly useful for developers who regularly run audits to ensure the integrity of their projects. Instead of executing a series of commands to compare the current state of the repository with a historical audit, users can now achieve this in one step, saving time and reducing the potential for human error.
When invoked, the skill automatically retrieves the most recent audit record from the metaharness-audit namespace and performs a fresh audit of the current repository. It then compares the two audits using a similarity threshold defined by the user, alerting them if the structural distance crosses the specified limit. This allows developers to quickly identify any significant changes that may have occurred since the last audit, enabling them to take action as needed.
This skill is designed for developers who are already using the ruflo toolset and need a reliable way to monitor drift in their code. By integrating seamlessly with existing workflows, it enhances productivity and ensures that developers can maintain high standards of code quality without the overhead of managing multiple commands. Additionally, the skill is built to handle various scenarios gracefully, including cases where audit history may be absent, ensuring a smooth user experience.
Overall, the Drift Detection from History skill is an essential tool for developers looking to maintain control over their codebase and ensure consistency over time. Its ease of use and integration with the ruflo ecosystem make it a valuable addition to any developer's toolkit.
When to use it
Use this skill when you need to quickly check for structural changes in your codebase after running an audit.
When not to use it
Avoid using this skill if you are not utilizing the `ruflo` toolset or if you do not have a historical audit record available.
What you can build with it
Weekly Audit Check
Run the skill weekly to ensure no significant changes have occurred in your codebase since the last audit.
Continuous Integration
Integrate this skill into your CI pipeline to automatically check for drift after each deployment.
Historical Comparison
Use the skill to compare the current state of your repository against historical audits to track changes over time.
How to install Drift Detection from History
View source1. Install with the skills CLI
npx skills add ruvnet/ruflo/harness-drift-from-history --agent claude-code2. Or install it manually
Download the skill folder and drop it into ~/.claude/skills/ for all projects, or .claude/skills/ to scope it to one repo. Restart Claude Code so it picks up the new skill.
Anthropic's agentic coding CLI, and the reference implementation of Agent Skills. Drop a skill folder into ~/.claude/skills and Claude Code loads it automatically whenever a task matches the skill's description. Claude Code docs
Inside SKILL.md
Written by ruvnetThe 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
- Lists records from
metaharness-auditnamespace via audit-list.mjs - Picks the most recent record by
startedAt(or--baseline-since 7dskips anything newer than 7 days) - Runs a fresh
oia-auditagainst the current path - Diffs the two via audit-trend, applying
--alert-on-distance-below ${threshold} - 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
Frequently asked questions about Drift Detection from History
Similar skills
Turborepo
Optimized build system for JavaScript/TypeScript monorepos.
Azure Pipelines Validation
Streamline your Azure DevOps pipeline changes locally.
Azure Developer CLI
Streamline your Azure project workflows with best practices.
Azure Container Registry CLI
Manage Azure Container Registry resources with ease.
Aspire
Build and orchestrate polyglot distributed applications seamlessly.
Vercel CLI
Manage and deploy Vercel projects from the command line.
