# 信息存储体系 ## 1. 目标 信息存储体系的目标是把分散信息沉淀成可复查、可连接、可迁移的信息拓扑。 核心要求: ```text 能存数据库的尽量存数据库。 每张表都要能把枝叶串起来。 暗线必须分层。 事件也必须分层。 所有证据能回到原始来源。 所有判断能保留版本。 ``` ## 2. 存储分层 | 层 | 内容 | 主表 | | --- | --- | --- | | 原始来源层 | 原文、链接、文件、时间、hash | source_document | | 事件节点层 | 现实发生的事件 | event_node | | 暗线假设层 | 反推意图和目标 | darkline_hypothesis | | 应有之线层 | 如果暗线为真应发生什么 | expected_line | | 证据链层 | 证据和节点的多对多关系 | evidence, evidence_node_link | | 影响对象层 | 暗线影响什么对象 | impact_target | | 显影层 | 输出层是否出现预期变化 | manifestation_bridge | | 替代解释层 | 其他可能解释 | alternative_explanation | | 状态层 | 链路状态和置信度变化 | chain_state | ## 3. ID 原则 ID 必须稳定,不依赖可变标题。 建议: ```text source_id = hash(source_url_or_path + publish_time + source_title_normalized) event_node_id = hash(event_type + actor_key + target_key + event_date + source_id) darkline_hypothesis_id = hash(inferred_intention_key + actor_type + target_scope + version) expected_line_id = hash(darkline_hypothesis_id + expected_event_key + expected_window) evidence_id = hash(source_id + raw_excerpt_hash) bridge_id = hash(darkline_hypothesis_id + impact_target_id + output_layer + manifestation_time) ``` 展示名、摘要、标题可以变,不能当唯一主键。 ## 4. 版本原则 任何判断更新都不能覆盖旧判断。 必须新增版本: ```text AI_PREREVIEW_V1 AI_CHART_REVIEW_V1 OBSERVER_REVIEW_V1 USER_FEEDBACK_V1 RULE_IMPLICATION_V2 ``` 至少记录: ```text old_status new_status change_reason changed_by changed_at evidence_id ``` ## 5. 数据库优先 长期资产优先入数据库。 文件系统只作为: ```text 原始文件仓库 导出快照 图表附件 manifest 人工阅读文档 ``` 数据库负责: ```text 主键 去重 查询 关联 版本 状态 复核 ``` ## 6. 文件归档 每轮任务至少输出: ```text source_snapshot/ clean_table/ readout.md summary.json manifest.csv ``` manifest 最低字段: ```text artifact_id artifact_type relative_path row_count byte_size sha256 schema_version artifact_status created_at ``` ## 7. 状态枚举 推荐状态: ```text READY REVIEW HELD_BY_DATA_GAP HELD_BY_EVIDENCE_GAP HELD_BY_TIME_ANCHOR_GAP REJECTED SUPERSEDED DEPRECATED ``` 状态要分账: ```text 事件节点状态 现实验证状态 输出显影状态 链路清晰状态 消费等级状态 ``` 不能混成一个大字段。 ## 8. 案例数据最小入库层 案例是 darkline 的常用复核资产,不能只留 Markdown。 最小入库表: ```text dl_case_import_batch dl_case_record dl_darkline_hypothesis dl_chain_state ``` 对应说明: ```text data_contract/案例数据入库说明.md casebook/案例数据入口说明.md ``` 规则: - `dl_case_record` 保留案例正文快照和 hash。 - `dl_darkline_hypothesis` 保留暗线假设入口。 - `dl_chain_state` 保留当前验证状态和消费等级。 - 历史导入案例默认 `LEGACY_IMPORTED_REVIEW`,复用前必须重新复核。