drift

A comparison of the latest code scan with an earlier baseline and recent history. A baseline is a saved picture of the project's previous state, while the time window can cover 7, 30, or 90 days.

In plain words
What is it for?
Use it after a rescan to find worsening health measures, newly risky files, and newly appearing or growing rule violations. It can also show longer-term trend information when the selected period lacks enough data.
Why use it?
It shows what has worsened over time, making gradual losses in code structure easier to spot than a single current scan.

Skill for Claude CodeCodex

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/rayforcedb/raysense/drift
Any agent
npx skills add RayforceDB/raysense --skill drift
Clone the repo
git clone --depth 1 https://github.com/RayforceDB/raysense

Made for: Claude Code, Codex.

Per session 75 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 891 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00075 $0.00891
Opus 5 $0.00037 $0.00445
Sonnet 5 $0.00015 $0.00178
Haiku 4.5 $0.00007 $0.00089

Measured yesterday against content hash 46d4f88ce1bd, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

drift scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured yesterday.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

claude-plugin/skills/drift/SKILL.md · 81 lines

How it starts

The opening of the file, as written. The whole thing — 81 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Drift

drift answers one question: "what got worse since N days ago?" It is heavier than verify (which only diffs against the saved baseline) but lighter than audit (which sweeps the whole repo). Run it when the question is shaped like "are we slowly losing modularity?" or "did a bad pattern creep in over the last sprint?"

All tools take a path argument; pass the current repo root as an absolute path.

Steps

  1. Rescan. Call raysense_rescan with path: <cwd> so the active health is current.
  2. Drift summary. Call raysense_drift with path: <cwd> and window: 30d (the default). Returns:
    • worsened_dimensions: the dimensions whose scores dropped (or rule count rose) across the window.
    • hotspots_new_or_risen: files that newly entered the top hotspots or whose risk_score climbed.
    • rules_new_or_increased: rule codes that newly tripped or whose violation count grew.
  3. Trend context. When drift reports available: false (fewer than 2 samples in the window), call raysense_trend with window: all so the user sees how short the history is. Suggest they call raysense_baseline_save to seed a sample.
  4. Remediations on regression. For each entry in rules_new_or_increased, call raysense_remediations and surface the suggestion alongside the regression.

What to surface to the user

A good drift report leads with the worst regression, not the full list. Three focused lines beat one wall of metrics:

  • "Modularity dropped 0.92 to 0.78 (worst dimension this window)."
  • "src/big.rs is the new top hotspot (risk_score 50 to 216)."
  • "Rule max_function_complexity newly tripped (0 to 2)."

If drift returns nothing in any of the three categories, say so plainly: "No drift detected in the last 30d." Do not pad with empty sections.

Window choice

  • 7d: catches regressions from the current week's edits.
  • 30d: default. Sees a typical sprint's worth of structural movement.
  • 90d: quarterly review cadence. Often spans refactors that haven't fully settled.
  • all: every recorded sample. Use when you want the full arc.

Read the full file on GitHub · 81 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. yesterday First seen · 81 lines · 75 tokens per session scan A 46d4f88ce1bd

Subscribe to this mod's changes

drift is a skill published in the GitHub repository RayforceDB/raysense (11 stars, last pushed 4mo ago), licensed MIT. It adds 75 tokens to every session and 891 once invoked, about $0.0004 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

coverage-loop

Iteratively improve Fallow Rust test coverage with cargo-llvm-cov, prioritizing meaningful untested behavior and preserving runtime correctness.

fallow-rs/fallow · 29 tokens

ci-formats-review

Review SARIF, CodeClimate, compact, markdown, badge, and other CI-facing output formats for correctness and integrator expectations. Use when changes affect machine-consumed report formats or CI presentation layers.

fallow-rs/fallow · 45 tokens

brooks-sweep

Full-sweep mode: runs a unified analysis across all quality dimensions — code decay, architecture, tech debt, and test quality — then applies fixes directly to the codebase. Safe changes are auto-applied; risky changes are confirmed before execution. Drawing on twelve classic engineering books. Triggers when: user…

hyhmrright/brooks-lint · 178 tokens

llm-friendly-context

Clarifies inputs, outputs, success criteria, decisions, and unresolved conditions so downstream consumers can execute without guessing. Use when writing or revising LLM-facing prompts, handoffs, planning artifacts, reviews, reports, or generated instructions.

shinpr/claude-code-workflows · 52 tokens

ring:exploring-codebases

Exploring a codebase across phases: scopes the target, detects architecture, components, and layers, deep-dives each discovered perspective, then synthesizes findings into actionable guidance with file:line evidence. Use to understand how a feature or system works before planning changes, or to orient on an unfamiliar…

LerianStudio/ring · 91 tokens

deps-audit

Audit dependencies for vulnerabilities, staleness, unused packages, and license risks — produce a health report with actionable fixes.

optave/ops-codegraph-tool · 27 tokens