@dtmd/temper 0.0.4 → 0.0.6

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.
Files changed (84) hide show
  1. package/README.md +10 -12
  2. package/dist/src/assembly.d.ts +32 -16
  3. package/dist/src/assembly.js +11 -10
  4. package/dist/src/builtins.d.ts +104 -40
  5. package/dist/src/builtins.js +130 -53
  6. package/dist/src/claude-code.d.ts +7 -9
  7. package/dist/src/claude-code.js +6 -8
  8. package/dist/src/contract.d.ts +47 -24
  9. package/dist/src/contract.js +35 -9
  10. package/dist/src/declarations.d.ts +25 -103
  11. package/dist/src/declarations.js +311 -47
  12. package/dist/src/emit.d.ts +13 -32
  13. package/dist/src/emit.js +136 -53
  14. package/dist/src/generated/AssemblyFactRow.d.ts +29 -0
  15. package/dist/src/generated/AssemblyFactRow.js +2 -0
  16. package/dist/src/generated/BoundRow.d.ts +14 -0
  17. package/dist/src/generated/BoundRow.js +2 -0
  18. package/dist/src/generated/CharsetRow.d.ts +15 -0
  19. package/dist/src/generated/CharsetRow.js +2 -0
  20. package/dist/src/generated/ClauseRow.d.ts +97 -0
  21. package/dist/src/generated/ClauseRow.js +1 -0
  22. package/dist/src/generated/CollectionEntryRow.d.ts +23 -0
  23. package/dist/src/generated/CollectionEntryRow.js +2 -0
  24. package/dist/src/generated/CollectionEntryWire.d.ts +17 -0
  25. package/dist/src/generated/CollectionEntryWire.js +2 -0
  26. package/dist/src/generated/CountBoundRow.d.ts +13 -0
  27. package/dist/src/generated/CountBoundRow.js +2 -0
  28. package/dist/src/generated/Declarations.d.ts +72 -0
  29. package/dist/src/generated/Declarations.js +1 -0
  30. package/dist/src/generated/DegreeBoundRow.d.ts +15 -0
  31. package/dist/src/generated/DegreeBoundRow.js +1 -0
  32. package/dist/src/generated/EdgeBoundRow.d.ts +13 -0
  33. package/dist/src/generated/EdgeBoundRow.js +2 -0
  34. package/dist/src/generated/EmbeddedMember.d.ts +45 -0
  35. package/dist/src/generated/EmbeddedMember.js +1 -0
  36. package/dist/src/generated/EmbeddedMemberCollectionEntry.d.ts +21 -0
  37. package/dist/src/generated/EmbeddedMemberCollectionEntry.js +1 -0
  38. package/dist/src/generated/FeatureValue.d.ts +23 -0
  39. package/dist/src/generated/FeatureValue.js +1 -0
  40. package/dist/src/generated/Features.d.ts +82 -0
  41. package/dist/src/generated/Features.js +1 -0
  42. package/dist/src/generated/FencedBlock.d.ts +24 -0
  43. package/dist/src/generated/FencedBlock.js +2 -0
  44. package/dist/src/generated/IncludeRow.d.ts +18 -0
  45. package/dist/src/generated/IncludeRow.js +2 -0
  46. package/dist/src/generated/KindFactRow.d.ts +51 -0
  47. package/dist/src/generated/KindFactRow.js +1 -0
  48. package/dist/src/generated/LayoutRegionRow.d.ts +29 -0
  49. package/dist/src/generated/LayoutRegionRow.js +2 -0
  50. package/dist/src/generated/LayoutRow.d.ts +12 -0
  51. package/dist/src/generated/LayoutRow.js +1 -0
  52. package/dist/src/generated/MentionRow.d.ts +17 -0
  53. package/dist/src/generated/MentionRow.js +2 -0
  54. package/dist/src/generated/NestedMemberRow.d.ts +39 -0
  55. package/dist/src/generated/NestedMemberRow.js +1 -0
  56. package/dist/src/generated/Payload.d.ts +25 -0
  57. package/dist/src/generated/Payload.js +1 -0
  58. package/dist/src/generated/PayloadMember.d.ts +31 -0
  59. package/dist/src/generated/PayloadMember.js +2 -0
  60. package/dist/src/generated/RangeBoundRow.d.ts +15 -0
  61. package/dist/src/generated/RangeBoundRow.js +2 -0
  62. package/dist/src/generated/RequirementRow.d.ts +40 -0
  63. package/dist/src/generated/RequirementRow.js +1 -0
  64. package/dist/src/generated/SatisfiesRow.d.ts +14 -0
  65. package/dist/src/generated/SatisfiesRow.js +2 -0
  66. package/dist/src/generated/Section.d.ts +21 -0
  67. package/dist/src/generated/Section.js +2 -0
  68. package/dist/src/generated/SectionContainsRow.d.ts +14 -0
  69. package/dist/src/generated/SectionContainsRow.js +2 -0
  70. package/dist/src/generated/ValueType.d.ts +9 -0
  71. package/dist/src/generated/ValueType.js +2 -0
  72. package/dist/src/generated/index.d.ts +29 -0
  73. package/dist/src/generated/index.js +1 -0
  74. package/dist/src/index.d.ts +14 -18
  75. package/dist/src/index.js +10 -13
  76. package/dist/src/kind.d.ts +163 -41
  77. package/dist/src/kind.js +24 -24
  78. package/dist/src/needs.d.ts +8 -8
  79. package/dist/src/needs.js +7 -7
  80. package/dist/src/prose.d.ts +75 -28
  81. package/dist/src/prose.js +0 -0
  82. package/package.json +1 -1
  83. package/dist/src/genres.d.ts +0 -38
  84. package/dist/src/genres.js +0 -24
