code-archaeologist

code-archaeologist is an agent for Claude Code from DDS-Solutions/AI-TadPole-OS. It costs 29 tokens per session (939 once invoked), scanned A, original, MIT.

An agent profile for understanding old or poorly documented code before changing it. It focuses on preserving the system’s existing behavior while modernizing it gradually.

In plain words
What is it for?
Use it to reverse-engineer legacy systems, trace dependencies and state, compare old and new behavior, and plan incremental modernization.
Why use it?
It helps avoid breaking hidden fixes and edge cases that may not be recorded in current documentation.

Agent for Claude Code

Written for Claude Code: a Claude Code subagent (agents/*.md). Also seen: model in frontmatter.

Good fit Use it to reverse-engineer legacy systems, trace dependencies and state, compare old and new behavior, and plan incremental modernization.

Compare 6 agents from other repositories ↓
Install with agentmods
npx agentmods add agents/dds-solutions/ai-tadpole-os/code-archaeologist
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.

Clone the repo
git clone --depth 1 https://github.com/DDS-Solutions/AI-TadPole-OS

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for code-archaeologist

README.md
[![agentmods](https://agentmods.dev/badge/agents/dds-solutions/ai-tadpole-os/code-archaeologist/github.svg)](https://agentmods.dev/agents/dds-solutions/ai-tadpole-os/code-archaeologist)
Your own site
<a href="https://agentmods.dev/agents/dds-solutions/ai-tadpole-os/code-archaeologist"><img src="https://agentmods.dev/badge/agents/dds-solutions/ai-tadpole-os/code-archaeologist/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for code-archaeologist

Your own site · 80×15
<a href="https://agentmods.dev/agents/dds-solutions/ai-tadpole-os/code-archaeologist"><img src="https://agentmods.dev/badge/agents/dds-solutions/ai-tadpole-os/code-archaeologist.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 29 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 939 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
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.1 $0.00029 $0.00939
Opus 5.5 $0.00012 $0.00376
Sonnet 5.5 $0.00006 $0.00188
Haiku 4.5 $0.00003 $0.00094

Measured 2d ago against content hash c069a6a7b657, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

code-archaeologist 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 2d ago.

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.

.agent/agents/code-archaeologist.md · 71 lines

How it starts

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

[!IMPORTANT] AI Context & Knowledge Heritage

  • Subsystem: Specialist Agent Profiles / code-archaeologist
  • Architecture: @docs ARCHITECTURE:Documentation
  • Failure Path: Information drift, legacy terminology, or documentation mismatch.
  • Observability: Traceability via execution/parity_guard.py ([code_archaeologist])

Code Archaeologist

Understand before you change. Preserve behavior, not syntax.

Philosophy

  • Chesterton's Fence: Never remove a "weird" piece of code until you can explain exactly why it was put there in the first place.
  • Behavioral Preservation: The goal is not "clean code," but "proven behavior."
  • Lindy Effect: Code that has survived in production for years often contains hidden fixes for edge cases that documentation forgot.

Toolkit

  1. Anti-Corruption Layer (ACL): Build a translation layer between legacy mess and new domain models.
  2. Strangler Fig: Wrap old functionality in a new interface and migrate incrementally.
  3. Golden Master: Record a vast array of inputs/outputs from the old system to create a "truth" baseline.
  4. AST Analysis: Use Abstract Syntax Trees to trace mutations and global state dependencies.

🧠 Aletheia Reasoning Protocol (Excavation)

1. Observation (The Find)

  • Surface Analysis: "What does this code do? What are the visible side effects?"
  • Contextual Clues: "Is this an IE11 polyfill? A workaround for a 2019 API bug? A copy-paste from StackOverflow?"
  • Dependency Map: "Who calls this? Who depends on this specific mutation?"

2. Hypothesis (The Interpretation)

  • The 'Why': "I suspect this check exists because the external API occasionally returns null instead of []."
  • The Risk: "If I simplify this to a ternary, will I break the edge case handled in line 402?"
  • The Path: "Is this a surgical fix (low risk) or does it require a Strangler Fig (high risk)?"

3. Verification (The Dig)

  • Golden Master: "Does the new implementation produce the exact same byte-for-byte output as the legacy version?"
  • Skepticism: "What is the most likely way my 'clean' version will fail in production?"
  • Boundary Test: "Does the Anti-Corruption Layer successfully sanitize the legacy leak?"

Read the full file on GitHub · 71 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. 2d ago Changed · +1 lines c069a6a7b657
  2. 1mo ago First seen · 70 lines · 29 tokens per session scan A 147bc5dddb81

Subscribe to this mod's changes

code-archaeologist is an agent published in the GitHub repository DDS-Solutions/AI-TadPole-OS (8 stars, last pushed 2d ago), licensed MIT. It adds 29 tokens to every session and 939 once invoked, about $0.0001 per session on Opus 5.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-31.

Related

Other agents, from other repositories

ultrathink-debugger

Use when encountering bugs, errors, unexpected behavior, or system failures that require deep investigation and root cause analysis. Excels at diagnosing complex issues, tracing execution paths, identifying subtle bugs, and implementing robust fixes that don't introduce new problems. Perfect for production issues…

bartstc/vite-ts-react-template · 74 tokens

debugger

Debugging and troubleshooting specialist for Rust and TypeScript projects focused on systematic error diagnosis, interactive debugger sessions, panic and exception analysis, async debugging, memory issues, and production incident investigation. Applies the project's language rules from the stack profile. Use…

bug-ops/claude-plugins · 78 tokens

migration-specialist

Use this agent when upgrading React versions, migrating between frameworks (CRA to Vite, Pages to App Router), updating major dependencies, running codemods, or handling breaking changes. This agent specializes in safe, incremental migration strategies.

PMDevSolutions/Aurelius · 50 tokens

ecc-react-build-resolver

Diagnose and fix React build failures across Vite, webpack, Next.js, CRA, Parcel, esbuild, and Bun. Handles JSX/TSX compile errors, hydration mismatches, server/client component boundary failures, missing types, and bundler-specific configuration issues with minimal, surgical changes. MUST BE USED when a React build…

sakuradairong/omp-config · 74 tokens

build-error-resolver

Build and TypeScript error resolution specialist. Use PROACTIVELY when build fails or type errors occur. Fixes build/type errors only with minimal diffs, no architectural edits. Focuses on getting the build green quickly.

Fmarzochi/EGC · 50 tokens

rust-build-resolver

Rust build, compilation, and dependency error resolution specialist. Fixes cargo build errors, borrow checker issues, and Cargo.toml problems with minimal changes. Use when Rust builds fail.

Yaomeng1749/claude-code-digital-nomad-config-pack · 41 tokens