Cross-Language Coding Standards
zereight/gitlab-mcp
Shared reference for naming, function size, complexity and error handling rules that reviewer agents apply across TypeScript, Python, Go, Rust, Java, C# and Swift.
Shows how to add product analytics events to Opik's frontend, Java backend and Python SDK, all reporting through Segment to PostHog with an opik_ name prefix.
$ npx skills add comet-ml/opik --skill analytics-instrumentation -a claude-codeProject install by default; add -g for ~/.claude/skills/.
$ gh skill install comet-ml/opik analytics-instrumentation --agent claude-codeProject scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).
$ git clone --depth 1 https://github.com/comet-ml/opik.git skills-src && mkdir -p .claude/skills && cp -r skills-src/.agents/skills/analytics-instrumentation .claude/skills/analytics-instrumentation && rm -rf skills-srcUse ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.
Claude Code skills documentation · loads skills from .claude/skills/
Install the "analytics-instrumentation" agent skill from https://github.com/comet-ml/opik/tree/main/.agents/skills/analytics-instrumentation into .claude/skills/analytics-instrumentation/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "analytics-instrumentation", then confirm the skill loads.Claude Code copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$skill-installer install https://github.com/comet-ml/opik/tree/main/.agents/skills/analytics-instrumentationType this inside Codex. $skill-installer <name> installs a curated skill from openai/skills. The installer writes to $CODEX_HOME/skills (default ~/.codex/skills). Restart Codex if the skill does not show up.
$ npx skills add comet-ml/opik --skill analytics-instrumentation -a codexProject install goes to .agents/skills/; add -g for ~/.codex/skills/.
$ gh skill install comet-ml/opik analytics-instrumentation --agent codexProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/comet-ml/opik.git skills-src && mkdir -p .agents/skills && cp -r skills-src/.agents/skills/analytics-instrumentation .agents/skills/analytics-instrumentation && rm -rf skills-srcUse ~/.agents/skills/ instead of .agents/skills for a personal install.
Codex skills documentation · loads skills from .agents/skills/
Install the "analytics-instrumentation" agent skill from https://github.com/comet-ml/opik/tree/main/.agents/skills/analytics-instrumentation into .agents/skills/analytics-instrumentation/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "analytics-instrumentation", then confirm the skill loads.Codex copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add comet-ml/opik --skill analytics-instrumentation -a cursorProject install goes to .agents/skills/; add -g for ~/.cursor/skills/.
$ gh skill install comet-ml/opik analytics-instrumentation --agent cursorProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/comet-ml/opik.git skills-src && mkdir -p .cursor/skills && cp -r skills-src/.agents/skills/analytics-instrumentation .cursor/skills/analytics-instrumentation && rm -rf skills-srcUse ~/.cursor/skills/ instead of .cursor/skills for a personal install.
Cursor skills documentation · loads skills from .cursor/skills/, .agents/skills/, .claude/skills/, .codex/skills/
Install the "analytics-instrumentation" agent skill from https://github.com/comet-ml/opik/tree/main/.agents/skills/analytics-instrumentation into .cursor/skills/analytics-instrumentation/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "analytics-instrumentation", then confirm the skill loads.Cursor copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gemini skills install https://github.com/comet-ml/opik.git --path .agents/skills/analytics-instrumentation--scope user (default) or --scope workspace; --path is the subfolder of the repo that holds the skill; --consent skips the security confirmation prompt.
$ npx skills add comet-ml/opik --skill analytics-instrumentation -a gemini-cliProject install goes to .agents/skills/; add -g for ~/.gemini/skills/.
$ gh skill install comet-ml/opik analytics-instrumentation --agent gemini-cliProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/comet-ml/opik.git skills-src && mkdir -p .gemini/skills && cp -r skills-src/.agents/skills/analytics-instrumentation .gemini/skills/analytics-instrumentation && rm -rf skills-srcUse ~/.gemini/skills/ instead of .gemini/skills for a personal install, then run /skills reload.
Gemini CLI skills documentation · loads skills from .gemini/skills/, .agents/skills/
Install the "analytics-instrumentation" agent skill from https://github.com/comet-ml/opik/tree/main/.agents/skills/analytics-instrumentation into .gemini/skills/analytics-instrumentation/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "analytics-instrumentation", then confirm the skill loads.Gemini CLI copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gh skill install comet-ml/opik analytics-instrumentationInstalls for Copilot at project scope by default; add --scope user for a personal install. Preview a skill first with gh skill preview. Needs GitHub CLI 2.90.0 or later (public preview).
$ npx skills add comet-ml/opik --skill analytics-instrumentation -a github-copilotProject install goes to .agents/skills/; add -g for ~/.copilot/skills/.
$ git clone --depth 1 https://github.com/comet-ml/opik.git skills-src && mkdir -p .github/skills && cp -r skills-src/.agents/skills/analytics-instrumentation .github/skills/analytics-instrumentation && rm -rf skills-srcUse ~/.copilot/skills/ instead of .github/skills for a personal install. Commit .github/skills so cloud agent and code review can use it.
GitHub Copilot skills documentation · loads skills from .github/skills/, .claude/skills/, .agents/skills/
Install the "analytics-instrumentation" agent skill from https://github.com/comet-ml/opik/tree/main/.agents/skills/analytics-instrumentation into .github/skills/analytics-instrumentation/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "analytics-instrumentation", then confirm the skill loads.GitHub Copilot copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add comet-ml/opik --skill analytics-instrumentation -a opencodeOpenCode documents no install command of its own. Project install goes to .agents/skills/; add -g for ~/.config/opencode/skills/.
$ gh skill install comet-ml/opik analytics-instrumentation --agent opencodeProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/comet-ml/opik.git skills-src && mkdir -p .opencode/skills && cp -r skills-src/.agents/skills/analytics-instrumentation .opencode/skills/analytics-instrumentation && rm -rf skills-srcUse ~/.config/opencode/skills/ instead of .opencode/skills for a personal install.
OpenCode skills documentation · loads skills from .opencode/skills/, .claude/skills/, .agents/skills/
Install the "analytics-instrumentation" agent skill from https://github.com/comet-ml/opik/tree/main/.agents/skills/analytics-instrumentation into .opencode/skills/analytics-instrumentation/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "analytics-instrumentation", then confirm the skill loads.OpenCode copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
analytics-instrumentationShows how to add product analytics events to Opik's frontend, Java backend and Python SDK, all reporting through Segment to PostHog with an opik_ name prefix.
Every event name must start with opik_, because Segment routes opik_ events on to PostHog; tooling enforces the prefix and names in code should already carry it. On the frontend, you add the name to the OpikEvent constant in tracking.ts and call trackEvent from the component or hook where the action happens. trackEvent does nothing when Segment is not loaded (open-source mode), adds the analytics environment to event properties, and PostHog still handles pageviews, identification and feature flags directly.
On the backend, an AnalyticsService in the Java infrastructure package exposes two trackEvent overloads: one resolves identity from the current request scope, the other takes an explicit identity, needed outside a request such as in reactive schedulers, background threads and event listeners. Tracking is a no-op unless OPIK_ANALYTICS_ENABLED is true, and it is false by default. Configuration lives in AnalyticsConfig and an analytics section of config.yml, and the Python SDK reports through the same Segment pipeline.
2 steps, taken from the first numbered list in SKILL.md.
Read from SKILL.md and the folder at commit 8e3f6e5. It shows what the files ask for, not the result of running them.
Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.
From allowed-tools in the SKILL.md frontmatter.
Shell commands in SKILL.md call:
pytestpythonFrom the folder's file list and the shell code blocks in SKILL.md.
Links to these hosts (documentation or services it may open):
us.posthog.comFrom URLs in SKILL.md, links to its own repository left out.
Names these keys or tokens, usually read from environment variables:
OPIK_POSTHOG_KEYFrom names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.
Opik Analytics Instrumentation loads about 4.4k tokens when it runs. Until then it costs about 49 tokens; SKILL.md has 1,922 words of instructions outside code blocks.
Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.
The automated check found no risky patterns in SKILL.md.
Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.
The full file from comet-ml/opik at commit 8e3f6e5, republished under its Apache-2.0 licence (© comet-ml). 1,922 words, ~4,381 tokens.
.claude/skills/analytics-instrumentation/SKILL.md (or your agent's skills folder).All events MUST be prefixed with opik_. Segment routes opik_* events to PostHog. The tooling enforces this automatically, but event names defined in code should already include the prefix.
Examples: opik_onboarding_agent_name_submitted, opik_eval_suite_created, opik_optimization_created
apps/opik-frontend/src/lib/analytics/tracking.ts (mode-agnostic; safe to import from any project code)apps/opik-frontend/src/plugins/comet/analytics/index.ts (comet-only)apps/opik-frontend/src/plugins/comet/init.tsx (comet-only)OpikEvent const in tracking.ts:export const OpikEvent = {
ONBOARDING_AGENT_NAME_SUBMITTED: "opik_onboarding_agent_name_submitted",
} as const;trackEvent from the component or hook where the action happens:import { trackEvent, OpikEvent } from "@/lib/analytics/tracking";
trackEvent(OpikEvent.ONBOARDING_AGENT_NAME_SUBMITTED, {
agent_name: agentName,
});trackEvent() safely no-ops when Segment isn't loaded (OSS mode)opik_ prefix is enforced at runtime as a safety netOPIK_ANALYTICS_ENVIRONMENT is injected into event properties automatically by trackEvent()apps/opik-backend/src/main/java/com/comet/opik/infrastructure/bi/AnalyticsService.javaapps/opik-backend/src/main/java/com/comet/opik/infrastructure/AnalyticsConfig.javaapps/opik-backend/config.yml (under analytics:)AnalyticsService exposes two overloads:
void trackEvent(String eventType, Map<String, String> properties);
void trackEvent(String eventType, Map<String, String> properties, String identity);RequestContext.trackEvent() no-ops when OPIK_ANALYTICS_ENABLED is false (default).opik_ prefix is auto-prepended if missing — but keep the prefix in code for grep-ability.environment property is auto-injected from OPIK_ANALYTICS_ENVIRONMENT.AnalyticsService.sendEvent wraps the body in catch (RuntimeException) — callers must not add their own try/catch.Inject and call inline. The 2-arg overload resolves identity from RequestContext.
private final @NonNull AnalyticsService analyticsService;
analyticsService.trackEvent("opik_onboarding_first_trace",
Map.of("trace_id", traceId, "project_id", projectId));doOnSuccess, doOnNext, etc.)Two things are required: offload with Schedulers.boundedElastic() and pass identity explicitly.
Why offload: when identity is absent AnalyticsService.resolveIdentity() falls back to UsageReportService.getAnonymousId(), which is a synchronous JDBC read. Inside a doOnSuccess lambda that runs on the reactor event loop, that read blocks a scheduler-critical thread.
Why explicit identity: RequestContext is bound to the request thread via a Guice scope — inside the scheduler's lambda it throws ProvisionException, and you silently degrade to the anonymous-ID fallback, losing user attribution.
Capture userName up front from the reactor context alongside workspaceId, then pass both into the scheduled call:
return Mono.deferContextual(ctx -> {
String workspaceId = ctx.get(RequestContext.WORKSPACE_ID);
// Use getOrDefault on paths that internal/system callers reach without seeding USER_NAME
// (e.g. a self-triggered cancellation written only with WORKSPACE_ID in the context).
String userName = ctx.getOrDefault(RequestContext.USER_NAME, null);
return someDao.write(...)
.doOnSuccess(__ -> Schedulers.boundedElastic().schedule(
() -> analyticsService.trackEvent("opik_thing_happened",
Map.of(
"thing_id", thing.id().toString(),
"workspace_id", workspaceId),
userName)));
});If you already depend on a Schedulers.boundedElastic().schedule(() -> { ... }) block that does other non-reactive work (e.g. a blocking datasetService.getById like ExperimentService.trackEvalSuiteRunIfApplicable), add the trackEvent call inside that existing lambda instead of nesting another.
trackEvent — sendEvent catches RuntimeException internally. Extra catches are noise and diverge from the codebase pattern.trackEvent — inline the call at the entry point. Wrap in a helper only when it encapsulates real logic (e.g. applicability check + enrichment + tracking).NotFound. Use the pre-write snapshot; some analytics drift is acceptable, a failed user-facing request is not.verify(analyticsService)... — the codebase convention is for existing integration tests to exercise these paths organically. Sister analytics PRs (#6326 eval suite, #6333 onboarding, #6338 agent config) ship without emission assertions.trackEvent is fully non-blocking — the Javadoc contract is aspirational; the identity-fallback path is synchronous JDBC today. Offload from reactive chains as shown above.sdks/python/src/opik/analytics/ — api.py (public surface), rules.py (when
reporting is allowed), worker.py (background thread), comet_stats.py (the HTTP
call). Config lives in sdks/python/src/opik/config.py, prefixed analytics_.
Identity and environment metadata are shared with Sentry error tracking, not
reimplemented. Both live at the top level so neither subsystem depends on the other:
opik/environment.py::get_user_identifier() (workspace name, falling back to a
hostname/username hash) and opik/environment_details.py (collect_tags_once() /
collect_context_once()). Analytics and error_tracking/before_send.py both read
them, so an event carries the same user id, the same session_id and the same
environment details as any error report from the same run. Add environment metadata
there, not in either consumer.
One function, called explicitly as the first line of whatever is being reported:
from opik import analytics
analytics.track_event("client", "create_dataset")
analytics.track_event("integration", "openai")
analytics.track_event("evaluation", "metric_created", metric=name)No decorators, by design: the payload is written out at the call site, so what gets sent is whatever you can read right there.
The positional arguments form a path, broadest first, and go as deep as an event needs:
analytics.track_event("integration", "bedrock") # the integration
analytics.track_event("integration", "bedrock", "invoke_agent") # one part of itThe first element is a closed set (analytics.Component): client, evaluation,
integration — extend it there rather than passing a new string. Every level after
it is free-form, and the second is normally just the method being reported.
A longer path is a different event, not a repeat of the shorter one, so instrumenting part of a feature never silences the feature itself.
Names are composed by joining the path with a double underscore —
opik_python_sdk__integration__bedrock__invoke_agent — in one private helper, so the
scheme can be changed for every event at once without touching a call site. The
separator is doubled so the name splits back into the path: segments are method names,
so they contain single underscores but never a pair. A test enforces that
(test_event_names.py); keep it true when adding events. Extra properties are keyword
arguments; adding one never changes the API.
Pick the path. First element from the closed analytics.Component set —
client, evaluation, integration. Second is normally the method being
reported. Add further levels only to narrow a feature down
("integration", "bedrock", "invoke_agent"), remembering a longer path is a
separate event, not a repeat of the shorter one.
Check the segments. No level may contain a double underscore, because that is
the separator the name is joined with. Method names never do, so this is normally
free — test_event_names.py fails the build if it is ever not.
Put the call on the first line of the user-facing function, before it does its
work, so a call that goes on to fail still counts as usage. Do not wrap it in
try/except and do not guard it with a config check; it already swallows
everything and no-ops when reporting is off.
Decide the properties, if any. Keyword arguments, scalars only. 97 of the 98
events carry none — reach for one only when the event genuinely has variants worth
splitting, as metric_created does. Never a value the user chose: report the
Opik-owned name and "custom" otherwise.
Check it should be reported at all. Skip it if Opik calls the same entry point
internally (litellm's track_completion), or if it is a per-call hot path
(Opik.trace(), Opik.span(), an OTel on_start) — instrument the constructor or
the user-facing function instead.
Verify it locally. Intercepting the HTTP call is the quickest way to see the exact payload without sending anything:
import json, os, unittest.mock
import httpx
os.environ["OPIK_ANALYTICS_ENABLE"] = "true"
sent = []
def fake_post(self, url, **kwargs):
sent.append(kwargs["json"])
return type("R", (), {"status_code": 201})()
# Patched for the block only. Replacing `post` outright leaves every later
# request in the process - the SDK's own included - talking to the stub.
with unittest.mock.patch.object(httpx.Client, "post", fake_post):
from opik import analytics
... # exercise your new call site
analytics.flush(timeout=10) # batched; nothing appears without this
print(json.dumps(sent, indent=2))Reporting is off under pytest, so this has to be a plain script, not a test. Then run the suite from the SDK directory, where it lives:
cd sdks/python && pytest tests/unit/analytics # 67 testsKnow how it will be read. The event surfaces on the
Python SDK Usage dashboard,
where every tile counts uniq(distinct_id). A new event needs no dashboard change
to appear in the adoption tiles, which group on the name.
track_event() never raises, never blocks on I/O, and no-ops when reporting is off.evaluate_threads calls
search_threads, get_or_create_dataset calls get_dataset, the CLI calls both —
35 of the 69 instrumented Opik methods are reachable this way. An event is dropped
when either the reporting function was reached from a different Opik module, or
some function further up the stack is already reporting. Being called from the
reporter's own module is not enough on its own, so a private helper reporting on its
caller's behalf (as BaseMetric does) still works. Internal calls record nothing, so
the user's own call to the same API still reports.track_event call site joins in
automatically.fork() — with _ALREADY_REPORTED deliberately inherited, so a child reports
its own events but not the parent's. Separate processes cannot share that state, so
a spawn pool reports one copy per worker: count uniq(anonymous_id), never raw
event volume.analytics/worker.py), and on through Segment to PostHog — the same route the
backend reports through. The collector takes no credentials, so there is no
write key to configure; OPIK_ANALYTICS_URL alone points it somewhere else.Opik.span() in a hot loop costs one event and a
set lookup. Events differing in their properties count as different events, so one
name still covers variants (each metric class, say).OPIK_ANALYTICS_ENABLE=false is the only way to switch reporting off. Reporting is
also skipped under pytest, which is not a user-facing switch but the thing keeping
test suites from making network calls. Add another process-level veto with
analytics.register_rule(lambda config: ...) before the first tracked event.opik.configure(...) is taken into account.str | int | float | bool | None); pick each key deliberately. Counts, flags and
library names only."custom" otherwise (see _track_metric_creation in
evaluation/metrics/base_metric.py).track_event - it already swallows everything.track_completion case is why: LiteLLMChatModel calls it, so the event would
measure Opik's own behaviour rather than the user's.on_start). Instrument the
constructor or the user-facing function instead. Opik.trace() and Opik.span() are
deliberately uninstrumented for the same reason - the backend already sees them.| Variable | Default | Purpose |
|---|---|---|
OPIK_ANALYTICS_ENABLED | false | Backend: controls whether analytics events are sent |
OPIK_ANALYTICS_ENVIRONMENT | empty | Frontend and backend: tags events with deployment name (e.g. staging, production) |
OPIK_POSTHOG_KEY | — | Frontend: PostHog API key (set in config.js) |
OPIK_POSTHOG_HOST | — | Frontend: PostHog API host (set in config.js) |
OPIK_ANALYTICS_ENABLE | true | Python SDK: controls whether usage events are sent |
OPIK_ANALYTICS_URL | stats.comet.com/notify/event/ | Python SDK: where events are sent. Needs no credentials; set it empty to stop reporting |
Backend analytics is disabled by default; the Python SDK's is opt-out. OSS installations are unaffected on the backend.
Frontend custom events: Browser → Segment → PostHog
Backend events: Java → comet-stats → Segment → PostHog
Python SDK events: Python → comet-stats → Segment → PostHog (background thread)
PostHog native: Browser → posthog-js → PostHog (pageviews, feature flags, identification)blueprint_id for the UUID, blueprint_name for the display name). If one is unavailable in a code path, omit the key or send an empty string — don't repurpose the other key.workspace_id: All backend analytics events should include the workspace ID for segmentation.track_openai vs track_anthropic both
produce ordinary spans server-side.© comet-ml, Apache-2.0. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file
Just SKILL.md in .agents/skills/analytics-instrumentation of comet-ml/opik.
Open the folder on GitHubat commit 8e3f6e5
Opik Analytics Instrumentation next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.
| Skill | Stars | Used in | Tokens | Auto-check | Licence | Repo updated |
|---|---|---|---|---|---|---|
| Opik Analytics Instrumentation this skillcomet-ml/opik | 22k | — | ~4.4k | Automated safety check: Pass | Apache-2.0 | |
| Cross-Language Coding Standardszereight/gitlab-mcp | 2k | 1 repos | ~1.4k | Automated safety check: Pass | MIT | |
| Dbgtheodo-group/debug-that | 158 | — | ~2.2k | Automated safety check: Pass | MIT | |
| Supercovsupercorp-ai/supercov | 150 | 1 repos | ~415 | Automated safety check: Pass | MIT | |
| CodeScope Codebase Graph AnalysisQwenLM/qwen-code | 28k | 1 repos | ~9.3k | Automated safety check: Pass | Apache-2.0 | |
| Codegraph QAQwenLM/qwen-code-examples | 143 | — | ~4.3k | Automated safety check: Pass | None |
zereight/gitlab-mcp
Shared reference for naming, function size, complexity and error handling rules that reviewer agents apply across TypeScript, Python, Go, Rust, Java, C# and Swift.
theodo-group/debug-that
Debug applications using the dbg CLI debugger. An agent skill from theodo-group/debug-that.
supercorp-ai/supercov
Measures test coverage and code quality in a repository with the supercov CLI, and turns what it finds into small, focused tests or fixes.
QwenLM/qwen-code
Answers questions about code structure, history, bugs and PR risk using a CodeScope knowledge graph and semantic index built from the repository.
QwenLM/qwen-code-examples
Use CodeScope to analyze any indexed codebase via its graph database (neug) and vector index (zvec).
telagod/code-abyss
Software development knowledge reference covering Python, Go, Rust, TypeScript, Java, C++, and Shell.
comet-ml/opik
Checklist for wiring a new linter into Opik's Code Quality pipeline: the four files to edit, the silent-failure gotchas and the pass/fail verification loop.
comet-ml/opik
Investigates a failed Opik end-to-end test from CI, TestOps or a local run, decides regression versus flake, and proposes a fix without editing tests.
comet-ml/opik
Rules for writing PR descriptions, changelog entries and feature documentation in the Opik repository, including the exact headings that CI requires.
comet-ml/opik
Turns a code change into one committed, passing Playwright end-to-end spec by resolving the change scope and handing authoring to a companion skill.
comet-ml/opik
Starts, rebuilds, and troubleshoots the Opik local dev stack, including an optional Comet Platform integration mode for the Opik team.
comet-ml/opik
Specifies how to instrument an opik-backend pipeline with per-stage OpenTelemetry metrics for throughput, latency, errors and queue delay by workspace.
Works with
Categories
Shows how to add product analytics events to Opik's frontend, Java backend and Python SDK, all reporting through Segment to PostHog with an opik_ name prefix. Every event name must start with opik_, because Segment routes opik_ events on to PostHog; tooling enforces the prefix and names in code should already carry it.ts and call trackEvent from the component or hook where the action happens.
Opik Analytics Instrumentation fits situations like: wiring a new product analytics event into an Opik frontend feature; adding a tracked event from Opik's Java backend; instrumenting the Python SDK so its events reach PostHog through Segment.
Run `npx skills add comet-ml/opik --skill analytics-instrumentation -a claude-code`. Or copy the skill folder (.agents/skills/analytics-instrumentation in comet-ml/opik) into .claude/skills/analytics-instrumentation in your project. Claude Code loads it when a task matches its description.
Run `npx skills add comet-ml/opik --skill analytics-instrumentation -a codex`. Or copy the skill folder (.agents/skills/analytics-instrumentation in comet-ml/opik) into .agents/skills/analytics-instrumentation in your project. Codex loads it when a task matches its description.
Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add comet-ml/opik --skill analytics-instrumentation -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/analytics-instrumentation, .gemini/skills/analytics-instrumentation, .github/skills/analytics-instrumentation and .opencode/skills/analytics-instrumentation in your project.
Going by SKILL.md and its folder, Opik Analytics Instrumentation needs the command-line tools its instructions call (pytest and python) and credentials named OPIK_POSTHOG_KEY. Our summary lists: A checkout of the Opik repository.
SKILL.md names 1 domain. As links in the text: us.posthog.com. This is read from the text; nothing was executed.
Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.
Opik Analytics Instrumentation is published under the Apache-2.0 licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.
About 4.4k tokens (SKILL.md is roughly 18k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.
Skills that share tags, products or a category with Opik Analytics Instrumentation: Cross-Language Coding Standards (zereight/gitlab-mcp, 2k stars), Dbg (theodo-group/debug-that, 158 stars), Supercov (supercorp-ai/supercov, 150 stars) and CodeScope Codebase Graph Analysis (QwenLM/qwen-code, 28k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.
comet-ml (a GitHub organization) maintains it in comet-ml/opik, which has 22,443 GitHub stars. The repository holds 19 skills in this directory. The repository was last updated on October 8, 2026.
Source: comet-ml/opik on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.