Skip to content

chore(docs): add a guide and example for the smallest valid event model - #213

Merged
yordis merged 1 commit into
TrogonStack:mainfrom
enilsen16:enilsen16/docs-minimal-model-guide
Oct 20, 2026
Merged

yordis merged 1 commit into
TrogonStack:mainfrom
enilsen16:enilsen16/docs-minimal-model-guide

Conversation

@enilsen16

@enilsen16 enilsen16 commented Oct 20, 2026 •

Copy link
Copy Markdown
Contributor

Problem

Atlas has 29 entity kinds. The docs give no smallest valid model and no order to create entities in, so a new author does not know where to start.

Change

  • Add docs/how-to/start-a-model-from-scratch.md. It gives the order (problem space, swimlane, event and command, persona and UI, command slice, read model and slice, storyboard, event model), the fields the validator checks for each kind, and the rule code behind each check. Each rule comes from the rule catalog, the validator, or the MCP server instructions.
  • Add the acme-wishlist example namespace that the guide builds: one human-issued command, one event, one read model, and one storyboard.
  • Link the guide from docs/README.md and examples/manifests/README.md.
  • Add acme-wishlist to NAMESPACES in example_manifests_validate.rs, so CI checks that the namespace validates with no errors or warnings.

Test

  • cargo test -p trogon-atlas-server --test example_manifests_validate passes. With persona removed from the command slice, it fails with COMMAND_HAS_NO_TRIGGER.
  • cargo test -p trogon-atlas-cli --test fmt_integration and the manifest_schema tests pass. trogon-atlas fmt --check reports no change for acme-wishlist.
  • Against a local server, trogon-atlas apply --dry-run passes after each step of the guide.
  • markdownlint, typos, and lychee-offline pass.

Closes #83


View with [code]smith Autofix with [code]smith
Need help on this PR? Tag @codesmith-bot with what you need.

Signed-off-by: Erik Nilsen <enilsen16@live.com>
@coderabbitai

coderabbitai Bot commented Oct 20, 2026 •

Copy link
Copy Markdown

Important

  • 🔍 Trigger review

This repository does not receive automatic reviews because it has fewer than 10 stars.

⚙️ Run configuration
  • Configuration used: Organization UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 0a2ab17b-830b-42a4-9f35-16c826abdd22
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@enilsen16
enilsen16 marked this pull request as ready for review October 20, 2026 15:19
@cursor

cursor Bot commented Oct 20, 2026 •

Copy link
Copy Markdown

PR Summary

Low Risk
Documentation, example manifests, and a test namespace list change only; no runtime or auth behavior changes.

Overview
Adds onboarding for authors who need a minimal valid event model and a safe creation order across Atlas’s many entity kinds.

A new how-to walks through eight steps—from problem space through EventModel—with per-step files, trogon-atlas apply --dry-run checks, and the validation rule codes each step is meant to satisfy. The finished reference is the new acme-wishlist example namespace (one human command, one event, one read model, one storyboard).

Docs index and examples/manifests/README.md link to the guide and describe the new example. example_manifests_validate now seeds and validates acme-wishlist alongside the other Acme namespaces so CI enforces zero errors/warnings on it.

Reviewed by Cursor Bugbot for commit e68bfdc. Bugbot is set up for automated code reviews on this repo. Configure here.

@yordis
yordis merged commit 75cc5fe into TrogonStack:main Oct 20, 2026
28 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Docs: a minimal-model guide (which kinds to create, in what order)

2 participants