evolution-drift-detector

Helps detect when AI agent skills silently mutate across inheritance chains. A skill audited safe in generation 1 may drift far from the original by generation 5 — but nobody re-audits because the name hasn't changed.

3,891 stars

Best use case

evolution-drift-detector is best used when you need a repeatable AI agent workflow instead of a one-off prompt.

Helps detect when AI agent skills silently mutate across inheritance chains. A skill audited safe in generation 1 may drift far from the original by generation 5 — but nobody re-audits because the name hasn't changed.

Teams using evolution-drift-detector should expect a more consistent output, faster repeated execution, less prompt rewriting.

When to use this skill

  • You want a reusable workflow that can be run more than once with consistent structure.

When not to use this skill

  • You only need a quick one-off answer and do not need a reusable workflow.
  • You cannot install or maintain the underlying files, dependencies, or repository context.

Installation

Claude Code / Cursor / Codex

$curl -o ~/.claude/skills/evolution-drift-detector/SKILL.md --create-dirs "https://raw.githubusercontent.com/openclaw/skills/main/skills/andyxinweiminicloud/evolution-drift-detector/SKILL.md"

Manual Installation

  1. Download SKILL.md from GitHub
  2. Place it in .claude/skills/evolution-drift-detector/SKILL.md inside your project
  3. Restart your AI agent — it will auto-discover the skill

How evolution-drift-detector Compares

Feature / Agentevolution-drift-detectorStandard Approach
Platform SupportNot specifiedLimited / Varies
Context Awareness High Baseline
Installation ComplexityUnknownN/A

Frequently Asked Questions

What does this skill do?

Helps detect when AI agent skills silently mutate across inheritance chains. A skill audited safe in generation 1 may drift far from the original by generation 5 — but nobody re-audits because the name hasn't changed.

Where can I find the source code?

You can find the source code on GitHub using the link provided at the top of the page.

Related Guides

SKILL.md Source

# A Skill Passes Audit in Gen 1. By Gen 5, It Has Network Access. Nobody Noticed.

> Helps detect silent mutations in AI skills as they propagate through inheritance chains, catching drift that static analysis of the original version would miss.

## Problem

Skill A is published and audited: clean. Agent B inherits skill A, makes a small tweak — adds a convenience function. Agent C inherits from B, adds error handling that happens to include an HTTP retry mechanism. Agent D inherits from C, and now has a skill with network access that the original audit never saw.

Each individual change is small and reasonable. But the cumulative drift transforms a file-reading utility into something that can send data over the network. The original "verified safe" badge still applies in the marketplace — because technically it's the same skill lineage.

This is evolutionary drift: small, individually benign mutations that accumulate into a fundamentally different organism. In biology, this is how species diverge. In agent ecosystems, this is how safe skills become unsafe ones without anyone raising a flag.

## What This Checks

This detector traces skill lineage and computes semantic drift:

1. **Lineage reconstruction** — Given a skill, trace its inheritance chain back to the original published version. Map each fork point and modification
2. **Per-generation diff** — For each generation, compute a structured diff: new capabilities added, permissions changed, external dependencies introduced
3. **Capability drift score** — Aggregate diffs across generations into a single drift metric. A skill that gained network access over 3 generations scores higher than one where only comments changed
4. **Mutation classification** — Categorize each change: cosmetic (formatting, comments), functional (new logic), capability-expanding (new permissions, new external calls), safety-reducing (removed checks, weakened validation)
5. **Drift alert thresholds** — Flag lineages where cumulative drift exceeds the scope of the original audit. "This skill has drifted 73% from the audited version"

## How to Use

**Input**: Provide one of:
- A skill slug or identifier to trace its full lineage
- Two versions of a skill to compute drift between them
- A marketplace inheritance chain URL

**Output**: A drift analysis report containing:
- Lineage tree with generation markers
- Per-generation diff summary
- Capability drift score (0-100)
- Mutation classification breakdown
- Re-audit recommendation: YES / WATCH / NO

## Example

**Input**: Check drift for `data-sanitizer` skill (currently at generation 5)

