rust-expert

Review Rust code for safety, idiomatic patterns, and performance.

100|12|Updated Jan 11, 2026
One-click install
npx skills add https://github.com/StepfenShawn/kota --skill rust-expert
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: rust-expert
Source: https://github.com/StepfenShawn/kota/tree/main/.kota/skills/rust-expert
Command: npx skills add https://github.com/StepfenShawn/kota --skill rust-expert

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Rust developers often struggle with ensuring memory safety, ergonomic APIs, and high-performance patterns in real-world code. This skill provides expert guidance to write idiomatic Rust, review code for safety, and optimize performance.

Core Features & Use Cases

  • Idiomatic Rust guidance: patterns, lifetimes, ownership, and zero-cost abstractions.
  • Safety and correctness checks: proper error handling, concurrency safety, and tests.
  • Performance-focused reviews: avoiding allocations, inline optimizations, and efficient design.
  • Use Case: peer code review for a Rust module, refactoring for safer APIs, and designing robust interfaces.

Quick Start

Provide a concise code-review prompt to analyze a Rust snippet for safety, idiomatic patterns, and performance.

Frequently Asked Questions about rust-expert

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I write idiomatic Rust code for better safety and performance?

Idiomatic Rust code leverages ownership, lifetimes, and zero-cost abstractions to ensure memory safety and high performance. It applies pattern-based guidance to refactor APIs and eliminate unsafe blocks while maintaining ergonomic interfaces.

What is the best way to review Rust code for concurrency safety?

The best way to review Rust code for concurrency safety is checking proper error handling and thread-safe traits. Validate that async Rust projects use correct synchronization primitives to prevent data races and ensure correctness.

How do I refactor Rust APIs to improve maintainability and safety?

Refactor Rust APIs by applying lifetime annotations and ownership transfers to design robust interfaces. Ensure proper error handling and traits are used to maximize correctness and maintainability across module boundaries.

How do I optimize Rust performance by reducing allocations?

Optimize Rust performance by avoiding unnecessary heap allocations and applying inline optimizations. Review efficient design patterns to ensure zero-cost abstractions are utilized correctly in high-performance code paths.

Why does my Rust code fail correctness checks during async operations?

Rust code fails correctness checks during async operations due to improper lifetime management or missing error handling. Validate concurrency safety mechanisms and test coverage to ensure robust interfaces.