feat(ui): wants, intentions, commitments, plans, agency timeline, why, research

- Wants: active wants by effective strength with origin, means, drives,
  values, goal, reinforcement, suppressions and each conflict with its
  resolution rule; closed wants with their resolution.
- Intentions grouped by status with blocked reasons and plans, plus the
  wants that did not become intentions and why. An intention page shows
  sources, subordinate intentions, formation terms, every plan revision as
  a dependency graph, decisions and the correlated timeline; operators can
  abandon it.
- Commitments with polarity, exception, matcher, weight and due time,
  live conflicts between commitments, a creation form and close controls.
- Plans with estimate against budget; a plan page with the dependency
  graph, per-step expectations, observations and linked approvals,
  requests, executions and subordinate intentions, resources, completion
  and abort conditions, assumptions, alternatives, revisions and
  validation; operators can cancel a plan or release a blocked step.
- Agency timeline labelling each event as wanted, intended, committed,
  planned, requested, approved, acted, observed or reconsidered.
- "Why did this happen?" pages built from agency.Explain, reachable from
  events, executions in the approval centre, plan steps and intentions.
- A research dashboard per mind (volition and agency rates, introspection
  accuracy, action claims, self-model accuracy, calibration by confidence
  band, experiments on the mind) and a global research page grouping
  experiments by protocol; every figure sits next to its operational
  definition and the disclaimer. Experiment pages show the protocol,
  reproducibility, build, per-variant research measures, divergence
  extras and counterfactual findings.
- The mind tabs gain Volition; the navigation gains Research.
This commit is contained in:
Andy Dixon
2026-09-24 21:16:48 +01:00
parent a43fc31643
commit 2ecdbc39b5
23 changed files with 975 additions and 5 deletions
+30
View File
@@ -0,0 +1,30 @@
{{define "content"}}
{{$m := .Data.Mind}}{{$d := .Data.D}}{{$it := $d.Intention}}
<div class="pagehead mindhead"><div><p class="muted small"><a href="/minds/{{$m.Slug}}/intentions">intentions</a></p>
<h1>{{$it.Description}} <span class="badge">{{$it.Status}}</span></h1>
<p class="muted">{{$it.Kind}} · priority {{conf $it.Priority}} · confidence {{conf $it.Confidence}}{{if $it.RequireApproval}} · <span class="warn">approval required</span>{{end}}{{if $it.FormedEvent}} · <a href="/events/{{$it.FormedEvent}}">formed</a>{{end}} · <a href="/minds/{{$m.Slug}}/why?kind=intention&id={{$it.ID}}">why?</a> · <a href="/minds/{{$m.Slug}}/agency?intention={{$it.ID}}">timeline</a></p>
{{if $it.BlockedReason}}<p><strong>Blocked ({{$it.BlockedKind}}):</strong> {{$it.BlockedReason}}</p>{{end}}{{with $it.StatusReason}}<p class="small muted">{{.}}</p>{{end}}</div>
{{if and (.Principal.User.Role.AtLeast "operator") ($it.Status.Open)}}<form method="post" action="/minds/{{$m.Slug}}/intentions/{{$it.ID}}/abandon" class="row"><input type="hidden" name="_csrf" value="{{.CSRF}}"><input name="reason" placeholder="reason (recorded)" maxlength="300"><button class="btn btn-danger" data-confirm="Abandon this intention? Its plan is cancelled and open requests withdrawn.">Abandon</button></form>{{end}}</div>
{{template "mind_tabs" (dict "M" $m "Active" "intentions")}}
<section class="grid cols-2">
<div class="card"><h2>Sources</h2>
{{range $d.Wants}}<p><span class="badge">want</span> {{.Description}} <span class="small muted">({{.Origin}}, {{conf .Strength}}, {{.Status}})</span></p>{{else}}<p class="muted">No source want recorded.</p>{{end}}
{{if $it.GoalID}}<p><span class="badge">goal</span> <a href="/minds/{{$m.Slug}}/goals">{{$it.GoalID}}</a></p>{{end}}
{{if $it.CommitmentID}}<p><span class="badge">commitment</span> <a href="/minds/{{$m.Slug}}/commitments">{{$it.CommitmentID}}</a></p>{{end}}
{{if $it.ParentID}}<p><span class="badge">serves</span> <a href="/minds/{{$m.Slug}}/intentions/{{$it.ParentID}}">parent intention</a></p>{{end}}
{{if $d.Subordinates}}<h3>Subordinate intentions</h3><ul class="plain small">{{range $d.Subordinates}}<li><a href="/minds/{{$m.Slug}}/intentions/{{.ID}}">{{.Description}}</a> <span class="badge small">{{.Status}}</span></li>{{end}}</ul>{{end}}
<h3>Expected result</h3><p class="small">{{$it.ExpectedResult}}</p>
</div>
<div class="card"><h2>Formation</h2><p class="small muted">The deterministic terms that produced this intention.</p><pre class="json">{{.Data.Formation}}</pre></div>
</section>
<section class="card"><h2>Plans <span class="muted small">{{len $d.Plans}} revision(s); earlier revisions are kept as history</span></h2>
{{range $i, $p := $d.Plans}}<div class="stack"><h3><a href="/minds/{{$m.Slug}}/plans/{{$p.ID}}">revision {{$p.Revision}}</a> · {{$p.Strategy}} · <span class="badge">{{$p.Status}}</span> <span class="small muted">{{$p.StatusReason}}</span></h3>
{{template "plan_dag" (dict "Levels" (index $.Data.Levels $i) "M" $m)}}</div>{{else}}<p class="muted">No plan.</p>{{end}}
</section>
<section class="card"><h2>Decisions</h2>
{{if $d.Decisions}}<table class="table compact"><thead><tr><th>Kind</th><th>Outcome</th><th>Rationale</th><th>When</th></tr></thead><tbody>{{range $d.Decisions}}<tr><td class="small">{{.Kind}}</td><td><span class="badge">{{.Outcome}}</span> <span class="small muted">{{.Reason}}</span></td><td class="small">{{.Rationale}}{{if .EventID}} <a href="/events/{{.EventID}}">event</a>{{end}}</td><td class="small muted nowrap">{{ago .CreatedAt}}</td></tr>{{end}}</tbody></table>{{else}}<p class="muted">None.</p>{{end}}
</section>
<section class="card"><h2>Agency timeline</h2>
{{range .Data.Timeline}}<div class="small"><span class="etype cat-{{.Category}}">{{.Type}}</span> <a href="/events/{{.ID}}">{{trunc .Summary 160}}</a> <span class="muted">{{ago .OccurredAt}}</span></div>{{else}}<p class="muted">No correlated events.</p>{{end}}
</section>
{{end}}