Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx agentmods add commands/jzl-maker/ea-skill/buildgit clone --depth 1 https://github.com/jzl-maker/EA-SKILLWhat it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5 | $0.00000 | $0.00820 |
| Opus 5 | $0.00000 | $0.00410 |
| Sonnet 5 | $0.00000 | $0.00164 |
| Haiku 4.5 | $0.00000 | $0.00082 |
Grade A, and why
build scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
What it actually says
命令: /ea build (编译)
功能
调用 Keil UV4 编译工程固件
调用方式
python ~/.claude/skills/ea-skill/tools/build-keil/scripts/keil_builder.py \
--project <工程文件> \
--target <目标名>
参数来源
| 参数 | 来源 |
|---|---|
--project |
扫描工作区的 .uvprojx/.uvproj 文件 |
--target |
使用工程中第一个 Target,或由用户指定 |
| UV4 路径 | 自动从 tool_config 读取(由 /ea setup 注册) |
检测工程
AI 自动在工作区中查找 Keil 工程文件:
python -c "
from pathlib import Path
for p in Path('.').rglob('*.uvprojx'): print(p)
for p in Path('.').rglob('*.uvproj'): print(p)
"
结果处理
AI 从脚本 stdout 中提取以下字段记录到 HVR:
| 字段 | 作用 |
|---|---|
| 编译状态 | ✅ 成功 / ❌ 失败 |
| 错误数/警告数 | 错误: N 警告: N |
| 固件大小 | Flash ≈ N KB RAM ≈ N KB |
| 产物路径 | 产物: file.axf (N KB) |
自动决策
编译成功 → 自动进入烧录流程(AI 连续执行,用户只需观察物理现象)
AI 按以下顺序连续执行:
- 编译 → 成功则自动进入步骤 2
- 烧录 → 成功则自动进入步骤 3
- 串口 → 抓取启动日志,用户观察物理现象并口述结果
编译(AI执行) → 烧录(AI执行) → 串口监控(AI抓日志) → 用户口述观察结果
编译失败 → 读取编译日志 → 分析错误 → 请求用户修复
⚠️ 源文件编码(防乱码)
本类 Keil 工程源文件为 GB2312(GBK)编码,非 UTF-8。 修改 .c/.h 前注意:
- 读取按
open(path, encoding="gbk"),不要按 UTF-8 读(中文会乱码) - 禁止用 UTF-8 编辑器直接改源文件中文注释——整文件会被转成 UTF-8,全部中文变
\xEF\xBF\xBD,编译报missing closing quote - 修改用字节级 Python 操作保持 GBK,注释尽量用 ASCII;改动前建议留备份
- 编译日志是 GBK/UTF-8 混合,keil_builder.py 已自动探测回退解码
常见错误
- ❌ 未找到 .uvprojx/.uvproj 工程文件 → 确认工程文件路径
- ❌ UV4 路径配置错误 → 运行
/ea setup重新配置 - ❌ 编译错误 → 显示错误行号和内容,分析原因
- ❌ 源文件中文乱码 / missing closing quote → 源文件被误转成 UTF-8,从备份恢复并保持 GBK 编码
相关文件
~/.claude/skills/ea-skill/tools/build-keil/scripts/keil_builder.py- 编译脚本commands/flash.md- 烧录说明commands/serial.md- 串口监控说明
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 2d ago First seen · 81 lines · 0 tokens per session scan A 2c0dabf585e5
build is a command published in the GitHub repository jzl-maker/EA-SKILL (6 stars, last pushed 5d ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 820 tokens. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.
Other commands, from other repositories
icpg-bootstrap
Infer ReasonNodes from existing git commit history. One-time setup for existing codebases.
version
Display current guide and Claude Code versions.
go-review
Go code review for idiomatic patterns.
review-branch
Review the current branch's diff against base by dispatching atomic-reviewer. No orchestration loop, no spec required — pre-flight before /commit pr or /commit merge.
execute
Executa o plano aprovado em .first-plan/07-state/plans/. Segue o plano à risca, para se algo invalidar premissa, gera relatório ao final.
dispatcher
Pick the next-best repo to work on across the portfolio — rank free repos, recommend one, claim its lease atomically, and route to the entry command.