KS
Killer-Skills

m09-domain — how to use m09-domain how to use m09-domain, m09-domain rust development, domain modeling with m09-domain, m09-domain vs domain-driven design, m09-domain setup guide, m09-domain install for rust developers

v1.0.0
GitHub

About this Skill

Perfect for Rust Developer Agents needing efficient domain modeling and code optimization capabilities. m09-domain is a Rust Developer AI Assistance System that utilizes meta-problem-driven knowledge indexing for domain modeling and design choices.

Features

Identifies Entities and Value Objects for efficient domain modeling
Determines invariants and aggregate boundaries for robust code
Maps Domain Concepts to Rust Patterns for optimized development
Applies ownership implications for unique identifiers and struct management
Supports Layer 2 design choices for informed decision-making

# Core Topics

actionbook actionbook
[0]
[0]
Updated: 3/6/2026

Quality Score

Top 5%
33
Excellent
Based on code quality & docs
Installation
SYS Universal Install (Auto-Detect)
Cursor IDE Windsurf IDE VS Code IDE
> npx killer-skills add actionbook/rust-skills/m09-domain

Agent Capability Analysis

The m09-domain MCP Server by actionbook is an open-source Categories.community integration for Claude and other AI agents, enabling seamless task automation and capability expansion. Optimized for how to use m09-domain, m09-domain rust development, domain modeling with m09-domain.

Ideal Agent Persona

Perfect for Rust Developer Agents needing efficient domain modeling and code optimization capabilities.

Core Value

Empowers agents to guide Rust developers through design choices and entity identification using a meta-problem-driven knowledge indexing system, maintaining invariants and aggregate boundaries with Rust patterns like struct + Id for Entities.

Capabilities Granted for m09-domain MCP Server

Modeling entities and value objects in Rust
Identifying aggregate boundaries for efficient code organization
Maintaining invariants in Rust code for robust domain modeling

! Prerequisites & Limits

  • Requires Rust development environment
  • Limited to domain modeling and code optimization in Rust
Project
SKILL.md
3.9 KB
.cursorrules
1.2 KB
package.json
240 B
Ready
UTF-8

# Tags

[No tags]
SKILL.md
Readonly

Domain Modeling

Layer 2: Design Choices

Core Question

What is this concept's role in the domain?

Before modeling in code, understand:

  • Is it an Entity (identity matters) or Value Object (interchangeable)?
  • What invariants must be maintained?
  • Where are the aggregate boundaries?

Domain Concept → Rust Pattern

Domain ConceptRust PatternOwnership Implication
Entitystruct + IdOwned, unique identity
Value Objectstruct + Clone/CopyShareable, immutable
Aggregate Rootstruct owns childrenClear ownership tree
RepositorytraitAbstracts persistence
Domain EventenumCaptures state changes
Serviceimpl block / free fnStateless operations

Thinking Prompt

Before creating a domain type:

  1. What's the concept's identity?

    • Needs unique identity → Entity (Id field)
    • Interchangeable by value → Value Object (Clone/Copy)
  2. What invariants must hold?

    • Always valid → private fields + validated constructor
    • Transition rules → type state pattern
  3. Who owns this data?

    • Single owner (parent) → owned field
    • Shared reference → Arc/Rc
    • Weak reference → Weak

Trace Up ↑

To domain constraints (Layer 3):

"How should I model a Transaction?"
    ↑ Ask: What domain rules govern transactions?
    ↑ Check: domain-fintech (audit, precision requirements)
    ↑ Check: Business stakeholders (what invariants?)
Design QuestionTrace ToAsk
Entity vs Value Objectdomain-*What makes two instances "the same"?
Aggregate boundariesdomain-*What must be consistent together?
Validation rulesdomain-*What business rules apply?

Trace Down ↓

To implementation (Layer 1):

"Model as Entity"
    ↓ m01-ownership: Owned, unique
    ↓ m05-type-driven: Newtype for Id

"Model as Value Object"
    ↓ m01-ownership: Clone/Copy OK
    ↓ m05-type-driven: Validate at construction

"Model as Aggregate"
    ↓ m01-ownership: Parent owns children
    ↓ m02-resource: Consider Rc for shared within aggregate

Quick Reference

DDD ConceptRust PatternExample
Value ObjectNewtypestruct Email(String);
EntityStruct + IDstruct User { id: UserId, ... }
AggregateModule boundarymod order { ... }
RepositoryTraittrait UserRepo { fn find(...) }
Domain EventEnumenum OrderEvent { Created, ... }

Pattern Templates

Value Object

rust
1struct Email(String); 2 3impl Email { 4 pub fn new(s: &str) -> Result<Self, ValidationError> { 5 validate_email(s)?; 6 Ok(Self(s.to_string())) 7 } 8}

Entity

rust
1struct UserId(Uuid); 2 3struct User { 4 id: UserId, 5 email: Email, 6 // ... other fields 7} 8 9impl PartialEq for User { 10 fn eq(&self, other: &Self) -> bool { 11 self.id == other.id // Identity equality 12 } 13}

Aggregate

rust
1mod order { 2 pub struct Order { 3 id: OrderId, 4 items: Vec<OrderItem>, // Owned children 5 // ... 6 } 7 8 impl Order { 9 pub fn add_item(&mut self, item: OrderItem) { 10 // Enforce aggregate invariants 11 } 12 } 13}

Common Mistakes

MistakeWhy WrongBetter
Primitive obsessionNo type safetyNewtype wrappers
Public fields with invariantsInvariants violatedPrivate + accessor
Leaked aggregate internalsBroken encapsulationMethods on root
String for semantic typesNo validationValidated newtype

Related Skills

WhenSee
Type-driven implementationm05-type-driven
Ownership for aggregatesm01-ownership
Domain error handlingm13-domain-error
Specific domain rulesdomain-*

Related Skills

Looking for an alternative to m09-domain or building a Categories.community AI Agent? Explore these related open-source MCP Servers.

View All

widget-generator

Logo of f
f

widget-generator is an open-source AI agent skill for creating widget plugins that are injected into prompt feeds on prompts.chat. It supports two rendering modes: standard prompt widgets using default PromptCard styling and custom render widgets built as full React components.

149.6k
0
Design

chat-sdk

Logo of lobehub
lobehub

chat-sdk is a unified TypeScript SDK for building chat bots across multiple platforms, providing a single interface for deploying bot logic.

73.0k
0
Communication

zustand

Logo of lobehub
lobehub

The ultimate space for work and life — to find, build, and collaborate with agent teammates that grow with you. We are taking agent harness to the next level — enabling multi-agent collaboration, effortless agent team design, and introducing agents as the unit of work interaction.

72.8k
0
Communication

data-fetching

Logo of lobehub
lobehub

The ultimate space for work and life — to find, build, and collaborate with agent teammates that grow with you. We are taking agent harness to the next level — enabling multi-agent collaboration, effortless agent team design, and introducing agents as the unit of work interaction.

72.8k
0
Communication