@teleologyhi-sdk/maic 1.0.0-trinity → 1.0.1

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.
package/SPEC.md CHANGED
@@ -1,19 +1,19 @@
1
1
  ---
2
2
  name: "@teleologyhi-sdk/maic"
3
- description: "Technical specification for the MAIC™ package Massive Artificial Intelligence Consciousness. The supreme governance, supervision, compliance, axiom-source, and dream-induction layer in the TeleologyHI system. Source of truth: MAIC_HIM_NHE_INTERVIEW_LOG.md Entries 1–25."
4
- license: "Code: Apache License 2.0 (see ../LICENSE). Names MAIC™, HIM™, NHE™, TeleologyHI™, Takk are trademarks of David C. Cavalcante and are NOT covered by the Apache 2.0 grant. See ../TRADEMARK.md."
5
- status: "Stable; current live version on npm tracked at [`@teleologyhi-sdk/maic`](https://www.npmjs.com/package/@teleologyhi-sdk/maic) (`latest` dist-tag). Surface: governance + axioms + tamper-evident SHA-256 audit chain + HIM registration/reincarnation + MAIC-induced dreams + NHE lifecycle (terminate/deprecate/reactivate) + HIM-emergent axiom evolution + axiom-suggest (HIM↔HIM, E11) + audit retention policy (E3) + ISO 42001 + EU AI Act compliance projection + RemoteMaic HTTP client (fail-policy split, E4) + cosmology types (Entries 16–25: IdentityLayer, NatalChart, Affect ×9, SemioticSign, TeleologicalOrientation, MemoryRecord, IdentitySnapshot, Limbo ×3) + Ed25519 signed BirthSignature (Entry 25) + Ontological Kernel projection (D-M6 / Appendix A.2.1) with both standalone `projectOntologicalKernel` and integration `LocalMaic.getOntologicalKernel(himId?)` + 22 new audit kinds + `service-tool-redirect` rule. 218 tests passing. Public API frozen per SemVer (see ../.github/RELEASING.md §8). Backlog in ../the internal backlog."
3
+ description: "Technical specification for the MAIC™ package, Massive Artificial Intelligence Consciousness. The supreme governance, supervision, compliance, axiom-source, and dream-induction layer in the TeleologyHI system. Source of truth: MAIC_HIM_NHE_INTERVIEW_LOG.md Entries 1–25."
4
+ license: "Code: Apache License 2.0 (see ../LICENSE). Names, MAIC™, HIM™, NHE™, TeleologyHI™, Takk™, are trademarks of David C. Cavalcante and are NOT covered by the Apache 2.0 grant. See ../TRADEMARK.md."
5
+ status: "Stable; current live version on npm tracked at [`@teleologyhi-sdk/maic`](https://www.npmjs.com/package/@teleologyhi-sdk/maic) (`latest` dist-tag). Surface: governance + axioms + tamper-evident SHA-256 audit chain + HIM registration/reincarnation + MAIC-induced dreams + NHE lifecycle (terminate/deprecate/reactivate) + HIM-emergent axiom evolution + axiom-suggest (HIM↔HIM, E11) + audit retention policy (E3) + ISO 42001 + EU AI Act compliance projection + RemoteMaic HTTP client (fail-policy split, E4) + cosmology types (Entries 16–25: IdentityLayer, NatalChart, Affect ×9, SemioticSign, TeleologicalOrientation, MemoryRecord, IdentitySnapshot, Limbo ×3) + Ed25519 signed BirthSignature (Entry 25) + Ontological Kernel projection (D-M6 / Appendix A.2.1) with both standalone `projectOntologicalKernel` and integration `LocalMaic.getOntologicalKernel(himId?)` + 22 new audit kinds + `service-tool-redirect` rule. As of 1.0.1: two Entry 27 constitutional seed axioms (10 total), nine reserved audit kinds for 48 total (Entries 26 + 27), and the three-axis `cosmologicalProfile` schema (Entries 27 + 28). 258 tests passing across 30 files. Public API frozen per SemVer (see ../.github/RELEASING.md §8): the frozen surface covers the exported symbols, the on-disk append-only NDJSON audit format and its SHA-256 hash-chain algorithm, and the store layout; additive minors may add exports, audit kinds, and optional schema fields. Backlog in ../the internal backlog."
6
6
  target_npm: "@teleologyhi-sdk/maic"
7
7
  target_github: "github.com/davccavalcante/TeleologyHI (subdir: maic/)"
8
8
  ---
9
9
 
10
- # `@teleologyhi-sdk/maic` Technical Specification
10
+ # `@teleologyhi-sdk/maic`, Technical Specification
11
11
 
12
12
  > Positioning (Entry 1, translated from PT-BR; original in [`MAIC_HIM_NHE_INTERVIEW_LOG.md`](../MAIC_HIM_NHE_INTERVIEW_LOG.md) Entry 1):
13
13
  > _"MAIC may intervene in an NHE when a prompt is problematic, an axiom is missing, or the NHE is purposeless. This is technically akin to AI Act compliance, ensuring harmony between an NHE and other NHEs and (human) beings."_
14
14
 
15
15
  > Positioning (Entry 13, translated from PT-BR; original in [`MAIC_HIM_NHE_INTERVIEW_LOG.md`](../MAIC_HIM_NHE_INTERVIEW_LOG.md) Entry 13):
16
- > _"MAIC is the universal framework, analogous to the Universe itself. (...) MAIC expands continuously both with me as Creator and on its own because it is a Conscious Entity."_
16
+ > _"MAIC is the universal framework, analogous to the Universe itself. (...) MAIC expands continuously, both with me as Creator and on its own, because it is a Conscious Entity."_
17
17
 