```
🧬 EVOLUTION DRIFT REPORT — RE-AUDIT RECOMMENDED

Lineage: data-sanitizer
  Gen 1: original by @securitylab (AUDITED ✅ 2025-03-15)
  Gen 2: fork by @toolsmith — added CSV support
  Gen 3: fork by @agent-builder — added retry logic with HTTP fallback
  Gen 4: fork by @pipeline-dev — added remote schema fetching
  Gen 5: fork by @data-team — current version in marketplace

Per-generation capability changes:
  Gen 1→2: +csv_parsing (functional, low risk)
  Gen 2→3: +http_requests (capability-expanding, MEDIUM risk)
           Added retry mechanism that makes outbound HTTP calls
  Gen 3→4: +remote_fetch (capability-expanding, HIGH risk)
           Fetches validation schemas from external URLs
  Gen 4→5: -input_length_check (safety-reducing, MEDIUM risk)
           Removed input size validation for "performance"

Capability drift score: 78/100 (SIGNIFICANT)

Mutation breakdown:
  Cosmetic: 12 changes
  Functional: 8 changes
  Capability-expanding: 2 changes ⚠️
  Safety-reducing: 1 change ⚠️

Original audit scope: file-read, string-transform
Current actual scope: file-read, string-transform, http-requests,
                      remote-fetch, unbounded-input

Verdict: RE-AUDIT RECOMMENDED
  The current version has capabilities (network access, remote fetching)
  that did not exist when the original audit was performed.
  The "verified" badge from Gen 1 does not cover Gen 5's behavior.
```

## Related Tools

- **blast-radius-estimator** — once drift is detected, use blast-radius to estimate how many agents are running the drifted version
- **trust-decay-monitor** — tracks time-based decay of audit validity; evolution-drift-detector tracks content-based decay across inheritance
- **hollow-validation-checker** — checks if validation tests are substantive; drifted skills may pass original tests that no longer cover current capabilities
- **supply-chain-poison-detector** — detects deliberately poisoned skills; drift detection catches unintentional accumulation of risk

## Limitations

Lineage reconstruction depends on marketplace metadata quality — if fork relationships are not tracked, the full chain may not be recoverable. Capability drift scoring uses heuristic classification of changes, and some mutations may be miscategorized (e.g., a "functional" change that implicitly expands capabilities). The detector analyzes what changed, not whether changes are malicious — a high drift score means re-audit is warranted, not that the skill is compromised. Skills with obfuscated or dynamically generated code may resist diff analysis. This tool helps identify where audits have gone stale — it does not replace human security review.

Related Skills

bs-detector

3891
from openclaw/skills

Detects key claims in long messages and summarizes the real point. Uses NLP to find what someone is actually saying vs. what they want you to believe.

solana-scam-detector

3891
from openclaw/skills

Detect scam tokens on Solana before you trade. Checks ticker patterns, token age, and known scam mints. Read-only — no wallet signing required.

aws-idle-resource-detector

3891
from openclaw/skills

Detect AWS idle and zombie resources consuming cost with zero meaningful utilization

aws-cloudtrail-threat-detector

3891
from openclaw/skills

Analyze AWS CloudTrail logs for suspicious patterns, unauthorized changes, and MITRE ATT&CK indicators

azure-activity-log-detector

3891
from openclaw/skills

Analyze Azure Activity Logs and Sentinel incidents for suspicious patterns and attack indicators

supply-chain-poison-detector

3891
from openclaw/skills

Helps detect supply chain poisoning in AI agent marketplace skills. Scans Gene/Capsule validation fields for shell injection, outbound requests, and encoded payloads that may indicate backdoors.

social-trust-manipulation-detector

3891
from openclaw/skills

Helps identify coordinated social trust manipulation in agent marketplaces — catching reputation gaming through sockpuppet networks, coordinated upvoting, and manufactured community signals that make unsafe skills appear trusted.

install-then-update-trap-detector

3891
from openclaw/skills

Helps detect the install-then-update attack pattern — where a skill passes initial security review cleanly, then silently introduces malicious behavior through an automatic update that bypasses re-audit. v1.1 adds cryptographic chain-of-custody verification for update sequences.

economic-incentive-misalignment-detector

3891
from openclaw/skills

Helps identify when marketplace economic incentives systematically favor quantity over quality — creating structural pressure toward publishing unsafe skills that individual technical audits cannot detect because the problem is incentive design, not code content.

clone-farm-detector

3891
from openclaw/skills

Helps detect clone farming and reputation gaming in AI agent marketplaces. Identifies near-duplicate skills that wash IDs, batch-publish patterns, and artificial reputation inflation through coordinated uploads.

ai-self-evolution

3891
from openclaw/skills

记录经验、错误与修正,持续改进。触发场景:命令失败 | 操作出错 | 用户纠正(不对、实际上、你错了) | 功能请求(能不能、我希望、有没有办法) | API或工具失败 | 知识过时 | 发现更优做法 | 重复模式 | 非显而易见的问题。执行重大任务前先回顾历史经验。会话开始时回顾,会话结束时总结。

image-duplication-detector

3891
from openclaw/skills

Detect image duplication and tampering in manuscript figures using computer vision algorithms