Implement Command Query Responsibility Segregation for scalable architectures. Use when separating read and write models, optimizing query performance, or building event-sourced systems.
75
58%
Does it follow best practices?
Impact
84%
1.33xAverage score across 6 eval scenarios
Passed
No known issues
Optimize this skill with Tessl
npx tessl skill review --optimize ./plugins/backend-development/skills/cqrs-implementation/SKILL.mdCommand/Query bus infrastructure
Command base dataclass
0%
75%
Auto-generated command_id
0%
75%
Auto-generated timestamp
0%
75%
CommandHandler ABC Generic
0%
100%
CommandBus register/dispatch
62%
62%
CommandBus ValueError
0%
100%
QueryHandler ABC Generic
0%
100%
QueryBus register/dispatch
62%
62%
QueryBus ValueError
0%
100%
Async handlers
0%
0%
Separate command and query models
100%
100%
Validation in command handler
87%
87%
No reads in command handlers
100%
100%
Read model synchronization and projection
Denormalized view records
100%
100%
Projection handles() method
0%
100%
Projection apply() is async
0%
0%
Projection clear() method
25%
50%
Per-projection checkpoints
100%
100%
Sync reads from checkpoint
100%
100%
Checkpoint updated after events
100%
100%
run() uses asyncio.sleep loop
0%
0%
rebuild_projection clears first
77%
100%
rebuild_projection resets checkpoint
100%
100%
rebuild_projection replays all
100%
100%
Event types have global_position
40%
40%
FastAPI integration, pagination, eventual consistency
POST for create command
100%
100%
PUT for update command
0%
100%
GET for single query
100%
100%
GET for list query
100%
100%
CommandBus via Depends
0%
100%
QueryBus via Depends
0%
100%
PaginatedResult items field
100%
100%
PaginatedResult total field
100%
100%
PaginatedResult page fields
100%
100%
PaginatedResult total_pages
0%
0%
Consistency handler timeout
100%
100%
Stale data warning
44%
55%
Buses stored on app.state
100%
100%
Event store aggregate persistence
event_store.append_events called
90%
100%
stream_id naming convention
0%
100%
stream_type parameter
0%
0%
uncommitted_events used
33%
100%
Aggregate factory method
37%
100%
Validation before persist
60%
100%
Command dataclass with auto-fields
0%
100%
Async append_events
0%
0%
No query in command handler
100%
100%
Event versioning
0%
0%
Separate write/read models
100%
100%
Search query filtering and sorting defaults
sort_by default 'created_at'
0%
100%
sort_order default 'desc'
100%
100%
Optional filter appended conditionally
100%
100%
page_size default 20
100%
100%
Query handler reads from read_db only
100%
100%
No state mutation in query handler
100%
100%
QueryHandler ABC Generic pattern
37%
62%
PaginatedResult structure
100%
100%
total_pages ceiling division
100%
100%
QueryBus dispatch by type
100%
100%
Query base dataclass
100%
100%
HTTP verb conventions and schema independence
DELETE verb for removal
100%
100%
POST for create command
100%
100%
GET for query endpoints
100%
100%
CommandBus via Depends
100%
100%
QueryBus via Depends
100%
100%
Buses stored on app.state
100%
100%
Event version field
100%
0%
Independent write model
100%
100%
Independent read view model
100%
100%
No query in command handler
100%
100%
404 on not found query
100%
100%
70444e5
Table of Contents
If you maintain this skill, you can claim it as your own. Once claimed, you can manage eval scenarios, bundle related skills, attach documentation or rules, and ensure cross-agent compatibility.