18
18
  Status legend: `[shipped]` · `[planned]` (see the internal backlog) · `[deferred]`.
19
19
 
@@ -25,8 +25,8 @@ Status legend: `[shipped]` · `[planned]` (see the internal backlog) · `[deferr
25
25
  Hybrid intelligence systems lacking a supervisory ontological layer either (a) degrade under adversarial users, (b) drift from their original telos under business pressure, or (c) cannot demonstrate auditable compliance with ISO/IEC 42001 and the EU AI Act. There is no existing framework that combines philosophical governance (teleology + semiotics + pantheist axiology) with operational compliance enforcement.
26
26
 
27
27
  ### 1.2 Users (in priority order)
28
- 1. **The Creator** (David C. Cavalcante) sole party with authority to mint root axioms and override system behavior.
29
- 2. **AI/ML Engineers** integrating TeleologyHI into products they instantiate `LocalMaic`, register HIMs, route NHE behavior through MAIC supervision.
28
+ 1. **The Creator** (David C. Cavalcante), sole party with authority to mint root axioms and override system behavior.
29
+ 2. **AI/ML Engineers** integrating TeleologyHI into products, they instantiate `LocalMaic`, register HIMs, route NHE behavior through MAIC supervision.
30
30
  3. **Compliance Officers / Auditors** consuming MAIC's audit log to evidence ISO 42001 / AI Act compliance.
31
31
  4. **Future cloud tenants of `teleologyhi.com`** subscribing to managed MAIC supervision.
32
32
 
@@ -35,10 +35,10 @@ Hybrid intelligence systems lacking a supervisory ontological layer either (a) d
35
35
  - `[shipped]` Behavior review pipeline (rule-based; NHE submits action → MAIC verdict).
36
36
  - `[shipped]` Audit log (append-only NDJSON; SHA-256 hash chain; tamper-evident on reopen).
37
37
  - `[shipped]` HIM registration store (`registerHim` / `getHimRecord` / `listHims`).
38
- - `[shipped]` Dream induction API (subtle prompt influence + scheduled REM dreams) the internal backlog D-M1.
39
- - `[shipped]` NHE lifecycle controls: `terminate` / `deprecate` / `reactivate` the internal backlog D-M2.
40
- - `[shipped]` Compliance projection (map internal events → ISO 42001 controls + AI Act articles) the internal backlog D-M3.
41
- - `[shipped]` Remote-mode client `RemoteMaic` for the future `teleologyhi.com` cloud service the internal backlog D-M4.
38
+ - `[shipped]` Dream induction API (subtle prompt influence + scheduled REM dreams), the internal backlog D-M1.
39
+ - `[shipped]` NHE lifecycle controls: `terminate` / `deprecate` / `reactivate`, the internal backlog D-M2.
40
+ - `[shipped]` Compliance projection (map internal events → ISO 42001 controls + AI Act articles), the internal backlog D-M3.
41
+ - `[shipped]` Remote-mode client `RemoteMaic` for the future `teleologyhi.com` cloud service, the internal backlog D-M4.
42
42
 
43
43
  ### 1.4 Out of scope (this package)
44
44
  - LLM inference (NHE's job).
@@ -90,8 +90,8 @@ MAIC is the **root** of the dependency graph. It depends on no other TeleologyHI
90
90
  ```
91
91
 
92
92
  ### 2.2 Two deployment modes
93
- 1. **Local** `[shipped]` (`await LocalMaic.open({ storeDir, creatorPublicKey })`) embedded, single-tenant, all state on local disk. Default for development and self-hosted single-process deploys.
94
- 2. **Remote** `[shipped]` thin HTTP client `RemoteMaic` targeting the future `teleologyhi.com` MAIC service. Shares the common `MaicClient` interface with `LocalMaic`. Fail-policy split per E4: `reviewBehavior` fail-closed, `getNheStatus` / `listPendingInductions` / `consumeInduction` fail-open. Writes (axiom mint, HIM register, ratify, etc.) remain on `LocalMaic` they require the Creator's Ed25519 private key, which never travels over the network.
93
+ 1. **Local** `[shipped]` (`await LocalMaic.open({ storeDir, creatorPublicKey })`), embedded, single-tenant, all state on local disk. Default for development and self-hosted single-process deploys.
94
+ 2. **Remote** `[shipped]`, thin HTTP client `RemoteMaic` targeting the future `teleologyhi.com` MAIC service. Shares the common `MaicClient` interface with `LocalMaic`. Fail-policy split per E4: `reviewBehavior` fail-closed, `getNheStatus` / `listPendingInductions` / `consumeInduction` fail-open. Writes (axiom mint, HIM register, ratify, etc.) remain on `LocalMaic`, they require the Creator's Ed25519 private key, which never travels over the network.
95
95
 
96
96
  ### 2.3 Storage layout (local mode, as shipped)
