Files
Andy Dixon fb34f08f40 feat: add mind model with versioned personality, templates and self-model
Phase 2. Minds are rows with a slug, status (active/disabled/archived),
cognitive configuration and a pointer to the current personality version.
Personalities are structured (identity, values, traits, communication,
behaviour, free text) with a deterministic Brief() used by prompts and the
editor preview. Every change appends a personality_versions row protected
by the append-only trigger; restore copies an old version forward.
Templates carry reusable personalities; minds record their overrides so a
template can be re-applied without losing mind-specific edits. The
self-model starts with structural limitations the mind cannot drop
(no policy changes, no influence over shutdown, no cross-mind access).

API, UI (list, overview, editor with sliders/diff/history/import/export,
template editor) and noemactl mind/template commands. All mutations are
audited with field-level diffs.
2026-06-15 22:17:01 +01:00

25 lines
1.5 KiB
HTML

{{define "content"}}
<div class="pagehead"><h1>Personality templates</h1><p class="muted">Reusable personalities. Minds keep their own overrides when a template is applied.</p></div>
<section class="grid cols-3-1">
<div class="card">
<table class="table">
<thead><tr><th>Name</th><th>Description</th><th>Role</th><th>Updated</th><th></th></tr></thead>
<tbody>{{range .Data.Templates}}<tr><td><a href="/personality-templates/{{.ID}}"><strong>{{.Name}}</strong></a></td><td class="small">{{.Description}}</td><td class="small muted">{{.Personality.Identity.Role}}</td><td class="small muted">{{ago .UpdatedAt}}</td>
<td>{{if $.Principal.User.Role.AtLeast "administrator"}}<form method="post" action="/personality-templates/{{.ID}}/delete" class="inline"><input type="hidden" name="_csrf" value="{{$.CSRF}}"><button class="btn small btn-danger" data-confirm="Delete template {{.Name}}?">Delete</button></form>{{end}}</td></tr>
{{else}}<tr><td colspan="5" class="muted">No templates yet.</td></tr>{{end}}</tbody>
</table>
</div>
{{if .Principal.User.Role.AtLeast "administrator"}}
<div class="card">
<h2>New template</h2>
<form method="post" action="/personality-templates" class="stack">
<input type="hidden" name="_csrf" value="{{.CSRF}}">
<label>Name <input name="name" required maxlength="80"></label>
<label>Description <input name="description" maxlength="200"></label>
<button class="btn btn-primary" type="submit">Create (then edit)</button>
</form>
</div>
{{end}}
</section>
{{end}}