Skip to content

fatihaydin9/rust-development-skill

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 

Repository files navigation

rust-development agent skill

An Agent Skill for substantive Rust development across libraries, CLIs, systems code, and backend applications. It guides coding agents toward idiomatic ownership, explicit error contracts, appropriate trait and async boundaries, maintainable project structure, deliberate dependency selection, and verifiable quality checks.

The skill is context-sensitive. It preserves an existing repository's architecture and only applies Tokio, repository, layered-workspace, or outbox patterns when the project actually needs them.

Install

# Install into the current project.
npx skills add fatihaydin9/rust-development-skill

# Or target a specific agent and install globally.
npx skills add fatihaydin9/rust-development-skill -a claude-code -g

Alternative installation methods:

  • Claude.ai / Claude Desktop: upload the packaged .skill file and save it.
  • Manual: copy skills/rust-development/ into the skills directory used by your agent, such as ~/.claude/skills/ or .claude/skills/.

What the agent receives

  • SKILL.md contains the workflow, decision precedence, general Rust rules, context-sensitive async and architecture guidance, testing expectations, quality gates, and anti-patterns.
  • references/patterns.md contains complete application patterns: public async traits with explicit Send futures, transactional state plus durable outbox writes, a rollback-aware fake transaction, relay lifecycle, composition root, actor pattern, typed configuration, graceful shutdown, builders, and newtype IDs.
  • references/project-layout.md contains layouts for a small binary, library, single-crate service, and layered workspace service, plus Rust 2024 workspace configuration and CI guidance.
  • references/crates.md contains dependency-selection criteria, candidate crates, YAML cautions, and dependency hygiene rules.
  • evals/evals.json contains realistic output-quality cases.
  • evals/trigger-queries.json contains positive and negative prompts for checking whether the skill description activates at the right time.

The references use progressive disclosure: the agent loads the core instructions first and reads detailed files only when the task needs them.

Layout

skills/
└── rust-development/
    ├── SKILL.md
    ├── evals/
    │   ├── evals.json
    │   └── trigger-queries.json
    └── references/
        ├── patterns.md
        ├── project-layout.md
        └── crates.md

Design boundaries

The skill intentionally avoids several universal mandates:

  • A small or medium application may remain a single crate.
  • A reusable library should not inherit a Tokio dependency merely because an application uses Tokio.
  • Generics and trait objects are chosen from composition and performance needs rather than ideology.
  • #[non_exhaustive], builders, newtypes, repositories, and outboxes are applied only when their semantic benefits justify their costs.
  • Existing repository conventions remain the default unless the user requests a migration or a correctness issue requires change.

Evaluation

Run each case in evals/evals.json with the skill and against a baseline or previous version. Grade the expected output and assertions, then revise the skill only when failures reveal a general rule rather than a prompt-specific keyword gap.

Use evals/trigger-queries.json separately to measure description-trigger accuracy. Positive cases should load the skill; near-miss negative cases should not.

Releases

Packages

Contributors