Skip to content
CAI
Software that uses CAICheck a score

xai-org/grok-build

62.9

Adequate · 27 September 2026

1330.2k

lines of production code

Rust

primary language

4

measurements over time

CAI band scale
CAI trend line
CAI lens gauges

What this system is

This system is a comprehensive AI chat and bot management platform that handles complex conversation state, including image context preservation, token-efficient history compaction, and robust session lifecycle management. It provides a multi-language interface for interacting with bot agents, supporting features like agent rostering, command execution, and transcript retrieval through generated protocol types for both CLI and Kotlin clients. The infrastructure ensures reliable message delivery and tool execution via retry policies, circuit breakers, and a centralized tool definition schema, while also integrating diagnostic, search, and feedback capabilities.

Features

Enhanced CLI chat proxy types: managed config, feedback images, and metadata updates

This update introduces several capabilities to the CLI chat proxy type definitions. It adds a new \team\_managed\_config\_types\ module to support team-managed configuration policies with partial-update semantics and optimistic locking. Signed payloads now include domain-separation tags and per-response nonces, and a new \ManagedIdentityClaim\ type enforces principal management status. Feedback submissions now support attaching up to four images with validation, and include new fields for reasoning effort, author identity, and terminal version. Prompt metadata schema is bumped to v1.24 to track subagent attempt IDs, and the sandbox mode enum is simplified to remove the Agent and Bare variants.

prod/mc/cli-chat-proxy-types · high confidence

Generated Kotlin protocol types for the Bot Relay service

New Kotlin source files (BotRelay.kt, BotRelayCommands.kt, BotRelaySchema.kt) have been added to the common protocol crate, providing generated data classes, serialization logic, and command allowlists for the Bot Relay API. These types enable Kotlin clients to interact with bot management features such as agent rostering, status monitoring, transcript retrieval, usage tracking, and command execution (e.g., creating agents, managing automations, connecting channels).

repository · high confidence

New common infrastructure for retry policies, message addressing, and tool definitions

This update introduces several new core libraries to \crates/common\. The \xai-circuit-breaker\ crate adds a \GrpcRetryPolicy\ that classifies gRPC status codes, retrying only transient errors (Unavailable, Unknown) by default while treating internal or permission errors as terminal. The \xai-message-delivery-core\ crate provides the foundational types for message delivery, including opaque \AgentAddress\ and \AgentId\ structures, an \OperationSet\ for authorizing delivery actions (Queue, Steer, Interject), and logic to resolve address candidates. The \xai-computer-hub-core\ crate defines the canonical list and JSON schemas for Grok Bot harness tools (e.g., \bot\_create\_agent\, \bot\_send\_prompt\), serving as the single source of truth for tool IDs and descriptions. Additionally, the \xai-grok-compaction\ crate implements an ordered 'fit ladder' to summarize conversation history by progressively dropping oldest turns or truncating tool results to fit a token budget. Finally, the \xai-proto-build\ crate adds support for a \debug\_redact\ protobuf option to automatically redact sensitive fields in debug output.

crates/common · high confidence

Behavioural changes

Flowchart diagrams now support class-based text coloring and ampersand grouping

