opik: Skill for Claude Code

.agents/skills/diagram-generation/SKILL.md

diagram-generation is a skill for Claude Code, Codex from comet-ml/opik. It costs 26 tokens per session (576 once invoked), scanned A, original, Apache-2.0.

Guidance for generating self-contained HTML diagrams of software architecture, code changes, and data flows. The diagrams include a dark GitHub-style layout and a button for copying them as images.

In plain words
What is it for?
Use it to show request flows, before-and-after behavior, files changed by layer, or important design decisions. It specifies the output location, template, style, and suitable sections.
Why use it?
It makes complex changes and relationships easier to review and share in places such as pull requests, Slack, and Jira.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one. Also seen: installed under .agents/ (shared by several agents).

This is comet-ml/opik's own configuration. It tells Claude Code and Codex how to work on opik 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 opik configures →

About the project

Opik is an open-source platform for tracing, evaluating, and monitoring applications that use large language models, retrieval systems, or AI agents. Teams use it to inspect agent activity, manage prompts, run evaluations, and monitor these applications in production.

comet-ml/opik · 21,864 stars · on GitHub · comet.com

Reuse

Borrowing it

Nothing to install: this file belongs to comet-ml/opik. 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/comet-ml/opik/main/.agents/skills/diagram-generation/SKILL.md
Clone the repo
git clone --depth 1 https://github.com/comet-ml/opik

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

README.md
[![agentmods](https://agentmods.dev/badge/skills/comet-ml/opik/diagram-generation/github.svg)](https://agentmods.dev/skills/comet-ml/opik/diagram-generation)
Your own site
<a href="https://agentmods.dev/skills/comet-ml/opik/diagram-generation"><img src="https://agentmods.dev/badge/skills/comet-ml/opik/diagram-generation/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 diagram-generation

Your own site · 80×15
<a href="https://agentmods.dev/skills/comet-ml/opik/diagram-generation"><img src="https://agentmods.dev/badge/skills/comet-ml/opik/diagram-generation.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 26 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 576 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. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
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.00026 $0.00576
Opus 5 $0.00013 $0.00288
Sonnet 5 $0.00005 $0.00115
Haiku 4.5 $0.00003 $0.00058

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

Security

Grade A, and why

diagram-generation 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 9d 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.

.agents/skills/diagram-generation/SKILL.md · 53 lines

How it starts

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

Diagram Generation

Generate self-contained HTML diagrams that visualize code changes, data flows, and architecture decisions.

When to Use

  • Visualizing PR changes for code review
  • Explaining architectural decisions
  • Documenting data/request flows
  • Illustrating before/after comparisons

Output

  • Self-contained HTML file at {MAIN_REPO_ROOT}/diagrams/opik-{TICKET_NUMBER}-diagram.html — always resolved against the main repo root (via git rev-parse --git-common-dir), even when the session runs inside a worktree, so the file outlives the worktree
  • Includes "Copy as image" button for sharing in Slack, Jira, PR descriptions
  • Dark GitHub theme, semantic color coding, responsive layout

How to Generate

Follow the style guide in style-guide.md and use the HTML template in template.md.

Required Sections (pick what applies)

  1. Request / Data Flow — how data moves through layers
  2. Why This Approach — problem vs solution comparison
  3. Files Changed by Layer — grid of affected files grouped by component
  4. Key Design Decisions — numbered guards, trade-offs, or constraints

Section Selection

  • Bug fix: Focus on before/after flow, root cause, safety guards
  • New feature: Focus on data flow, architecture, files changed
  • Refactor: Focus on before/after architecture, files changed
  • Cross-component: Show all layers with connecting flows

Reference Files

  • style-guide.md — Semantic colors, box themes, section labels, flow patterns, architecture trees
  • template.md — Base HTML structure, copy-as-image script, section recipes

Common Gotchas

  • SRI hash on CDN scripts: The html2canvas <script> tag must include integrity and crossorigin attributes — see template.md for the current hash
  • Absolute paths for Playwright screenshots: Playwright saves relative to its own CWD, not the repo root — always use absolute paths when calling browser_take_screenshot
  • Max 4 sections: More than 4 sections makes diagrams too tall for screenshots and hard to scan visually
  • No raw diff content: Diagrams show high-level summaries (component names, file names, flow descriptions) — never embed verbatim diff hunks or Jira comments
  • toBlob can return null: The Canvas toBlob call in the copy-as-image script needs a null check — see template.md

Read the full file on GitHub · 53 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. 9d ago First seen · 53 lines · 26 tokens per session scan A 3ebc6370fe1f

Subscribe to this mod's changes

diagram-generation is a skill published in the GitHub repository comet-ml/opik (21,864 stars, last pushed today), licensed Apache-2.0. It adds 26 tokens to every session and 576 once invoked, about $0.0001 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

visualize

Render a polished visual inline in the chat as part of your answer — a diagram, a chart, an interactive explainer, or a UI mockup. Load it proactively whenever an explanation would land better as a picture than as prose. Do not wait to be asked.

vellum-ai/vellum-assistant · 57 tokens

vellum-workspace-theme

Customize the app's visual theme — author design-token overrides (accent, background, surfaces, text, message-bubble colors) in the workspace ui/theme.json, validated by the assistant runtime and applied live to connected clients. Covers the token slots, the all-or-none override groups, the contrast floor, and reading…

vellum-ai/vellum-assistant · 72 tokens

vellum-avatar

Customize the assistant's avatar - build a native character, upload an image, or generate one with AI.

vellum-ai/vellum-assistant · 24 tokens

frontend-design-studio

Direct, design, implement, animate, critique, audit, polish, and deploy distinctive production frontend interfaces for websites, landing pages, web apps, dashboards, mobile concepts, and desktop shells. Use for new frontend builds, redesigns, bland or visually generic UI, messy interfaces, design systems, Vue Bits or…

TIKAZI/TIKAZ-AI-Skills · 126 tokens

frontend-design

Orchestrate product-aware frontend art direction, implementation, responsive QA, code impact analysis, and engineering handoff. Use for websites, landing pages, web apps, dashboards, mobile concepts, and desktop shells that need one coherent visual world and objective verification.

TIKAZI/TIKAZ-AI-Skills · 54 tokens

magazine-web-deck

Create editorial or Swiss-inspired single-file web presentations with strong typographic hierarchy, horizontal navigation, responsive composition, and restrained motion. Use for keynote-like web decks, editorial stories, launches, and visually distinctive browser presentations.

TIKAZI/TIKAZ-AI-Skills · 49 tokens