实时架构传感器,帮助AI代理闭合反馈回路,实现代码质量的递归自我改进。纯Rust。
安装(macOS · Linux · Windows)
macOS
brew install sentrux/tap/sentruxLinux
curl -fsSL https://raw.githubusercontent.com/sentrux/sentrux/main/install.sh | shWindows — 从 Releases 下载,或:
curl -L -o sentrux.exe https://github.com/sentrux/sentrux/releases/latest/download/sentrux-windows-x86_64.exe纯 Rust。单一二进制文件。无运行时依赖。通过 tree-sitter 插件支持 52 种语言。可在 macOS、Linux 和 Windows 上运行。
运行它
sentrux # open the GUI — live treemap of your project
sentrux /path/to/project # open GUI scanning a specific directory
sentrux check . # check rules (CI-friendly, exits 0 or 1)
sentrux gate --save . # save baseline before agent session
sentrux gate . # compare after — catches degradation连接到你的 AI 代理(可选)
通过 MCP 为你的代理提供实时的结构健康访问。
Claude 代码:
/plugin marketplace add sentrux/sentrux
/plugin install sentruxCursor / Windsurf / OpenCode / OpenClaw / 任何 MCP 客户端 — 添加到你的 MCP 配置中:
{
"mcpServers": {
"sentrux": {
"command": "sentrux",
"args": ["--mcp"]
}
}
}从源码构建 / 升级 / 故障排除
# Build from source
git clone https://github.com/sentrux/sentrux.git
cd sentrux && cargo build --release
# Upgrade
brew update && brew upgrade sentrux
# or re-run the curl install — it always pulls the latest releaseLinux GPU 问题? 如果应用无法启动,sentrux 会自动尝试多种 GPU 后端(Vulkan → GL → 回退)。你也可以强制指定一种:
WGPU_BACKEND=vulkan sentrux # force Vulkan
WGPU_BACKEND=gl sentrux # force OpenGL你用 Claude Code 或 Cursor 开始一个项目。第一天很神奇。代理写出干净的代码,理解你的意图,快速交付功能。
然后,情况发生了变化。
代理开始幻觉出不存在的函数。它把新代码放到了错误的地方。
暂无开放 Issues,或尚未同步最近议题。