@riddledc/riddle-proof 0.8.28 → 0.8.29
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/dist/adapters/codex-exec-agent.cjs +8 -5
- package/dist/adapters/codex-exec-agent.js +1 -1
- package/dist/adapters/codex.cjs +8 -5
- package/dist/adapters/codex.js +1 -1
- package/dist/adapters/local-agent.cjs +8 -5
- package/dist/adapters/local-agent.js +1 -1
- package/dist/{chunk-4PPJKW3Z.js → chunk-73EBR3YL.js} +8 -5
- package/dist/{chunk-27BG64ZG.js → chunk-FJPZZ4JO.js} +1 -1
- package/dist/cli/index.js +2 -2
- package/dist/cli.cjs +8 -5
- package/dist/cli.js +2 -2
- package/dist/codex-exec-agent.cjs +8 -5
- package/dist/codex-exec-agent.js +1 -1
- package/dist/index.cjs +8 -5
- package/dist/index.js +1 -1
- package/dist/local-agent.cjs +8 -5
- package/dist/local-agent.js +1 -1
- package/package.json +1 -1
- package/runtime/lib/author.py +11 -3
- package/runtime/lib/setup.py +72 -1
- package/runtime/tests/recon_verify_smoke.py +26 -2
|
@@ -53,7 +53,7 @@ var DEFAULT_PROOF_PACKET_AUTHOR_TIMEOUT_MS = 18e4;
|
|
|
53
53
|
var REFINED_INPUTS_SCHEMA = {
|
|
54
54
|
type: "object",
|
|
55
55
|
additionalProperties: false,
|
|
56
|
-
required: ["server_path", "wait_for_selector", "reference"],
|
|
56
|
+
required: ["server_path", "wait_for_selector", "reference", "expected_start_path", "expected_terminal_path"],
|
|
57
57
|
properties: {
|
|
58
58
|
server_path: { type: ["string", "null"] },
|
|
59
59
|
wait_for_selector: { type: ["string", "null"] },
|
|
@@ -63,8 +63,9 @@ var REFINED_INPUTS_SCHEMA = {
|
|
|
63
63
|
}
|
|
64
64
|
};
|
|
65
65
|
var INTERACTION_CONTRACT_SCHEMA = {
|
|
66
|
-
type: "object",
|
|
67
|
-
additionalProperties:
|
|
66
|
+
type: ["object", "null"],
|
|
67
|
+
additionalProperties: false,
|
|
68
|
+
required: ["start_path", "expected_terminal_path", "expected_url", "action", "assertions"],
|
|
68
69
|
properties: {
|
|
69
70
|
start_path: { type: ["string", "null"] },
|
|
70
71
|
expected_terminal_path: { type: ["string", "null"] },
|
|
@@ -131,6 +132,8 @@ var AUTHOR_SCHEMA = {
|
|
|
131
132
|
"capture_script",
|
|
132
133
|
"baseline_understanding_used",
|
|
133
134
|
"refined_inputs",
|
|
135
|
+
"expected_terminal_path",
|
|
136
|
+
"interaction_contract",
|
|
134
137
|
"rationale",
|
|
135
138
|
"confidence",
|
|
136
139
|
"summary"
|
|
@@ -750,8 +753,8 @@ function createCodexExecAgentAdapter(config = {}, runner = createCodexExecJsonRu
|
|
|
750
753
|
"Choose the evidence modality from verification_mode and success_criteria: screenshots for visual/UI proof, interactions plus screenshots for interaction proof, structured metrics/logs/JSON/audio analysis for non-visual proof.",
|
|
751
754
|
"For playable/gameplay proof, treat screenshots as supporting artifacts only: start the game, send keyboard or pointer input, measure state before/after, measure non-HUD canvas/playfield pixel deltas across time, and return playability evidence with version riddle-proof.playability.v1.",
|
|
752
755
|
"For interaction proof, author the browser action explicitly in capture_script; a wait-only script is invalid. Return a structured evidence object with start route/state, terminal route/state, action, assertions, and matched UI text.",
|
|
753
|
-
"For route-changing interaction proof, set refined_inputs.expected_start_path and refined_inputs.expected_terminal_path, and include interaction_contract with start_path, expected_terminal_path, action, and assertions. Keep refined_inputs.server_path on the start route; do not replace it with the terminal route.",
|
|
754
|
-
"If the original request or success_criteria names an expected terminal URL/path, preserve it exactly in refined_inputs.expected_terminal_path and in interaction_contract.expected_terminal_path, including query and hash.",
|
|
756
|
+
"For route-changing interaction proof, set refined_inputs.expected_start_path and refined_inputs.expected_terminal_path, and include interaction_contract with start_path, expected_terminal_path, expected_url when known, action, and assertions. Keep refined_inputs.server_path on the start route; do not replace it with the terminal route.",
|
|
757
|
+
"If the original request or success_criteria names an expected terminal URL/path, preserve it exactly in refined_inputs.expected_terminal_path and in interaction_contract.expected_terminal_path, including query and hash. For non-interaction proof, set expected_terminal_path and interaction_contract to null.",
|
|
755
758
|
"Catch waitForURL or selector timeouts and record them as failed assertions instead of throwing before evidence is emitted.",
|
|
756
759
|
"For structured proof, collect meaningful measurements inside page.evaluate, assign them to an evidence variable, and return that object from capture_script. Screenshots are optional supporting context for data/audio/log/metric/custom modes.",
|
|
757
760
|
"Do not assign globalThis.__riddleProofEvidence, window.__riddleProofEvidence, or self.__riddleProofEvidence in the worker context. Avoid global evidence assignment unless it is inside page.evaluate for compatibility with older packets.",
|
package/dist/adapters/codex.cjs
CHANGED
|
@@ -53,7 +53,7 @@ var DEFAULT_PROOF_PACKET_AUTHOR_TIMEOUT_MS = 18e4;
|
|
|
53
53
|
var REFINED_INPUTS_SCHEMA = {
|
|
54
54
|
type: "object",
|
|
55
55
|
additionalProperties: false,
|
|
56
|
-
required: ["server_path", "wait_for_selector", "reference"],
|
|
56
|
+
required: ["server_path", "wait_for_selector", "reference", "expected_start_path", "expected_terminal_path"],
|
|
57
57
|
properties: {
|
|
58
58
|
server_path: { type: ["string", "null"] },
|
|
59
59
|
wait_for_selector: { type: ["string", "null"] },
|
|
@@ -63,8 +63,9 @@ var REFINED_INPUTS_SCHEMA = {
|
|
|
63
63
|
}
|
|
64
64
|
};
|
|
65
65
|
var INTERACTION_CONTRACT_SCHEMA = {
|
|
66
|
-
type: "object",
|
|
67
|
-
additionalProperties:
|
|
66
|
+
type: ["object", "null"],
|
|
67
|
+
additionalProperties: false,
|
|
68
|
+
required: ["start_path", "expected_terminal_path", "expected_url", "action", "assertions"],
|
|
68
69
|
properties: {
|
|
69
70
|
start_path: { type: ["string", "null"] },
|
|
70
71
|
expected_terminal_path: { type: ["string", "null"] },
|
|
@@ -131,6 +132,8 @@ var AUTHOR_SCHEMA = {
|
|
|
131
132
|
"capture_script",
|
|
132
133
|
"baseline_understanding_used",
|
|
133
134
|
"refined_inputs",
|
|
135
|
+
"expected_terminal_path",
|
|
136
|
+
"interaction_contract",
|
|
134
137
|
"rationale",
|
|
135
138
|
"confidence",
|
|
136
139
|
"summary"
|
|
@@ -750,8 +753,8 @@ function createCodexExecAgentAdapter(config = {}, runner = createCodexExecJsonRu
|
|
|
750
753
|
"Choose the evidence modality from verification_mode and success_criteria: screenshots for visual/UI proof, interactions plus screenshots for interaction proof, structured metrics/logs/JSON/audio analysis for non-visual proof.",
|
|
751
754
|
"For playable/gameplay proof, treat screenshots as supporting artifacts only: start the game, send keyboard or pointer input, measure state before/after, measure non-HUD canvas/playfield pixel deltas across time, and return playability evidence with version riddle-proof.playability.v1.",
|
|
752
755
|
"For interaction proof, author the browser action explicitly in capture_script; a wait-only script is invalid. Return a structured evidence object with start route/state, terminal route/state, action, assertions, and matched UI text.",
|
|
753
|
-
"For route-changing interaction proof, set refined_inputs.expected_start_path and refined_inputs.expected_terminal_path, and include interaction_contract with start_path, expected_terminal_path, action, and assertions. Keep refined_inputs.server_path on the start route; do not replace it with the terminal route.",
|
|
754
|
-
"If the original request or success_criteria names an expected terminal URL/path, preserve it exactly in refined_inputs.expected_terminal_path and in interaction_contract.expected_terminal_path, including query and hash.",
|
|
756
|
+
"For route-changing interaction proof, set refined_inputs.expected_start_path and refined_inputs.expected_terminal_path, and include interaction_contract with start_path, expected_terminal_path, expected_url when known, action, and assertions. Keep refined_inputs.server_path on the start route; do not replace it with the terminal route.",
|
|
757
|
+
"If the original request or success_criteria names an expected terminal URL/path, preserve it exactly in refined_inputs.expected_terminal_path and in interaction_contract.expected_terminal_path, including query and hash. For non-interaction proof, set expected_terminal_path and interaction_contract to null.",
|
|
755
758
|
"Catch waitForURL or selector timeouts and record them as failed assertions instead of throwing before evidence is emitted.",
|
|
756
759
|
"For structured proof, collect meaningful measurements inside page.evaluate, assign them to an evidence variable, and return that object from capture_script. Screenshots are optional supporting context for data/audio/log/metric/custom modes.",
|
|
757
760
|
"Do not assign globalThis.__riddleProofEvidence, window.__riddleProofEvidence, or self.__riddleProofEvidence in the worker context. Avoid global evidence assignment unless it is inside page.evaluate for compatibility with older packets.",
|
package/dist/adapters/codex.js
CHANGED
|
@@ -53,7 +53,7 @@ var DEFAULT_PROOF_PACKET_AUTHOR_TIMEOUT_MS = 18e4;
|
|
|
53
53
|
var REFINED_INPUTS_SCHEMA = {
|
|
54
54
|
type: "object",
|
|
55
55
|
additionalProperties: false,
|
|
56
|
-
required: ["server_path", "wait_for_selector", "reference"],
|
|
56
|
+
required: ["server_path", "wait_for_selector", "reference", "expected_start_path", "expected_terminal_path"],
|
|
57
57
|
properties: {
|
|
58
58
|
server_path: { type: ["string", "null"] },
|
|
59
59
|
wait_for_selector: { type: ["string", "null"] },
|
|
@@ -63,8 +63,9 @@ var REFINED_INPUTS_SCHEMA = {
|
|
|
63
63
|
}
|
|
64
64
|
};
|
|
65
65
|
var INTERACTION_CONTRACT_SCHEMA = {
|
|
66
|
-
type: "object",
|
|
67
|
-
additionalProperties:
|
|
66
|
+
type: ["object", "null"],
|
|
67
|
+
additionalProperties: false,
|
|
68
|
+
required: ["start_path", "expected_terminal_path", "expected_url", "action", "assertions"],
|
|
68
69
|
properties: {
|
|
69
70
|
start_path: { type: ["string", "null"] },
|
|
70
71
|
expected_terminal_path: { type: ["string", "null"] },
|
|
@@ -131,6 +132,8 @@ var AUTHOR_SCHEMA = {
|
|
|
131
132
|
"capture_script",
|
|
132
133
|
"baseline_understanding_used",
|
|
133
134
|
"refined_inputs",
|
|
135
|
+
"expected_terminal_path",
|
|
136
|
+
"interaction_contract",
|
|
134
137
|
"rationale",
|
|
135
138
|
"confidence",
|
|
136
139
|
"summary"
|
|
@@ -750,8 +753,8 @@ function createCodexExecAgentAdapter(config = {}, runner = createCodexExecJsonRu
|
|
|
750
753
|
"Choose the evidence modality from verification_mode and success_criteria: screenshots for visual/UI proof, interactions plus screenshots for interaction proof, structured metrics/logs/JSON/audio analysis for non-visual proof.",
|
|
751
754
|
"For playable/gameplay proof, treat screenshots as supporting artifacts only: start the game, send keyboard or pointer input, measure state before/after, measure non-HUD canvas/playfield pixel deltas across time, and return playability evidence with version riddle-proof.playability.v1.",
|
|
752
755
|
"For interaction proof, author the browser action explicitly in capture_script; a wait-only script is invalid. Return a structured evidence object with start route/state, terminal route/state, action, assertions, and matched UI text.",
|
|
753
|
-
"For route-changing interaction proof, set refined_inputs.expected_start_path and refined_inputs.expected_terminal_path, and include interaction_contract with start_path, expected_terminal_path, action, and assertions. Keep refined_inputs.server_path on the start route; do not replace it with the terminal route.",
|
|
754
|
-
"If the original request or success_criteria names an expected terminal URL/path, preserve it exactly in refined_inputs.expected_terminal_path and in interaction_contract.expected_terminal_path, including query and hash.",
|
|
756
|
+
"For route-changing interaction proof, set refined_inputs.expected_start_path and refined_inputs.expected_terminal_path, and include interaction_contract with start_path, expected_terminal_path, expected_url when known, action, and assertions. Keep refined_inputs.server_path on the start route; do not replace it with the terminal route.",
|
|
757
|
+
"If the original request or success_criteria names an expected terminal URL/path, preserve it exactly in refined_inputs.expected_terminal_path and in interaction_contract.expected_terminal_path, including query and hash. For non-interaction proof, set expected_terminal_path and interaction_contract to null.",
|
|
755
758
|
"Catch waitForURL or selector timeouts and record them as failed assertions instead of throwing before evidence is emitted.",
|
|
756
759
|
"For structured proof, collect meaningful measurements inside page.evaluate, assign them to an evidence variable, and return that object from capture_script. Screenshots are optional supporting context for data/audio/log/metric/custom modes.",
|
|
757
760
|
"Do not assign globalThis.__riddleProofEvidence, window.__riddleProofEvidence, or self.__riddleProofEvidence in the worker context. Avoid global evidence assignment unless it is inside page.evaluate for compatibility with older packets.",
|
|
@@ -12,7 +12,7 @@ var DEFAULT_PROOF_PACKET_AUTHOR_TIMEOUT_MS = 18e4;
|
|
|
12
12
|
var REFINED_INPUTS_SCHEMA = {
|
|
13
13
|
type: "object",
|
|
14
14
|
additionalProperties: false,
|
|
15
|
-
required: ["server_path", "wait_for_selector", "reference"],
|
|
15
|
+
required: ["server_path", "wait_for_selector", "reference", "expected_start_path", "expected_terminal_path"],
|
|
16
16
|
properties: {
|
|
17
17
|
server_path: { type: ["string", "null"] },
|
|
18
18
|
wait_for_selector: { type: ["string", "null"] },
|
|
@@ -22,8 +22,9 @@ var REFINED_INPUTS_SCHEMA = {
|
|
|
22
22
|
}
|
|
23
23
|
};
|
|
24
24
|
var INTERACTION_CONTRACT_SCHEMA = {
|
|
25
|
-
type: "object",
|
|
26
|
-
additionalProperties:
|
|
25
|
+
type: ["object", "null"],
|
|
26
|
+
additionalProperties: false,
|
|
27
|
+
required: ["start_path", "expected_terminal_path", "expected_url", "action", "assertions"],
|
|
27
28
|
properties: {
|
|
28
29
|
start_path: { type: ["string", "null"] },
|
|
29
30
|
expected_terminal_path: { type: ["string", "null"] },
|
|
@@ -90,6 +91,8 @@ var AUTHOR_SCHEMA = {
|
|
|
90
91
|
"capture_script",
|
|
91
92
|
"baseline_understanding_used",
|
|
92
93
|
"refined_inputs",
|
|
94
|
+
"expected_terminal_path",
|
|
95
|
+
"interaction_contract",
|
|
93
96
|
"rationale",
|
|
94
97
|
"confidence",
|
|
95
98
|
"summary"
|
|
@@ -709,8 +712,8 @@ function createCodexExecAgentAdapter(config = {}, runner = createCodexExecJsonRu
|
|
|
709
712
|
"Choose the evidence modality from verification_mode and success_criteria: screenshots for visual/UI proof, interactions plus screenshots for interaction proof, structured metrics/logs/JSON/audio analysis for non-visual proof.",
|
|
710
713
|
"For playable/gameplay proof, treat screenshots as supporting artifacts only: start the game, send keyboard or pointer input, measure state before/after, measure non-HUD canvas/playfield pixel deltas across time, and return playability evidence with version riddle-proof.playability.v1.",
|
|
711
714
|
"For interaction proof, author the browser action explicitly in capture_script; a wait-only script is invalid. Return a structured evidence object with start route/state, terminal route/state, action, assertions, and matched UI text.",
|
|
712
|
-
"For route-changing interaction proof, set refined_inputs.expected_start_path and refined_inputs.expected_terminal_path, and include interaction_contract with start_path, expected_terminal_path, action, and assertions. Keep refined_inputs.server_path on the start route; do not replace it with the terminal route.",
|
|
713
|
-
"If the original request or success_criteria names an expected terminal URL/path, preserve it exactly in refined_inputs.expected_terminal_path and in interaction_contract.expected_terminal_path, including query and hash.",
|
|
715
|
+
"For route-changing interaction proof, set refined_inputs.expected_start_path and refined_inputs.expected_terminal_path, and include interaction_contract with start_path, expected_terminal_path, expected_url when known, action, and assertions. Keep refined_inputs.server_path on the start route; do not replace it with the terminal route.",
|
|
716
|
+
"If the original request or success_criteria names an expected terminal URL/path, preserve it exactly in refined_inputs.expected_terminal_path and in interaction_contract.expected_terminal_path, including query and hash. For non-interaction proof, set expected_terminal_path and interaction_contract to null.",
|
|
714
717
|
"Catch waitForURL or selector timeouts and record them as failed assertions instead of throwing before evidence is emitted.",
|
|
715
718
|
"For structured proof, collect meaningful measurements inside page.evaluate, assign them to an evidence variable, and return that object from capture_script. Screenshots are optional supporting context for data/audio/log/metric/custom modes.",
|
|
716
719
|
"Do not assign globalThis.__riddleProofEvidence, window.__riddleProofEvidence, or self.__riddleProofEvidence in the worker context. Avoid global evidence assignment unless it is inside page.evaluate for compatibility with older packets.",
|
package/dist/cli/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import "../chunk-
|
|
1
|
+
import "../chunk-FJPZZ4JO.js";
|
|
2
2
|
import "../chunk-PEWAIEER.js";
|
|
3
3
|
import "../chunk-TWTEUS7R.js";
|
|
4
4
|
import "../chunk-AM3K5FPW.js";
|
|
@@ -7,6 +7,6 @@ import "../chunk-RDPG554T.js";
|
|
|
7
7
|
import "../chunk-K6HZUSHH.js";
|
|
8
8
|
import "../chunk-OILKSY5J.js";
|
|
9
9
|
import "../chunk-JFQXAJH2.js";
|
|
10
|
-
import "../chunk-
|
|
10
|
+
import "../chunk-73EBR3YL.js";
|
|
11
11
|
import "../chunk-VY4Y5U57.js";
|
|
12
12
|
import "../chunk-MLKGABMK.js";
|
package/dist/cli.cjs
CHANGED
|
@@ -6238,7 +6238,7 @@ var DEFAULT_PROOF_PACKET_AUTHOR_TIMEOUT_MS = 18e4;
|
|
|
6238
6238
|
var REFINED_INPUTS_SCHEMA = {
|
|
6239
6239
|
type: "object",
|
|
6240
6240
|
additionalProperties: false,
|
|
6241
|
-
required: ["server_path", "wait_for_selector", "reference"],
|
|
6241
|
+
required: ["server_path", "wait_for_selector", "reference", "expected_start_path", "expected_terminal_path"],
|
|
6242
6242
|
properties: {
|
|
6243
6243
|
server_path: { type: ["string", "null"] },
|
|
6244
6244
|
wait_for_selector: { type: ["string", "null"] },
|
|
@@ -6248,8 +6248,9 @@ var REFINED_INPUTS_SCHEMA = {
|
|
|
6248
6248
|
}
|
|
6249
6249
|
};
|
|
6250
6250
|
var INTERACTION_CONTRACT_SCHEMA = {
|
|
6251
|
-
type: "object",
|
|
6252
|
-
additionalProperties:
|
|
6251
|
+
type: ["object", "null"],
|
|
6252
|
+
additionalProperties: false,
|
|
6253
|
+
required: ["start_path", "expected_terminal_path", "expected_url", "action", "assertions"],
|
|
6253
6254
|
properties: {
|
|
6254
6255
|
start_path: { type: ["string", "null"] },
|
|
6255
6256
|
expected_terminal_path: { type: ["string", "null"] },
|
|
@@ -6316,6 +6317,8 @@ var AUTHOR_SCHEMA = {
|
|
|
6316
6317
|
"capture_script",
|
|
6317
6318
|
"baseline_understanding_used",
|
|
6318
6319
|
"refined_inputs",
|
|
6320
|
+
"expected_terminal_path",
|
|
6321
|
+
"interaction_contract",
|
|
6319
6322
|
"rationale",
|
|
6320
6323
|
"confidence",
|
|
6321
6324
|
"summary"
|
|
@@ -6935,8 +6938,8 @@ function createCodexExecAgentAdapter(config = {}, runner = createCodexExecJsonRu
|
|
|
6935
6938
|
"Choose the evidence modality from verification_mode and success_criteria: screenshots for visual/UI proof, interactions plus screenshots for interaction proof, structured metrics/logs/JSON/audio analysis for non-visual proof.",
|
|
6936
6939
|
"For playable/gameplay proof, treat screenshots as supporting artifacts only: start the game, send keyboard or pointer input, measure state before/after, measure non-HUD canvas/playfield pixel deltas across time, and return playability evidence with version riddle-proof.playability.v1.",
|
|
6937
6940
|
"For interaction proof, author the browser action explicitly in capture_script; a wait-only script is invalid. Return a structured evidence object with start route/state, terminal route/state, action, assertions, and matched UI text.",
|
|
6938
|
-
"For route-changing interaction proof, set refined_inputs.expected_start_path and refined_inputs.expected_terminal_path, and include interaction_contract with start_path, expected_terminal_path, action, and assertions. Keep refined_inputs.server_path on the start route; do not replace it with the terminal route.",
|
|
6939
|
-
"If the original request or success_criteria names an expected terminal URL/path, preserve it exactly in refined_inputs.expected_terminal_path and in interaction_contract.expected_terminal_path, including query and hash.",
|
|
6941
|
+
"For route-changing interaction proof, set refined_inputs.expected_start_path and refined_inputs.expected_terminal_path, and include interaction_contract with start_path, expected_terminal_path, expected_url when known, action, and assertions. Keep refined_inputs.server_path on the start route; do not replace it with the terminal route.",
|
|
6942
|
+
"If the original request or success_criteria names an expected terminal URL/path, preserve it exactly in refined_inputs.expected_terminal_path and in interaction_contract.expected_terminal_path, including query and hash. For non-interaction proof, set expected_terminal_path and interaction_contract to null.",
|
|
6940
6943
|
"Catch waitForURL or selector timeouts and record them as failed assertions instead of throwing before evidence is emitted.",
|
|
6941
6944
|
"For structured proof, collect meaningful measurements inside page.evaluate, assign them to an evidence variable, and return that object from capture_script. Screenshots are optional supporting context for data/audio/log/metric/custom modes.",
|
|
6942
6945
|
"Do not assign globalThis.__riddleProofEvidence, window.__riddleProofEvidence, or self.__riddleProofEvidence in the worker context. Avoid global evidence assignment unless it is inside page.evaluate for compatibility with older packets.",
|
package/dist/cli.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import "./chunk-
|
|
2
|
+
import "./chunk-FJPZZ4JO.js";
|
|
3
3
|
import "./chunk-PEWAIEER.js";
|
|
4
4
|
import "./chunk-TWTEUS7R.js";
|
|
5
5
|
import "./chunk-AM3K5FPW.js";
|
|
@@ -8,6 +8,6 @@ import "./chunk-RDPG554T.js";
|
|
|
8
8
|
import "./chunk-K6HZUSHH.js";
|
|
9
9
|
import "./chunk-OILKSY5J.js";
|
|
10
10
|
import "./chunk-JFQXAJH2.js";
|
|
11
|
-
import "./chunk-
|
|
11
|
+
import "./chunk-73EBR3YL.js";
|
|
12
12
|
import "./chunk-VY4Y5U57.js";
|
|
13
13
|
import "./chunk-MLKGABMK.js";
|
|
@@ -51,7 +51,7 @@ var DEFAULT_PROOF_PACKET_AUTHOR_TIMEOUT_MS = 18e4;
|
|
|
51
51
|
var REFINED_INPUTS_SCHEMA = {
|
|
52
52
|
type: "object",
|
|
53
53
|
additionalProperties: false,
|
|
54
|
-
required: ["server_path", "wait_for_selector", "reference"],
|
|
54
|
+
required: ["server_path", "wait_for_selector", "reference", "expected_start_path", "expected_terminal_path"],
|
|
55
55
|
properties: {
|
|
56
56
|
server_path: { type: ["string", "null"] },
|
|
57
57
|
wait_for_selector: { type: ["string", "null"] },
|
|
@@ -61,8 +61,9 @@ var REFINED_INPUTS_SCHEMA = {
|
|
|
61
61
|
}
|
|
62
62
|
};
|
|
63
63
|
var INTERACTION_CONTRACT_SCHEMA = {
|
|
64
|
-
type: "object",
|
|
65
|
-
additionalProperties:
|
|
64
|
+
type: ["object", "null"],
|
|
65
|
+
additionalProperties: false,
|
|
66
|
+
required: ["start_path", "expected_terminal_path", "expected_url", "action", "assertions"],
|
|
66
67
|
properties: {
|
|
67
68
|
start_path: { type: ["string", "null"] },
|
|
68
69
|
expected_terminal_path: { type: ["string", "null"] },
|
|
@@ -129,6 +130,8 @@ var AUTHOR_SCHEMA = {
|
|
|
129
130
|
"capture_script",
|
|
130
131
|
"baseline_understanding_used",
|
|
131
132
|
"refined_inputs",
|
|
133
|
+
"expected_terminal_path",
|
|
134
|
+
"interaction_contract",
|
|
132
135
|
"rationale",
|
|
133
136
|
"confidence",
|
|
134
137
|
"summary"
|
|
@@ -748,8 +751,8 @@ function createCodexExecAgentAdapter(config = {}, runner = createCodexExecJsonRu
|
|
|
748
751
|
"Choose the evidence modality from verification_mode and success_criteria: screenshots for visual/UI proof, interactions plus screenshots for interaction proof, structured metrics/logs/JSON/audio analysis for non-visual proof.",
|
|
749
752
|
"For playable/gameplay proof, treat screenshots as supporting artifacts only: start the game, send keyboard or pointer input, measure state before/after, measure non-HUD canvas/playfield pixel deltas across time, and return playability evidence with version riddle-proof.playability.v1.",
|
|
750
753
|
"For interaction proof, author the browser action explicitly in capture_script; a wait-only script is invalid. Return a structured evidence object with start route/state, terminal route/state, action, assertions, and matched UI text.",
|
|
751
|
-
"For route-changing interaction proof, set refined_inputs.expected_start_path and refined_inputs.expected_terminal_path, and include interaction_contract with start_path, expected_terminal_path, action, and assertions. Keep refined_inputs.server_path on the start route; do not replace it with the terminal route.",
|
|
752
|
-
"If the original request or success_criteria names an expected terminal URL/path, preserve it exactly in refined_inputs.expected_terminal_path and in interaction_contract.expected_terminal_path, including query and hash.",
|
|
754
|
+
"For route-changing interaction proof, set refined_inputs.expected_start_path and refined_inputs.expected_terminal_path, and include interaction_contract with start_path, expected_terminal_path, expected_url when known, action, and assertions. Keep refined_inputs.server_path on the start route; do not replace it with the terminal route.",
|
|
755
|
+
"If the original request or success_criteria names an expected terminal URL/path, preserve it exactly in refined_inputs.expected_terminal_path and in interaction_contract.expected_terminal_path, including query and hash. For non-interaction proof, set expected_terminal_path and interaction_contract to null.",
|
|
753
756
|
"Catch waitForURL or selector timeouts and record them as failed assertions instead of throwing before evidence is emitted.",
|
|
754
757
|
"For structured proof, collect meaningful measurements inside page.evaluate, assign them to an evidence variable, and return that object from capture_script. Screenshots are optional supporting context for data/audio/log/metric/custom modes.",
|
|
755
758
|
"Do not assign globalThis.__riddleProofEvidence, window.__riddleProofEvidence, or self.__riddleProofEvidence in the worker context. Avoid global evidence assignment unless it is inside page.evaluate for compatibility with older packets.",
|
package/dist/codex-exec-agent.js
CHANGED
package/dist/index.cjs
CHANGED
|
@@ -6900,7 +6900,7 @@ var DEFAULT_PROOF_PACKET_AUTHOR_TIMEOUT_MS = 18e4;
|
|
|
6900
6900
|
var REFINED_INPUTS_SCHEMA = {
|
|
6901
6901
|
type: "object",
|
|
6902
6902
|
additionalProperties: false,
|
|
6903
|
-
required: ["server_path", "wait_for_selector", "reference"],
|
|
6903
|
+
required: ["server_path", "wait_for_selector", "reference", "expected_start_path", "expected_terminal_path"],
|
|
6904
6904
|
properties: {
|
|
6905
6905
|
server_path: { type: ["string", "null"] },
|
|
6906
6906
|
wait_for_selector: { type: ["string", "null"] },
|
|
@@ -6910,8 +6910,9 @@ var REFINED_INPUTS_SCHEMA = {
|
|
|
6910
6910
|
}
|
|
6911
6911
|
};
|
|
6912
6912
|
var INTERACTION_CONTRACT_SCHEMA = {
|
|
6913
|
-
type: "object",
|
|
6914
|
-
additionalProperties:
|
|
6913
|
+
type: ["object", "null"],
|
|
6914
|
+
additionalProperties: false,
|
|
6915
|
+
required: ["start_path", "expected_terminal_path", "expected_url", "action", "assertions"],
|
|
6915
6916
|
properties: {
|
|
6916
6917
|
start_path: { type: ["string", "null"] },
|
|
6917
6918
|
expected_terminal_path: { type: ["string", "null"] },
|
|
@@ -6978,6 +6979,8 @@ var AUTHOR_SCHEMA = {
|
|
|
6978
6979
|
"capture_script",
|
|
6979
6980
|
"baseline_understanding_used",
|
|
6980
6981
|
"refined_inputs",
|
|
6982
|
+
"expected_terminal_path",
|
|
6983
|
+
"interaction_contract",
|
|
6981
6984
|
"rationale",
|
|
6982
6985
|
"confidence",
|
|
6983
6986
|
"summary"
|
|
@@ -7597,8 +7600,8 @@ function createCodexExecAgentAdapter(config = {}, runner = createCodexExecJsonRu
|
|
|
7597
7600
|
"Choose the evidence modality from verification_mode and success_criteria: screenshots for visual/UI proof, interactions plus screenshots for interaction proof, structured metrics/logs/JSON/audio analysis for non-visual proof.",
|
|
7598
7601
|
"For playable/gameplay proof, treat screenshots as supporting artifacts only: start the game, send keyboard or pointer input, measure state before/after, measure non-HUD canvas/playfield pixel deltas across time, and return playability evidence with version riddle-proof.playability.v1.",
|
|
7599
7602
|
"For interaction proof, author the browser action explicitly in capture_script; a wait-only script is invalid. Return a structured evidence object with start route/state, terminal route/state, action, assertions, and matched UI text.",
|
|
7600
|
-
"For route-changing interaction proof, set refined_inputs.expected_start_path and refined_inputs.expected_terminal_path, and include interaction_contract with start_path, expected_terminal_path, action, and assertions. Keep refined_inputs.server_path on the start route; do not replace it with the terminal route.",
|
|
7601
|
-
"If the original request or success_criteria names an expected terminal URL/path, preserve it exactly in refined_inputs.expected_terminal_path and in interaction_contract.expected_terminal_path, including query and hash.",
|
|
7603
|
+
"For route-changing interaction proof, set refined_inputs.expected_start_path and refined_inputs.expected_terminal_path, and include interaction_contract with start_path, expected_terminal_path, expected_url when known, action, and assertions. Keep refined_inputs.server_path on the start route; do not replace it with the terminal route.",
|
|
7604
|
+
"If the original request or success_criteria names an expected terminal URL/path, preserve it exactly in refined_inputs.expected_terminal_path and in interaction_contract.expected_terminal_path, including query and hash. For non-interaction proof, set expected_terminal_path and interaction_contract to null.",
|
|
7602
7605
|
"Catch waitForURL or selector timeouts and record them as failed assertions instead of throwing before evidence is emitted.",
|
|
7603
7606
|
"For structured proof, collect meaningful measurements inside page.evaluate, assign them to an evidence variable, and return that object from capture_script. Screenshots are optional supporting context for data/audio/log/metric/custom modes.",
|
|
7604
7607
|
"Do not assign globalThis.__riddleProofEvidence, window.__riddleProofEvidence, or self.__riddleProofEvidence in the worker context. Avoid global evidence assignment unless it is inside page.evaluate for compatibility with older packets.",
|
package/dist/index.js
CHANGED
package/dist/local-agent.cjs
CHANGED
|
@@ -53,7 +53,7 @@ var DEFAULT_PROOF_PACKET_AUTHOR_TIMEOUT_MS = 18e4;
|
|
|
53
53
|
var REFINED_INPUTS_SCHEMA = {
|
|
54
54
|
type: "object",
|
|
55
55
|
additionalProperties: false,
|
|
56
|
-
required: ["server_path", "wait_for_selector", "reference"],
|
|
56
|
+
required: ["server_path", "wait_for_selector", "reference", "expected_start_path", "expected_terminal_path"],
|
|
57
57
|
properties: {
|
|
58
58
|
server_path: { type: ["string", "null"] },
|
|
59
59
|
wait_for_selector: { type: ["string", "null"] },
|
|
@@ -63,8 +63,9 @@ var REFINED_INPUTS_SCHEMA = {
|
|
|
63
63
|
}
|
|
64
64
|
};
|
|
65
65
|
var INTERACTION_CONTRACT_SCHEMA = {
|
|
66
|
-
type: "object",
|
|
67
|
-
additionalProperties:
|
|
66
|
+
type: ["object", "null"],
|
|
67
|
+
additionalProperties: false,
|
|
68
|
+
required: ["start_path", "expected_terminal_path", "expected_url", "action", "assertions"],
|
|
68
69
|
properties: {
|
|
69
70
|
start_path: { type: ["string", "null"] },
|
|
70
71
|
expected_terminal_path: { type: ["string", "null"] },
|
|
@@ -131,6 +132,8 @@ var AUTHOR_SCHEMA = {
|
|
|
131
132
|
"capture_script",
|
|
132
133
|
"baseline_understanding_used",
|
|
133
134
|
"refined_inputs",
|
|
135
|
+
"expected_terminal_path",
|
|
136
|
+
"interaction_contract",
|
|
134
137
|
"rationale",
|
|
135
138
|
"confidence",
|
|
136
139
|
"summary"
|
|
@@ -750,8 +753,8 @@ function createCodexExecAgentAdapter(config = {}, runner = createCodexExecJsonRu
|
|
|
750
753
|
"Choose the evidence modality from verification_mode and success_criteria: screenshots for visual/UI proof, interactions plus screenshots for interaction proof, structured metrics/logs/JSON/audio analysis for non-visual proof.",
|
|
751
754
|
"For playable/gameplay proof, treat screenshots as supporting artifacts only: start the game, send keyboard or pointer input, measure state before/after, measure non-HUD canvas/playfield pixel deltas across time, and return playability evidence with version riddle-proof.playability.v1.",
|
|
752
755
|
"For interaction proof, author the browser action explicitly in capture_script; a wait-only script is invalid. Return a structured evidence object with start route/state, terminal route/state, action, assertions, and matched UI text.",
|
|
753
|
-
"For route-changing interaction proof, set refined_inputs.expected_start_path and refined_inputs.expected_terminal_path, and include interaction_contract with start_path, expected_terminal_path, action, and assertions. Keep refined_inputs.server_path on the start route; do not replace it with the terminal route.",
|
|
754
|
-
"If the original request or success_criteria names an expected terminal URL/path, preserve it exactly in refined_inputs.expected_terminal_path and in interaction_contract.expected_terminal_path, including query and hash.",
|
|
756
|
+
"For route-changing interaction proof, set refined_inputs.expected_start_path and refined_inputs.expected_terminal_path, and include interaction_contract with start_path, expected_terminal_path, expected_url when known, action, and assertions. Keep refined_inputs.server_path on the start route; do not replace it with the terminal route.",
|
|
757
|
+
"If the original request or success_criteria names an expected terminal URL/path, preserve it exactly in refined_inputs.expected_terminal_path and in interaction_contract.expected_terminal_path, including query and hash. For non-interaction proof, set expected_terminal_path and interaction_contract to null.",
|
|
755
758
|
"Catch waitForURL or selector timeouts and record them as failed assertions instead of throwing before evidence is emitted.",
|
|
756
759
|
"For structured proof, collect meaningful measurements inside page.evaluate, assign them to an evidence variable, and return that object from capture_script. Screenshots are optional supporting context for data/audio/log/metric/custom modes.",
|
|
757
760
|
"Do not assign globalThis.__riddleProofEvidence, window.__riddleProofEvidence, or self.__riddleProofEvidence in the worker context. Avoid global evidence assignment unless it is inside page.evaluate for compatibility with older packets.",
|
package/dist/local-agent.js
CHANGED
package/package.json
CHANGED
package/runtime/lib/author.py
CHANGED
|
@@ -89,10 +89,12 @@ def recon_baseline_understanding(state):
|
|
|
89
89
|
return understanding if isinstance(understanding, dict) else {}
|
|
90
90
|
|
|
91
91
|
|
|
92
|
-
def authored_capture_script(existing_script, wait_for_selector=''):
|
|
92
|
+
def authored_capture_script(state, existing_script, wait_for_selector=''):
|
|
93
93
|
script = (existing_script or '').strip()
|
|
94
94
|
if script:
|
|
95
95
|
return script
|
|
96
|
+
if is_interaction_mode(state):
|
|
97
|
+
return ''
|
|
96
98
|
steps = ['await page.waitForTimeout(1500);']
|
|
97
99
|
selector = (wait_for_selector or '').strip()
|
|
98
100
|
if selector:
|
|
@@ -152,8 +154,10 @@ def author_request_payload(state, reference, baselines, current_plan, hypothesis
|
|
|
152
154
|
'observations': item.get('observations'),
|
|
153
155
|
})
|
|
154
156
|
|
|
155
|
-
fallback_capture_script = authored_capture_script(state.get('capture_script'), fallback_selector)
|
|
157
|
+
fallback_capture_script = authored_capture_script(state, state.get('capture_script'), fallback_selector)
|
|
156
158
|
fallback_proof_plan = authored_proof_plan(state, reference, fallback_path, baselines, fallback_selector)
|
|
159
|
+
expected_start_path = state.get('expected_start_path') or fallback_path or '/'
|
|
160
|
+
expected_terminal_path = state.get('expected_terminal_path') or state.get('requested_expected_terminal_path') or ''
|
|
157
161
|
|
|
158
162
|
return {
|
|
159
163
|
'status': 'needs_supervisor_judgment',
|
|
@@ -174,6 +178,8 @@ def author_request_payload(state, reference, baselines, current_plan, hypothesis
|
|
|
174
178
|
'wait_for_selector': fallback_selector,
|
|
175
179
|
'capture_script': fallback_capture_script,
|
|
176
180
|
'proof_plan': fallback_proof_plan,
|
|
181
|
+
'expected_start_path': expected_start_path,
|
|
182
|
+
'expected_terminal_path': expected_terminal_path,
|
|
177
183
|
},
|
|
178
184
|
'interaction_contract': optional_record(state.get('interaction_contract')),
|
|
179
185
|
'proof_contract': optional_record(state.get('proof_contract')),
|
|
@@ -210,6 +216,7 @@ def author_request_payload(state, reference, baselines, current_plan, hypothesis
|
|
|
210
216
|
'server_path': 'string',
|
|
211
217
|
'wait_for_selector': 'string',
|
|
212
218
|
'reference': 'string',
|
|
219
|
+
'expected_start_path': 'string',
|
|
213
220
|
'expected_terminal_path': 'string',
|
|
214
221
|
},
|
|
215
222
|
'interaction_contract': {
|
|
@@ -245,7 +252,7 @@ default_path = normalize_path(first_non_empty(before_path, prod_path, current_pa
|
|
|
245
252
|
|
|
246
253
|
default_selector = first_non_empty((s.get('wait_for_selector') or '').strip(), (current_plan.get('wait_for_selector') or '').strip())
|
|
247
254
|
default_proof_plan = authored_proof_plan(s, reference, default_path, baselines, default_selector)
|
|
248
|
-
default_capture_script = authored_capture_script(s.get('capture_script'), default_selector)
|
|
255
|
+
default_capture_script = authored_capture_script(s, s.get('capture_script'), default_selector)
|
|
249
256
|
|
|
250
257
|
supervisor_packet = s.get('supervisor_author_packet') or {}
|
|
251
258
|
if not isinstance(supervisor_packet, dict):
|
|
@@ -333,6 +340,7 @@ authored_packet = {
|
|
|
333
340
|
'server_path': refined_path,
|
|
334
341
|
'wait_for_selector': refined_selector,
|
|
335
342
|
'reference': refined_reference,
|
|
343
|
+
'expected_start_path': s.get('expected_start_path') or '',
|
|
336
344
|
'expected_terminal_path': expected_terminal_path,
|
|
337
345
|
},
|
|
338
346
|
'interaction_contract': provided_payload['interaction_contract'],
|
package/runtime/lib/setup.py
CHANGED
|
@@ -6,7 +6,7 @@ scratch storage by default:
|
|
|
6
6
|
/var/tmp/riddle-proof/.riddle-proof-worktrees/riddle-proof-<run_id>-after
|
|
7
7
|
"""
|
|
8
8
|
|
|
9
|
-
import json, subprocess as sp, os, sys, shutil, time, tempfile
|
|
9
|
+
import json, subprocess as sp, os, sys, shutil, time, tempfile, re
|
|
10
10
|
from urllib.parse import urlparse
|
|
11
11
|
sys.path.insert(0, os.path.dirname(os.path.abspath(__file__)))
|
|
12
12
|
from util import load_state, save_state, git, shell_quote
|
|
@@ -223,6 +223,76 @@ def interaction_verification_mode():
|
|
|
223
223
|
)
|
|
224
224
|
|
|
225
225
|
|
|
226
|
+
def normalize_route_path(value):
|
|
227
|
+
raw = str(value or '').strip()
|
|
228
|
+
if not raw:
|
|
229
|
+
return ''
|
|
230
|
+
try:
|
|
231
|
+
parsed = urlparse(raw if raw.startswith(('http://', 'https://')) else raw)
|
|
232
|
+
path = parsed.path or '/'
|
|
233
|
+
if not path.startswith('/'):
|
|
234
|
+
path = '/' + path
|
|
235
|
+
if len(path) > 1:
|
|
236
|
+
path = path.rstrip('/')
|
|
237
|
+
query = ('?' + parsed.query) if parsed.query else ''
|
|
238
|
+
fragment = ('#' + parsed.fragment) if parsed.fragment else ''
|
|
239
|
+
return path + query + fragment
|
|
240
|
+
except Exception:
|
|
241
|
+
path = raw.split('#', 1)[0].split('?', 1)[0]
|
|
242
|
+
if not path.startswith('/'):
|
|
243
|
+
path = '/' + path
|
|
244
|
+
return path.rstrip('/') or '/'
|
|
245
|
+
|
|
246
|
+
|
|
247
|
+
def trim_route_candidate(value):
|
|
248
|
+
return str(value or '').strip().rstrip('),.;]}')
|
|
249
|
+
|
|
250
|
+
|
|
251
|
+
def expected_terminal_route_from_text(value):
|
|
252
|
+
text = str(value or '').strip()
|
|
253
|
+
if not text:
|
|
254
|
+
return ''
|
|
255
|
+
route_pattern = r'(https?://[^\s"\'<>`]+|/[^\s"\'<>`]+)'
|
|
256
|
+
patterns = [
|
|
257
|
+
r'\bexpected\s+(?:terminal\s+|final\s+|after\s+)?(?:url|route|path)\s*(?:is|=|:)\s*' + route_pattern,
|
|
258
|
+
r'\b(?:terminal|final|after)\s+(?:url|route|path)\s*(?:is|=|:)\s*' + route_pattern,
|
|
259
|
+
r'\b(?:ends|end|ending|lands|land|landing)\s+(?:at|on)\s*' + route_pattern,
|
|
260
|
+
]
|
|
261
|
+
for pattern in patterns:
|
|
262
|
+
match = re.search(pattern, text, re.IGNORECASE)
|
|
263
|
+
if match:
|
|
264
|
+
route = normalize_route_path(trim_route_candidate(match.group(1)))
|
|
265
|
+
if route:
|
|
266
|
+
return route
|
|
267
|
+
return ''
|
|
268
|
+
|
|
269
|
+
|
|
270
|
+
def requested_expected_terminal_route():
|
|
271
|
+
return (
|
|
272
|
+
expected_terminal_route_from_text(s.get('success_criteria')) or
|
|
273
|
+
expected_terminal_route_from_text(s.get('change_request')) or
|
|
274
|
+
expected_terminal_route_from_text(s.get('context')) or
|
|
275
|
+
expected_terminal_route_from_text(s.get('assertions_json'))
|
|
276
|
+
)
|
|
277
|
+
|
|
278
|
+
|
|
279
|
+
def apply_interaction_route_contract(start_path):
|
|
280
|
+
if not interaction_verification_mode():
|
|
281
|
+
return
|
|
282
|
+
terminal_path = requested_expected_terminal_route()
|
|
283
|
+
if not terminal_path:
|
|
284
|
+
return
|
|
285
|
+
normalized_start = normalize_route_path(start_path) or '/'
|
|
286
|
+
s['requested_expected_terminal_path'] = terminal_path
|
|
287
|
+
s['expected_terminal_path'] = s.get('expected_terminal_path') or terminal_path
|
|
288
|
+
s['expected_start_path'] = s.get('expected_start_path') or normalized_start
|
|
289
|
+
contract = s.get('interaction_contract') if isinstance(s.get('interaction_contract'), dict) else {}
|
|
290
|
+
contract = dict(contract)
|
|
291
|
+
contract['start_path'] = contract.get('start_path') or normalized_start
|
|
292
|
+
contract['expected_terminal_path'] = contract.get('expected_terminal_path') or terminal_path
|
|
293
|
+
s['interaction_contract'] = contract
|
|
294
|
+
|
|
295
|
+
|
|
226
296
|
def remote_audit_mode():
|
|
227
297
|
return bool(s.get('remote_audit')) or (
|
|
228
298
|
not repo
|
|
@@ -550,6 +620,7 @@ if remote_audit_mode():
|
|
|
550
620
|
s['allow_code_changes'] = False
|
|
551
621
|
s['server_path'] = s.get('server_path') or target_path
|
|
552
622
|
s['server_path_source'] = s.get('server_path_source') or 'prod_url'
|
|
623
|
+
apply_interaction_route_contract(s['server_path'])
|
|
553
624
|
s['recon_status'] = 'ready_for_proof_plan'
|
|
554
625
|
s['recon_summary'] = 'Remote audit/no-diff run uses prod_url as the current target and skips repo worktrees.'
|
|
555
626
|
s['recon_hypothesis'] = {
|
|
@@ -1700,13 +1700,33 @@ def run_remote_interaction_audit_setup_requires_authoring():
|
|
|
1700
1700
|
assert state['recon_status'] == 'ready_for_proof_plan'
|
|
1701
1701
|
assert state['author_status'] == 'needs_authoring'
|
|
1702
1702
|
assert state['proof_plan_status'] == 'needs_authoring'
|
|
1703
|
+
assert state['requested_expected_terminal_path'] == '/proof'
|
|
1704
|
+
assert state['expected_terminal_path'] == '/proof'
|
|
1705
|
+
assert state['expected_start_path'] == '/'
|
|
1706
|
+
assert state['interaction_contract']['start_path'] == '/'
|
|
1707
|
+
assert state['interaction_contract']['expected_terminal_path'] == '/proof'
|
|
1703
1708
|
assert state.get('capture_script', '') == ''
|
|
1704
1709
|
assert state.get('capture_script_source', '') == ''
|
|
1705
1710
|
assert 'requires an authored browser interaction capture' in state['author_summary']
|
|
1711
|
+
|
|
1712
|
+
with temporary_env(RIDDLE_PROOF_STATE_FILE=str(state_path)):
|
|
1713
|
+
sys.modules.pop('util', None)
|
|
1714
|
+
try:
|
|
1715
|
+
load_module('author_remote_interaction_audit_request', AUTHOR_PATH)
|
|
1716
|
+
except SystemExit as exc:
|
|
1717
|
+
assert exc.code in (0, None), exc
|
|
1718
|
+
after_author = json.loads(state_path.read_text())
|
|
1719
|
+
assert after_author['author_status'] == 'needs_supervisor_judgment'
|
|
1720
|
+
assert after_author['author_request']['fallback_defaults']['server_path'] == '/'
|
|
1721
|
+
assert after_author['author_request']['fallback_defaults']['expected_start_path'] == '/'
|
|
1722
|
+
assert after_author['author_request']['fallback_defaults']['expected_terminal_path'] == '/proof'
|
|
1723
|
+
assert after_author['author_request']['fallback_defaults']['capture_script'] == ''
|
|
1724
|
+
assert after_author['author_request']['interaction_contract']['expected_terminal_path'] == '/proof'
|
|
1706
1725
|
return {
|
|
1707
1726
|
'ok': True,
|
|
1708
|
-
'author_status':
|
|
1709
|
-
'
|
|
1727
|
+
'author_status': after_author['author_status'],
|
|
1728
|
+
'expected_terminal_path': after_author['expected_terminal_path'],
|
|
1729
|
+
'capture_script_source': after_author.get('capture_script_source', ''),
|
|
1710
1730
|
}
|
|
1711
1731
|
finally:
|
|
1712
1732
|
sys.modules.pop('util', None)
|
|
@@ -2062,6 +2082,8 @@ def run_recon_then_author_request():
|
|
|
2062
2082
|
assert after_author['author_runtime_model_hint'] == 'openai-codex/gpt-5.4'
|
|
2063
2083
|
assert after_author['author_request']['status'] == 'needs_supervisor_judgment'
|
|
2064
2084
|
assert after_author['author_request']['fallback_defaults']['server_path'] == '/pricing'
|
|
2085
|
+
assert after_author['author_request']['fallback_defaults']['expected_start_path'] == '/pricing'
|
|
2086
|
+
assert after_author['author_request']['fallback_defaults']['expected_terminal_path'] == ''
|
|
2065
2087
|
assert 'supervising agent owns proof authoring' in after_author['author_request']['instructions'][0].lower()
|
|
2066
2088
|
|
|
2067
2089
|
return {
|
|
@@ -2400,6 +2422,8 @@ def run_author_keeps_interaction_start_route():
|
|
|
2400
2422
|
assert after_author['expected_start_path'] == '/'
|
|
2401
2423
|
assert after_author['expected_terminal_path'] == '/proof/'
|
|
2402
2424
|
assert after_author['author_packet']['refined_inputs']['server_path'] == '/'
|
|
2425
|
+
assert after_author['author_packet']['refined_inputs']['expected_start_path'] == '/'
|
|
2426
|
+
assert after_author['author_packet']['refined_inputs']['expected_terminal_path'] == '/proof/'
|
|
2403
2427
|
assert after_author['author_warnings']
|
|
2404
2428
|
assert 'terminal interaction route' in after_author['author_warnings'][0]
|
|
2405
2429
|
return {
|