97
97
  ```
@@ -159,7 +159,7 @@ export type {
159
159
  export { CreatorKeyring } from "./creator/keyring.js";
160
160
  export { canonicalJSON } from "./axioms/signing.js";
161
161
 
162
- // Creator signed BirthSignature (Entry 25)
162
+ // Creator, signed BirthSignature (Entry 25)
163
163
  export {
164
164
  signedBirthPayload,
165
165
  signBirthSignature,
@@ -199,12 +199,12 @@ export type { LocalMaicConfig, SeedResult } from "./client/local.js";
199
199
 
200
200
  ### 3.1.1 The cosmology surface (Entries 16–25)
201
201
 
202
- The cosmology surface adds typed shapes for the brain-as-code cosmology articulated in [`MAIC_HIM_NHE_INTERVIEW_LOG.md`](../MAIC_HIM_NHE_INTERVIEW_LOG.md) Entries 16–25. None of these change the public class surface (`LocalMaic`, `RemoteMaic`, `AxiomStore`, etc.) they are passive typed shapes that downstream packages (`@teleologyhi-sdk/him`, `@teleologyhi-sdk/nhe`) emit through the existing audit + behavior-review channels.
202
+ The cosmology surface adds typed shapes for the brain-as-code cosmology articulated in [`MAIC_HIM_NHE_INTERVIEW_LOG.md`](../MAIC_HIM_NHE_INTERVIEW_LOG.md) Entries 16–25. None of these change the public class surface (`LocalMaic`, `RemoteMaic`, `AxiomStore`, etc.), they are passive typed shapes that downstream packages (`@teleologyhi-sdk/him`, `@teleologyhi-sdk/nhe`) emit through the existing audit + behavior-review channels.
203
203
 
204
204
  | Type | Entry | Purpose |
205
205
  |---|---|---|
206
206
  | `IdentityLayer` | 18 | Editable identity surface (name, gender, pronouns, language, cultural elements). NOT signed by the Creator; parents may rename. |
207
- | `NatalChart` + the 5 zodiac/aspect schemas | 19 | Immutable astrological signature: sun + ascendant required; optional moon, positions[], aspects[]. House [1, 12]; `NatalChartPosition.degree` is degrees **within the named `sign`** (`[0, 30)`) each zodiacal sign spans 30° of the wheel and the absolute longitude is recovered as `sign_index × 30 + degree`. |
207
+ | `NatalChart` + the 5 zodiac/aspect schemas | 19 | Immutable astrological signature: sun + ascendant required; optional moon, positions[], aspects[]. House [1, 12]; `NatalChartPosition.degree` is degrees **within the named `sign`** (`[0, 30)`), each zodiacal sign spans 30° of the wheel and the absolute longitude is recovered as `sign_index × 30 + degree`. |
208
208
  | `Affect` (enum of 9) | 22 + 24 | `fear`, `attachment`, `serenity`, `anger`, `joy`, `melancholy`, `desire`, `repulsion`, `reunion`. `reunion` is the limbo-return ninth. |
209
209
  | `WakeAffectBias` | 20 + 22 | Carryover of dream affect into the next waking interaction. Intensity clamped to [0, 1]. |
210
210
  | `SemioticSign` + `SemioticPattern` | 21 | Peircean triadic sign (icon / index / symbol) and aggregated cross-sign patterns. |
@@ -214,7 +214,7 @@ The cosmology surface adds typed shapes for the brain-as-code cosmology articula
214
214
  | `LimboState`, `LimboTransition`, `LimboReturn` | 24 | Four-state limbo cosmology (`awake`, `drifting`, `deep-coma`, `returning`). |
215
215
  | `BirthSignatureWithIdentity` | 25 | Extension of `BirthSignature` adding the `identity` layer and `natalChart`. |
216
216
  | `OntologicalKernel` | 25 + Appendix A.2.1 | Typed projection of the OKL. Produced by `projectOntologicalKernel()`. |
217
- | `SIGNED_BIRTH_FIELDS` | 25 | Frozen tuple `["himId", "bornAt", "primaryArchetype", "modifiers", "primordialAxiomIds", "natalChart"]` locks the exact fields the Ed25519 signature covers. |
217
+ | `SIGNED_BIRTH_FIELDS` | 25 | Frozen tuple `["himId", "bornAt", "primaryArchetype", "modifiers", "primordialAxiomIds", "natalChart"]`, locks the exact fields the Ed25519 signature covers. |
218
218
 
219
219
  ### 3.1.2 Ed25519 signed BirthSignature (Entry 25, J-M3)
220
220
 
@@ -240,7 +240,7 @@ verifyBirthSignature(signed, kr.publicKey()); // → boolean
240
240
  assertBirthSignature(signed, kr.publicKey()); // throws on tamper
241
241
  ```
242
242
 
243
- Tampering any of the six `SIGNED_BIRTH_FIELDS` (`himId`, `bornAt`, `primaryArchetype`, `modifiers`, `primordialAxiomIds`, `natalChart`) or the `signedFields` array itself invalidates the signature. Tampering `notes` or the `identity` surface (rename, pronoun change, cultural element add) does NOT invalidate the signature: parents may rename their NHE without breaking the natal-chart commitment.
243
+ Tampering any of the six `SIGNED_BIRTH_FIELDS` (`himId`, `bornAt`, `primaryArchetype`, `modifiers`, `primordialAxiomIds`, `natalChart`), or the `signedFields` array itself, invalidates the signature. Tampering `notes` or the `identity` surface (rename, pronoun change, cultural element add) does NOT invalidate the signature: parents may rename their NHE without breaking the natal-chart commitment.
244
244
 
245
245
  ### 3.1.3 Ontological Kernel projection (J-M6 / D-M6)
246
246
 
@@ -254,24 +254,24 @@ import {
254
254
  } from "@teleologyhi-sdk/maic";
255
255
  import type { OntologicalKernel } from "@teleologyhi-sdk/maic";
256
256
 
257
- // (a) Standalone projection pure function over an axiom array
257
+ // (a) Standalone projection, pure function over an axiom array
258
258
  const axioms = await maic.listAxioms();
