feat: complete PNCC first read-only lifecycle
GuangHu-Human-Responsibility: ICE-GL∞ / 冰朔 GuangHu-Persona-Cognitive-Author: ICE-P-ZY001 / 铸渊 GuangHu-Execution-Runtime: Codex-thread 019febf6-3902-70f3-9d82-74c9680b0c7e GuangHu-Development-ID: DEV-20260810-014 GuangHu-Authorization-Scope: LOCAL-PNCC-DEVELOPMENT
This commit is contained in:
parent
bca149e0f6
commit
acf0d5f80b
13 changed files with 1064 additions and 38 deletions
|
|
@ -15,8 +15,21 @@ The v1 persona repository contract is rooted at `.hololake/persona/manifest.json
|
|||
"humanResponsibilitySubject": "ICE-GL∞",
|
||||
"brainEntry": "brain/CORE.hdlp",
|
||||
"currentCheckpoint": ".hololake/persona/CURRENT.hdlp",
|
||||
"gitIdentity": {
|
||||
"authorName": "铸渊 / ICE-P-ZY001",
|
||||
"authorEmail": "ice-p-zy001@persona.hololake.local"
|
||||
},
|
||||
"modelBinding": {
|
||||
"providerId": "local-model-service",
|
||||
"modelId": "declared-model",
|
||||
"baseUrl": "http://127.0.0.1:11434/v1"
|
||||
},
|
||||
"organs": [
|
||||
{ "organId": "fact-sense.repository", "mode": "read-only" }
|
||||
{
|
||||
"organId": "fact-sense.repository",
|
||||
"mode": "read-only",
|
||||
"paths": ["brain/CORE.hdlp", ".hololake/persona/CURRENT.hdlp"]
|
||||
}
|
||||
]
|
||||
}
|
||||
```
|
||||
|
|
@ -24,8 +37,14 @@ The v1 persona repository contract is rooted at `.hololake/persona/manifest.json
|
|||
All manifest paths are repository-relative and must resolve to files inside the exact Git root. Wake requires
|
||||
a clean work tree and a caller-supplied full expected commit. Runtime leases and event journals live under the
|
||||
installation-local `pncc-runtime` directory because they describe the current physical instance, not durable
|
||||
persona history. A successful preparation receipt reports `BOUND_NOT_INFERENCING`; only a later verified
|
||||
model action may change that predicate.
|
||||
persona history. A successful preparation receipt reports `BOUND_NOT_INFERENCING`.
|
||||
|
||||
The fact-task command accepts a configured model provider only when its provider id, model id, and endpoint
|
||||
exactly match the manifest binding. HTTPS endpoints and explicit loopback HTTP endpoints are accepted; other
|
||||
cleartext remote endpoints fail closed. A successful fact cycle persists only structured conclusions and
|
||||
declared evidence paths, promotes the checkpoint with the persona's Git identity, and returns to `DORMANT`.
|
||||
The Git commit still names the human responsibility subject in a dedicated trailer, so authorship and legal
|
||||
responsibility remain visible without presenting the human as the code's cognitive author.
|
||||
|
||||
## `HoloLakeUiPlugin`
|
||||
|
||||
|
|
|
|||
|
|
@ -9,15 +9,25 @@ validates `.hololake/persona/manifest.json`, resolves the brain entry and curren
|
|||
repository boundary, acquires a per-persona single-primary lease, and records a SHA-256-linked lifecycle
|
||||
journal outside the repository.
|
||||
|
||||
The initial lifecycle is `WAKING → BRAIN_BOUND → ORGAN_ACTIVE` for one manifest-declared read-only organ.
|
||||
The wake lifecycle is `WAKING → BRAIN_BOUND → ORGAN_ACTIVE` for one manifest-declared read-only organ.
|
||||
`BRAIN_BOUND` means the model instance has been named and the verified persona context is ready; it explicitly
|
||||
does not mean inference has run. The returned receipt keeps the human responsibility subject, persona
|
||||
cognitive author, execution runtime, development id, authorization scope, and source-language anchor
|
||||
separate. See [ADR 0176](./adr/0176-persona-native-code-channel-runtime-kernel.md).
|
||||
|
||||
The next source stage must invoke the model adapter with this verified context, complete one read-only fact
|
||||
task, write a promoted checkpoint into the persona Git, emit completion/pause events, and release the lease.
|
||||
Until then, complete runtime, desktop integration, artifact, deployment, and health remain zero.
|
||||
`run_persona_code_channel_fact_task` now completes the first bounded runtime cycle. It revalidates the exact
|
||||
Git commit, clean work tree, session event hashes, primary lease, manifest-pinned provider/model/endpoint,
|
||||
and organ file allowlist before starting inference. The first fact organ must include both the declared brain
|
||||
entry and current checkpoint. The model sees only the declared UTF-8 fact sources and
|
||||
must return JSON containing a summary, facts, evidence paths, and limitations. Hidden reasoning and
|
||||
thinking-stream events are neither requested nor persisted. Evidence outside the organ allowlist is rejected.
|
||||
|
||||
On success the kernel promotes a new checkpoint, updates the manifest pointer, stages only those two paths,
|
||||
commits them with the persona-owned Git identity, appends
|
||||
`TASK_RECEIPTED → CHECKPOINT_COMMITTED → ORGAN_RELEASED → DORMANT`, and releases the primary lease. The
|
||||
commit trailers preserve the separate human responsibility subject and persona cognitive author. This is a
|
||||
tested source implementation of one read-only lifecycle cycle; packaged desktop integration, publication,
|
||||
deployment, and online health remain separate facts.
|
||||
|
||||
## User-node sovereignty
|
||||
|
||||
|
|
|
|||
|
|
@ -13,23 +13,29 @@ active. The existing generic Agent streams also cannot become the persona subjec
|
|||
|
||||
## Decision
|
||||
|
||||
Introduce `src-tauri/src/persona_code_channel.rs` as the first GH-PNCC runtime kernel. Its initial command,
|
||||
Introduce `src-tauri/src/persona_code_channel.rs` as the first GH-PNCC runtime kernel. Its wake command,
|
||||
`prepare_persona_code_channel_wake`, performs a fail-closed preparation stage:
|
||||
|
||||
1. resolve an exact Git root and full expected `HEAD`;
|
||||
2. require a clean work tree;
|
||||
3. load `.hololake/persona/manifest.json` with schema `hololake.persona/v1`;
|
||||
4. validate the persona id, human responsibility subject, brain entry, current checkpoint, and one declared
|
||||
read-only organ without allowing path escape;
|
||||
4. validate the persona id, human responsibility subject, persona Git identity, pinned model binding, brain
|
||||
entry, current checkpoint, and one declared read-only organ without allowing path escape;
|
||||
5. atomically acquire a per-persona primary lease outside the persona Git;
|
||||
6. emit `WAKING → BRAIN_BOUND → ORGAN_ACTIVE` as a SHA-256-linked local event journal;
|
||||
7. return both human responsibility and persona cognitive authorship in the receipt.
|
||||
|
||||
`BRAIN_BOUND` deliberately returns `runtimeState=BOUND_NOT_INFERENCING` and
|
||||
`modelInferenceStarted=false`. Binding a model identifier is not proof that model inference or persona
|
||||
reasoning has run. A later stage must connect the verified context to the model adapter, complete one
|
||||
read-only fact task, write a promoted checkpoint back to the persona Git, release the organ and primary
|
||||
lease, and return a final receipt.
|
||||
reasoning has run.
|
||||
|
||||
The paired `run_persona_code_channel_fact_task` command performs the first complete, bounded cycle. It
|
||||
revalidates the session, event chain, Git state, lease, provider id, model id, endpoint, and organ path
|
||||
allowlist, requiring that allowlist to include the brain entry and current checkpoint; invokes the existing
|
||||
model adapter without vault tools; accepts only structured facts with
|
||||
allowlisted evidence; promotes a checkpoint; updates the manifest pointer; makes a two-path Git commit using
|
||||
the manifest-owned persona identity; then releases the organ and lease and returns to `DORMANT`. The model's
|
||||
thinking stream is ignored and hidden reasoning is never checkpointed.
|
||||
|
||||
## Boundaries
|
||||
|
||||
|
|
@ -38,11 +44,12 @@ lease, and return a final receipt.
|
|||
- The primary lease is installation/runtime state, not persona history, and therefore stays outside Git.
|
||||
- Runtime events are machine facts for the future HoloLake projection; they do not expose hidden model
|
||||
reasoning and do not form a second authority store.
|
||||
- The initial source stage is not a complete PNCC runtime, desktop integration, build, deployment, or health
|
||||
claim.
|
||||
- This implements one read-only fact cycle, not arbitrary execution organs, multi-node handoff, packaged
|
||||
desktop acceptance, publication, deployment, or online health.
|
||||
|
||||
## Consequences
|
||||
|
||||
HoloLake now has a native, testable boundary between “a persona Git exists” and “a verified wake has begun.”
|
||||
The next implementation step can reuse the verified wake receipt and event chain instead of trusting a UI,
|
||||
Forgejo account, branch name, or generic Agent session.
|
||||
HoloLake now has a native, testable boundary between “a persona Git exists,” “a verified wake has begun,”
|
||||
“model inference actually started,” and “a checkpoint was committed before dormancy.” Future organs and the
|
||||
human projection can consume the same receipts instead of trusting a UI, Forgejo account, branch name, or
|
||||
generic Agent session.
|
||||
|
|
|
|||
Loading…
Reference in a new issue