Skip to main content

Comet Opik logo
🔭 Opik Observability for Hermes

Plugin for the Hermes agent that exports conversation, LLM, and tool traces to
Opik for observability and monitoring.

License PyPI version Python versions

Why this plugin

Opik is Comet's open-source LLM and agent observability, tracing, evaluation, and optimization platform. opik-hermes adds native Opik tracing for Hermes agent runs — conversations, LLM calls, and tool usage — with no code changes to your agent. Modeled on Hermes' bundled Langfuse observability plugin, swapped to the Opik Python SDK.

What it captures

  • A root trace per agent turn (Hermes turn), grouped into Opik threads by Hermes session_id.
  • An LLM span (type=llm) per API call, with input messages, assistant output, model/provider, token usage, and USD cost (via Hermes' agent.usage_pricing).
  • A tool span (type=tool) per tool call, with arguments and results.

Install

Install the package into the same Python environment as Hermes, then enable the plugin by adding it to plugins.enabled in ~/.hermes/config.yaml:

pip install opik-hermes
# ~/.hermes/config.yaml
plugins:
  enabled: [opik]

pip install opik-hermes pulls in the opik SDK automatically (it's a declared dependency) and registers the plugin with Hermes via the hermes_agent.plugins entry point (name opik) — no manual file copying. Enable it through plugins.enabled as above; the entry-point name is opik.

This is the pip install path. A directory-based install (hermes plugins install comet-ml/opik-hermes, enabled via hermes plugins enable observability/opik) is tracked separately — see the follow-up work in the repo's issues.

Configure

Set these in ~/.hermes/.env (or via hermes tools).

Local open-source Opik needs no API key:

# ~/.hermes/.env
OPIK_URL_OVERRIDE=http://localhost:5173/api
OPIK_PROJECT_NAME=hermes

Comet-hosted Opik:

OPIK_API_KEY=...
OPIK_WORKSPACE=your-workspace

Use it

Talk to Hermes however you normally do — every turn is traced to the hermes project (or whatever OPIK_PROJECT_NAME you set):

hermes chat -q "list the files here and tell me how many there are"

…or open the Hermes web UI at http://localhost:9119 and use the Chat tab. Then open Opik and look for a trace named after your message, with an LLM span and a span per tool call.

See observability/opik/README.md for the full configuration and tuning reference.

Repository layout

opik-hermes/
├── pyproject.toml              # pip package + hermes_agent.plugins entry point
├── observability/opik/         # the plugin, in Hermes' flat bundled-plugin shape
│   ├── plugin.yaml
│   ├── __init__.py             # register(ctx) + hooks (Opik Python SDK)
│   └── README.md
└── tests/

The observability/opik/ directory is byte-compatible with Hermes' bundled plugin layout, so it can be mounted as a user plugin, vendored into Hermes, or shipped as the pip package above — all from one source.

Metadata

Release files for opik-hermes 0.1.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for opik-hermes 0.1.2
File Size Uploaded
opik_hermes-0.1.2.tar.gz 40.2 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for opik-hermes 0.1.2
File Interpreter ABI Platform
opik_hermes-0.1.2-py3-none-any.whl Python 3 none any Details

Total release size: 72.9 kB

Release files / opik_hermes-0.1.2.tar.gz

Download URL opik_hermes-0.1.2.tar.gz
Size 40.2 kB
Tags Source
SHA-256 checksum
How to use checksums
4a7391f8cf43fe4ed6ae09c795cf41884b6d083f89fd94fbab29e1535ed2d4dd
BLAKE2b-256 checksum
How to use checksums
6bd8c36cbd30b32e0cc1c6c393d55857f556e76227def27b23316798b24a4939
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.12.8

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Jul 10, 2026.

Transparency log

Release files / opik_hermes-0.1.2-py3-none-any.whl

Download URL opik_hermes-0.1.2-py3-none-any.whl
Size 32.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
f549e8155cd422bb88191650e14837af0ff5cf2769cd1c6ffef001c3a5da8509
BLAKE2b-256 checksum
How to use checksums
988c0399b9827eeb0ea76b17d6b60e180a3bf0f8a27231d90ad79445b065259e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.12.8

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Jul 10, 2026.

Transparency log

Release history Release notifications | RSS feed

This release

0.1.2 This release

2 release files

0.1.1

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page