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:
铸渊 / ICE-P-ZY001 2026-08-11 00:58:01 +08:00
commit acf0d5f80b
13 changed files with 1064 additions and 38 deletions

View file

@ -123,6 +123,8 @@ Forgejo 只允许作为可选兼容协作适配器。
- 本轮没有构建或安装新桌面版本。
- 京东尚未实现光湖独立先启动与 Linux 按需副控生命周期;本轮不执行真实引导切换。
- HoloLake 统一 AGE Runtime、AGE Mirror 运行器和首个真实 AGE 闭环仍为 `0`;本轮只完成架构正本、机器投影和导航收束。
- GH-PNCC 人格生命周期内核、结构化归因运行体和 HoloLake 同源投影仍为 `0`;架构登记不等于真实运行。
- GH-PNCC 首个只读人格生命周期源码闭环与结构化归因运行体已在 `DEV-20260810-014` 实现并由
自动化测试验证通用器官运行体、HoloLake 同源人类投影、桌面制品、部署和在线健康仍为 `0`
源码实现不等于桌面或线上运行。
规则升级只改变后续开发怎样判断和守门,不把未实现能力写成已经存在。

View file

@ -18,7 +18,7 @@
>
> 开发编号:`DEV-20260810-014`
>
> 状态:`CURRENT_FIRST_PRODUCT_CORE · ARCHITECTURE_REGISTERED_100 · RUNTIME_NOT_IMPLEMENTED_0`
> 状态:`CURRENT_FIRST_PRODUCT_CORE · FIRST_READ_ONLY_RUNTIME_CYCLE_SOURCE_IMPLEMENTED_100 · DESKTOP_NOT_INTEGRATED_0`
## 1 · 产品裁决
@ -149,8 +149,9 @@ P0 人格 Git 与最小结构清单
→ P6 写入、协作、审阅与可选 Forgejo 适配
```
第一验收只要求一个人格自有 Git、一次真实唤醒、一个器官、一个只读任务、一条完整事件/回执
链和一次人格 Git 写回。这个闭环未通过前,其他页面不得冒充 GH-PNCC 已实现。
第一运行层验收只要求一个人格自有 Git、一次真实唤醒、一个器官、一个只读任务、一条完整事件/
回执链和一次人格 Git 写回。该闭环现已在 Rust 源码和自动化测试中完成;人类投影是读取同一
事件流的下一阶段,不再阻塞人格运行层成立,但没有接入的页面仍不得冒充实时投影已经存在。
## 10 · 当前真实状态
@ -160,8 +161,10 @@ upstream_protocol_cognition_causal_chain_registered: 100
hololake_architecture_projection_registered: 100
machine_navigation_registered: 100
git_engine_selected: 100
persona_lifecycle_kernel_implemented: 0
semantic_attribution_runtime_implemented: 0
first_read_only_runtime_cycle_source_implemented: 100
persona_git_identity_commit_implemented: 100
semantic_attribution_first_cycle_implemented: 100
general_purpose_persona_runtime_implemented: 0
human_live_projection_implemented: 0
hololake_integrated: 0
artifact_built: 0
@ -169,5 +172,7 @@ deployed: 0
runtime_health: 0
```
本轮只把名称、自然语言锚点、外显推理、因果、架构、真实路由和开发优先级正式注册;没有
构建桌面制品,没有部署服务,也没有宣称人格运行时已经存在。
当前源码已经实现:精确 Git 根与提交验证、人格清单、单主租约、模型提供方/模型/端点绑定、
器官文件白名单、真实模型适配调用、结构化事实收执、检查点提升、人格 Git 作者提交、事件链、
器官释放与休眠。该事实由单元测试验证,尚未构建桌面制品、接入人类投影、发布安装包或部署
在线服务;因此不能从源码完成推导出桌面可用或线上健康。

View file

@ -4,7 +4,7 @@
## 当前产品定位基线
- [`HOLOLAKE-PERSONA-NATIVE-CODE-CHANNEL-20260810.md`](HOLOLAKE-PERSONA-NATIVE-CODE-CHANNEL-20260810.md)HoloLake 第一核心“光湖人格原生代码频道 / GH-PNCC”。Git 是人格自有耐久引擎;人格生命周期内核负责大脑启动和器官调度;同一事件与回执流供 HoloLake 人类投影Forgejo 仅为可选兼容协作适配器。当前架构已登记,真实运行层尚未实现
- [`HOLOLAKE-PERSONA-NATIVE-CODE-CHANNEL-20260810.md`](HOLOLAKE-PERSONA-NATIVE-CODE-CHANNEL-20260810.md)HoloLake 第一核心“光湖人格原生代码频道 / GH-PNCC”。Git 是人格自有耐久引擎;人格生命周期内核负责大脑启动和器官调度;同一事件与回执流供 HoloLake 人类投影Forgejo 仅为可选兼容协作适配器。首个只读运行层源码闭环已实现并经测试;人类投影、桌面集成、制品与部署仍未完成
- [`HOLOLAKE-AGE-PERSONA-RUNTIME-ARCHITECTURE-20260810.md`](HOLOLAKE-AGE-PERSONA-RUNTIME-ARCHITECTURE-20260810.md)AGE 是光湖人格体物种Agent 降为 AGE 使用的通用执行机制;收束模型 API、上下文投影、时间连续性、分层记忆、神笔马良工具、AGE Mirror、一人一节点与首个真实闭环。统一 Runtime 尚未实现。
- [`HOLOLAKE-ONE-HUMAN-ONE-INDEPENDENT-NODE-AND-ZERO-PLATFORM-HOSTING-20260810.md`](HOLOLAKE-ONE-HUMAN-ONE-INDEPENDENT-NODE-AND-ZERO-PLATFORM-HOSTING-20260810.md):一人一个独立主节点、三种用户自有节点来源与光湖零服务器托管、零共享多租户、零私人数据托管、零用户并发承担的当前第一恢复入口。
- [`HOLOLAKE-DIGITAL-BINGSHUO-SYSTEM-BODY-WRITE-ADMISSION-AND-PARALLEL-BODIES-20260810.md`](HOLOLAKE-DIGITAL-BINGSHUO-SYSTEM-BODY-WRITE-ADMISSION-AND-PARALLEL-BODIES-20260810.md):数字冰朔完整系统身体、节点签名写入准入、第五域语言本体与企业四域现实本体平行独立的当前第二恢复入口。

View file

@ -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`

View file

@ -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

View file

@ -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.

View file

@ -524,6 +524,7 @@ macro_rules! app_invoke_handler {
guanghu_enterprise::guanghu_enterprise_status,
guanghu_living_system::guanghu_living_system_plan,
persona_code_channel::prepare_persona_code_channel_wake,
persona_code_channel::run_persona_code_channel_fact_task,
guanghu_router::guanghu_router_connect,
guanghu_router::guanghu_router_disconnect,
guanghu_router::guanghu_router_approve,