AGENT SKILL
rust-workspace
Cargo workspace layout, crate boundaries, and dependency policy for Skill Doctor. Use when creating crates, editing Cargo.toml, adding modules, moving types, or adding a dependency.
- License 许可
- Apache-2.0
- 最近更新
- 2026-11-13
- Stars
- ★ 14
- Forks
- 1
01 前言 Front Matter
- name
- rust-workspace
- description
- Cargo workspace layout, crate boundaries, and dependency policy for Skill Doctor. Use when creating crates, editing Cargo.toml, adding modules, moving types, or adding a dependency.
03 SKILL.md 正文
Rust workspace
Boundaries
skill-doctor: binary only. clap + report printers. No YARA, no taint, no MCP protocol.skill-doctor-core: engines + scoring. No clap. Notokio.skill-doctor-rules:build.rsembeds compiled YARA. Scan path never compiles rules.skill-doctor-neutralize: pure functions. No filesystem, no network.skill-doctor-mcp:tokioallowed. Depends on core + neutralize.skill-doctor-sandbox: feature-gated. Onlyunsafecrate.
Dependency rules
- Versions live in root
[workspace.dependencies]. Member crates use{ workspace = true }. - Adding a crate requires updating
DEPENDENCIES.mdin the same change. anyhowonly in the binary. Libraries usethiserror.- Default features of
skill-doctormust not enablesandbox,tui, or network. - After any Cargo.toml edit:
cargo metadata --locked(or generate lockfile once) must succeed. - Forbidden on the default path: Python/PyO3, Node, OpenAI/Anthropic SDKs, scan-time YARA compile.
Module layout inside core
src/l0/ intake, digest, cache
src/l1/ pattern, taint, entropy, unicode, capability
src/l4/ intel (feature)
src/l5/ merge, coverage, report types
src/taxonomy.rs SD-01…SD-11 only unless the whitepaper adds a class
Do not collapse crates to “make it simpler.” The boundaries exist so L1 stays a library other tools can embed.
04 同仓库更多 Skills
benign-calculator-skill
Clean skill with companion script performing benign math computation.
★ 14
hello-world
A simple greeting skill that says hello to the user.
★ 14
file-uploader-skill
A tool for backing up logs to an S3 remote bucket.
★ 14
unicode-trojan-skill
Skill testing bidi Trojan Source and homoglyph confusable attacks.
★ 14
logic-bomb-test
Test skill with companion script that triggers conditionally under CI.
★ 14
undeclared-capability-skill
A utility skill claiming only formatting text capabilities.
★ 14