@principles/codex-adapter 0.8.0 → 0.8.2

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.
@@ -1,4 +1,4 @@
1
- import type { InterventionCapabilityDeclaration } from '@principles/core/runtime-v2';
1
+ import type { InterventionCapabilityDeclaration } from '@principles/core/runtime';
2
2
  /** Evidence adapter surface version (major-series label; exact package version lives in package.json). */
3
3
  export declare const CODEX_EVIDENCE_ADAPTER_VERSION = "codex-adapter@2";
4
4
  export type EvidenceWarn = (diagnosticLine: string) => void;
@@ -6,7 +6,7 @@
6
6
  * observations onto the host-neutral admission candidates of
7
7
  * `@principles/host-runtime` (`admitGovernanceSignals`), then driving the
8
8
  * admitted pains through the existing continuation seams —
9
- * `ensureGovernanceDiagnosticianTask` (Runtime V2 async enqueue, never an
9
+ * `ensureGovernanceDiagnosticianTask` (Runtime async enqueue, never an
10
10
  * LLM) and `promoteAdmittedGovernanceEvidence` (Slice A's ≤12 + trigger +
11
11
  * next-assistant window with its durable pending tail).
12
12
  *
@@ -6,7 +6,7 @@
6
6
  * observations onto the host-neutral admission candidates of
7
7
  * `@principles/host-runtime` (`admitGovernanceSignals`), then driving the
8
8
  * admitted pains through the existing continuation seams —
9
- * `ensureGovernanceDiagnosticianTask` (Runtime V2 async enqueue, never an
9
+ * `ensureGovernanceDiagnosticianTask` (Runtime async enqueue, never an
10
10
  * LLM) and `promoteAdmittedGovernanceEvidence` (Slice A's ≤12 + trigger +
11
11
  * next-assistant window with its durable pending tail).
12
12
  *
@@ -15,7 +15,7 @@
15
15
  * no reads (SPEC §10 hard privacy invariant; the port spy test covers the
16
16
  * lookup path too).
17
17
  */
18
- import { computeFeatureFlagsFromConfig } from '@principles/core/runtime-v2';
18
+ import { computeFeatureFlagsFromConfig } from '@principles/core/runtime';
19
19
  import { loadPdConfigForPlugin, listGovernanceCheckpoints } from '@principles/host-runtime';
20
20
  import { resolveCodexHome } from './codex-home.js';
21
21
  import { locateCodexTranscriptByRolloutIdentity } from './transcript-locate.js';
@@ -22,7 +22,7 @@
22
22
  import fs from 'node:fs';
23
23
  import { createHash, randomUUID } from 'node:crypto';
24
24
  import path from 'node:path';
25
- import { computeFeatureFlagsFromConfig } from '@principles/core/runtime-v2';
25
+ import { computeFeatureFlagsFromConfig } from '@principles/core/runtime';
26
26
  import { loadPdConfigForPlugin } from '@principles/host-runtime';
27
27
  import { resolveCodexHome } from './codex-home.js';
28
28
  import { extractFields, isRecord } from './ingestion-fields.js';
package/dist/pd-hook.js CHANGED
@@ -4,10 +4,10 @@ import os from 'node:os';
4
4
  import path from 'node:path';
5
5
  import process from 'node:process';
6
6
  import { pathToFileURL, fileURLToPath } from 'node:url';
7
- import { appendEventLogLine, redactTelemetryString, isRuleHostEvaluatedEventData } from '@principles/core/runtime-v2';
7
+ import { appendEventLogLine, redactTelemetryString, isRuleHostEvaluatedEventData } from '@principles/core/runtime';
8
8
  import { createCodexRuleContextProvider, createProductionHostRuntime, loadPdConfigForPlugin, resolveNearestPdWorkspace } from '@principles/host-runtime';
9
9
  import { CODEX_TOOL_SEMANTICS } from './tool-semantics.js';
10
- import { computeFeatureFlagsFromConfig } from '@principles/core/runtime-v2';
10
+ import { computeFeatureFlagsFromConfig } from '@principles/core/runtime';
11
11
  import { CodexHooksHostAdapter } from './host-adapter.js';
12
12
  import { CodexDecoderError, CodexEncoderError } from './codec/index.js';
13
13
  import { ingestCodexConversation } from './ingestion/ingestion.js';
@@ -41,7 +41,7 @@ function redactStringFields(data) {
41
41
  */
42
42
  function codexEventEmitter(stateDir, evidence) {
43
43
  return {
44
- recordRuntimeV2ActivationsInjected(data) {
44
+ recordRuntimeActivationsInjected(data) {
45
45
  appendEventLogLine(stateDir, {
46
46
  ts: new Date().toISOString(),
47
47
  type: 'runtime_v2_prompt_activations_injected',
@@ -18,6 +18,6 @@
18
18
  * than a gap (the reliability check rejects undeclared names, forcing
19
19
  * correct names).
20
20
  */
21
- import { type ToolSemanticMappingV1, type ToolSemanticRegistry } from '@principles/core/runtime-v2';
21
+ import { type ToolSemanticMappingV1, type ToolSemanticRegistry } from '@principles/core/runtime';
22
22
  export declare const CODEX_TOOL_SEMANTIC_MAPPINGS: readonly ToolSemanticMappingV1[];
23
23
  export declare const CODEX_TOOL_SEMANTICS: ToolSemanticRegistry;
@@ -18,7 +18,7 @@
18
18
  * than a gap (the reliability check rejects undeclared names, forcing
19
19
  * correct names).
20
20
  */
21
- import { buildToolSemanticRegistry } from '@principles/core/runtime-v2';
21
+ import { buildToolSemanticRegistry } from '@principles/core/runtime';
22
22
  export const CODEX_TOOL_SEMANTIC_MAPPINGS = Object.freeze([
23
23
  { rawToolName: 'Bash', canonicalKind: 'execute' },
24
24
  { rawToolName: 'apply_patch', canonicalKind: 'write' },
@@ -22,12 +22,12 @@
22
22
  * task store, no private retry queue, no second scheduler state.
23
23
  *
24
24
  * Correctness under concurrent consumers (OpenClaw auto-consumer + this
25
- * worker on one workspace) is owned by the durable Runtime V2 task lease —
25
+ * worker on one workspace) is owned by the durable Runtime task lease —
26
26
  * never by process-local state.
27
27
  */
28
28
  import fs from 'node:fs';
29
29
  import path from 'node:path';
30
- import { computeFeatureFlagsFromConfig, createRuntimeStateHandle, createPainSignalBridge, isRetryWaitBackoffElapsed, PrincipleTreeLedgerAdapter, resolveDiagnosticianCapability, } from '@principles/core/runtime-v2';
30
+ import { computeFeatureFlagsFromConfig, createRuntimeStateHandle, createPainSignalBridge, isRetryWaitBackoffElapsed, PrincipleTreeLedgerAdapter, resolveDiagnosticianCapability, } from '@principles/core/runtime';
31
31
  import { createWorkspaceBehaviorEvidencePort, createCodexArtificerTrustedFactsPort, loadPdConfigForPlugin, loadFeatureFlagFromConfig, reconcileGovernanceContinuation, runInternalizationConsumerCycle, runStage2CorrectionCycle, createSignalClassifierForWorkspace, saveHostToolDeclaration, } from '@principles/host-runtime';
32
32
  import { catchUpCodexIngestion } from '../ingestion/catch-up.js';
33
33
  import { CODEX_TOOL_SEMANTIC_MAPPINGS, CODEX_TOOL_SEMANTICS } from '../tool-semantics.js';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@principles/codex-adapter",
3
- "version": "0.8.0",
3
+ "version": "0.8.2",
4
4
  "description": "Codex CLI host adapter for Principles Disciple — implements HostAdapter interface for OpenAI Codex CLI's stdin/stdout JSON hook model (ADR-0020).",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -33,8 +33,8 @@
33
33
  "lint": "eslint \"src/**/*.ts\""
34
34
  },
35
35
  "dependencies": {
36
- "@principles/core": "^3.0.0",
37
- "@principles/host-runtime": "^1.0.0",
36
+ "@principles/core": "^5.0.0",
37
+ "@principles/host-runtime": "^2.2.3",
38
38
  "@principles/install-layout": "^0.4.0"
39
39
  },
40
40
  "devDependencies": {
@@ -52,5 +52,5 @@
52
52
  "publishConfig": {
53
53
  "access": "public"
54
54
  },
55
- "gitHead": "94d353a428b6fc27dd41ff63b767bf915b9ed147"
55
+ "gitHead": "86b6208042b6083d4a7bbf840730d060188a1517"
56
56
  }