Glaude — AI skill for Claude Code
A blazing-fast, zero-dependency AI coding agent written in Go, inspired by Claude Code.
How to install Glaude
This entry records only its repository, not the path inside it, so there is no
exact command to give. Open xmh1011/glaude and copy the folder into
~/.claude/skills/, or the file into ~/.claude/agents/.
What Glaude does
A blazing-fast, zero-dependency AI coding agent written in Go, inspired by Claude Code.
Alternatives in AI
- WindsurfAPI — Turn Windsurf / Devin Desktop's 100+ AI models (Claude, GPT, Gemini, DeepSeek, Kimi, GLM, SWE) into OpenAI-, A 3k ★
- Agent Rules Books — AGENTS.md rules / skills for AI coding agents: Codex, Cursor & Claude Code 2.6k ★
- CoreCoder — Minimal AI coding agent (~1,400 LoC Python) inspired by Claude Code 616 ★
README
Glaude
用 Go 语言实现的 AI Coding Agent,参照 Claude Code 架构设计。单二进制、零依赖、毫秒级启动。
特性
- Agentic Loop — LLM 自主决策工具调用,循环执行直到任务完成
- 8 种内置工具 — Bash、文件读写编辑、Glob、Grep、LS、子 Agent
- 多 Provider — Anthropic / OpenAI / Ollama,统一接口 + 流式输出
- 权限治理 — 4 种安全模式 + 30+ 条危险命令检测规则
- 上下文压缩 — Token 预算管理 + 自动摘要,支持长对话
- 会话持久化 — JSONL append-only,支持中断恢复和会话切换
- MCP 协议 — 连接外部 MCP 工具服务器,动态注册远端工具
- 生命周期 Hook — 在工具执行前后运行自定义脚本(格式化、静态分析等)
- 记忆系统 — 四层指令文件(企业/用户/项目/本地)+ 文件快照回滚
- 终端 UI — 基于 Bubble Tea 的交互界面,Markdown 渲染 + diff 展示
快速开始
安装
# 从源码构建
go build -o glaude ./cmd/glaude
# 或使用 Makefile
make build
配置 API Key
# Anthropic(默认)
export ANTHROPIC_API_KEY="sk-ant-..."
# OpenAI
export OPENAI_API_KEY="sk-..."
# Ollama(本地,无需 key)
# 默认连接 http://localhost:11434/v1
运行
# 交互模式(REPL)
./glaude
# 单次执行
./glaude -p "用 Go 写一个 HTTP server"
# 恢复上次会话
./glaude --continue
# 恢复指定会话
./glaude --resume
项目初始化
# 交互式生成 .glaude.json 配置文件
./glaude init
使用指南
CLI 参数
| 参数 | 短写 | 说明 |
|---|---|---|
--prompt |
-p |
运行单条 prompt 后退出 |
--continue |
-c |
恢复最近一次会话 |
--resume |
恢复指定 session ID 的会话 |
子命令:
| 命令 | 说明 |
|---|---|
glaude init |
交互式初始化项目配置 |
glaude version |
打印版本信息 |
REPL 斜杠命令
在交互模式下,输入以下命令:
| 命令 | 说明 |
|---|---|
/help |
显示可用命令 |
/exit, /quit |
退出 |
/clear |
清空对话历史 |
/undo |
撤销最近一次文件变更 |
/context |
显示上下文信息(消息数、token 用量、undo 栈) |
/mode [name] |
查看或切换权限模式 |
内置工具
Agent 在对话中自主调用这些工具:
| 工具 | 说明 | 只读 |
|---|---|---|
Bash |
执行 shell 命令,持久化 shell 状态(cd、环境变量跨调用保留) | 否 |
Read |
读取文件内容,支持行号分页,自动截断长行 | 是 |
Edit |
精准字符串替换(str_replace),替换前自动快照 | 否 |
Write |
创建或覆盖文件,自动创建父目录 | 否 |
Glob |
文件模式匹配(**/*.go),按修改时间排序,上限 100 条 |
是 |
Grep |
正则搜索文件内容,优先使用 ripgrep,支持多种输出模式 | 是 |
LS |
列出目录内容(名称、类型、大小) | 是 |
Agent |
派生子 Agent 处理独立子任务,仅返回结论 | 是 |
配置
配置文件层级
优先级从高到低:
| 层级 | 来源 | 路
Related Skills
Rusty Gitclaw
A universal git-native AI agent framework — written in Rust. Single binary. Zero dependencies. 383 models. Bla
Crustoxy
Unlimited coding with Claude Code on ANY LLM. A Blazing-Fast Rust proxy featuring auto-routing and load balanc
Datafog Python
Offline PII firewall for AI agents and LLM apps: fast local detection and redaction, Claude Code hook, LiteLLM
Bridge Search
Blazing-fast WSL2 to Windows file search bridge for AI Agents via MCP
Toktoken
TokToken is a fast, single-binary C codebase indexer for AI coding agents. Powered by universal-ctags and SQLi
SnapAI
Fast macOS screenshot & screen-recording tool written in Rust, built for handing captures to AI agents (Claude
Related Agents
Context Analyst David
Analyze given Bible verses from the Psalms, written by David, and provide a comprehensive understanding of the
Code Reviewer TDD Expert
TDD expert persona for code review (inspired by Wada Takuhito's approach). Focuses on testability, design qual
Sf Security Engineer
Security Engineer of the Software Factory cell. Use to run SAST/dependency/secret scans, verify zero-trust sec