Six-tab editor
For the five atom kinds that carry Layer 2 (feature, ui_view, rule, criterion, fixture), the cloud editor splits into six tabs:
[1.Fields] [2.Intent] [3.Relations] [4.Behavior] [5.Provenance] [6.Preview]The other 21 kinds use a simpler 3-tab editor (Fields / Intent / Relations).
Tab 1 — Fields
Section titled “Tab 1 — Fields”The kind-specific form. For criterion you fill EARS pattern + actor + system_response. For task you fill title + complexity + depends_on. Etc.
This is where the kind-specific top-level fields of the atom get edited. Validation runs on Save against the Zod schema for the kind.
Tab 2 — Intent (Layer 1)
Section titled “Tab 2 — Intent (Layer 1)”Three free-form fields, all optional:
userStory— prose. Vietnamese / English / whatever.relatedAtoms— list of atom IDs you mention in the user story.notes— internal commentary.
Fill this before you fill Layer 2. The LLM Pattern D suggester reads it as part of every prompt.
Tab 3 — Relations
Section titled “Tab 3 — Relations”Wire edges between this atom and others. The cloud picker has 3 dropdowns:
- Relation type — one of 20 (
verifies,parent_of,uses_rule, …). - Atom kind filter — narrow the target picker.
- Target atom — pick from current project.
The atom’s outgoing edges show above the picker. Incoming edges are read-only here (edit them on the source atom).
Tab 4 — Behavior (Layer 2)
Section titled “Tab 4 — Behavior (Layer 2)”Structured executable detail. Two ways to populate:
a. Hand-author (Pattern A, 🟢)
Section titled “a. Hand-author (Pattern A, 🟢)”For feature: a structured Step list editor with 7 step kinds (validate, call, dispatch, setState, navigate, log, if). Click ⇧⇩ to reorder, × to delete. Each step has form fields per kind.
Plus a raw JSON textarea fallback for any field.
b. Automated (Pattern C / D)
Section titled “b. Automated (Pattern C / D)”- 🟡 Re-infer (Pattern C) — deterministic synthesis from linked criterion + fixture atoms (or in reverse: criterion from feature steps). Free, no LLM call.
- ⚪ Suggest with AI (Pattern D) — calls OpenRouter / Anthropic with a kind-specific prompt + your Layer 1 prose. ~$0.001-0.01/call.
Either path opens a Diff modal before applying — review current vs suggested side-by-side, then Apply or Cancel.
If behavior is empty, the panel shows a Pattern B preview describing what the codegen-senlang bridge will fall back to (e.g. events[<slug>] = [{ $do: log, level: warn, msg: "TODO ..." }] for an unfilled feature).
Tab 5 — Provenance
Section titled “Tab 5 — Provenance”Per-field audit table. Each row:
- Field path (e.g.
behavior.steps.0). - Pattern badge (🟢 A / 🔵 B / 🟡 C / ⚪ D).
- Source (e.g.
cri_xxx + fix_yyyfor C,llm:claude-sonnet-4.6for D). - Confidence (% — only for C / D).
- 🔒 Lock toggle (click to flip).
- Timestamp.
Lock fields you don’t want overwritten when you re-run Pattern C / D. The merge logic respects locks. See Concepts → Four patterns → The lock flag.
Tab 6 — Preview
Section titled “Tab 6 — Preview”Visualisation of what the codegen bridge will emit:
feature→ numbered Action chain cards.ui_view→ screen tree with section types.rule→ enforced_at site cards.criterion→ before/after state diff table + api calls list.fixture→ API call traces with method badge + response preview.
For full live render, the homepage hosts /demos/from-atomprd.
Save semantics
Section titled “Save semantics”The Save button in the modal footer commits all 6 tabs at once. There is no per-tab save. Unsaved drafts are lost on browser refresh — save often.
See also
Section titled “See also”- User flow → Workspace — the surrounding workspace UX (tour, ring, banner, sections, graph) that frames the editor modal.
- Concepts → Four patterns — A / B / C / D + lock flag.
- Spec → Layer 2 schemas — the structures Tab 4 edits.
- Spec → Provenance — the shape Tab 5 surfaces.