Agent skill · Design & Presentation

legal-diagram

Use when a user needs a legal or legal-adjacent Mermaid diagram from a document, pasted text, matter description, process, timeline, party map, obligation map, corporate structure, funds flow, or compliance workflow. Trigger on: "diagram this contract", "visualise this deal/matter", "map the parties", "create a timeline of events", "make an org chart", "obligation checklist", "export as HTML diagram". Not for general-purpose non-legal diagrams, pure graphic design, image generation, or legal advice.

lawve-aigithub.com/lawve-aiGitHub ↗
claude-codeships scriptsNOASSERTION
Install
npx skills add lawve-ai/awesome-legal-skills --skill legal-diagram-sam-zhai --agent claude-code

Same command for any agent — swap --agent for codex, cursor, copilot.

Facts
Files in the skill folder: 167
SKILL.md size: 10 KB
Bundled scripts: yes
Version: 1.2.0
Path: skills/legal-diagram-sam-zhai/SKILL.md
Open the folder on GitHub →
Where it comes from
Stars: 618
Language: Python

Weekly change comes from our own snapshots, not the repository page — it measures attention, not adoption.

From the SKILL.md

# /legal-diagram Standalone skill: turn legal material into a context-appropriate Mermaid diagram, with an optional downloadable HTML figure. A structure-preserving Python engine extracts a typed ground truth; directive-driven LLM enrichment fills the gaps; a selector picks the diagram type; the diagram is generated natively. ## Routing gate Every real diagram request runs in this fixed order: first-run check, ingest, build-mode gate, generate, report gate. Non-diagram intents short-circuit at Step 0. Three human gates = mandatory hard stops: GATE 0 (tutorial offer), GATE A (build mode), GATE B (HTML report). Gate discipline, no exceptions: - Present each as structured choice (the question tool). No such tool → numbered plain-text list. Either way, STOP, wait for reply. - Never skip a gate. Never infer its answer from wording. Never generate past an unanswered gate. Detailed, specific, or named-diagram request = still a request, not a gate answer. - Only a literal typed flag may pre-answer: `--direct`/`--guided` (GATE A), `--html` (GATE B), `--tutorial` (tutorial). Nothing else counts. ### Step 0 — Intent and first-run Check explicit short-circuits first: 1. **Tutorial** signals: "

What's inside
Steps it walks through
  1. Routing gate
  2. Step 0 — Intent and first-run
  3. Step 1 — Ingest before choosing a lane
  4. Step 2 — GATE A: build mode (after ingestion) ⛔ BLOCKING
  5. Scripts
  6. Workflow loading map
  7. Reference loading map
  8. Output
  9. Boundaries
Ships with 24 files
  • LICENSE.txt
  • PORTABILITY.md
  • README.md
  • assets/html_template.html
  • constraints.txt
  • references/extraction-schema.md
  • requirements.txt
  • scripts/check_setup.py
  • scripts/diagram_selector.py
  • scripts/eval_pass2.py
  • scripts/extract_entities.py
  • scripts/extraction/__init__.py
  • scripts/extraction/context.py
  • scripts/extraction/domain.py
  • scripts/extraction/domain/__init__.py
  • scripts/extraction/domain/compliance.py
  • scripts/extraction/domain/core.py
  • scripts/extraction/domain/corporate.py
  • scripts/extraction/domain/litigation.py
  • scripts/extraction/domain/result.py
  • scripts/extraction/engine.py
  • scripts/extraction/evaluation.py
  • scripts/extraction/handoff.py
  • scripts/extraction/harvesters/__init__.py
first 24 of 167
More from awesome-legal-skills
All skills →
About this skill
What does the legal-diagram skill do?

Use when a user needs a legal or legal-adjacent Mermaid diagram from a document, pasted text, matter description, process, timeline, party map, obligation map, corporate structure, funds flow, or compliance workflow. Trigger on: "diagram this contract", "visualise this deal/matter", "map the parties", "create a timeline of events", "make an org chart", "obligation checklist", "export as HTML diagram". Not for general-purpose non-legal diagrams, pure graphic design, image generation, or legal advice.

How do I install it?

Run `npx skills add lawve-ai/awesome-legal-skills --skill legal-diagram-sam-zhai --agent claude-code` — it drops the skill into your project so the agent can pick it up. Swap the --agent value for codex, cursor or copilot if you use one of those.

Where does this skill come from?

From lawve-ai/awesome-legal-skills, a repository with 618 stars. We read it straight from the repository tree rather than a submitted listing, so what you see here is what is actually published.

Is a popular skill a good skill?

Not necessarily. Stars measure attention, not adoption — a repository can trend for a week and be abandoned. That is why we show the weekly change from our own snapshots next to the total, instead of a single flattering number.

Keep going