package/README.md CHANGED
@@ -1,8 +1,8 @@
1
1
  # temper-sdk — the authoring face
2
2
 
3
3
  The typed module library the ratified corpus names as temper's authoring
4
- medium (`specs/intent/00-intent.md`, the SDK Decision; `specs/architecture/20-surface.md`,
5
- "The seam — one implementation"). A harness author composes members as typed
4
+ medium (`specs/intent.md`; `specs/model/pipeline.md`, "The SDK"). A harness
5
+ author composes members as typed
6
6
  values in the **six-noun model**; `emit` compiles the whole into the declaration
7
7
  rows the engine reads, a byte-faithful `.claude/**` projection, and the lock. The
8
8
  SDK implements **no semantics** — every type erases at the seam, and the engine
@@ -11,14 +11,15 @@ consumes only declared data, offline, no Node.
11
11
  ## The six-noun face
12
12
 
13
13
  - **`harness()`** — the assembly as one typed value: `members · expect ·
14
- require · settings` (`specs/architecture/40-composition.md`).
15
- - **`kind<T>()` / `genre<T>()`** — the engine room: a kind is a typed
14
+ require · settings` (`specs/model/pipeline.md`, "The SDK").
15
+ - **`kind<T>()`** — the engine room: a kind is a typed
16
16
  constructor plus five facts of runtime residue (label, locus, layout,
17
- registration, edge fields — `specs/architecture/15-kinds.md`). The built-in
18
- Claude Code kinds `rule` / `skill` / `memory` are ordinary `kind<T>()` values.
17
+ registration, edge fields — `specs/model/representation.md`). The built-in
18
+ Claude Code kinds `rule` / `skill` / `memory` are ordinary `kind<T>()` values;
19
+ an embedded child kind is the same constructor at the `embedded` locus.
19
20
  - **Clause values** — `clause(predicate, { severity, guidance, cite })` over the
20
21
  closed predicate algebra (`required`, `maxLines`, …); a floor is an exported
21
- clause array, adopted by spread in `expect` (`specs/architecture/10-contracts.md`).
22
+ clause array, adopted by spread in `expect` (`specs/model/contract.md`).
22
23
  - **`needs`** — the capabilities a member uses (`bash("git diff")`); emit derives
23
24
  the permission union, so a permission is never authored twice.
24
25
  - **`file()` / `` text`…` `` / `blocks()`** — the three prose constructors, one
@@ -26,7 +27,8 @@ consumes only declared data, offline, no Node.
26
27
 
27
28
  ## What `emit` produces
28
29
 
29
- One deterministic pass over the harness, double-emit verified (law 5):
30
+ One deterministic pass over the harness, double-emit verified
31
+ (`specs/model/pipeline.md`, "Emit"):
30
32
 
31
33
  - **Declaration rows** — the erased program (kind facts, clauses, requirements,
32
34
  assembly facts) on the internal versioned JSON pipe and in the lock's
@@ -43,12 +45,8 @@ projection on disk; the JSON pipe is in-flight, not a committed artifact.
43
45
 
44
46
  ## Stated bounds — each a named follow-on, never silently faked
45
47
 
46
- - **`blocks()` composes now, renders later** — the shared genre fence format is
47
- `(genre-fence-format)`, deferred until its first consumer; emit refuses to
48
- project a `blocks()` body until then.
49
48
  - **The permission union is carried as data** — the fold into the settings
50
49
  artifact lands with the hook/MCP kinds it folds many-to-one.
51
- - **Publish name/scope** pending the PACKAGING-CHANNELS ruling; `private: true`.
52
50
 
53
51
  ## Tests
54
52
 
@@ -1,26 +1,34 @@
1
1
  /**
2
- * The assembly — `harness()` takes the whole as one typed value
3
- * (`specs/architecture/40-composition.md`): `Harness = members · expect · require ·
4
- * settings`. Like every SDK type it erases at the seam the
5
- * engine never sees the constructor, only the declaration rows it compiles to
6
- * (`20-surface.md`). There is no second authoring surface: no `temper.toml`, no
7
- * roster/bindings dialect (the Decision rejects both); composing partial
8
- * harnesses is ordinary code.
2
+ * The assembly — `harness()` takes the whole as one typed value: `Harness =
3
+ * members · expect · require · settings · mode`. Like every SDK type it
4
+ * erases at the seam the engine never sees the constructor, only the
5
+ * declaration rows it compiles to. There is no second authoring surface: no
6
+ * `temper.toml`, no roster/bindings dialect (the Decision rejects both);
7
+ * composing partial harnesses is ordinary code.
9
8
  */
10
9
  import type { Member, KindDefinition } from "./kind.js";
11
10
  import type { Clause, Requirement } from "./contract.js";
12
11
  /**
13
- * One `expect` binding — universal: every member of `kind` owes these clauses
14
- * (`40-composition.md`). Keyed by the kind **value**, an import never a string;
15
- * binding is implicit — a floor is just a clause array spread into `clauses`.
12
+ * One `expect` binding — universal: every member of `kind` owes these clauses.
13
+ * Keyed by the kind **value**, an import never a string; binding is implicit
14
+ * — a floor is just a clause array spread into `clauses`.
16
15
  */
17
16
  export interface ExpectBinding {
18
- readonly kind: KindDefinition<object>;
17
+ readonly kind: KindDefinition<never>;
19
18
  readonly clauses: readonly Clause[];
20
19
  }
21
- /** The composed harness — the four fields, erased to rows at the seam. */
20
+ /**
21
+ * The declared enforcement-mode vocabulary — how firmly the `PreToolUse` guard
22
+ * binds a tool call, split by where the finding goes.
23
+ * `block`: denies the call.
24
+ * `warn` (default): allows the call and surfaces the finding in-band, into the
25
+ * live context. `note`: allows the call and records the finding out-of-band
26
+ * only — the next report, never the session.
27
+ */
28
+ export type EnforcementMode = "note" | "warn" | "block";
29
+ /** The composed harness — the root member's own fields, erased to rows at the seam. */
22
30
  export interface Harness {
23
- /** The member roster — the assembly's imports (`40-composition.md`, "`members`"). */
31
+ /** The member roster — the assembly's imports. */
24
32
  readonly members: readonly Member[];
25
33
  /** Universal clause bindings, keyed by kind value. */
26
34
  readonly expect: readonly ExpectBinding[];
@@ -28,15 +36,23 @@ export interface Harness {
28
36
  readonly require: Readonly<Record<string, Requirement>>;
29
37
  /** The residual harness-level settings with no member home (a shrinking list). */
30
38
  readonly settings: Readonly<Record<string, unknown>>;
39
+ /**
40
+ * The root member's declared enforcement mode — harness-wide, overridable
41
+ * per member. Defaults to `warn`: temper fabricates no enforcement the
42
+ * author did not declare.
43
+ */
44
+ readonly mode: EnforcementMode;
31
45
  }
32
46
  /**
33
- * Compose the harness from its four fields — ordinary code, Turing-completeness
34
- * quarantined at authoring time (`00-intent.md`, the SDK Decision). Absent
35
- * fields default empty; the member list is the only required part.
47
+ * Compose the harness from its five fields — ordinary code, Turing-completeness
48
+ * quarantined at authoring time. Absent
49
+ * fields default empty (`mode` defaults `warn`); the member list is the
50
+ * only required part.
36
51
  */
37
52
  export declare function harness(init: {
38
53
  members: readonly Member[];
39
54
  expect?: readonly ExpectBinding[];
40
55
  require?: Readonly<Record<string, Requirement>>;
41
56
  settings?: Readonly<Record<string, unknown>>;
57
+ mode?: EnforcementMode;
42
58
  }): Harness;
@@ -1,16 +1,16 @@
1
1
  /**
2
- * The assembly — `harness()` takes the whole as one typed value
3
- * (`specs/architecture/40-composition.md`): `Harness = members · expect · require ·
4
- * settings`. Like every SDK type it erases at the seam the
5
- * engine never sees the constructor, only the declaration rows it compiles to
6
- * (`20-surface.md`). There is no second authoring surface: no `temper.toml`, no
7
- * roster/bindings dialect (the Decision rejects both); composing partial
8
- * harnesses is ordinary code.
2
+ * The assembly — `harness()` takes the whole as one typed value: `Harness =
3
+ * members · expect · require · settings · mode`. Like every SDK type it
4
+ * erases at the seam the engine never sees the constructor, only the
5
+ * declaration rows it compiles to. There is no second authoring surface: no
6
+ * `temper.toml`, no roster/bindings dialect (the Decision rejects both);
7
+ * composing partial harnesses is ordinary code.
9
8
  */
10
9
  /**
11
- * Compose the harness from its four fields — ordinary code, Turing-completeness
12
- * quarantined at authoring time (`00-intent.md`, the SDK Decision). Absent
13
- * fields default empty; the member list is the only required part.
10
+ * Compose the harness from its five fields — ordinary code, Turing-completeness
11
+ * quarantined at authoring time. Absent
12
+ * fields default empty (`mode` defaults `warn`); the member list is the
13
+ * only required part.
14
14
  */
15
15
  export function harness(init) {
16
16
  return {
@@ -18,5 +18,6 @@ export function harness(init) {
18
18
  expect: init.expect ?? [],
19
19
  require: init.require ?? {},
20
20
  settings: init.settings ?? {},
21
+ mode: init.mode ?? "warn",
21
22
  };
22
23
  }
@@ -1,13 +1,13 @@
1
1
  /**
2
- * The built-in Claude Code kinds — the face nouns a harness author imports
3
- * (`specs/architecture/15-kinds.md`, "Built-in and custom kinds"). Each is an
2
+ * The built-in Claude Code kinds — the face nouns a harness author imports.
3
+ * Each is an
4
4
  * ordinary `kind<T>()` value built with the same constructor every provider uses
5
5
  * (ownership not privilege). Their five facts are external facts about the Claude
6
6
  * Code harness, cited at the point of claim.
7
7
  *
8
8
  * These are the SDK's own provider-face exports, surfaced through the
9
- * `@dtmd/temper/claude-code` subpath (`50-distribution.md`, "Decision: one SDK
10
- * package the provider face is a subpath export") — never from the root.
9
+ * `@dtmd/temper/claude-code` subpath
10
+ * — never from the root.
11
11
  */
12
12
  import type { KindDefinition } from "./kind.js";
13
13
  import type { Prose } from "./prose.js";
@@ -15,27 +15,67 @@ import type { Clause } from "./contract.js";
15
15
  /** A Claude Code skill — a directory whose entry file is `SKILL.md` with YAML frontmatter. */
16
16
  export interface Skill {
17
17
  /**
18
- * The description trigger — always in context; the body loads on invocation
19
- * (code.claude.com/docs/en/skills, retrieved 2026-07-02).
20
- */
18
+ * The description trigger — always in context; the body loads on invocation
19
+ * (code.claude.com/docs/en/skills, retrieved 2026-07-02).
20
+ */
21
21
  readonly description: string;
22
22
  /** The optional license field the skill spec carries (agentskills.io/specification). */
23
23
  readonly license?: string;
24
+ /**
25
+ * Set `true` to prevent Claude from automatically loading this skill — only
26
+ * the user-invoked channel stays live (code.claude.com/docs/en/skills,
27
+ * "Control who invokes a skill", retrieved 2026-07-07). Default: `false`.
28
+ */
29
+ readonly "disable-model-invocation"?: boolean;
30
+ /**
31
+ * Set `false` to hide the skill from the `/` menu — only the
32
+ * description-trigger channel stays live (code.claude.com/docs/en/skills,
33
+ * "Control who invokes a skill", retrieved 2026-07-07). Default: `true`.
34
+ */
35
+ readonly "user-invocable"?: boolean;
24
36
  readonly prose?: Prose;
25
37
  }
26
38
  /**
27
39
  * `skill` — `.claude/skills/<name>/SKILL.md`, a directory unit, YAML frontmatter
28
- * carrying `name` then `description`; registers a description trigger
40
+ * carrying `name` then `description`; registers on both documented invocation
41
+ * channels — user-invoked (`/name`) and description-trigger — modulated per
42
+ * member by the `disable-model-invocation`/`user-invocable` fields
29
43
  * (code.claude.com/docs/en/skills, agentskills.io/specification, retrieved
30
- * 2026-07-02).
44
+ * 2026-07-07).
31
45
  */
32
46
  export declare const skill: KindDefinition<Skill>;
47
+ /**
48
+ * `command` — `.claude/commands/*.md`, the skill surface's legacy file placement
49
+ * (Claude Code merged commands into skills; code.claude.com/docs/en/skills,
50
+ * retrieved 2026-07-07): a lone file (identity from the stem, so no
51
+ * `identityField` — like `rule`), the skill's field schema by import, registering
52
+ * on the same two documented invocation channels as `skill`.
53
+ */
54
+ export declare const command: KindDefinition<Skill>;
55
+ /** A Claude Code subagent definition. */
56
+ export interface Agent {
57
+ /**
58
+ * When Claude should delegate to this subagent — the sole registration
59
+ * channel (code.claude.com/docs/en/sub-agents, retrieved 2026-07-07).
60
+ */
61
+ readonly description: string;
62
+ readonly prose?: Prose;
63
+ }
64
+ /**
65
+ * `agent` — every markdown file under `.claude/agents`, discovered recursively (a
66
+ * containing subdirectory is purely organizational), YAML frontmatter carrying
67
+ * `name` then `description`; identity is the `name` field (never the filename),
68
+ * the named-field mode; registers on the description-trigger channel only — no
69
+ * user-invoked slash command (code.claude.com/docs/en/sub-agents, retrieved
70
+ * 2026-07-07).
71
+ */
72
+ export declare const agent: KindDefinition<Agent>;
33
73
  /** A Claude Code rule — a flat markdown file with an optional `paths` scope. */
34
74
  export interface Rule {
35
75
  /**
36
- * The path scope — a present list matching zero files is a dead edge; an absent
37
- * one loads unconditionally (code.claude.com/docs/en/memory, retrieved 2026-07-02).
38
- */
76
+ * The path scope — a present list matching zero files is a dead edge; an absent
77
+ * one loads unconditionally (code.claude.com/docs/en/memory, retrieved 2026-07-02).
78
+ */
39
79
  readonly paths?: readonly string[];
40
80
  readonly prose?: Prose;
41
81
  }
@@ -58,11 +98,10 @@ export interface Memory {
58
98
  */
59
99
  export declare const memory: KindDefinition<Memory>;
60
100
  /**
61
- * The floor for `skill` — Anthropic's documented skill contract: the Agent
101
+ * The default contract for `skill` — Anthropic's documented skill contract: the Agent
62
102
  * Skills open standard (agentskills.io), Anthropic's platform upload
63
- * validation, and Claude Code's own docs (`packages/skill.anthropic/PACKAGE.md`,
64
- * the curated authoring reference this migrates verbatim; `10-contracts.md`,
65
- * "named for its source"). All sources retrieved 2026-07-01.
103
+ * validation, and Claude Code's own docs.
104
+ * All sources retrieved 2026-07-09.
66
105
  *
67
106
  * Checks the strictest documented profile: the spec and upload validation are
68
107
  * hard, Claude Code's runtime is deliberately forgiving ("All fields are
@@ -74,7 +113,7 @@ export declare const memory: KindDefinition<Memory>;
74
113
  * description actually triggers well or reads third-person (semantic);
75
114
  * vagueness/no-op detection (semantic); gerund naming (judgment). Two
76
115
  * decidable spec rules are also absent, pending a vocabulary addition (a
77
- * narrow shape predicate — `10-contracts.md` governs additions): the name
116
+ * narrow shape predicate governs additions): the name
78
117
  * must not start/end with a hyphen or contain consecutive hyphens; likewise
79
118
  * the platform's "no XML tags in the description."
80
119
  *
@@ -85,12 +124,34 @@ export declare const memory: KindDefinition<Memory>;
85
124
  * that is not a command; `metadata` is the sanctioned home for versioning —
86
125
  * there is no top-level `version` field.
87
126
  */
88
- export declare const skillFloor: readonly Clause[];
127
+ export declare const skillDefaultContract: readonly Clause[];
128
+ /**
129
+ * The default contract for `command` — `skillDefaultContract`'s clauses minus `nameMatchesDir`: a
130
+ * command is a lone file with no parent directory to match, so the one clause
131
+ * that ranges over the directory relationship does not apply; every other
132
+ * documented skill-schema recommendation, name-requiredness included, still
133
+ * governs a command by the same import (code.claude.com/docs/en/skills,
134
+ * retrieved 2026-07-07).
135
+ */
136
+ export declare const commandDefaultContract: readonly Clause[];
137
+ /**
138
+ * The default contract for `agent` — Anthropic's documented subagent contract
139
+ * (code.claude.com/docs/en/sub-agents, retrieved 2026-07-07): `name` and
140
+ * `description` are the only required fields, `name` is a "unique identifier
141
+ * using lowercase letters and hyphens" (no digits, unlike a skill's `name`), and
142
+ * "keep `name` values unique across the whole tree" — a same-scope collision
143
+ * loads only one definition.
144
+ *
145
+ * Deliberately narrow, like `ruleDefaultContract`: undecidable properties (whether the
146
+ * description triggers well, model/permissionMode's semi-open vocabularies) stay
147
+ * out of the gate — the format documents little else that is decidable.
148
+ */
149
+ export declare const agentDefaultContract: readonly Clause[];
89
150
  /**
90
- * The floor for `rule` — Anthropic's documented contract for a Claude Code
151
+ * The default contract for `rule` — Anthropic's documented contract for a Claude Code
91
152
  * rules file, sourced from the memory docs (`.claude/rules/` landed in
92
153
  * v2.0.64; `packages/rule.anthropic/PACKAGE.md`, the curated authoring
93
- * reference this migrates verbatim). All sources retrieved 2026-07-01.
154
+ * reference this migrates verbatim). All sources retrieved 2026-07-09.
94
155
  *
95
156
  * `paths` is the one documented frontmatter key for rules: glob patterns
96
157
  * (brace expansion supported) that scope the rule to matching files. Rules
@@ -98,9 +159,9 @@ export declare const skillFloor: readonly Clause[];
98
159
  * rules load when Claude reads a matching file. Note skills now take a
99
160
  * `paths` key too — the two schemas are separate. (Guidance only: an
100
161
  * optional field asserts nothing decidable, so it carries no clause of its
101
- * own — `10-contracts.md`, "Judged at the node scope": `required` is the one
162
+ * own: `required` is the one
102
163
  * presence predicate, and its absence is not itself a predicate.)
103
- * https://code.claude.com/docs/en/memory#path-specific-rules (retrieved 2026-07-01)
164
+ * https://code.claude.com/docs/en/memory#path-specific-rules (retrieved 2026-07-09)
104
165
  *
105
166
  * What the clauses cannot carry, as guidance: keep a rule to facts Claude
106
167
  * should hold whenever the rule is in scope — concrete enough to verify ("use
@@ -112,18 +173,17 @@ export declare const skillFloor: readonly Clause[];
112
173
  * behavior drifts, and test a change by watching whether Claude's behavior
113
174
  * actually shifts.
114
175
  */
115
- export declare const ruleFloor: readonly Clause[];
176
+ export declare const ruleDefaultContract: readonly Clause[];
116
177
  /**
117
- * The floor for the qualified `claude-code.memory` kind — Anthropic's
178
+ * The default contract for the qualified `claude-code.memory` kind — Anthropic's
118
179
  * documented contract for a project `CLAUDE.md` (`packages/memory.anthropic/PACKAGE.md`,
119
- * the curated authoring reference this migrates verbatim). Retrieved 2026-07-02.
180
+ * the curated authoring reference this migrates verbatim). Retrieved 2026-07-09.
120
181
  *
121
182
  * Deliberately near-empty, because the format is: `CLAUDE.md` is plain
122
183
  * markdown with no documented frontmatter and no required fields
123
- * (code.claude.com/docs/en/memory, retrieved 2026-07-02), so there is no
184
+ * (code.claude.com/docs/en/memory, retrieved 2026-07-09), so there is no
124
185
  * schema to gate — manufacturing a required field or a forbidden-key list
125
- * would fake a check the format does not carry (`specs/intent/00-intent.md`,
126
- * law 3: decidable clauses only). The single clause is a context-cost
186
+ * would fake a check the format does not carry. The single clause is a context-cost
127
187
  * budget; everything else the contract could say is guidance.
128
188
  *
129
189
  * What the clauses cannot carry, as guidance: a `paths:` frontmatter block
@@ -141,23 +201,27 @@ export declare const ruleFloor: readonly Clause[];
141
201
  * directory, not below it. Personal, un-shared notes go in `CLAUDE.local.md`
142
202
  * (gitignored), appended after `CLAUDE.md` at its level.
143
203
  */
144
- export declare const memoryAnthropicFloor: readonly Clause[];
204
+ export declare const memoryAnthropicDefaultContract: readonly Clause[];
145
205
  /**
146
- * The floor for the qualified `agents-md.memory` kind — the AGENTS.md
206
+ * The default contract for the qualified `agents-md.memory` kind — the AGENTS.md
147
207
  * standard's contract for a memory file, which is that there is almost none
148
208
  * (`packages/memory.agents-md/PACKAGE.md`, the curated authoring reference
149
209
  * this migrates). Guidance-only, and that is the honest encoding: `AGENTS.md`
150
210
  * "is just standard Markdown" with no required fields, no sections, and no
151
- * frontmatter (agents.md, retrieved 2026-07-02); the format deliberately
152
- * constrains nothing. A floor that manufactured a required field, a size
211
+ * frontmatter (agents.md, retrieved 2026-07-09); the format deliberately
212
+ * constrains nothing. A default contract that manufactured a required field, a size
153
213
  * gate, or a forbidden-key list would assert a contract the standard
154
- * disclaims (`specs/intent/00-intent.md`, law 3). Even the tempting size
214
+ * disclaims. Even the tempting size
155
215
  * number is a *tool's* rule, not the format's: agents read the closest
156
- * `AGENTS.md` in the tree (nested, nearest-wins); Codex concatenates the
157
- * chain root-to-cwd and stops once combined size hits a byte budget, not a
158
- * per-file line count; Gemini CLI reads `GEMINI.md` by default and only
159
- * treats `AGENTS.md` as an alias when configured; Claude Code does not read
160
- * `AGENTS.md` natively — bridge it with a `CLAUDE.md` that
161
- * `@AGENTS.md`-imports it. All retrieved 2026-07-02.
216
+ * `AGENTS.md` in the tree (nested, nearest-wins; agents.md, retrieved
217
+ * 2026-07-09); Codex concatenates the chain root-to-cwd and stops once
218
+ * combined size hits a byte budget, not a per-file line count
219
+ * (`project_doc_max_bytes`, 32 KiB default;
220
+ * developers.openai.com/codex/guides/agents-md, retrieved 2026-07-09);
221
+ * Gemini CLI reads `GEMINI.md` by default and only treats `AGENTS.md` as an
222
+ * alias when configured via `context.fileName` (geminicli.com/docs/cli/gemini-md,
223
+ * retrieved 2026-07-09); Claude Code does not read `AGENTS.md` natively —
224
+ * bridge it with a `CLAUDE.md` that `@AGENTS.md`-imports it
225
+ * (code.claude.com/docs/en/memory, retrieved 2026-07-09).
162
226
  */
163
- export declare const memoryAgentsMdFloor: readonly Clause[];
227
+ export declare const memoryAgentsMdDefaultContract: readonly Clause[];