1
0
Fork 0
polaris-task-force/docs
Z8MB1E 375d04d644 feat(npc-dialogue): generate a branch instead of replacing the conversation
Generate could only hand back a whole graph, so using it inside a
conversation meant losing what was already there. It now offers three
placements, and the branch one is the default whenever a node is selected.

Select a node, press Generate, and the model writes the next beat as a
branch that is wired in from that node's output: a new choice button, a
condition's free branch, or the node's continuation. A "come back" toggle
points the branch's open end back at where it attached, which is what
turns a generated tangent into a side question that returns to the menu.
Empty canvas keeps the old behaviour: a whole conversation, no selector.

The splice lives in `fragmentInsert.ts`, pure and under test. It remaps
every id (a collision would silently repoint the author's hops), strips
any start flag, requires an open end so the branch can be continued, and
places the branch beside its attachment while nudging clear of individual
cards. Attaching under a choice node derives the new button's text from
the branch's first line, since a blank button fails validation; attaching
under an end node inserts the branch unwired and says why rather than
discarding it.

The prompt splits its structure contract by scope (full demands one start
node, fragment demands none and one open end) while FIELDS, STATE and
OUTPUT stay shared, so the schema contract cannot fork. PROMPT_VERSION is
bumped to npc-gen-v2.
2026-11-24 14:18:56 -05:00
..
.logs docs(deployment): update deployment diagram for clarity and add subtask log 2026-08-14 21:21:16 -04:00
arma-bridge feat(lockers): seed and unlimited-stock sync for limited arsenal 2026-11-20 19:52:15 -05:00
backups/pre-agents-split-20261009 docs(agents): split domain guidance into nested AGENTS.md files 2026-10-09 15:46:36 -04:00
bot feat(evaluations): gate leadership ratings by rank instead of squad assignments 2026-10-25 02:53:49 -04:00
case-studies docs: add AGENTS.md subdirectories and login case study 2026-08-19 19:48:35 -04:00
economy feat(economy): add economy tick with demand simulation and price modifiers 2026-09-06 17:22:30 -04:00
operations chore(operations): rollout controls, reconciliation, and bridge recovery 2026-09-20 02:45:00 -04:00
ai-settings.md feat(ai): add admin-configurable model connections 2026-11-24 13:04:39 -05:00
map-system.md feat(map-objectives): superuser-authored strategic objectives on mission maps 2026-10-27 02:12:31 -04:00
npc-dialogue-ai.md feat(npc-dialogue): generate a branch instead of replacing the conversation 2026-11-24 14:18:56 -05:00
operation-timeline.md docs: add POLARIS operations timeline with campaign spine and branch stubs 2026-11-22 18:44:10 -05:00
wiki-demo-article.md docs(wiki): reword demo article examples 2026-09-06 17:23:03 -04:00
wiki-infobox-template.md feat(wiki): add scoped template CSS and developer HTML templates 2026-09-06 05:32:48 -04:00