Skip to content
CAI
Software that uses CAICheck a score

xai-org/grok-build

54.3

Adequate · 14 November 2026

1359.3k

lines of production code

Rust

primary language

7

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 cca.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.

How this codebase got here

Score

  • CAI 55 → 54 (-0.9)
  • Rubric changed (rubric-2026.10.5 → rubric-2026.11.4) — scores are not directly comparable.

Lenses

  • Code Health 73 → 69 (-3.8)
  • Architecture 97 → 97 (+0.0)
  • Maturity 76 → 76 (-0.1)
  • Readiness 40 → 38 (-2.0)
  • Security 57 → 59 (+2.0)
  • Domain Modelling 100 → 100 (+0.0)
  • Event-Driven 80 → 80 (+0.0)
  • Event Sourcing 100 → 100 (+0.0)
  • Performance 75 → 75 (+0.0)

Resolved (222)

  • Cross-context type CursorState (xai-grok-pager-render → xai-grok-pager) (crates/codegen/xai-grok-pager/src/app/app_view.rs)
  • Duplicated block (10 lines × 2) (crates/codegen/xai-fast-worktree/src/sync.rs)
  • Duplicated block (10 lines × 2) (crates/codegen/xai-fast-worktree/src/worktree/execute.rs)
  • Duplicated block (10 lines × 2) (crates/codegen/xai-grok-pager/src/app/dispatch/modes.rs)
  • Duplicated block (10 lines × 2) (crates/codegen/xai-grok-pager/src/app/dispatch/session/load.rs)
  • Duplicated block (10 lines × 2) (crates/codegen/xai-grok-pager/src/app/effects/mod.rs)
  • Duplicated block (10 lines × 2) (crates/codegen/xai-grok-pager/src/headless.rs)
  • Duplicated block (10 lines × 2) (crates/codegen/xai-grok-pager/src/scrollback/blocks/tool/memory_search.rs)
  • Duplicated block (10 lines × 2) (crates/codegen/xai-grok-pager/src/scrollback/blocks/tool/search.rs)
  • Duplicated block (10 lines × 2) (crates/codegen/xai-grok-pager/src/views/question_view.rs)
  • Duplicated block (10 lines × 2) (crates/codegen/xai-grok-shell/src/agent/feedback_client.rs)
  • Duplicated block (10 lines × 2) (crates/codegen/xai-grok-shell/src/session/goal_classifier/evidence.rs)
  • Duplicated block (10 lines × 2) (crates/codegen/xai-grok-shell/src/util/config/resolve/auto_mode.rs)
  • Duplicated block (10 lines × 2) (crates/codegen/xai-grok-tools/src/implementations/grok_build/image_gen/mod.rs)
  • Duplicated block (10 lines × 4) (crates/codegen/xai-grok-shell/src/remote/chat_models_client.rs)
  • Duplicated block (10–11 lines × 2) (crates/codegen/xai-grok-pager/src/scrollback/scrollback_pane.rs)
  • Duplicated block (11 lines × 2) (crates/codegen/xai-fast-worktree/src/auto_gc.rs)
  • Duplicated block (11 lines × 2) (crates/codegen/xai-file-utils/src/storage_client.rs)
  • Duplicated block (11 lines × 2) (crates/codegen/xai-grok-hooks/src/config.rs)
  • Duplicated block (11 lines × 2) (crates/codegen/xai-grok-pager-render/src/render/gboom_overlay.rs)
  • …and 202 more

New (1056)

  • AppView::apply_queue_changed (cognitive 16) (crates/codegen/xai-grok-pager/src/app/app_view.rs)
  • AppView::dispatch_scroll (cognitive 34) (crates/codegen/xai-grok-pager/src/app/app_view.rs)
  • AppView::dispatch_scroll (cyclomatic 19) (crates/codegen/xai-grok-pager/src/app/app_view.rs)
  • AppView::draw_inner (cognitive 170) (crates/codegen/xai-grok-pager/src/app/app_view.rs)
  • AppView::draw_inner (cyclomatic 76) (crates/codegen/xai-grok-pager/src/app/app_view.rs)
  • AppView::handle_input_at_with_paste_provenance (cognitive 247) (crates/codegen/xai-grok-pager/src/app/app_view.rs)
  • AppView::handle_input_at_with_paste_provenance (cyclomatic 127) (crates/codegen/xai-grok-pager/src/app/app_view.rs)
  • AppView::show_toast (cognitive 23) (crates/codegen/xai-grok-pager/src/app/app_view.rs)
  • AppView::tick (cognitive 77) (crates/codegen/xai-grok-pager/src/app/app_view.rs)
  • AppView::tick (cyclomatic 46) (crates/codegen/xai-grok-pager/src/app/app_view.rs)
  • AppView::view_tick_demand (cognitive 30) (crates/codegen/xai-grok-pager/src/app/app_view.rs)
  • AppView::view_tick_demand (cyclomatic 27) (crates/codegen/xai-grok-pager/src/app/app_view.rs)
  • Critical CVE: [GHSA redacted] (Cargo.lock)
  • Critical CVE: [GHSA redacted] (Cargo.lock)
  • Duplicated block (10 lines × 2) (crates/codegen/xai-codebase-graph/src/interner.rs)
  • Duplicated block (10 lines × 2) (crates/codegen/xai-fast-worktree/src/sync.rs)
  • Duplicated block (10 lines × 2) (crates/codegen/xai-fast-worktree/src/worktree/execute.rs)
  • Duplicated block (10 lines × 2) (crates/codegen/xai-grok-dashboard-store/src/types.rs)
  • Duplicated block (10 lines × 2) (crates/codegen/xai-grok-hooks/src/dispatcher.rs)
  • Duplicated block (10 lines × 2) (crates/codegen/xai-grok-pager-render/src/render/wrapping.rs)
  • …and 1036 more

Architecture

  • Unchanged — 0 containers · 2 contexts · 0 edges

Written by cca.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 14 November 2026 at a pinned commit. It is not a live figure and does not change until the project is measured again.
  • Measured at commit 2bdd1d6a6369de0e8c68132ea4539e9abd9e14a8 — the exact code this score is about.
  • Scored under rubric-2026.11.4 — the same rubric and the same method as every other entry in this index.
  • Measured by Canine Code Analyzer (cca.canine.dev) using cca measure-2026.11.65+preprod-36d4cd83012f.