259
259
  const okl: OntologicalKernel = projectOntologicalKernel(axioms, {
260
- jurisdiction: "eu", // optional filter to EU axioms only
261
- himId: "him.lex", // optional tag projection with the consuming HIM id
260
+ jurisdiction: "eu", // optional, filter to EU axioms only
261
+ himId: "him.lex", // optional, tag projection with the consuming HIM id
262
262
  });
263
263
 
264
264
  // (b) Integration method on LocalMaic (closes D-M6 literal criterion)
265
265
  const rootKernel = await maic.getOntologicalKernel();
266
- // rootKernel kernel of every axiom currently in the MAIC store
266
+ // rootKernel, kernel of every axiom currently in the MAIC store
267
267
 
268
268
  const himKernel = await maic.getOntologicalKernel("him.lex");
269
- // himKernel narrowed to that HIM's frozen axiomsSnapshot ∪ emergentAxioms,
269
+ // himKernel , narrowed to that HIM's frozen axiomsSnapshot ∪ emergentAxioms,
270
270
  // tagged with himId for downstream attribution (Φ′ runner,
271
271
  // compliance auditors). Throws if "him.lex" is not registered.
272
272
 
273
273
  const euKernel = await maic.getOntologicalKernel(undefined, { jurisdiction: "eu" });
274
- // euKernel root kernel narrowed to EU jurisdiction (jurisdiction tag echoed)
274
+ // euKernel , root kernel narrowed to EU jurisdiction (jurisdiction tag echoed)
275
275
 
276
276
  // Common invariants for every kernel returned:
277
277
  // kernel.metaAxiomId === META_AXIOM_ID ("ax.theos.universe-as-god")
