Skip to content

Add meta-harness user-agent dimension for omnigent#234

Merged
simonfaltum merged 1 commit into
mainfrom
simonfaltum/harness-omnigent-tracking
Jun 19, 2026
Merged

Add meta-harness user-agent dimension for omnigent#234
simonfaltum merged 1 commit into
mainfrom
simonfaltum/harness-omnigent-tracking

Conversation

@simonfaltum

@simonfaltum simonfaltum commented Jun 18, 2026

Copy link
Copy Markdown
Member

Summary

Adds an independent meta-harness/omnigent user-agent dimension for the omnigent meta-harness.

Why

Omnigent is a meta-harness that orchestrates AI coding agents (Claude Code, Codex, Cursor, and others). It is not itself an agent, so it does not belong in the existing agent/<name> user-agent dimension. We want telemetry that surfaces both the meta-harness and the underlying agent at the same time. ("meta-harness" matches omnigent's own self-description; "harness" alone is how the field labels the underlying agents like Claude Code.)

What changed

Before: the SDK reported only agent/<name> (e.g. agent/claude-code) for the detected AI coding agent.

Now: the SDK also reports an independent meta-harness/<name> dimension. When the OMNIGENT environment variable is present (omnigent stamps OMNIGENT=1 into every agent process, see omnigent-ai/omnigent#656), the user agent gains a meta-harness/omnigent segment. Because it is a separate dimension from agent detection, running Claude Code under omnigent yields both agent/claude-code and meta-harness/omnigent, and omnigent never trips the agent "multiple" logic.

Implementation mirrors the existing agent dimension:

  • New packages/core/src/clientinfo/meta-harness.ts: a KNOWN_META_HARNESSES table, presence-based lookupMetaHarnessProvider(), and a cached metaHarnessProvider().
  • createDefault() in default.ts appends the meta-harness/<name> segment after the agent segment. The browser entrypoint (default.browser.ts) is unchanged, since it performs no process.env detection.

Internal changes

  • meta-harness.test.ts is excluded from the browser test suite (like agent.test.ts), as it relies on process.env.

How is this tested

  • npm test (320 passed), including new tests/clientinfo/meta-harness.test.ts and independence cases in tests/clientinfo/default.test.ts
  • Independence case: with both OMNIGENT and CLAUDECODE set, the UA renders agent/claude-code meta-harness/omnigent
  • npm run test:browser (209 passed)
  • npm run format:check, npm run lint, npm run typecheck all clean

Detect the OMNIGENT environment variable and report meta-harness/omnigent
as an independent user-agent dimension, parallel to agent detection. This
lets the platform see both the meta-harness (omnigent) and the underlying
coding agent (e.g. claude-code) in the same request.

Co-authored-by: Isaac
Signed-off-by: simon <simon.faltum@databricks.com>
@simonfaltum simonfaltum force-pushed the simonfaltum/harness-omnigent-tracking branch from ecda92f to ea59fd4 Compare June 18, 2026 12:23
@simonfaltum simonfaltum changed the title Add harness user-agent dimension for omnigent meta-harness Add meta-harness user-agent dimension for omnigent Jun 18, 2026
@simonfaltum simonfaltum added this pull request to the merge queue Jun 19, 2026
Merged via the queue into main with commit 2fd8e13 Jun 19, 2026
24 checks passed
@simonfaltum simonfaltum deleted the simonfaltum/harness-omnigent-tracking branch June 19, 2026 07:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants