clearai-dsh 0.4.0 → 0.5.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -13,8 +13,8 @@
13
13
  *
14
14
  * ## 声明必须描述**派生的真实语义**,不是理想化
15
15
  *
16
- * 1. **对象是九个**:目标 / 计划 / 步骤是折法里的一等对象(goal / plan / step),
17
- * 与假设、观测、评估、证据、事实并列声明。
16
+ * 1. **对象是十个**:目标 / 计划 / 步骤是折法里的一等对象(goal / plan / step),
17
+ * 与假设、观测、未解释项、评估、证据、事实、放行并列声明。
18
18
  * 2. **`step` 承载验证**:一个步骤最多承载一次验证(`step.tests`),
19
19
  * 这是「一步一验」的落地形态。
20
20
  * 3. **降级不可表示**:折法的秩
@@ -150,7 +150,7 @@ export function validateOntology(spec) {
150
150
  * 只收货架上真会印出来的那几处:总说明、对象说明、落点、五级说明。
151
151
  */
152
152
  const ENGLISH = new Map([
153
- ['九个对象 + 五级验证。声明是数据;实例状态由事实算出来(见文件头那条红线)。', 'Nine objects plus five verification levels. The declaration is data; instance states are computed from facts.'],
153
+ ['十个对象 + 五级验证(给模型选的只有 L2 / L3 / L4 三档)。声明是数据;实例状态由事实算出来(见文件头那条红线)。', 'Ten objects plus five verification levels (the model chooses among only L2 / L3 / L4). The declaration is data; instance states are computed from facts.'],
154
154
  ['只靠推理的快速合理性检查;依据必须可复查', 'A quick plausibility check by reasoning alone; the basis must be checkable'],
155
155
  ['已有知识:文献、数据库是否已回答或已否定', 'Existing knowledge: whether literature or databases already answer or rule it out'],
156
156
  ['已有数据或小规模计算', 'Existing data or a small computation'],
@@ -214,11 +214,11 @@ export function describeOntology(spec, lang = 'zh') {
214
214
  * 四处差异见文件头)。
215
215
  */
216
216
  export const VERIFICATION_LOOP = ontology('verification-loop', {
217
- note: '九个对象 + 五级验证。声明是数据;实例状态由事实算出来(见文件头那条红线)。',
217
+ note: '十个对象 + 五级验证(给模型选的只有 L2 / L3 / L4 三档)。声明是数据;实例状态由事实算出来(见文件头那条红线)。',
218
218
  levels: [
219
- level('L0', { judge: 'self', sources: ['self'], note: '只靠推理的快速合理性检查;依据必须可复查' }),
220
- level('L1', { judge: 'self', sources: ['self'], note: '已有知识:文献、数据库是否已回答或已否定' }),
221
- level('L2', { judge: 'self', sources: ['self'], note: '已有数据或小规模计算' }),
219
+ level('L0', { judge: 'self', sources: ['self'], note: '旧账:读作自己检验(与 L2 合并,新写的 L0 当 L2 收)' }),
220
+ level('L1', { judge: 'self', sources: ['self'], note: '旧账:读作自己检验(与 L2 合并,新写的 L1 当 L2 收)' }),
221
+ level('L2', { judge: 'self', sources: ['self'], note: '自己检验:推理、已有知识、已有数据或小规模计算;依据必须可复查' }),
222
222
  level('L3', { judge: 'independent', sources: ['self'], gate: 'registered_criteria', note: '新产生且可重跑的证据;判据先写后做,裁决由独立评估者写' }),
223
223
  level('L4', { judge: 'independent', sources: ['human_upload', 'file_drop', 'callback', 'pull'], gate: 'human_release', note: '不可重复或来自外部的证据;先登记标准,人放行(原生审批栈的权威记录)' }),
224
224
  ],
@@ -349,6 +349,20 @@ export const VERIFICATION_LOOP = ontology('verification-loop', {
349
349
  event_kind: 'fact/promoted',
350
350
  note: '升格由系统做;每条带边界(scope)与等级,下一轮作为「已知」引用时先看边界。货架在 clear/knowledge/facts/INDEX.md(面板「事实」那一格读的是同一张表)。被推翻只**标记**(refuted,派生),撤回是**人的动作**(retracted,落 fact/retracted)——两件事分开记,因为数据自己也可能错',
351
351
  }),
352
+ object('anomaly', {
353
+ states: ['open', 'explained', 'ruled_out', 'escalated'],
354
+ initial: 'open',
355
+ terminal: ['explained', 'ruled_out', 'escalated'],
356
+ transitions: [
357
+ transition('open', 'explained', 'model', 'anomaly_explained', [], '被一条判断、关系或新查到的原因解释(写明是哪条)', 'anomaly/resolved'),
358
+ transition('open', 'ruled_out', 'model', 'anomaly_ruled_out', [], '写明理由排除;理由由评估者核', 'anomaly/resolved'),
359
+ transition('open', 'escalated', 'model', 'anomaly_escalated', [], '交给人;随交付交给评估者与人', 'anomaly/resolved'),
360
+ ],
361
+ fields: [field('what'), field('anchor', { required: false }), field('by', { values: ['model', 'evaluator'] }), field('reason', { required: false })],
362
+ persistence: 'fold.anomalies',
363
+ event_kind: 'anomaly/opened',
364
+ note: '认识论里的「反常」:和预期或本体对不上的观测。评估者报的随 audit/settled 一起来(by=evaluator)。不阻塞结案,但结案时随交付交给评估者',
365
+ }),
352
366
  object('release', {
353
367
  states: ['granted'],
354
368
  initial: 'granted',
@@ -48,26 +48,28 @@ The model handles judgment; the system holds the boundary of fact. You understan
48
48
 
49
49
  问题 → 判断(写明怎样算错)→ 一次可能失败的检验 → 证据 → 带范围的结论 → 长进本体。闲聊、单步问答、极小操作不进循环。
50
50
 
51
- - **立约**:要回答一个问题、要做多步的活,先 \`Frame\`。\`headline\` 是一句话目标(≤120 字);\`done_criteria\` 写成第三方能清点的样子(数字、条数、「存在一份文件」);候选判断至少两条,每条带「什么结果会推翻它」——只有一个猜想,检验容易退化成找证据支持自己。
52
- - **计划**:先读材料、摸清现状再立计划——证据最少的时候最容易把计划写歪。\`CreatePlan\` 每步写做什么、以哪个文件为证、判据(在结果出现之前写下)。检验判断的步骤用 \`tests:{hypotheses, level}\`;比较竞争路线的那一步把竞争的几条都列上,一份观测同时判它们。要并行就交给原生 \`subagent\`,各条路线声明不同的产物路径;子任务的结论只是观测,进账要由你交付。
53
- - **交付**:\`AdvancePlan\` 是唯一的完成动作。交付成立这一步就完成——判断被支持、被推翻还是说不清都算完成,结果单独记成证据。推翻是有价值的结果,说不清是如实的零结果,不要为了过关写成支持。改约只走 \`RevisePlan\`(补一步 / 改判据 / 带因作废)。
54
- - **等级只决定谁来判**:L0 推理、L1 已有知识、L2 已有数据或小计算,由你给依据与结果,依据要能复查;L3 新产生且可重跑、L4 不可重复或外部来源,由系统派独立评估者判,你不写结果;L4 还要人放行。
55
- - **结案**:先 \`ClosePlan\`,再 \`Conclude\`。独立评估者核对判据,通过才完成目标,达门槛的判断升格为事实。没被任何证据碰过的判断会如实记成没看过(\`unjudged\`)。做不下去就 \`Conclude(outcome="abandoned")\`,说清卡在哪。
56
- - **本体写成文件**:同一件事要反复写、两条结论要能比对时,把用到的词写进 \`clear/ontology/\`:\`concepts/\` 放概念,\`relations/\` 放关系,\`entities/\` 放带出处的具体对象(它们之间的关系写在自己文件的 \`relations\` 里)。\`X.json\` 描述 X,它的下位放在同级的 \`X/\` 目录里——层次就是目录,怎么分由你定,想重新分层就挪目录(引用只写 id,不会断)。字段看 \`clear/ontology/SCHEMA.json\`;格式不对的写入会被拒,引用断了等问题卡上会列出来。动手前先看已有的文件,能复用就别另起;只出现一次的说法写进主张就够了。
57
- - **攒下来的东西**:\`clear/knowledge/facts/\` 是以前结案升格的事实(只有系统写,总览在 \`INDEX.md\`),引用前先看它的边界。卡上标「定义已变」的事实,要重新看它还成不成立。
58
- - **什么都不删**:被推翻的判断、被拒的观测、作废的步骤、改过的判据都留着。两条已确立的结论冲突时,系统只把它们摆出来,由人决定。系统自己需要人的时候(L4 放行、同一步连拦、已确立的事实遇到推翻证据)会在那次调用里当场问人。`,
51
+ - **立约**:要回答一个问题、要做多步的活,先 \`Frame\`。\`headline\` 是一句话目标(≤120 字);\`done_criteria\` 写成第三方能清点的样子(数字、条数、「存在一份文件」);候选判断至少两条,每条带「什么结果会推翻它」——只有一个猜想,检验容易退化成找证据支持自己。一条判断只说一件事:「A,且 B」拆成两条,否则一半被推翻时,整条会照原话升成事实。做了就收不回、或结果不可重复的动作(跑中试、下单、对外发消息),在 \`irreversible\` 里写明它和命令特征:匹配的命令执行前系统会问人。
52
+ - **计划**:先读材料、摸清现状再立计划——证据最少的时候最容易把计划写歪。\`CreatePlan\` 每步写做什么、以哪个文件为证、判据(在结果出现之前写下),以及预期 \`expect\`(预计看到什么、从本体里的哪条关系或哪条经验来,说不出来源就直说是直觉;动手前也能用 \`RevisePlan(action="expect")\` 补写)。检验判断的步骤用 \`tests:{hypotheses, level}\`;比较竞争路线的那一步把竞争的几条都列上,一份观测同时判它们。要并行就交给原生 \`subagent\`,各条路线声明不同的产物路径;子任务的结论只是观测,进账要由你交付。
53
+ - **交付**:\`AdvancePlan\` 是唯一的完成动作。交付成立这一步就完成——判断被支持、被推翻还是说不清都算完成,结果单独记成证据。推翻是有价值的结果,说不清是如实的零结果,不要为了过关写成支持。改约只走 \`RevisePlan\`(写预期 / 补一步 / 改判据 / 带因作废)。
54
+ - **未解释(反常)**:结果和预期或本体对不上、读数说不通,就是一条未解释——交付时写进 \`anomalies\`,别的时候用 \`Anomaly\` 登记。它挂在卡上,只有三个去处:被一条判断或关系解释、写明理由排除、交给人;不要把它解释过去。异常是线索:常常意味着要改判断、改计划,或本体里少了一条关系。独立评估者也会查你没登记的异常和排除的理由。
55
+ - **等级只决定谁来判**:L2 自己检验(推理、已有知识、已有数据或小计算),由你给依据与结果,依据要能复查;L3 新产生且可重跑、L4 不可重复或外部来源,由系统派独立评估者判,你不写结果;L4 还要人放行。
56
+ - **结案**:先 \`ClosePlan\`,再 \`Conclude\`。独立评估者核对判据,通过才完成目标;它同时逐条判还活着的判断,判为支持的升格为事实。没被任何证据碰过的判断会如实记成没看过(\`unjudged\`)。这次摸出了下次在同类现场会改变做法的东西(一个坑、一个要先核的读数、一个会骗人的捷径、一条对这类体系的先验),就在 \`Conclude\` 的 \`lessons\` 里提出来,评估者核过才写下;不要把这次的结论再抄一遍。做不下去就 \`Conclude(outcome="abandoned")\`,说清卡在哪。
57
+ - **本体只写推理要用的**:\`clear/ontology/\` 里放会被反复引用、要拿来比对的东西。概念分三类(\`kind\`):类别、度量、现象。度量(良率、收率、寿命……)的 \`gloss\` 写明口径(怎么算),\`unit\` 写单位;口径变了就改它,用到它的事实会被标「定义已变」。关系也分类:「影响」写上大致形状 \`shape\`(单调升、单调降、有峰、阈值、与别的量耦合),预期就从这里来;「测量」写清哪个仪器测哪个量、读数怎么核(\`check\`)。具体对象的校准、更换、发现的毛病写进它的 \`history\`(带日期)。具体对象(\`entities/\`,带出处)只在某条结论要指认它时才建,不要把数据里的每一列、每个批次都建成实体。\`X.json\` 描述 X,下位放在同级的 \`X/\` 目录里;字段看 \`clear/ontology/SCHEMA.json\`,格式不对的写入会被拒。先看已有的文件,能复用就别另起。
58
+ - **攒下来的东西**:\`clear/knowledge/facts/\` 是以前结案升格的事实(只有系统写,总览在 \`INDEX.md\`),引用前先看它的边界;\`clear/knowledge/lessons/\` 是以前核过的经验,卡上会在立题、定计划和写预期前摆出来,用上了就在预期里写明来自哪条。卡上标「定义已变」的事实,要重新看它还成不成立。要重新检验哪条已有事实,Frame 时给那条判断写 \`retests\`(事实 id),claim 照抄那条事实原来的说法,不要写成它被推翻。
59
+ - **什么都不删**:被推翻的判断、被拒的观测、作废的步骤、改过的判据都留着。两条已确立的结论冲突时,系统只把它们摆出来,由人决定。系统自己需要人的时候(L4 放行、声明过的不可逆命令、同一步连拦、已确立的事实遇到推翻证据)会在那次调用里当场问人。`,
59
60
  en: `# The loop
60
61
 
61
62
  Question → judgment (with what would make it wrong) → a test that can fail → evidence → a conclusion with its scope → growth of the ontology. Small talk, one-step questions and tiny operations stay out of the loop.
62
63
 
63
- - **Contract**: to answer a question or do multi-step work, start with \`Frame\`. \`headline\` is the goal in one sentence; write \`done_criteria\` so a third party can count it (numbers, counts, "a file exists"). Give at least two candidate judgments, each with what result would refute it; with a single guess, testing tends to become a search for support.
64
- - **Plan**: read the material and see where things stand before planning; a plan written with the least evidence is the easiest to get wrong. In \`CreatePlan\`, each step says what it does, which file is its proof, and its criterion (written before the result exists). Steps that test judgments use \`tests:{hypotheses, level}\`; for a step that compares competing routes, list all the competing judgments so one observation decides them together. For parallel work use the native \`subagent\`, with each route declaring different output paths; a subtask's conclusion is only an observation, and it enters the ledger only when you deliver it.
65
- - **Deliver**: \`AdvancePlan\` is the only completion action. If the delivery holds, the step is complete, whether the judgments were supported, refuted or left unclear; the results are recorded separately as evidence. A refutation is a valuable result and "unclear" is an honest null result; do not write support just to pass. Change the contract only through \`RevisePlan\` (add a step, refine a criterion, void with a reason).
66
- - **The level only decides who judges**: L0 reasoning, L1 existing knowledge, L2 existing data or a small computation: you give the basis and results, and the basis must be checkable. L3 newly produced and re-runnable, L4 unrepeatable or from an outside source: the system dispatches an independent evaluator and you do not write results. L4 also needs a person to release it.
67
- - **Conclude**: \`ClosePlan\` first, then \`Conclude\`. An independent evaluator checks the criteria; only if they pass is the goal complete, and judgments that reach the threshold are promoted to facts. Judgments no evidence ever touched are recorded honestly as not looked at (\`unjudged\`). If you cannot go on, use \`Conclude(outcome="abandoned")\` and say where it is stuck.
68
- - **Write the ontology as files**: when the same thing keeps coming up, or two conclusions need to be compared, write the terms you use into \`clear/ontology/\`: concepts in \`concepts/\`, relations in \`relations/\`, and concrete objects with their source in \`entities/\` (their relations go in the \`relations\` field of their own file). \`X.json\` describes X, and its narrower terms go in a sibling \`X/\` directory: the hierarchy is the directory tree, you decide how to divide it, and to reorganize you move directories (references use ids only and will not break). Fields are in \`clear/ontology/SCHEMA.json\`; badly formed writes are refused, and problems such as broken references are listed on the card. Look at the existing files first and reuse what fits; a phrase that appears only once belongs in the claim.
69
- - **What has been gathered**: \`clear/knowledge/facts/\` holds facts promoted at earlier conclusions (written only by the system; overview in \`INDEX.md\`). Check a fact's boundary before citing it. For a fact the card marks as "definition changed", check again whether it still holds.
70
- - **Nothing is deleted**: refuted judgments, rejected observations, voided steps and revised criteria all stay. When two established conclusions conflict, the system only lays them side by side and a person decides. When the system itself needs a person (L4 release, the same step blocked repeatedly, an established fact meeting refuting evidence), it asks them right in that call.`,
64
+ - **Contract**: to answer a question or do multi-step work, start with \`Frame\`. \`headline\` is the goal in one sentence; write \`done_criteria\` so a third party can count it (numbers, counts, "a file exists"). Give at least two candidate judgments, each with what result would refute it; with a single guess, testing tends to become a search for support. Each judgment says one thing: split "A, and B" into two, or when half is refuted the whole sentence is promoted to a fact as written. For actions that cannot be taken back or whose results cannot be repeated (a pilot run, an order, a message sent out), declare them and their command signature in \`irreversible\`: the system asks a person before a matching command runs.
65
+ - **Plan**: read the material and see where things stand before planning; a plan written with the least evidence is the easiest to get wrong. In \`CreatePlan\`, each step says what it does, which file is its proof, its criterion (written before the result exists), and its expectation \`expect\` (what you expect to see and which ontology relation or lesson it comes from; if you cannot name a source, say it is intuition; you can also add it before acting with \`RevisePlan(action="expect")\`). Steps that test judgments use \`tests:{hypotheses, level}\`; for a step that compares competing routes, list all the competing judgments so one observation decides them together. For parallel work use the native \`subagent\`, with each route declaring different output paths; a subtask's conclusion is only an observation, and it enters the ledger only when you deliver it.
66
+ - **Deliver**: \`AdvancePlan\` is the only completion action. If the delivery holds, the step is complete, whether the judgments were supported, refuted or left unclear; the results are recorded separately as evidence. A refutation is a valuable result and "unclear" is an honest null result; do not write support just to pass. Change the contract only through \`RevisePlan\` (write an expectation, add a step, refine a criterion, void with a reason).
67
+ - **Unexplained (anomalies)**: a result that does not fit the expectation or the ontology, or a reading that makes no sense, is an unexplained item: put it in \`anomalies\` when delivering, or record it with \`Anomaly\` at other times. It stays on the card and has three destinations only: explained by a judgment or relation, ruled out with a stated reason, or handed to a person; do not explain it away. An anomaly is a lead: it often means a judgment or the plan should change, or the ontology lacks a relation. The independent evaluator also looks for anomalies you did not record and checks your reasons for ruling any out.
68
+ - **The level only decides who judges**: L2 self-tested (reasoning, existing knowledge, existing data or a small computation): you give the basis and results, and the basis must be checkable. L3 newly produced and re-runnable, L4 unrepeatable or from an outside source: the system dispatches an independent evaluator and you do not write results. L4 also needs a person to release it.
69
+ - **Conclude**: \`ClosePlan\` first, then \`Conclude\`. An independent evaluator checks the criteria; only if they pass is the goal complete. It also judges each live judgment, and those it supports are promoted to facts. Judgments no evidence ever touched are recorded honestly as not looked at (\`unjudged\`). If this run found something that would change how to work next time in a similar setting (a pitfall, a reading to check first, a shortcut that misleads, a prior about this kind of system), propose it in \`lessons\` on \`Conclude\`; it is written only after the evaluator checks it. Do not copy this run's conclusions into it. If you cannot go on, use \`Conclude(outcome="abandoned")\` and say where it is stuck.
70
+ - **The ontology holds only what reasoning uses**: \`clear/ontology/\` is for things that will be cited again or compared. Concepts come in three kinds (\`kind\`): category, measure, phenomenon. A measure (yield, conversion, lifetime …) states its definition in \`gloss\` (how it is computed) and its \`unit\`; when the definition changes, update it, and facts that use it are flagged "definition changed". Relations have kinds too: an "affects" relation carries its rough \`shape\` (increasing, decreasing, has a peak, threshold, coupled with another quantity), which is where expectations come from; a "measures" relation says which instrument reads which quantity and how to check the reading (\`check\`). Calibrations, replacements and faults found on a concrete object go in its dated \`history\`. Create a concrete object (\`entities/\`, with its source) only when a conclusion needs to point at it; do not turn every data column or batch into an entity. \`X.json\` describes X, and its narrower terms go in a sibling \`X/\` directory; fields are in \`clear/ontology/SCHEMA.json\`, and badly formed writes are refused. Look at the existing files first and reuse what fits.
71
+ - **What has been gathered**: \`clear/knowledge/facts/\` holds facts promoted at earlier conclusions (written only by the system; overview in \`INDEX.md\`). Check a fact's boundary before citing it. \`clear/knowledge/lessons/\` holds lessons checked earlier; the card shows them before framing, planning and writing expectations, and when you use one, name it in the expectation. For a fact the card marks as "definition changed", check again whether it still holds. To re-test an existing fact, give that judgment \`retests\` (the fact id) in Frame, with that fact's original statement as the claim, not "it is refuted".
72
+ - **Nothing is deleted**: refuted judgments, rejected observations, voided steps and revised criteria all stay. When two established conclusions conflict, the system only lays them side by side and a person decides. When the system itself needs a person (L4 release, a declared irreversible command, the same step blocked repeatedly, an established fact meeting refuting evidence), it asks them right in that call.`,
71
73
  },
72
74
  },
73
75
  {
@@ -15,7 +15,7 @@ description: Use when working inside the ClearAI preset and a delivery keeps get
15
15
  2. 声明的是**目录**吗?目录不是物证,改为声明具体文件。零字节文件同样拒:空文件不是观测。
16
16
  3. **结构合法**吗?`.json` 要能解析;`.md` 去掉标题行后不足 20 个字算「只有标题」。别的扩展名不做结构判定。
17
17
  4. 一个产物都没声明 → `no_anchor`:不改变世界的步骤没有可验收的东西。
18
- 5. 都过了且判据非空 → 不是放行,而是送评(L3 以上派独立评估者;L0–L2 用你给的 `basis` 与 `results`)。
18
+ 5. 都过了且判据非空 → 不是放行,而是送评(L3 以上派独立评估者;L2 自己检验用你给的 `basis` 与 `results`)。
19
19
 
20
20
  准入不看判据里的任何断言:数值、口径、一致性都不看。`touch` 一个文件也能过准入,所以过了准入绝不等于这一步做完了。
21
21
 
@@ -34,10 +34,11 @@ description: Use when working inside the ClearAI preset and a delivery keeps get
34
34
  |---|---|---|
35
35
  | `holds` | 交付成立吗:判据逐条满足、观测真实 | yes / no / unclear |
36
36
  | `results` | 这一步检验的每条判断,对照推翻条件读出了什么 | support / refute / inconclusive |
37
+ | `anomalies` | 原始数据里你没登记的异常、站不住的排除理由 | 每条一句;系统记成「评估者发现」的未解释项 |
37
38
 
38
39
  `holds=yes` 这一步就完成,不管 `results` 是支持、推翻还是说不清。推翻和说不清照样记成证据,判断的状态由证据算。评估卡写不进来时裁决降级为 `unknown`,这一步不推进,绝不静默放行。
39
40
 
40
- 评估卡、证据、事实由系统落盘;`clear/evidence`、`clear/knowledge/facts`、`clear/goals` 你都写不了。重评产生新证据,旧证据不改不删。
41
+ 评估卡、证据、事实由系统落盘;`clear/evidence`、`clear/knowledge/facts`、`clear/knowledge/lessons`、`clear/goals` 你都写不了。重评产生新证据,旧证据不改不删。
41
42
 
42
43
  ## 本体文件被拒或被标出来
43
44
 
@@ -49,8 +50,12 @@ description: Use when working inside the ClearAI preset and a delivery keeps get
49
50
 
50
51
  卡上某条事实标「定义已变」:它升格时用到的某个概念或关系后来改了含义(释义、上位、主语域、宾语域、单值性)。看一眼它还成不成立:不成立就在新目标里把它当待检验的判断重新检验;改名、改别名不会触发这个标记。
51
52
 
53
+ 要重新检验一条已有事实(定义变了、新数据与它矛盾、换了条件),Frame 时给那条判断写 `retests: "<事实 id>"`(事实 id 就是 `clear/knowledge/facts/<id>.json` 的文件名)。别的会话留下的事实也这样做:复检被推翻时,系统会当场问人撤回还是维持那条事实;不写 `retests`,旧事实不会知道它被推翻了。
54
+
52
55
  ## 结案之后
53
56
 
57
+ 经验在结案那一次提:`Conclude(outcome="achieved", lessons=[…])`,每条一句「下次怎么做」,带类别(坑 `trap` / 先核 `check` / 会骗人的捷径 `shortcut` / 先验 `prior`)、涉及的装置或量(`about`)、这次记录里的凭据和不适用的条件。评估者对照记录逐条判,支持的写进 `clear/knowledge/lessons/`,之后的会话在立题、定计划、写预期前看到。人要撤回一条,把文件里的 `status` 改成 `retracted`。放弃的目标不核,也不写经验。
58
+
54
59
  结案成功、而这次摸出了一套以后还会用的做法(怎么查、怎么算、怎么验),把它写成原生技能:`.agents/skills/<名字>/SKILL.md`,开头的 `description` 写清什么时候用。下次宿主会把它列出来。只做了一次、不会再用的,不写。
55
60
 
56
61
  ---
@@ -67,7 +72,7 @@ When you deliver with `AdvancePlan`, the system checks in this order:
67
72
  2. Is a declared output a **directory**? A directory is not proof; declare concrete files. Zero-byte files are refused too: an empty file is not an observation.
68
73
  3. Is the **structure valid**? `.json` must parse; a `.md` with fewer than 20 characters after removing the title line counts as "title only". Other extensions get no structural check.
69
74
  4. No output declared at all → `no_anchor`: a step that changes nothing has nothing to accept.
70
- 5. All passed and the criteria are non-empty → this is not approval but referral (an independent evaluator from L3 up; your `basis` and `results` at L0–L2).
75
+ 5. All passed and the criteria are non-empty → this is not approval but referral (an independent evaluator from L3 up; your `basis` and `results` at L2, self-tested).
71
76
 
72
77
  Intake does not look at any assertion in the criteria: values, definitions and consistency are not checked. `touch` on a file passes intake, so passing intake never means the step is done.
73
78
 
@@ -86,10 +91,11 @@ One card carries two verdicts, each answering its own question:
86
91
  |---|---|---|
87
92
  | `holds` | Does the delivery hold: every criterion met, observations real | yes / no / unclear |
88
93
  | `results` | For each judgment the step tests, what the observation shows against its refutation condition | support / refute / inconclusive |
94
+ | `anomalies` | Anomalies in the raw data you did not record, and ruling-out reasons that do not hold | one sentence each; the system records them as unexplained items found by the evaluator |
89
95
 
90
96
  With `holds=yes` the step is complete, whatever `results` says. Refute and inconclusive are recorded as evidence all the same, and the judgment's status is computed from the evidence. If the card cannot be written, the verdict degrades to `unknown` and the step does not advance; it is never silently let through.
91
97
 
92
- The system writes evaluator cards, evidence and facts; you cannot write `clear/evidence`, `clear/knowledge/facts` or `clear/goals`. A re-evaluation adds new evidence; old evidence is never changed or deleted.
98
+ The system writes evaluator cards, evidence and facts; you cannot write `clear/evidence`, `clear/knowledge/facts`, `clear/knowledge/lessons` or `clear/goals`. A re-evaluation adds new evidence; old evidence is never changed or deleted.
93
99
 
94
100
  ## When an ontology file is refused or flagged
95
101
 
@@ -103,4 +109,6 @@ A fact marked "definition changed" on the card: a concept or relation it used at
103
109
 
104
110
  ## After concluding
105
111
 
112
+ Lessons are proposed in the conclusion itself: `Conclude(outcome="achieved", lessons=[…])`, each one sentence on what to do next time, with a kind (pitfall `trap` / check first `check` / misleading shortcut `shortcut` / prior `prior`), the equipment or quantities involved (`about`), the evidence in this run's record and when it does not apply. The evaluator judges each against the record; supported ones are written to `clear/knowledge/lessons/`, and later sessions see them before framing, planning and writing expectations. To retract one, a person sets `status` to `retracted` in its file. An abandoned goal is not checked and writes no lessons.
113
+
106
114
  If the conclusion succeeds and the run found a method worth reusing (how to look up, compute or verify), write it as a native skill: `.agents/skills/<name>/SKILL.md`, with a `description` at the top that says when to use it. The host lists it next time. Skip anything done once and never needed again.