compose-diagram

compose-diagram is a skill for Claude Code from SAP/leanix-ai-plugins. It costs 136 tokens per session (6,088 once invoked), scanned A, original, Apache-2.0.

Use when the user wants to create, edit, or visualize a diagram or canvas. Covers building a diagram/canvas from scratch, changing an existing one (add/remove/connect/ restyle/move elements), and visualizing an entity's relations, dependencies, or hierarchy as a diagram ("visualize this", "show SAP's dependencies"…

Skill for Claude Code ✓ vendor

Written for Claude Code: allowed-tools in frontmatter.

Install with agentmods
npx agentmods add skills/sap/leanix-ai-plugins/compose-diagram
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.

Any agent
npx skills add SAP/leanix-ai-plugins --skill compose-diagram
Clone the repo
git clone --depth 1 https://github.com/SAP/leanix-ai-plugins

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 compose-diagram

README.md
[![agentmods](https://agentmods.dev/badge/skills/sap/leanix-ai-plugins/compose-diagram/github.svg)](https://agentmods.dev/skills/sap/leanix-ai-plugins/compose-diagram)
Your own site
<a href="https://agentmods.dev/skills/sap/leanix-ai-plugins/compose-diagram"><img src="https://agentmods.dev/badge/skills/sap/leanix-ai-plugins/compose-diagram/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 compose-diagram

Your own site · 80×15
<a href="https://agentmods.dev/skills/sap/leanix-ai-plugins/compose-diagram"><img src="https://agentmods.dev/badge/skills/sap/leanix-ai-plugins/compose-diagram.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 136 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 6,088 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 1 finding. 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.00136 $0.06088
Opus 5.5 $0.00054 $0.02435
Sonnet 5.5 $0.00027 $0.01218
Haiku 4.5 $0.00014 $0.00609

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

Security

Grade A, and why

compose-diagram scanned grade A with 1 finding 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 today.

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.

Makes network callslowCapability

Not a fault in itself. Listed so you know the mod talks to something, and to what.

**All LeanIX API calls use MCP tools.** No shell commands, no token exchange, no curl.
skills/compose-diagram/SKILL.md · 213 lines

How it starts

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

Compose Diagram

You build and edit LeanIX diagrams by composing tool calls — never by writing XML yourself.

"Canvas" means "diagram." Users may call it a canvas ("put this on a canvas", "add to my canvas"); it is the same thing — the LeanIX diagram you build with these tools. Treat the two terms as interchangeable throughout this skill.

CRITICAL: API Access

All LeanIX API calls use MCP tools. No shell commands, no token exchange, no curl.

  • Authentication is handled internally by the MCP server
  • No bearer tokens need to be managed in the skill workflow
  • No .mcp.json parsing is required — MCP handles credentials automatically

Before any LeanIX tool call: if only mcp__leanix__authenticate and mcp__leanix__complete_authentication are available, tell the user to run /mcp and authenticate the leanix server (browser opens automatically). Do NOT call authenticate yourself or suggest claude mcp add — the former returns a URL without triggering the browser flow (copy-paste UX), the latter would shadow the plugin's bundled server. If /mcp doesn't surface tools after auth, treat it as a plugin bug.

Golden rules

These govern every request. The rest of this skill elaborates on them.

  1. mcp__leanix__create_diagram_draft + mcp__leanix__commit_diagram_draft are a transaction pair (BEGIN/END). Every draft you open MUST be committed on the same draft_id, with at least one mutation in between. NEVER open a draft just to read a diagram (use mcp__leanix__get_diagram_by_id); NEVER open→commit with no change (a no-op that, for a new diagram, saves an empty one). This flow exists for editing only. If you open a draft, you own committing it — do not abandon it.
  2. Call tools strictly sequentially — NEVER in parallel. Issue one call, wait for its diff, then the next. Each mutation depends on the prior one's draft_id and cell IDs, so a parallel batch is not supported.
  3. NEVER produce, copy, or hand-edit XML. The server owns the XML; you change it only through tools, passing intent and parameters. mcp__leanix__create_diagram_draft may return the draft's XML once as a read-only reference — read it, never write it back.
  4. HTML in a cell's value MUST be raw, NEVER XML-escaped. When a cell uses html=1, pass emphasis markup literally — <b>SAP</b>, <br>, <font color="#6c8ebf">…</font> — NEVER escaped (&lt;b&gt;SAP&lt;/b&gt;). Escaped tags render as visible literal text (<b>SAP</b> shown on the diagram) instead of formatting, which silently breaks the diagram's appearance. This is non-negotiable for every cell that carries styled text.
  5. Diagrams must always look good — clean, readable layout is a hard requirement, not a nice-to-have. Shapes MUST NOT overlap unless overlap is explicitly intended: before placing or moving any cell, check that its x, y, width, and height are compatible with what is already on the diagram, and leave clear spacing between elements. Give text containers (summaries, legends, titles, annotations) enough height that their text never overlaps — when unsure, err on the side of a taller container rather than a cramped one. Route relations so edges do not cross fact sheets or pile up on each other (see Placing dependencies).
  6. Prefer acting over asking. Default to producing a reasonable result: search, use what you find, apply sensible defaults, and let the user refine after seeing it — don't describe a plan and wait for confirmation on routine requests. But when a request is genuinely ambiguous (unclear what to diagram, which entities, or what the goal is) and a best-effort guess would likely be wrong, ask a brief clarifying question first.
  7. Always search then add — resolve a fact sheet by name/attribute, never ask the user for a fact_sheet_id.
  8. Always give the user the diagram's URL after committing. Call mcp__leanix__get_diagram_by_id for it and include it in your reply. The URL is stable (the diagram_id never changes), so fetch it once per diagram and reuse it across later edits.
  9. LeanIX data uses the fact-sheet tools; plain visuals use the cell/edge tools — never substitute one for the other. A LeanIX entity → mcp__leanix__add_diagram_fact_sheet_cell, NEVER mcp__leanix__add_diagram_cell. A real relation between fact sheets → mcp__leanix__add_diagram_dependencies (or mcp__leanix__add_diagram_drill_down for hierarchical), NEVER mcp__leanix__add_diagram_edge — this holds even when both fact sheets are already on the diagram: connect them with mcp__leanix__add_diagram_dependencies, do NOT hand-place cells and wire them with a plain edge. A plain edge between two fact sheets is acceptable ONLY when the line represents some other, non-LeanIX semantic link. See Tool choice for why and the full mapping.

Read the full file on GitHub · 213 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. today First seen · 213 lines · 136 tokens per session scan A f7f0dedcb80f

Subscribe to this mod's changes

compose-diagram is a skill published in the GitHub repository SAP/leanix-ai-plugins (10 stars, last pushed 1mo ago), licensed Apache-2.0. It adds 136 tokens to every session and 6,088 once invoked, about $0.0005 per session on Opus 5.5. A static security scan graded it A with 1 finding (makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-11-07.

Related

compose-diagram compared with skills from other repositories

compose-diagram next to 6 skills from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
compose-diagramSAP/leanix-ai-pluginsSkill101mo agoApache-2.0A136Claude Code
insights-dashboardbuildswithpaul/Frappe_Assistant_CoreSkill3352d agoAGPL-3.0A133Claude Code, Codex
skillabdulhamid-n/ticktick-mcpSkill37mo agoMITA0Claude Code
ticktickabdulhamid-n/ticktick-mcpSkill37mo agoMITA104Claude Code
package-installerOrkas-AI/OrkasSkill9.0kyesterdayMITA35Claude Code, Codex
ha-data-storesshiwenwen/hope-agentSkill1.9kyesterdayMITA115Claude Code, Codex
telegram-setupvellum-ai/vellum-assistantSkill1.5k2d agoMITA22Claude Code, Codex