grok-build
27,746
Stars
5,242
Forks
243
Watchers
0
Open Issues
Apache-2.0
许可证
Rust
语言
2026-07-14
创建时间
2026-09-29
最近更新
项目能做什么
SpaceXAI 的编程 Agent 测试载体与 TUI,支持全屏展示、鼠标交互且易于扩展。
来源:AI 基于仓库事实生成
· 内容以仓库实际 README 为准
使用说明 查看原始 README 原仓库文档
中文使用说明暂未生成。下面保留原仓库 README 摘录,命令与配置均以原文为准。
原始 README 摘录(英文原文,节选前 3000 字符)
<div align="center">
<h1>
<picture>
<source media="(prefers-color-scheme: dark)" srcset="https://media.x.ai/v1/website/spacexai-symbol-white-transparent-0c31957f.png">
<source media="(prefers-color-scheme: light)" srcset="https://media.x.ai/v1/website/spacexai-symbol-black-transparent-6435cf42.png">
<img alt="SpaceXAI logo" src="https://media.x.ai/v1/website/spacexai-symbol-black-transparent-6435cf42.png" width="96">
</picture>
<br>
Grok Build (<code>grok</code>)
</h1>
**Grok Build** is SpaceXAI's terminal-based AI coding agent. It runs as a
full-screen TUI that understands your codebase, edits files, executes shell
commands, searches the web, and manages long-running tasks — interactively,
headlessly for scripting/CI, or embedded in editors via the Agent Client
Protocol (ACP).
[Installing the released binary](#installing-the-released-binary) ·
[Building from source](#building-from-source) ·
[Documentation](#documentation) ·
[Repository layout](#repository-layout) ·
[Development](#development) ·
[Contributing](#contributing) ·
[License](#license)

**Learn more about Grok Build at [x.ai/cli](https://x.ai/cli)**
This repository contains the Rust source for the `grok` CLI/TUI and its agent
runtime. It is synced periodically from the SpaceXAI monorepo.
A small `SOURCE_REV` file at the root records the full monorepo commit SHA
for the version of the code present in this tree.
</div>
---
## Installing the released binary
Prebuilt binaries are published for macOS, Linux, and Windows:
```sh
curl -fsSL https://x.ai/cli/install.sh | bash # macOS / Linux / Git Bash
irm https://x.ai/cli/install.ps1 | iex # Windows PowerShell
grok --version
```
See the [changelog](https://x.ai/build/changelog) for the latest fixes,
features, and improvements in each release.
## Building from source
Requirements:
- **Rust** — the toolchain is pinned by [`rust-toolchain.toml`](rust-toolchain.toml);
`rustup` installs it automatically on first build.
- **[DotSlash](https://dotslash-cli.com)** — required so hermetic tools under
[`bin/`](bin/) (notably [`bin/protoc`](bin/protoc)) can download and run.
Install it and ensure `dotslash` is on your `PATH` **before** building:
```sh
cargo install dotslash
# or: prebuilt packages — https://dotslash-cli.com/docs/installation/
/usr/bin/env dotslash --help # sanity check
```
- **protoc** — proto codegen resolves [`bin/protoc`](bin/protoc) via DotSlash,
or falls back to a `protoc` on `PATH` / `$PROTOC`.
- macOS and Linux are supported build hosts; Windows builds are best-effort
and not currently tested from this tree.
```sh
cargo run -p xai-grok-pager-bin # build + launch the TUI
cargo build -p xai-grok-pager-bin --release # release binary: target/release/xai-grok-pager
cargo check -p xai-grok-pager-bin # fast validation
```
The binary artifact is named `xai-gro
阅读完整原文
商业机会分析 AI 生成
多模型与本地模型兼容适配网关
| 产品构想 | 构建与grok-build兼容的轻量代理网关,将官方认证与模型请求桥接至DeepSeek、Claude、OpenAI或本地Ollama模型,降低使用门槛与使用成本。 |
| 核心功能 | 协议逆向/API转发适配、多模型上下文格式化、本地模型流式响应对齐、Token消耗监控与统计面板。 |
| 目标用户 | 受限于x.ai账户额度、国内网络环境或企业数据合规限制的开发者与团队。 |
| 难度/周期 | 中等 · 2-3周 · 成本:低于500元(本地开发与测试云主机) |
| 收费模式 | 核心开源,高级功能(企业团队配置下发、合规脱敏审计)提供商业授权或赞助席位。 |
| 竞争风险 | 官方客户端若更新专有加密认证或调整通信协议,需持续跟进维护;存在封禁推测风险。 |
| 依据 | AI推测 |
基于Headless模式的自动化CI自愈与Issue修复GitHub Action
| 产品构想 | 利用grok-build原生的headless(无头)执行能力,封装高易用性的CI/CD流水线插件,在测试失败或安全扫描告警时自动调用Agent修复代码并提交PR。 |
| 核心功能 | CI报错日志自动提取与上下文修剪、容器化沙箱静默修复、自动化git diff生成与安全检测、GitHub/GitLab PR自动创建与通知。 |
| 目标用户 | 追求高自动化研发效能的开源维护者、敏捷开发团队、中小型软件外包企业。 |
| 难度/周期 | 较低 · 1-2周 · 成本:极低(主要为CI运行环境与API调试消耗) |
| 收费模式 | Freemium模式,个人开源免费,企业版按每月触发次数/私有仓库席位订阅收费。 |
| 竞争风险 | 自动化代码修改存在产生隐蔽Bug风险;CI端多Agent竞品竞争激烈。 |
| 依据 | 已验证事实 |
企业安全沙箱隔离与企业级MCP工具集成套件
| 产品构想 | 针对grok-build执行系统命令的高风险痛点,提供基于Docker/Firejail的强制隔离沙箱层,以及预置企业研发系统(Jira/Confluence/GitLab/内部DB)的MCP服务集。 |
| 核心功能 | 破坏性命令拦截与多级审批Hook、文件读写白名单限制、企业通用MCP(Jira任务同步、内部API查询)即插即用集成、行为审计日志导出。 |
| 目标用户 | 有严格代码安全与执行权限控制要求的研发团队主管、DevSecOps工程师。 |
| 难度/周期 | 中等 · 3-4周 · 成本:低于1000元 |
| 收费模式 | 企业版软件许可(按节点或团队规模买断/订阅)、企业定制集成咨询实施费。 |
| 竞争风险 | 目标客群对开源Agent工具的合规审批周期长,标准化转化较慢。 |
| 依据 | 数据支持的判断 |
AI 基于仓库公开数据分析生成,含推测成分,不构成收益承诺。
报告会保存到 个人中心
竞品与相似项目 GitHub Search 真实检索
| 项目 | 中文简介 | Stars | 语言 |
|---|---|---|---|
| router-for-me/CLIProxyAPI | 中文介绍暂未生成 Wrap Antigravity, ChatGPT Codex, Claude Code, Grok Build, Mu |
58,296 | Go |
| justlovemaki/AIClient2API | 中文介绍暂未生成 Self-hosted multi-protocol AI API proxy for Antigravity, Cod |
8,982 | JavaScript |
| chenyme/grok2api | 中文介绍暂未生成 Multi-account API gateway for Grok Build, Grok Web, and Grok |
7,896 | Go |
| 0x0funky/agent-sprite-forge | 中文介绍暂未生成 Agent Skill for generating 2D sprite sheets and map, transpa |
5,536 | Python |
| tiann/hapi | 中文介绍暂未生成 App for Codex / Claude Code / Pi / OpenCode / Kimi Code / Gr |
5,403 | TypeScript |
| spacering-net/codeg | 中文介绍暂未生成 Collaborative multi-agent AI coding workspace: aggregate ses |
4,438 | Rust |
以上为通过 GitHub 官方 Search API 检索的相似项目,功能差异与优劣势需进一步人工确认,配置 AI 后可生成对比分析。
项目优势与风险
| 技术成熟度 | 创建于 2026-07-14,最近推送 2026-09-29 |
| 社区活跃 | Star 27,746 / Fork 5,242 / Issue 0(数据支持,可自行核实) |
| 许可证 | Apache-2.0 |
| 主要风险 | 上游项目方向可能变化;同赛道竞争者较多(见竞品表);热度与需求不完全等价 |
安装与使用
快速开始(以仓库 README 为准)
git clone https://github.com/xai-org/grok-build.git cd grok-build # 请阅读仓库 README 获取确切安装步骤(依赖、配置、启动命令)
术语说明:Docker=应用容器(把程序和依赖打包运行);API Key=调用外部服务的密钥;Git Clone=把仓库代码下载到本地。常见错误:API Key 未配置 / 端口占用 / 数据库连接失败,多数项目在 README 的 Troubleshooting 章节有说明。