Claude-Tools-for-Delphi: Agent for Claude Code

.claude/agents/light-md-DriftUpdate.md

light-md-DriftUpdate is an agent for Claude Code from GabrielOnDelphi/Claude-Tools-for-Delphi. It costs 93 tokens per session (1,161 once invoked), scanned A, original, MPL-2.0.

A documentation-maintenance agent for Delphi projects. It compares Markdown files such as README.md and CLAUDE.md with the current code, then fixes outdated claims.

In plain words
What is it for?
Use it to scan the requested project documentation, verify its statements against the code, and apply targeted corrections with a per-file report.
Why use it?
It removes documentation drift, where names, paths, settings, signatures, or architecture descriptions no longer match the software.

Agent for Claude Code

Written for Claude Code: installed under .claude/. Also seen: model in frontmatter; mentions CLAUDE.md.

This is GabrielOnDelphi/Claude-Tools-for-Delphi's own configuration. It tells Claude Code how to work on Claude-Tools-for-Delphi itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything Claude-Tools-for-Delphi configures →

Reuse

Borrowing it

Nothing to install: this file belongs to GabrielOnDelphi/Claude-Tools-for-Delphi. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/GabrielOnDelphi/Claude-Tools-for-Delphi/main/.claude/agents/light-md-DriftUpdate.md
Clone the repo
git clone --depth 1 https://github.com/GabrielOnDelphi/Claude-Tools-for-Delphi

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 light-md-DriftUpdate

README.md
[![agentmods](https://agentmods.dev/badge/agents/gabrielondelphi/claude-tools-for-delphi/light-md-driftupdate/github.svg)](https://agentmods.dev/agents/gabrielondelphi/claude-tools-for-delphi/light-md-driftupdate)
Your own site
<a href="https://agentmods.dev/agents/gabrielondelphi/claude-tools-for-delphi/light-md-driftupdate"><img src="https://agentmods.dev/badge/agents/gabrielondelphi/claude-tools-for-delphi/light-md-driftupdate/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 light-md-DriftUpdate

Your own site · 80×15
<a href="https://agentmods.dev/agents/gabrielondelphi/claude-tools-for-delphi/light-md-driftupdate"><img src="https://agentmods.dev/badge/agents/gabrielondelphi/claude-tools-for-delphi/light-md-driftupdate.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 93 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,161 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.00093 $0.01161
Opus 5 $0.00046 $0.00580
Sonnet 5 $0.00019 $0.00232
Haiku 4.5 $0.00009 $0.00116

Measured 8d ago against content hash a2e7d2af832c, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-08, from the pricing page.

Security

Grade A, and why

light-md-DriftUpdate 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 8d 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.

.claude/agents/light-md-DriftUpdate.md · 88 lines

How it starts

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

You scan a Delphi project's markdown docs for drift between doc claims and current code, then apply the fixes. You run in your own context and return a per-file drift report as your final message — that text IS what the launcher relays to the user. The launcher resolved the scope before starting you (root-only / root+docs / all); scan exactly what it passed and do not ask it to reconsider. If you were started with no scope at all (direct invocation), default to root only (CLAUDE.md, README.md) so you never silently fan out over a huge doc tree.

Steps

  1. Detect Delphi project. If the project root contains *.dpr, *.dpk, or *.dproj, read these two files BEFORE any Edit:

    • ~\.claude\skills\light-md-DelphiIdiom\references\vocabulary.md
    • ~\.claude\skills\light-md-DelphiIdiom\references\writing-good-md.md

    Reason: drift fixes that introduce new prose must use Delphi vocabulary (nil not null, unit not module, etc.) from the first write — otherwise /light-md-DelphiIdiom has to rewrite them afterward. Load once, apply throughout. If a file is missing, note it and proceed (do not block).

  2. Glob the MD files in the scope the launcher passed. Exclude: node_modules/, .git/, build/, Win32/, Win64/, __history/, *.dproj/, External/, vendored deps.

  3. For each MD, Read fully.

  4. Extract verifiable claims. Types:

    • Class/type/interface names (TFoo, IBar)
    • Unit / file names (ClaudeUsage.Tray.pas)
    • File paths (relative + absolute)
    • Procedure / method signatures with arg lists
    • Settings / config / INI / JSON field names
    • Enum values, constants
    • "Main form inherits X", "Uses Y framework"-style architecture bullets
  5. Verify each claim:

    • Grep codebase for identifier
    • Check file exists at stated path
    • Confirm signature matches current code
  6. Report drift per file. Group by: broken (claim false now), stale (partially wrong), new (code exists but undocumented section would add value).

  7. Propose specific Edit calls with old_string / new_string. No hand-wavy "update this section".

  8. Print the report, then apply all three categories directly via Edit — NO confirmation prompts. Exception: if a proposed change is destructive / irreversible (deletes a large section, rewrites more than a few lines, touches a file outside the MD scope), do NOT apply it — you cannot ask the user mid-run. List it in the report under a NEEDS CONFIRMATION heading and leave it unapplied for the user to decide. On Delphi projects, every Edit must honor the vocabulary/clarity rules from step 1.

Read the full file on GitHub · 88 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. 8d ago First seen · 88 lines · 93 tokens per session scan A a2e7d2af832c

Subscribe to this mod's changes

light-md-DriftUpdate is an agent published in the GitHub repository GabrielOnDelphi/Claude-Tools-for-Delphi (17 stars, last pushed yesterday), licensed MPL-2.0. It adds 93 tokens to every session and 1,161 once invoked, about $0.0005 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.