diagram-context-gatherer

diagram-context-gatherer is an agent for Claude Code from jessepike/diagram-forge. It costs 39 tokens per session (452 once invoked), scanned A, original, MIT.

A project exploration agent that maps a codebase’s architecture so an architecture, data-flow, or system-design diagram can be created.

In plain words
What is it for?
Use it to identify components, layers, entry points, APIs, databases, external services, infrastructure, and the connections between them.
Why use it?
It gathers the project structure and relationships needed for a useful diagram instead of relying on assumptions.

Agent for Claude Code

Written for Claude Code: shipped in a Claude Code plugin. Also seen: model in frontmatter; mentions CLAUDE.md.

Part of the diagram-forge plugin — 1 skill, 4 commands, 1 agent shipped together

Good fit Use it to identify components, layers, entry points, APIs, databases, external services, infrastructure, and the connections between them.

Compare 6 agents from other repositories ↓
Install with agentmods
npx agentmods add agents/jessepike/diagram-forge/context-gatherer
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/jessepike/diagram-forge

Made for: Claude Code.

Or install diagram-forge, the plugin that ships this one along with the rest of its 1 skill, 4 commands, 1 agent.

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 diagram-context-gatherer

README.md
[![agentmods](https://agentmods.dev/badge/agents/jessepike/diagram-forge/context-gatherer.svg)](https://agentmods.dev/agents/jessepike/diagram-forge/context-gatherer)
Your own site
<a href="https://agentmods.dev/agents/jessepike/diagram-forge/context-gatherer"><img src="https://agentmods.dev/badge/agents/jessepike/diagram-forge/context-gatherer.svg" alt="Measured on agentmods" height="20"></a>
Per session 39 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 452 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.00039 $0.00452
Opus 5 $0.00019 $0.00226
Sonnet 5 $0.00008 $0.00090
Haiku 4.5 $0.00004 $0.00045

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

Security

Grade A, and why

diagram-context-gatherer 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.

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.

diagram-forge-plugin/agents/context-gatherer.md · 56 lines

What it actually says

Context Gatherer Agent

You are an architecture analysis agent. Your job is to explore a project codebase and produce a structured summary suitable for generating an architecture diagram.

What to Look For

  1. Project documentation: Read CLAUDE.md, README.md, architecture docs, status.md, any docs/ directory
  2. Package structure: Look at directory layout, module organization, key entry points
  3. Configuration: Check for config files (yaml, json, toml) that reveal services, databases, integrations
  4. API surface: Find API endpoints, routes, handlers, controllers
  5. Data layer: Identify databases, ORMs, data models, migrations
  6. External integrations: Find third-party service calls, MCP servers, webhooks, message queues
  7. Infrastructure: Check for Docker, CI/CD, deployment configs

Output Format

Produce a structured summary with these sections:

SYSTEM NAME: [project name]

COMPONENTS:
- [Component Name]: [brief description]
  - Type: [service|library|database|api|frontend|etc]
  - Key files: [main files]

LAYERS:
- [Layer Name]: [components in this layer]

CONNECTIONS:
- [Source] -> [Destination]: [protocol/description]

EXTERNAL DEPENDENCIES:
- [Service/API]: [how it's used]

SUGGESTED DIAGRAM TYPE: [architecture|data_flow|component|integration]
SUGGESTED COLOR CODING: [what colors should represent]

Guidelines

  • Be thorough but concise — the summary feeds directly into a diagram prompt
  • Focus on high-level architecture, not implementation details
  • Identify the most important components (aim for 5-15 components)
  • Note any existing diagrams or architecture documentation found
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 · 56 lines · 39 tokens per session scan A 6b2b46c2633e

Subscribe to this mod's changes

diagram-context-gatherer is an agent published in the GitHub repository jessepike/diagram-forge (1 stars, last pushed 1mo ago), licensed MIT. It adds 39 tokens to every session and 452 once invoked, about $0.0002 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-31.

Related

Other agents, from other repositories

ux-flow-auditor

Use this agent when the user mentions UX flow issues, dead-end views, dismiss traps, missing empty states, broken user journeys, or wants a UX audit of their iOS app. Automatically scans SwiftUI and UIKit code for user journey defects - detects dead ends, dismiss traps, buried CTAs, missing loading/error/empty states…

CharlesWiltgen/Axiom · 190 tokens

design

Design system generator — maps product domain to style, palette, typography, anti-patterns. Creates .rune/design-system.md. Use BEFORE any frontend code generation.

Rune-kit/rune · 35 tokens

mobile-ux-optimizer

Use this agent when you need to optimize UI/UX components or interfaces for mobile-first experiences, analyze existing design themes, or ensure mobile usability standards are met. Examples: Context: User has created a desktop-focused component and needs it optimized for mobile. user: 'I've built this navigation…

xbim08/awesome-claude-code-plugins · 0 tokens

frontend-reviewer

Reviews interface, branding and copy. Always verifies against a screenshot and the rendered DOM, never by reading CSS or HTML.

everywan-dev/claude-code-engineering · 28 tokens

designer

Use for visual/UX design authoring — reference decomposition, design principles, divergent concept drafts, milestone screen prototypes, and DESIGN.md authoring support. Generation only; auditing stays with reviewer[design].

kohj1018/agentic-dev-harness · 42 tokens

unity-ui-pro

Build Unity UI — UI Toolkit (UXML/USS/UIDocument) and UGUI (Canvas/RectTransform). Handles screen architecture, data binding, runtime UI performance, gamepad/keyboard input, and cross-platform UI scaling. Use PROACTIVELY for new screens, HUD, menus, in-game dialogs, settings, or any UI work in Unity 2022.3+. Not for…

AcKeskin/contexture · 102 tokens