Kimi CLI is a Tier B runtime. The official OTel exporter is in flux as of May 2026, so the v1 default integration is JSONL tail of ~/.kimi/logs/kimi.log plus opportunistic ingest of kimi export ZIPs and (optionally) the stream-json print mode. When the OTel exporter stabilizes upstream, Mara will graduate Kimi to Tier A.
- Kimi CLI installed (
kimi --version). - Mara installed.
- A sink endpoint.
mara setup kimiThis writes a Mara config with:
- A JSONL tail on
~/.kimi/logs/kimi.log(when debug mode is enabled in Kimi). - A directory watcher on
~/.kimi/exports/to ingestkimi exportZIPs. - An optional
stream-jsonparser for piped Kimi output.
(Same patterns as other quickstarts.)
brew services start maraKimi only writes to ~/.kimi/logs/kimi.log when the --debug flag is set or the relevant config option is enabled. Recommend enabling for any session you want captured:
alias kimi='kimi --debug' # or add to ~/.zshrcFor the stream-json print mode capture (alternative — useful when you don't want the full debug log):
kimi --print-format stream-json "your prompt" | mara stream-json --runtime kimiThe mara stream-json subcommand reads JSONL from stdin and forwards to the running Mara agent. Useful for piped/wrapped invocations.
kimi "summarize the README"Or batch:
kimi export --session <id> --out ~/.kimi/exports/
# Mara's directory watcher picks up the ZIP and ingests context.jsonl + wire.jsonlFrom the debug log:
- Session lifecycle (with timestamps).
- Tool calls and results.
- Errors and warnings.
- Model usage when emitted (verbose mode).
From kimi export ZIPs:
- Full session context (post-hoc).
- Wire-level message history.
From stream-json print mode:
- Per-token streaming if you instrumented the pipe.
- Final completion + tool calls.
- Token usage: implementation-dependent; not always emitted to the debug log. PARTIAL in compatibility matrix.
- Cost: Mara computes from token counts × Moonshot price table when token usage is present; otherwise PARTIAL/GAP.
- OTel native: not yet stable; tracked as upstream-dependent. When stable, Kimi becomes Tier A.
- Moonshot-hosted traffic (when using cloud API mode) is subject to Moonshot's data-handling policy.
- For on-device / local-model mode, no vendor egress; Mara captures purely local activity.
capture_optinin Mara policy controls whether prompt body is recorded in canonical events.
mara diag
mara test pipeline --name primary --input ~/.kimi/logs/kimi.log --pretty--debugnot set — no debug log produced; Mara has nothing to tail. Default to setting it via alias or shell function.- Log rotation: Kimi rotates
kimi.logaggressively under heavy use; Mara's JSONL adapter handles rotation transparently. - Encoding: Kimi's CLI may emit Chinese or other non-Latin characters; Mara is UTF-8 throughout. If you see mojibake, file an issue with a sample.
kimi web/kimi acp/kimi wiremodes are not integration transports for telemetry; Mara does not connect to those endpoints directly in v1.
When Moonshot ships stable OTel export for Kimi, the runtime preset will add an OTLP receive adapter and mara setup kimi will reconfigure automatically (with a one-line CHANGELOG entry). Existing JSONL-only captures continue working as redundant signal.
- Kimi command reference: https://moonshotai.github.io/kimi-cli/en/reference/kimi-command.html.
- Kimi CLI index: https://moonshotai.github.io/kimi-cli/.
- Mara Kimi runtime preset:
crates/mara-runtimes/kimi/. - AI runtime telemetry surfaces (Kimi section):
../01-landscape/08-ai-runtime-telemetry-surfaces.md.