The mermaid-to-svg engine now correctly renders text color when using class definitions (e.g., \classDef ... color:\#fff\), ensuring that node labels inherit the specified text color rather than defaulting to the theme. Additionally, the parser now supports ampersand grouping in flowcharts (e.g., \A & B --\> C\), treating the ampersand as a logical connector that creates edges to all grouped nodes instead of creating a literal node with an ampersand in its ID. These changes improve the fidelity of complex flowcharts with styled nodes and grouped connections.

_third\party/mermaid-to-svg · high confidence

Image handling and session cleanup improvements

The chat state now preserves image context across conversation compaction, ensuring that attached images and their file paths are correctly carried over to maintain continuity. To prevent request bodies from exceeding the 50 MB proxy limit, the system now automatically evicts older inline images once a configurable byte threshold is reached, replacing them with a placeholder to avoid model hallucinations. Additionally, the application's home directory resolution now strictly prioritizes the \$GROK\_HOME\ environment variable over the default user home path, and the worktree garbage collection process has been enhanced with more robust liveness checks to prevent the accidental deletion of active sessions.

(repo-wide), crates/codegen · high confidence

Dependencies

Workspace dependency sync and new crate additions

This update syncs the workspace dependencies and introduces a large set of new crates to the build, including xai-compaction-transcript, xai-dirs, xai-fuzzy-file-search, xai-grok-active-sessions, xai-grok-bundle, xai-grok-dashboard-store, xai-grok-diag-server, xai-grok-extra-ca, xai-grok-feedback, xai-grok-file-lock, xai-grok-foreign-sessions, xai-grok-gboom, xai-grok-image, xai-grok-login, xai-grok-otel, xai-grok-pager-diff, xai-grok-session-events, xai-grok-session-search, xai-grok-shell-terminal, xai-grok-status-line, xai-grok-workspace-daemon, xai-workflow, and xai-message-delivery-core. It also updates several existing crates to use these new dependencies and bumps specific library versions such as async-openai (to a custom git fork), rusqlite (pinned to 0.37), and rustls (pinned to 0.23).

(dependencies) · high confidence

Written by watchdog.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.

How this codebase got here

Score

  • CAI 48 → 63 (+15.0)
  • Rubric changed (rubric-2026.08.15 → rubric-2026.09.15) — scores are not directly comparable.

Lenses

  • Code Health 97 → 73 (-23.7)
  • Architecture 69 → 100 (+30.6)
  • Maturity 80 → 76 (-4.2)
  • Readiness 17 → 45 (+28.9)
  • Security 81 → 83 (+2.0)
  • Domain Modelling 93 (new)
  • Event-Driven 80 (new)
  • Event Sourcing 100 (new)

Resolved (46)

  • Coverage not measured — test suite did not build
  • Dimension evaluation failed
  • LLM evaluation failed
  • Low CVE: [GHSA redacted] (Cargo.lock)
  • Low CVE: [GHSA redacted] (Cargo.lock)
  • Low CVE: [GHSA redacted] (Cargo.lock)
  • Low CVE: [GHSA redacted] (Cargo.lock)
  • Medium CVE: RUSTSEC-2023-0071 (Cargo.lock)
  • Medium CVE: RUSTSEC-2024-0320 (Cargo.lock)
  • Medium CVE: RUSTSEC-2024-0384 (Cargo.lock)
  • Medium CVE: RUSTSEC-2024-0436 (Cargo.lock)
  • Medium CVE: RUSTSEC-2025-0012 (Cargo.lock)
  • Medium CVE: RUSTSEC-2025-0052 (Cargo.lock)
  • Medium CVE: RUSTSEC-2025-0057 (Cargo.lock)
  • Medium CVE: RUSTSEC-2025-0141 (Cargo.lock)
  • Medium CVE: RUSTSEC-2026-0002 (Cargo.lock)
  • Medium CVE: RUSTSEC-2026-0008 (Cargo.lock)
  • Medium CVE: RUSTSEC-2026-0097 (Cargo.lock)
  • Medium CVE: RUSTSEC-2026-0183 (Cargo.lock)
  • Medium CVE: RUSTSEC-2026-0184 (Cargo.lock)
  • …and 26 more

New (3121)

  • AcpUpdateTracker::handle_tool_call (cognitive 22) (crates/codegen/xai-grok-pager/src/acp/tracker.rs)
  • AcpUpdateTracker::handle_tool_call_update (cognitive 111) (crates/codegen/xai-grok-pager/src/acp/tracker.rs)
  • AcpUpdateTracker::handle_tool_call_update (cyclomatic 39) (crates/codegen/xai-grok-pager/src/acp/tracker.rs)
  • AcpUpdateTracker::handle_update (cognitive 24) (crates/codegen/xai-grok-pager/src/acp/tracker.rs)
  • AcpUpdateTracker::handle_update (cyclomatic 24) (crates/codegen/xai-grok-pager/src/acp/tracker.rs)
  • AcpUpdateTracker::handle_user_message (cognitive 59) (crates/codegen/xai-grok-pager/src/acp/tracker.rs)
  • AcpUpdateTracker::handle_user_message (cyclomatic 40) (crates/codegen/xai-grok-pager/src/acp/tracker.rs)
  • ActionRegistry::lookup_with_mode (cognitive 16) (crates/codegen/xai-grok-pager/src/actions/mod.rs)
  • AgentActivity::flush_all_sessions (cognitive 17) (crates/codegen/xai-grok-shell/src/agent/activity.rs)
  • AgentBuilder::build (cognitive 153) (crates/codegen/xai-grok-agent/src/builder.rs)
  • AgentBuilder::build (cyclomatic 102) (crates/codegen/xai-grok-agent/src/builder.rs)
  • AgentRebuildSpec::build_agent_inner (cognitive 26) (crates/codegen/xai-grok-shell/src/session/agent_rebuild.rs)
  • AgentRebuildSpec::build_agent_inner (cyclomatic 25) (crates/codegen/xai-grok-shell/src/session/agent_rebuild.rs)
  • AgentView::activate_dock_item (cognitive 17) (crates/codegen/xai-grok-pager/src/app/agent_view/panes.rs)
  • AgentView::apply_reload_outcome (cognitive 32) (crates/codegen/xai-grok-pager/src/app/agent_view/session.rs)
  • AgentView::apply_reload_outcome (cyclomatic 16) (crates/codegen/xai-grok-pager/src/app/agent_view/session.rs)
  • AgentView::approve_plan (cognitive 22) (crates/codegen/xai-grok-pager/src/app/agent_view/plan.rs)
  • AgentView::build_inline_media_escapes (cognitive 17) (crates/codegen/xai-grok-pager/src/app/agent_view/media.rs)
  • AgentView::card_esc (cognitive 17) (crates/codegen/xai-grok-pager/src/app/agent_view/key_owner.rs)
  • AgentView::complete_clipboard_attachment_paste (cognitive 16) (crates/codegen/xai-grok-pager/src/app/agent_view/paste.rs)
  • …and 3101 more

Changes since last survey

  • 27 commits — 27 feature/other, 0 fixes

By area

  • crates/codegen — 27 commits

Notable commits

  • change: Synced from monorepo
  • change: Synced from monorepo
  • change: Synced from monorepo
  • change: Synced from monorepo
  • change: Synced from monorepo
  • change: Synced from monorepo
  • change: Synced from monorepo
  • change: Synced from monorepo
  • change: Synced from monorepo
  • change: Synced from monorepo
  • change: Synced from monorepo
  • change: Synced from monorepo
  • change: Synced from monorepo
  • change: Synced from monorepo
  • change: Synced from monorepo
  • change: Synced from monorepo
  • change: Synced from monorepo
  • change: Synced from monorepo
  • change: Synced from monorepo
  • change: Synced from monorepo
  • …and 7 more

Architecture

  • Containers 0 added · 0 removed · contexts 2 added · 0 removed · edges 0 added · 0 removed

Added bounded contexts (2)

  • python
  • repository

Written by watchdog.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.

Survey your own repository

xai-org/grok-build was measured the same way every project in this corpus was: the same rubric, at a pinned commit, with the result published in full. Point a surveyor at a repository you know and see whether you agree with it.

About this page

  • The score is its most recent published measurement, taken on 27 September 2026 at a pinned commit. It is not a live figure and does not change until the project is measured again.
  • Measured at commit f0e3be1100ef5252488e3be8bb0e91cf68d8c305 — the exact code this score is about.
  • Scored under rubric-2026.09.15 — the same rubric and the same method as every other entry in this index.
  • Measured by watchdog.canine.dev using codehealth-analyzer preprod-7c1cb6328e11.