opik: Skill for Claude Code

.agents/skills/add-code-quality-hook/SKILL.md

add-code-quality-hook is a skill for Claude Code, Codex from comet-ml/opik. It costs 0 tokens per session (2,332 once invoked), scanned A, original, Apache-2.0.

A checklist for connecting a new code linter or formatter to Opik's local and CI checks. It covers the files and settings needed for the hook to run correctly.

In plain words
What is it for?
Use it when adding a pre-commit linter or formatter to Opik. It guides changes to the pre-commit setup, descriptions, change detection, and GitHub Actions workflow.
Why use it?
It prevents a linter from being added incompletely and then silently not running, appearing blank in reports, or using the wrong runtime.

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 β†’

Needs its repository: it runs a file that does not travel with it, so clone the repository first. The line is python3 scripts/precommit-detect-hooks.py .pre-commit-config.yaml path/to/target.file.

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 Β· 22,998 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/add-code-quality-hook/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 add-code-quality-hook

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

Your own site Β· 80Γ—15
<a href="https://agentmods.dev/skills/comet-ml/opik/add-code-quality-hook"><img src="https://agentmods.dev/badge/skills/comet-ml/opik/add-code-quality-hook.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 0 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,332 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
  • Snyk pass 7 Sept 2026
  • 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.00000 $0.02332
Opus 5.5 $0.00000 $0.00933
Sonnet 5.5 $0.00000 $0.00466
Haiku 4.5 $0.00000 $0.00233

Measured 2mo ago against content hash 8f5d21a2c128, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

add-code-quality-hook 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 2mo 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/add-code-quality-hook/SKILL.md Β· 110 lines

How it starts

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

Add a Code Quality Hook

Opik runs all linters through one pipeline: pre-commit locally, and the πŸ™ Code Quality workflow (.github/workflows/code_quality.yml) in CI. CI does not run pre-commit wholesale β€” it derives, per PR, the set of hooks that actually have work using scripts/precommit-detect-hooks.py, then runs one CI job per matched linter. That design makes adding a linter a small, fixed set of edits β€” but each edit is load-bearing, and skipping one produces a silent gap (the hook runs nowhere, or renders blank in the summary, or provisions the wrong runtime) rather than a loud failure. This skill is the checklist.

The whole recipe is a generalization of two real PRs: actionlint (live in .pre-commit-config.yaml today β€” grep it as you read) and hadolint (OPIK-6673, PR #7352 β€” the first Docker-image hook, toolchain: none). Read the actionlint hook alongside this doc; it is the canonical, verifiable example.

The wiring files

Each linter touches these four files. Do all four.

1. .pre-commit-config.yaml β€” add the hook

Add the upstream hook (repo / rev / id). Pin rev to a tag or SHA β€” never a floating ref.

An explicit files: regex is mandatory, not optional. This is the single most common miss. The CI matrix detector (precommit-detect-hooks.py) routes work to hooks by path regex, not by pre-commit's types:. Most upstream hooks (actionlint, hadolint) ship a types:-only match with no files:. If you copy them verbatim, the detector cannot route any file to your hook and CI silently never runs it β€” pre-commit locally still works, so the gap hides until something slips through. The detector guards against this: it raises loudly if a hook has types:/types_or: without files: (see precommit-detect-hooks.py lines ~115). So a missing files: fails the detect step rather than regressing silently β€” but you still must write the regex.

Write a files: regex that captures exactly the paths the linter should gate. Example (actionlint β€” workflows only):

Read the full file on GitHub Β· 110 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. 2mo ago First seen Β· 110 lines Β· 0 tokens per session scan A 8f5d21a2c128

Subscribe to this mod's changes

add-code-quality-hook is a skill published in the GitHub repository comet-ml/opik (22,998 stars, last pushed today), licensed Apache-2.0. It costs nothing until one of its globs matches a file; then it loads 2,332 tokens. 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

code-review

Perform comprehensive code reviews focusing on best practices, security vulnerabilities, performance optimization, and maintainability.

kyegomez/swarms Β· 21 tokens

rag-techniques-contribution-guidelines

Checks a RAGTechniques pull request against the repository's contribution guidelines (CONTRIBUTING.md): where new technique notebooks go, the README list entry and table row every new technique needs, the required notebook structure, and notebook hygiene. Use on any PR that adds or changes a notebook under…

NirDiamant/RAG_Techniques Β· 111 tokens

verification-quality

Truth scoring, code-quality verification, and automatic rollback with a high accuracy threshold. Use when validating agent output before it ships, gating changes on quality, or adding a verify-and-rollback safety loop.

frankxai/claude-skills-library Β· 43 tokens

code-review

This skill should be used when the user asks for a code review of a change β€” a pull request, merge request, branch, commit range, working-tree change, or pasted diff β€” covering correctness, security, performance, structure, and repository-specific rules. Trigger on phrases like "review this PR", "review this MR"…

srtab/daiv Β· 164 tokens

security-audit

This skill should be used when the user asks to review code for security vulnerabilities, audit a pull request or merge request for risks, check if code is safe, find injection flaws or hardcoded secrets, or assess the security posture of a feature or codebase area. Use this skill even when the user doesn't say…

srtab/daiv Β· 153 tokens

code-intelligence

Understand repositories as systems: map code structure and semantic relationships, analyze change impact, review pull requests, and plan safe refactors. Use when a task involves unfamiliar codebases, dependency tracing, architecture mapping, PR review, or cross-file refactoring.

TIKAZI/TIKAZ-AI-Skills Β· 54 tokens