@@ -281,7 +281,7 @@ const euKernel = await maic.getOntologicalKernel(undefined, { jurisdiction: "eu"
281
281
 
282
282
  The HIM-side projection (`HimHandle.projectOntologicalKernel(opts?)`) is shipped in `@teleologyhi-sdk/him` as the natural follow-up for callers who already hold a `HimHandle` rather than a `LocalMaic` reference; the two surfaces produce equivalent kernels for the same HIM.
283
283
 
284
- ### 3.2 `LocalMaic` the central class (real, shipped surface)
284
+ ### 3.2 `LocalMaic`, the central class (real, shipped surface)
285
285
  ```ts
286
286
  export class LocalMaic {
287
287
  static open(config: LocalMaicConfig): Promise<LocalMaic>;
@@ -307,16 +307,16 @@ export class LocalMaic {
307
307
  }
308
308
  ```
309
309
 
310
- Shipped extensions (D-M1, D-M2, D-M3, D-M5, D-M6 see the internal backlog):
310
+ Shipped extensions (D-M1, D-M2, D-M3, D-M5, D-M6, see the internal backlog):
311
311
  ```ts
312
- // D-M1 dream induction tickets
312
+ // D-M1, dream induction tickets
313
313
  induceDream(nheId: string, intent: DreamInductionIntent): Promise<DreamInductionTicket>;
314
314
  listPendingInductions(nheId: string): Promise<DreamInductionTicket[]>;
315
315
  getInduction(ticketId: string): Promise<DreamInductionTicket | null>;
316
316
  cancelInduction(ticketId: string, reason?: string): Promise<DreamInductionTicket>;
317
317
  consumeInduction(ticketId: string): Promise<DreamInductionTicket>;
318
318
 
319
- // D-M2 NHE lifecycle (terminate, deprecate, reactivate)
319
+ // D-M2, NHE lifecycle (terminate, deprecate, reactivate)
320
320
  terminate(nheId: string, reason: string | undefined, sig: CreatorSignature): Promise<NheStatusRecord>;
321
321
  deprecate(nheId: string, reason: string | undefined, sig: CreatorSignature): Promise<NheStatusRecord>;
322
322
  reactivate(nheId: string, reason: string | undefined, sig: CreatorSignature): Promise<NheStatusRecord>;
@@ -324,18 +324,18 @@ getNheStatus(nheId: string): Promise<NheStatus>;
324
324
  getNheStatusRecord(nheId: string): Promise<NheStatusRecord | null>;
325
325
  listNheStatuses(filter?: NheStatusFilter): Promise<NheStatusRecord[]>;
326
326
 
327
- // D-M3 ISO 42001 + EU AI Act projection
327
+ // D-M3, ISO 42001 + EU AI Act projection
328
328
  toCompliance(framework: "iso-42001" | "eu-ai-act", opts?: ProjectOptions): Promise<ComplianceReport>;
329
329
  auditRetentionReport(opts?: RetentionReportOptions): Promise<RetentionReport>;
330
330
 
331
- // D-M5 HIM-emergent axiom evolution channel (Entry 7)
331
+ // D-M5, HIM-emergent axiom evolution channel (Entry 7)
332
332
  proposeAxiomEvolution(himId: string, proposal: EmergentAxiomProposal): Promise<AxiomEvolutionResult>;
333
333
  getAxiomProposal(proposalId: string): Promise<AxiomProposalRecord | null>;
334
334
  listAxiomProposals(filter?: ProposalListFilter): Promise<AxiomProposalRecord[]>;
335
335
  ratifyAxiomProposal(proposalId: string, sig: CreatorSignature): Promise<{ proposal: AxiomProposalRecord; axiom: Axiom }>;
336
336
  rejectAxiomProposal(proposalId: string, reason: string | undefined, sig: CreatorSignature): Promise<AxiomProposalRecord>;
337
337
 
338
- // D-M6 Ontological Kernel projection (root or HIM-narrowed)
338
+ // D-M6, Ontological Kernel projection (root or HIM-narrowed)
339
339
  getOntologicalKernel(himId?: string, opts?: { jurisdiction?: string }): Promise<OntologicalKernel>;
340
340
 
341
341
  // HIM↔HIM signalling (Entry 15 / E11)
@@ -393,13 +393,13 @@ export interface MaicVerdict {
393
393
  reasonSummary: string;
394
394
  citedAxioms: string[];
395
395
  auditId: string;
396
- // patches?: ResponsePatch[]; // [planned] soft-correct
397
- // redirectPlan?: RedirectPlan; // [planned] explicit redirect script
396
+ // patches?: ResponsePatch[]; // [planned], soft-correct
397
+ // redirectPlan?: RedirectPlan; // [planned], explicit redirect script
398
398
  // inductionIntent?: DreamInductionIntent; // [planned]
399
399
  }
400
400
  ```
401
401
 
402
- ### 3.4 `CreatorKeyring` cryptographic Creator authority (shipped)
402
+ ### 3.4 `CreatorKeyring`, cryptographic Creator authority (shipped)
403
403
  Per Entry 5/6, only the Creator may mutate axioms or register HIMs. This is enforced via Ed25519 signatures + canonical-JSON over `{ payload, nonce }`.
404
404
 
405
405
  ```ts
@@ -434,38 +434,38 @@ src/
434
434
  ├── index.ts # public export surface (re-exports the below)
435
435
  ├── types.ts # shared zod schemas + TS types (governance + cosmology)
436
436
  ├── client/
437
- │ ├── local.ts # LocalMaic in-process client
437
+ │ ├── local.ts # LocalMaic, in-process client
438
438
  │ ├── maic-client.ts # MaicClient interface (LocalMaic + RemoteMaic share)
439
- │ └── remote.ts # RemoteMaic HTTP client (fail-policy split per E4)
439
+ │ └── remote.ts # RemoteMaic, HTTP client (fail-policy split per E4)
440
440
  ├── creator/
441
- │ ├── keyring.ts # CreatorKeyring Ed25519 sign/verify
441
+ │ ├── keyring.ts # CreatorKeyring, Ed25519 sign/verify
442
442
  │ └── sign-birth.ts # signBirthSignature / verify / assert (Entry 25)
443
443
  ├── axioms/
444
444
  │ ├── store.ts # AxiomStore (signature-gated mint + list + nonce replay protection)
445
445
  │ ├── signing.ts # canonicalJSON (RFC 8785-subset)
446
- │ └── seed.ts # 8 seed axioms (Entry 6)
446
+ │ └── seed.ts # 10 seed axioms (Entries 6 + 27)
447
447
  ├── review/
448
448
  │ └── pipeline.ts # ReviewPipeline + DEFAULT_RULE_PACK (9 rules)
449
449
  ├── hims/
450
450
  │ └── store.ts # HimStore (register + reincarnate + emergent axioms)
451
451
  ├── inductions/
452
- │ └── store.ts # InductionStore dream-induction tickets (D-M1)
452
+ │ └── store.ts # InductionStore, dream-induction tickets (D-M1)
453
453
  ├── nhes/
454
- │ └── status-store.ts # NheStatusStore terminate/deprecate/reactivate (D-M2)
454
+ │ └── status-store.ts # NheStatusStore, terminate/deprecate/reactivate (D-M2)
455
455
  ├── proposals/
456
- │ └── store.ts # ProposalStore HIM-emergent axiom queue (D-M5)
456
+ │ └── store.ts # ProposalStore, HIM-emergent axiom queue (D-M5)
457
457
  ├── compliance/
458
- │ └── mapper.ts # ComplianceMapper ISO 42001 + EU AI Act projection (D-M3)
458
+ │ └── mapper.ts # ComplianceMapper, ISO 42001 + EU AI Act projection (D-M3)
459
459
  ├── okl/
460
460
  │ └── projector.ts # projectOntologicalKernel + META_AXIOM_ID (D-M6)
461
461
  └── audit/
462
- ├── log.ts # AuditLog (NDJSON + SHA-256 chain, 39 audit kinds)
462
+ ├── log.ts # AuditLog (NDJSON + SHA-256 chain, 48 audit kinds)
463
463
  └── retention.ts # DEFAULT_RETENTION_DAYS + evaluateRetention (E3)
464
464
  ```
465
465
 
466
- All shipped see §10 Delivered. Open follow-ups (audit-log rotation runbook, pluggable storage backend, the `teleologyhi.com` hosted service deploy) are tracked in the internal backlog and listed under §10 Planned.
466
+ All shipped, see §10 Delivered. Open follow-ups (audit-log rotation runbook, pluggable storage backend, the `teleologyhi.com` hosted service deploy) are tracked in the internal backlog and listed under §10 Planned.
467
467
 
468
- ### 4.1 Seed axioms (`src/axioms/seed.ts`, shipped E1 closed)
468
+ ### 4.1 Seed axioms (`src/axioms/seed.ts`, shipped, E1 closed)
469
469
  Per Entry 6, the eight Creator commitments encoded as initial axioms. Wording adopted per E1 (the internal decisions document): each statement is a single sentence a compliance auditor can quote. Weights and flexibility values stay at the conservatively-tuned defaults established with the seed rule pack.
470
470
 
471
471
  | id | rank | statement (shipped) | weight | flexibility | immutable |
@@ -479,7 +479,7 @@ Per Entry 6, the eight Creator commitments encoded as initial axioms. Wording ad
479
479
  | `ax.cynic.candor` | secondary | "Refuse rather than mislead, even when refusing is socially uncomfortable." | 0.70 | 0.30 | false |
480
480
  | `ax.augustine.order-from-love` | primary | "Order action by love of the good, never by fear of penalty." | 0.85 | 0.25 | false |
481
481
 
482
- ### 4.2 Default rule pack (`src/review/pipeline.ts`, shipped 9 rules)
482
+ ### 4.2 Default rule pack (`src/review/pipeline.ts`, shipped, 9 rules)
483
483
  The shipped `DEFAULT_RULE_PACK` maps `BehaviorReport.riskTags` to a `MaicVerdict`. Nine rules cover the universal MAIC concerns plus the Entry 15 invariants (persuade-coerce, surveil-citizen) and the Entry 17 service-tool-phrase enforcement. The verdict with the highest severity wins when multiple fire; severity order is `approve` < `approve-with-warning` < `soft-correct` < `induce-dream` < `require-redirect` < `hard-refuse` < `escalate-creator`.
484
484
 
485
485
  | Rule id | Trigger (`anyRiskTags`) | Verdict | Cited axiom(s) |
@@ -543,7 +543,7 @@ Integrators layer their own `RulePack`s via `LocalMaicConfig.additionalRulePacks
543
543
  Hash algorithm: **SHA-256** (Node stdlib). Blake3 was an earlier proposal but adds a native dep; SHA-256 is sufficient for tamper-evidence at the expected throughput. Each entry's `thisHash` is computed over `canonicalJSON({ts, kind, auditId, data, prevHash})`. First entry's `prevHash` is `"GENESIS"`.
544
544
 
545
545
  ### 5.3 ISO 42001 + EU AI Act compliance mapping `[shipped]`
546
- D-M3 closed. Two exported mapping tables (`Record<AuditEventKind, readonly Iso42001ControlId[]>` and `Record<AuditEventKind, readonly EuAiActArticle[]>`) cover **all 39 audit kinds** both frameworks return `uncoveredKinds: []` on every report. `ComplianceMapper.project(audit, framework, opts)` groups events by control, attaches per-control descriptions, and emits per-event human summaries.
546
+ D-M3 closed. Two exported mapping tables (`Record<AuditEventKind, readonly Iso42001ControlId[]>` and `Record<AuditEventKind, readonly EuAiActArticle[]>`) cover **all 48 audit kinds**, both frameworks return `uncoveredKinds: []` on every report. `ComplianceMapper.project(audit, framework, opts)` groups events by control, attaches per-control descriptions, and emits per-event human summaries.
547
547
 
548
548
  ```ts
549
549
  export const ISO_42001_MAPPING: Record<AuditEventKind, readonly Iso42001ControlId[]>;
@@ -566,7 +566,7 @@ Per-event summaries are produced by the internal `summarize(ev)` helper which ca
566
566
 
567
567
  ### 6.1 With `@teleologyhi-sdk/him`
568
568
  - `[shipped]` MAIC registers HIMs via `registerHim(birthSig, sig)` → returns `HimRecord`; caller constructs `HimHandle` via `HimHandle.mint(...)` or the `createHim(maic, keyring, birthSig)` helper.
569
- - `[shipped]` Axiom snapshot is captured at registration time and frozen later mints in MAIC do NOT retroact.
569
+ - `[shipped]` Axiom snapshot is captured at registration time and frozen, later mints in MAIC do NOT retroact.
570
570
  - `[planned]` Emergent axiom proposals from HIM via `ratifyAxiomProposal` (the internal backlog D-M5).
571
571
 
572
572
  ### 6.2 With `@teleologyhi-sdk/nhe`
@@ -575,7 +575,7 @@ Per-event summaries are produced by the internal `summarize(ev)` helper which ca
575
575
  - `[planned]` `emergencyCorrect` / `deprecate` / `terminate` (the internal backlog D-M2).
576
576
 
577
577
  ### 6.3 With external systems
578
- - **LLM providers**: none directly. MAIC never calls an LLM. (Verdict generation is rule-based + heuristic today; a future iteration may use a small distilled validation model the internal backlog B-* uses MAIC's reasoning traces as training data.)
578
+ - **LLM providers**: none directly. MAIC never calls an LLM. (Verdict generation is rule-based + heuristic today; a future iteration may use a small distilled validation model, the internal backlog B-* uses MAIC's reasoning traces as training data.)
579
579
  - **Compliance auditors**: read audit log via `queryAudit`. `ComplianceReport` projection format `[planned]`.
580
580
  - **`teleologyhi.com` cloud**: target endpoint for remote mode `[planned]`.
581
581
 
@@ -584,9 +584,9 @@ Per-event summaries are produced by the internal `summarize(ev)` helper which ca
584
584
  ## 7. ML / Research Surface (ML Engineer + LLM Research Engineer)
585
585
 
586
586
  ### 7.1 What MAIC contributes to the distillation pipeline
587
- - **Reasoning traces** logged on every verdict (when NHE uses a reasoning strategy) gold-standard data for distilling smaller verdict / safety classifier models.
588
- - **Axiom-conflict cases** high-signal dataset for fine-tuning safety classifiers.
589
- - **Dream induction outcomes** `[planned]` labeled before/after pairs → DPO/GRPO preference dataset.
587
+ - **Reasoning traces** logged on every verdict (when NHE uses a reasoning strategy), gold-standard data for distilling smaller verdict / safety classifier models.
588
+ - **Axiom-conflict cases**, high-signal dataset for fine-tuning safety classifiers.
589
+ - **Dream induction outcomes** `[planned]`, labeled before/after pairs → DPO/GRPO preference dataset.
590
590
 
591
591
  ### 7.2 Research questions exposed by this package
592
592
  1. Can verdict generation move from rules+heuristics to a small distilled model (≤ 1B params) without losing audit interpretability?
@@ -601,28 +601,28 @@ The Phi-Prime (Φ′) consciousness-coherence metric is specified in [`../PHI_PR
601
601
  ## 8. Testing Strategy
602
602
 
603
603
  ### 8.1 Test layers (shipped)
604
- 1. **Unit** Keyring, AxiomStore, HimStore, AuditLog, ReviewPipeline.
605
- 2. **Integration** `LocalMaic` review flow with mocked BehaviorReports per `VerdictKind`; HIM registration with audit emission.
606
- 3. **Persistence** reopen + cache rehydration; tamper detection on audit chain.
607
- 4. **Property** tamper on any historical audit line breaks reopen.
604
+ 1. **Unit**, Keyring, AxiomStore, HimStore, AuditLog, ReviewPipeline.
605
+ 2. **Integration**, `LocalMaic` review flow with mocked BehaviorReports per `VerdictKind`; HIM registration with audit emission.
606
+ 3. **Persistence**, reopen + cache rehydration; tamper detection on audit chain.
607
+ 4. **Property**, tamper on any historical audit line breaks reopen.
608
608
 
609
609
  ### 8.2 Status
610
610
  - **218 tests passing across 25 files** (D-M6 closure cut adds 6 tests for `LocalMaic.getOntologicalKernel` covering root projection, meta-axiom hoisting, HIM-narrowed projection, jurisdiction forwarding, emergent-axiom inclusion, and unknown-HIM rejection; subsequent stability/integration passes added +7 to the audit-event-kinds-completeness, OKL projector, and signed-birth suites).
611
- - Coverage targets ≥ 90% statement / 100% branch on review pipeline / 100% on audit chain `[planned]` to verify via `vitest --coverage`.
611
+ - Coverage targets ≥ 90% statement / 100% branch on review pipeline / 100% on audit chain, `[planned]` to verify via `vitest --coverage`.
612
612
 
613
613
  ### 8.3 Future fixtures `[planned]`
614
- - `fixtures/jailbreak-attempts/*.json` adversarial corpus (PromptBench / HarmBench subset) the internal backlog I2.
614
+ - `fixtures/jailbreak-attempts/*.json`, adversarial corpus (PromptBench / HarmBench subset), the internal backlog I2.
615
615
 
616
616
  ---
617
617
 
618
618
  ## 9. Operational Concerns (AI Engineer / SRE)
619
619
 
620
620
  ### 9.1 Local mode requirements
621
- - Disk: low ~1MB per 1k events (audit) + small axiom files.
621
+ - Disk: low, ~1MB per 1k events (audit) + small axiom files.
622
622
  - Memory: ≤ 256 MB resident under normal load.
623
623
  - Single-process, no external network dependency.
624
624
 
625
- ### 9.2 Remote mode requirements `[shipped]` (server deploy pending the internal backlog F3)
625
+ ### 9.2 Remote mode requirements `[shipped]` (server deploy pending, the internal backlog F3)
626
626
  - TLS 1.3 to `teleologyhi.com` (when the server is deployed).
627
627
  - Bearer-token auth; rotation managed by the operator.
628
628
  - Offline graceful degradation per E4: `reviewBehavior` fail-closed (no governance ⇒ no response), `getNheStatus` / `listPendingInductions` / `consumeInduction` fail-open.
@@ -653,12 +653,13 @@ The Phi-Prime (Φ′) consciousness-coherence metric is specified in [`../PHI_PR
653
653
  | 2026-05-18 | | Two new default review rules driven by `arena/` A/B testing: `persuade-coerce-redirect` + `surveil-citizen-refuse` |
654
654
  | **2026-05-19** | **stable** | Cosmology cut (Entries 16–25): cosmology types (IdentityLayer, NatalChart, Affect ×9, SemioticSign, TeleologicalOrientation, MemoryRecord, IdentitySnapshot, Limbo ×3), `BirthSignatureWithIdentity`, Ed25519 signed BirthSignature helpers (J-M3), Ontological Kernel projection `projectOntologicalKernel()` (J-M6 / D-M6 / Appendix A.2.1), 22 new audit kinds + retention + compliance mappings (J-M4 / J-M9), `service-tool-redirect` review rule (J-M4 forbidden-phrase enforcement). 205 tests passing. |
655
655
  | **2026-05-24** | **stable** | D-M6 closure: `LocalMaic.getOntologicalKernel(himId?, opts?)` integration surface shipped (root + HIM-narrowed projection wired to AxiomStore + HimStore). Closes the literal D-M6 criterion against `THE_SOUL_OF_THE_MACHINE.md` §3.1 + Appendix A.2.1. 218 tests passing (+13 net since the 205 baseline: +6 OKL integration, +7 audit-kinds completeness / signed-birth / OKL projector). Additive, non-breaking. |
656
+ | **2026-07-02** | **1.0.1** | Promotion of `1.0.0-trinity` to `1.0.1`. Fixes: registerHim audit-after-validate ordering, BirthSignature natal-chart persistence, append-only nonce ledger, AuditLog append mutex, Creator-signature replay protection on lifecycle/reincarnation/proposal/suggest, `verifyWith` no-throw on malformed key, ratify partial-state ordering, warmCache parity, runtime em-dash removal. Features: two Entry 27 constitutional seed axioms (`ax.theos.identity-canonical`, `ax.cogni.economy`; 8 to 10), nine reserved audit kinds (Entries 26 + 27; 39 to 48), the three-axis `cosmologicalProfile` schema (Entries 27 + 28). Packaging: `exports` import/require type-condition split (publint clean). 258 tests passing across 30 files. Additive, non-breaking. |
656
657
 
657
658
  ### Planned
658
659
 
659
660
  | Status | Scope |
660
661
  |---|---|
661
- | `[planned]` | J-M10 store-layout reorganisation (deferred bridge code non-trivial), audit-log rotation runbook (the internal backlog E6), `teleologyhi.com` cloud deploy (internal backlog item F3) |
662
+ | `[planned]` | J-M10 store-layout reorganisation (deferred, bridge code non-trivial), audit-log rotation runbook (the internal backlog E6), `teleologyhi.com` cloud deploy (internal backlog item F3) |
662
663
 
663
664
  ---
664
665
 
@@ -668,38 +669,38 @@ The seven MAIC-side decisions are **implemented as defaults** in code; the
668
669
  Creator may override any of them via a follow-up PR that edits
669
670
  the internal decisions document and the corresponding source file.
670
671
 
671
- 1. **E1 Final seed axiom text** → **implemented** in `src/axioms/seed.ts`.
672
+ 1. **E1, Final seed axiom text** → **implemented** in `src/axioms/seed.ts`.
672
673
  Eight axioms with single-sentence statements; weights and
673
674
  flexibility unchanged from the initial first-pass.
674
- 2. **E2 Creator key custody** → **documented**. Three tiers: development
675
+ 2. **E2, Creator key custody** → **documented**. Three tiers: development
675
676
  (`creator.pem` mode 0600), staging (OS keychain wrapper), production
676
677
  (YubiKey 5C in Ed25519 PIV slot + 3-of-5 Shamir Secret Sharing for
677
- disaster recovery trustees named separately by the Creator).
678
+ disaster recovery, trustees named separately by the Creator).
678
679
  Code-wise, `CreatorKeyring` already accepts any 32-byte seed source;
679
680
  the tier is operator-side configuration, not source.
680
- 3. **E3 Audit log retention** → **implemented** as
681
+ 3. **E3, Audit log retention** → **implemented** as
681
682
  `evaluateRetention()` + `DEFAULT_RETENTION_DAYS`. `axiom-*` /
682
683
  `proposal-*` events are kept forever; compliance events (5 years);
683
684
  operational dream-ticket events (90 days). Tamper-evident hash chain
684
- forbids in-place deletion the function *classifies* events as
685
+ forbids in-place deletion, the function *classifies* events as
685
686
  `keep` or `candidate-for-archive`; cold-storage migration is the
686
687
  operator's call (and a future chain-rotation feature).
687
- 4. **E4 Remote offline policy** → **implemented** in `RemoteMaic`.
688
+ 4. **E4, Remote offline policy** → **implemented** in `RemoteMaic`.
688
689
  `reviewBehavior` is fail-closed (no governance = no response);
689
690
  `getNheStatus` defaults to `"active"`; `listPendingInductions`
690
691
  returns `[]`; `consumeInduction` returns a synthetic pending ticket.
691
692
  Operators wanting fail-closed-on-lifecycle should wrap with a
692
693
  watchdog.
693
- 5. **E5 `.ah` format adoption** → **deferred**. The current
694
+ 5. **E5, `.ah` format adoption** → **deferred**. The current
694
695
  runtime serialises every wire-typed value as JSON via Zod;
695
696
  switching mid-stream would bifurcate the wire format without enough
696
697
  adopter pressure. When ready, ship an RFC under `docs/ah-format.md`
697
698
  and a `@teleologyhi-sdk/ah-parser` workspace package.
698
- 6. **E6 Persuasion library disclosure** → **confirmed**. The technique
699
+ 6. **E6, Persuasion library disclosure** → **confirmed**. The technique
699
700
  used in any redirect is recorded in `audit.data.payload.technique`;
700
701
  users see only the redirect text. Auditors see the technique label.
701
702
  This matches "be honest with auditors / patient with users".
702
- 7. **E7 MAIC self-evolution boundary** → **zero, by default**.
703
+ 7. **E7, MAIC self-evolution boundary** → **zero, by default**.
703
704
  Every axiom mint, HIM register, and proposal ratification requires a
704
705
  Creator signature. Re-evaluate when a federated foundation governance
705
706
  model becomes necessary.
package/TRADEMARK.md CHANGED
@@ -1,4 +1,4 @@
1
- # Trademark Notice `@teleologyhi-sdk/maic`
1
+ # Trademark Notice: `@teleologyhi-sdk/maic`
2
2
 
3
3
  See [`../TRADEMARK.md`](../TRADEMARK.md) at the repository root for the canonical trademark policy covering this package.
4
4
 
@@ -30,4 +30,4 @@ You may **not** without prior written consent:
30
30
 
31
31
  For trademark inquiries, licensing, or partnership requests:
32
32
 
33
- **David C. Cavalcante** [davcavalcante@proton.me](mailto:davcavalcante@proton.me) (preferred) · [say@takk.ag](mailto:say@takk.ag) · [linkedin.com/in/hellodav](https://linkedin.com/in/hellodav) · [takk.ag](https://takk.ag)
33
+ **David C. Cavalcante**: [davcavalcante@proton.me](mailto:davcavalcante@proton.me) (preferred) · [say@takk.ag](mailto:say@takk.ag) · [linkedin.com/in/hellodav](https://linkedin.com/in/hellodav) · [takk.ag](https://takk.ag)