Premier can normalize structured output from five agent CLIs into its stable event envelope. Automatic detection is deliberately narrow: the executable must be recognized and the command must already request the provider’s JSONL format.

Record native structured output

Provider Structured-output flag detected by --adapter auto
Codex --json
Claude --output-format stream-json
Gemini --output-format stream-json
Grok --output-format streaming-json
OpenCode --format json
premier record --adapter auto -- codex exec --json "review this repository"
premier record --adapter claude -- claude --output-format stream-json -p "review this repository"

Use an explicit adapter when a wrapper changes the executable name. Use --adapter none when the JSON stream is application output rather than agent evidence.

Native adapters require pipe capture. Premier rejects an explicit adapter with --pty because terminal framing cannot provide a trustworthy JSONL boundary.

What normalization preserves

Each normalized event records source=adapter.<provider>.v1, provider identity, the native event type, correlation identifiers when present, and the complete native object under payload.native. The manifest carries adapter provider, schema version, transport, and completeness provenance.

Malformed, non-object, or oversized JSONL records become adapter.diagnostic evidence rather than silently disappearing. Normalization maps recognizable lifecycle evidence into agent, model, tool, and approval families; unknown native event kinds remain visible as provider.event.

Typed emit remains the portable contract

Automatic adapters reflect provider output formats that can change. For framework-specific metadata or an unsupported runtime, emit the stable event schema through premier emit, the TypeScript SDK, shell helper, or collector HTTP endpoint.

Runtime compatibility

Choose the integration path that is real today

Assistant access and trace capture are separate capabilities. Premier never labels a generic emitter as automatic instrumentation.

5 providers match
ProviderLocal AIAuto captureTyped emitOperational note
ClaudeclaudeAvailableNativeSupportedAuto-detects stream-json output; local AI safety is capability-probed.
CodexcodexAvailableNativeSupportedAuto-detects --json; local AI runs ephemerally in a read-only sandbox.
GrokgrokAvailableNativeSupportedAuto-detects streaming-json; local AI disables tools, subagents, memory, and web search.
GeminigeminiAvailableNativeSupportedAuto-detects stream-json; local AI uses plan approval mode and sandboxing.
OpenCodeopencodeBlockedNativeSupportedAuto-detects JSON trace output; local AI stays blocked without a verified tool-deny mode.