delphi-uses-graph

delphi-uses-graph is a skill for Claude Code, Codex from MaxiDonkey/DelphiGenAI. It costs 105 tokens per session (985 once invoked), scanned A, original, MIT.

A tool for analyzing dependencies between units in Delphi or Object Pascal code. It builds a graph showing which source units use other units and measures their connections.

In plain words
What is it for?
Use it to map a Delphi project, find dependency cycles, inspect fan-in and fan-out, and create Mermaid, SVG, or DOT architecture diagrams.
Why use it?
It makes hidden architecture problems easier to see, including circular dependencies and units that are heavily connected to the rest of the codebase.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

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/maxidonkey/delphigenai/delphi-uses-graph
Any agent
npx skills add MaxiDonkey/DelphiGenAI --skill delphi-uses-graph
Clone the repo
git clone --depth 1 https://github.com/MaxiDonkey/DelphiGenAI

Made for: Claude Code, Codex.

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 delphi-uses-graph

README.md
[![agentmods](https://agentmods.dev/badge/skills/maxidonkey/delphigenai/delphi-uses-graph.svg)](https://agentmods.dev/skills/maxidonkey/delphigenai/delphi-uses-graph)
Your own site
<a href="https://agentmods.dev/skills/maxidonkey/delphigenai/delphi-uses-graph"><img src="https://agentmods.dev/badge/skills/maxidonkey/delphigenai/delphi-uses-graph.svg" alt="Measured on agentmods" height="20"></a>
Per session 105 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 985 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.1 $0.00105 $0.00985
Opus 5 $0.00053 $0.00492
Sonnet 5 $0.00021 $0.00197
Haiku 4.5 $0.00011 $0.00098

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

Security

Grade A, and why

delphi-uses-graph 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 6d ago.

The scan reads SKILL.md. This mod also ships 1 executable file (scripts/tool.py), listed below but not scanned — reading those needs a real analyzer, not pattern matching.

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.

demos/bin32/FMX_OpenAI/delphi-uses-graph/SKILL.md · 96 lines

How it starts

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

Delphi uses-graph skill

This skill builds a directed graph of uses dependencies between Delphi / Object Pascal units, computes coupling metrics, and detects circular dependencies.

OpenAI Responses container note

This OpenAI-adapted bundle is intended to be registered through the OpenAI Skills API and attached to a Responses shell/container tool as a skill_reference. The analysis logic is vendor-neutral; the OpenAI-specific requirement is that the container can run Python and can read the uploaded Delphi project files.

When to use this skill

  • The user uploads an archive (.zip, .tar, .tar.gz) containing a Delphi project, or a folder of .pas / .dpr / .dpk sources, and asks for an architecture map or a dependency graph.
  • The user asks "which unit depends on what?", "are there cycles?", "what's the fan-in / fan-out?" against a Delphi codebase.
  • The user wants a visual artifact (Mermaid, SVG, DOT) summarizing unit-level coupling.

Do not use this skill for non-Pascal codebases.

Inputs

The skill expects exactly one of:

  1. A .zip / .tar / .tar.gz archive of a Delphi project.
  2. A directory already containing .pas, .dpr, or .dpk files.

If the user pastes raw Pascal source instead, persist it to one or more temporary .pas files first, then point --input at their parent directory.

Workflow

  1. Locate the input archive or directory in the working area.
  2. Run scripts/tool.py with --input pointing at it and --output pointing at a fresh output folder.
  3. Read the generated report.md and summarize parsed units, fan-in/fan-out, cycles, and orphan units.
  4. Attach or surface the generated artifacts: Mermaid, DOT, SVG when present, JSON, and report. Embed uses-graph.mmd inline when the conversation surface supports Mermaid rendering.

Quick start

python scripts/tool.py \
    --input  /path/to/project.zip \
    --output /path/to/out

If the container exposes python3 instead of python, use python3 with the same arguments.

Read the full file on GitHub · 96 lines

Files

What ships with it

2 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

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. 6d ago First seen · 96 lines · 105 tokens per session scan A 6d4ba3940fba

Subscribe to this mod's changes

delphi-uses-graph is a skill published in the GitHub repository MaxiDonkey/DelphiGenAI (86 stars, last pushed 2mo ago), licensed MIT. It adds 105 tokens to every session and 985 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.

Related

Other skills, from other repositories