@riddledc/riddle-proof 0.1.0 → 0.2.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.
- package/README.md +40 -3
- package/dist/chunk-GWGXPNON.js +407 -0
- package/dist/index.cjs +397 -0
- package/dist/index.d.cts +2 -1
- package/dist/index.d.ts +2 -1
- package/dist/index.js +4 -0
- package/dist/runner.cjs +569 -0
- package/dist/runner.d.cts +21 -0
- package/dist/runner.d.ts +21 -0
- package/dist/runner.js +8 -0
- package/dist/types.d.cts +30 -2
- package/dist/types.d.ts +30 -2
- package/package.json +7 -2
package/dist/types.d.ts
CHANGED
|
@@ -6,7 +6,7 @@ type JsonObject = {
|
|
|
6
6
|
type RiddleProofStatus = "running" | "blocked" | "failed" | "ready_to_ship" | "shipped" | "completed";
|
|
7
7
|
type RiddleProofVerificationMode = "proof" | "visual" | "interaction" | "render" | "data" | "json" | "audio" | "log" | "logs" | "metric" | "metrics" | (string & {});
|
|
8
8
|
type RiddleProofDecision = "ready_to_ship" | "needs_richer_proof" | "revise_capture" | "needs_recon" | "needs_implementation" | (string & {});
|
|
9
|
-
type RiddleProofStage = "setup" | "recon" | "author" | "implement" | "verify" | "ship" | (string & {});
|
|
9
|
+
type RiddleProofStage = "setup" | "recon" | "author" | "implement" | "prove" | "verify" | "ship" | "notify" | (string & {});
|
|
10
10
|
interface RiddleProofRunParams {
|
|
11
11
|
repo?: string;
|
|
12
12
|
branch?: string;
|
|
@@ -132,6 +132,20 @@ interface RiddleProofAssessment {
|
|
|
132
132
|
reasons?: string[];
|
|
133
133
|
source?: "supervising_agent" | "supervisor" | "human" | (string & {});
|
|
134
134
|
}
|
|
135
|
+
interface SetupAdapterInput {
|
|
136
|
+
request: RiddleProofRunParams;
|
|
137
|
+
state: RiddleProofRunState;
|
|
138
|
+
}
|
|
139
|
+
interface SetupAdapterResult {
|
|
140
|
+
ok: boolean;
|
|
141
|
+
workdir?: string;
|
|
142
|
+
evidence_context?: RiddleProofEvidenceBundle;
|
|
143
|
+
blockers?: string[];
|
|
144
|
+
raw?: Record<string, unknown>;
|
|
145
|
+
}
|
|
146
|
+
interface SetupAdapter {
|
|
147
|
+
setup(input: SetupAdapterInput): Promise<SetupAdapterResult>;
|
|
148
|
+
}
|
|
135
149
|
interface ImplementationAdapterInput {
|
|
136
150
|
workdir: string;
|
|
137
151
|
change_request: string;
|
|
@@ -149,6 +163,20 @@ interface ImplementationAdapterResult {
|
|
|
149
163
|
interface ImplementationAdapter {
|
|
150
164
|
implement(input: ImplementationAdapterInput): Promise<ImplementationAdapterResult>;
|
|
151
165
|
}
|
|
166
|
+
interface ProofAdapterInput {
|
|
167
|
+
state: RiddleProofRunState;
|
|
168
|
+
implementation?: ImplementationAdapterResult;
|
|
169
|
+
evidence_context?: RiddleProofEvidenceBundle;
|
|
170
|
+
}
|
|
171
|
+
interface ProofAdapterResult {
|
|
172
|
+
ok: boolean;
|
|
173
|
+
evidence_bundle?: RiddleProofEvidenceBundle;
|
|
174
|
+
blockers?: string[];
|
|
175
|
+
raw?: Record<string, unknown>;
|
|
176
|
+
}
|
|
177
|
+
interface ProofAdapter {
|
|
178
|
+
prove(input: ProofAdapterInput): Promise<ProofAdapterResult>;
|
|
179
|
+
}
|
|
152
180
|
interface JudgeAdapter {
|
|
153
181
|
assessProof(input: {
|
|
154
182
|
state: RiddleProofRunState;
|
|
@@ -176,4 +204,4 @@ interface RiddleProofTerminalMetadata {
|
|
|
176
204
|
finalized?: boolean;
|
|
177
205
|
}
|
|
178
206
|
|
|
179
|
-
export type { EvidenceArtifact, EvidenceReference, ImplementationAdapter, ImplementationAdapterInput, ImplementationAdapterResult, IntegrationContext, JsonObject, JsonPrimitive, JsonValue, JudgeAdapter, NotificationAdapter, RiddleProofAssessment, RiddleProofBlocker, RiddleProofDecision, RiddleProofEvent, RiddleProofEvidenceBundle, RiddleProofRunParams, RiddleProofRunResult, RiddleProofRunState, RiddleProofStage, RiddleProofStatus, RiddleProofTerminalMetadata, RiddleProofVerificationMode, ShipAdapter };
|
|
207
|
+
export type { EvidenceArtifact, EvidenceReference, ImplementationAdapter, ImplementationAdapterInput, ImplementationAdapterResult, IntegrationContext, JsonObject, JsonPrimitive, JsonValue, JudgeAdapter, NotificationAdapter, ProofAdapter, ProofAdapterInput, ProofAdapterResult, RiddleProofAssessment, RiddleProofBlocker, RiddleProofDecision, RiddleProofEvent, RiddleProofEvidenceBundle, RiddleProofRunParams, RiddleProofRunResult, RiddleProofRunState, RiddleProofStage, RiddleProofStatus, RiddleProofTerminalMetadata, RiddleProofVerificationMode, SetupAdapter, SetupAdapterInput, SetupAdapterResult, ShipAdapter };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@riddledc/riddle-proof",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.2.0",
|
|
4
4
|
"description": "Reusable Riddle Proof contracts and helpers for evidence-backed agent changes.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": "RiddleDC",
|
|
@@ -34,6 +34,11 @@
|
|
|
34
34
|
"import": "./dist/state.js",
|
|
35
35
|
"require": "./dist/state.cjs"
|
|
36
36
|
},
|
|
37
|
+
"./runner": {
|
|
38
|
+
"types": "./dist/runner.d.ts",
|
|
39
|
+
"import": "./dist/runner.js",
|
|
40
|
+
"require": "./dist/runner.cjs"
|
|
41
|
+
},
|
|
37
42
|
"./openclaw": {
|
|
38
43
|
"types": "./dist/openclaw.d.ts",
|
|
39
44
|
"import": "./dist/openclaw.js",
|
|
@@ -55,7 +60,7 @@
|
|
|
55
60
|
"typescript": "^5.4.5"
|
|
56
61
|
},
|
|
57
62
|
"scripts": {
|
|
58
|
-
"build": "tsup src/index.ts src/types.ts src/result.ts src/state.ts src/openclaw.ts --format cjs,esm --dts --out-dir dist --clean",
|
|
63
|
+
"build": "tsup src/index.ts src/types.ts src/result.ts src/state.ts src/runner.ts src/openclaw.ts --format cjs,esm --dts --out-dir dist --clean",
|
|
59
64
|
"clean": "rm -rf dist",
|
|
60
65
|
"lint": "echo 'lint: (not configured)'",
|
|
61
66
|
"test": "npm run build && node test.js"
|