- Python 100%
Register dialogue_plan and scene_plan deterministic fields so relax_output_schema makes structural fields optional at the LLM boundary -- the model omits IDs, hashes, dramatic_turn_id, response_to_action_ids, voice/knowledge provenance, candidate_id, source hashes -- and the deterministic assemblers (_seed_action_draft_from_scene / _materialise_action_lines / scene assembly) materialize them after generation. Final validators stay strict post-assembly. Cuts the 140 structured-validation failures (weak LLM fills bad structural fields it can't produce reliably) by moving structure ownership to the harness. Dialogue(66)/scene(79)/semantic(8) tests pass. Co-Authored-By: Claude <noreply@anthropic.com> |
||
|---|---|---|
| .narrativeos | ||
| benchmarks | ||
| comparison-archive-2026-07-27 | ||
| config | ||
| docs | ||
| engine | ||
| evals | ||
| examples | ||
| kernel | ||
| narrativeos-reader-edition | ||
| prompts | ||
| release | ||
| reports | ||
| schema | ||
| templates/minimal_project | ||
| tests | ||
| .gitignore | ||
| AGENTS.md | ||
| CHECKSUMS.sha256 | ||
| CLAUDE.md | ||
| CONTRIBUTING.md | ||
| legacy_debt_report.json | ||
| LICENSE | ||
| MANIFEST.json | ||
| narrativeos.py | ||
| pyproject.toml | ||
| QUICKSTART.md | ||
| README.md | ||
| SECURITY.md | ||
| uv.lock | ||
| VERSION | ||
NarrativeOS 2.3
NarrativeOS 是一个图原生、审批门控、内容寻址、可审计的 LLM 叙事生产系统。
Creative Brief
→ Concept
→ Truth Architecture
→ Model Graph
→ Question Graph
→ Dynamic Season Plan
→ Episode IR
→ Scene IR
→ Character Voice / Dialogue
→ Repair / Selective Recompile
→ Evaluation / Security / Recovery / Release Audit
统一的 2.0 基线
Product Version: 2.3.0
Protocol Version: 2.0.0
Package Version: 2.3.0
Release Channel: stable
本发行包只有一套 2.0 协议、一条 Canonical 链路、一个 Prompt 根目录和一套 Release Audit。项目不会猜测或静默转换其他协议的数据。
核心原则
- LLM 只生成 Candidate IR;
- Candidate 必须通过 JSON Schema 与语义合同;
- Human Approval 是进入 Canonical State 的唯一入口;
- Canonical 采用 Merkle DAG:父节点只引用子节点 Hash;
- 审批日志采用独立 Hash Chain;
- 上游变化按依赖图精确失效下游;
- Repair 只能提交受限 Patch,先 Dry-run、Diff、验证,再审批;
- 云端适配器存在不等于真实云端已经验证;
- 没有真实评审响应时,不宣称人工偏好已经成立。
安装
pip install narrativeos-2.3.0-py3-none-any.whl
narrativeos init my-story
cd my-story
随后从 QUICKSTART.md 开始。
目录
engine/
├── architecture/
├── canonical/
├── cli/
├── core/
├── dialogue/
├── operations/
├── planning/
├── providers/
└── repair/
prompts/ 统一的 2.0 Prompt Packages
schema/ 2.0 JSON Schema 唯一源
config/ Provider 与 Release Audit 配置
benchmarks/ 100 Brief 基准语料
evals/ 盲测评审模板
examples/ 完整 Merkle Canonical 与 Repair 示例
docs/ 产品文档
reports/ 当前发行证据
release/ 当前发行说明与 Wheel
Canonical Merkle DAG
Production provider boundary (v2.3.0)
narrativeos workflow run requires at least one configured real provider. A
provider with type: "mock" is never accepted by the production workflow and
cannot be used as a silent fallback. Mock providers remain available only to
unit tests and offline release benchmarks. Configure credentials in
the user-level Provider config using api_key_env before starting generation.
On Windows the default path is %USERPROFILE%\\.narrativeos\\providers.json; set
NARRATIVEOS_PROVIDER_CONFIG to use another global file. Project-local
llm-config.json settings remain the base configuration and global providers
are overlaid without copying credentials into the project.
Canonical 不再由一个巨型状态文件承载。磁盘结构为:
canonical/
├── root.json
├── project.json
├── brief.json
├── architecture/
├── season/
├── episodes/
├── scenes/
├── dialogue/
├── repairs/
├── audit/
└── objects/
每个节点包含 node_hash、data_hash、refs 与 payload。修改单场对白只改变该对白、对应场景、对应单集组合节点与根节点;Architecture、Season 和无关单集 Hash 保持不变。
验证:
narrativeos canonical verify --project-dir .
正式输出
Architecture Package
Season Package
Episode Package
Story Package
Dialogue Package
Dialogue Draft
Repair Approval
Selective Recompile Plan
Editorial Quality Report
Revision Tasks
Release Audit
零债务门禁
narrativeos release debt-audit --project-dir .
正式发行要求:
Historical Debt Findings = 0
Flat Engine Modules = 0
Monolithic Canonical Nodes = 0
Schema Drift = 0
Prompt Root Drift = 0
Merkle Verification Errors = 0
文档入口
docs/architecture.mddocs/canonical-merkle.mddocs/planning.mddocs/dialogue.mddocs/repair.mddocs/providers.mddocs/evaluation.mddocs/security-recovery.mddocs/operations.mddocs/schema-index.md