@signalridge/pi-goal 1.4.4 → 1.4.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +19 -0
- package/README.md +3 -1
- package/package.json +10 -10
- package/src/runtime.ts +9 -1
- package/src/tools.ts +4 -0
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,24 @@
|
|
|
1
1
|
# @signalridge/pi-goal
|
|
2
2
|
|
|
3
|
+
## 1.4.6
|
|
4
|
+
### Patch Changes
|
|
5
|
+
|
|
6
|
+
- c2fd867: Treat unknown continuation-shaped user comments as ordinary input while retaining owned stale-delivery rejection and provenance guards.
|
|
7
|
+
- Updated dependencies [c2fd867]
|
|
8
|
+
- @signalridge/pi-ui@1.4.0
|
|
9
|
+
|
|
10
|
+
## 1.4.5
|
|
11
|
+
### Patch Changes
|
|
12
|
+
|
|
13
|
+
- 3364cc0: Adopt Pi 1.0.4's host-provided dependency contract: declare imported Pi and TypeBox modules as `*` peers rather than installing duplicate runtime modules, and align Pi development pins with the repository's tested 1.0.4 baseline. The wildcard identifies host module ownership; it does not promise compatibility with every Pi version.
|
|
14
|
+
- 3364cc0: Keep Goal terminal tools directly declared but unavailable to nested execution, where termination is not propagated. Verify direct termination and settlement-gated queue advancement against the installed Pi 1.0.4 host and codemode.
|
|
15
|
+
|
|
16
|
+
Translate Pi exec results into the existing gate executor contract, failing killed commands even when their code is zero and enabling successful git fingerprint inspection. Exercise real-SDK exposure, nested approval, policy, and navigation regressions on Pi 1.0.4 instead of skipping them.
|
|
17
|
+
- Updated dependencies [3364cc0]
|
|
18
|
+
- Updated dependencies [3364cc0]
|
|
19
|
+
- Updated dependencies [3364cc0]
|
|
20
|
+
- @signalridge/pi-ui@1.3.3
|
|
21
|
+
|
|
3
22
|
## 1.4.4
|
|
4
23
|
### Patch Changes
|
|
5
24
|
|
package/README.md
CHANGED
|
@@ -38,7 +38,7 @@ Goal mode uses Codex-like persistence instructions and sends guarded continuatio
|
|
|
38
38
|
|
|
39
39
|
## Install
|
|
40
40
|
|
|
41
|
-
The
|
|
41
|
+
The current tested host is Pi `1.0.4`. Host-provided dependencies use `"*"` peers to identify module ownership, not to guarantee compatibility with every Pi version. See the [compatibility review](https://github.com/signalridge/pi-extensions/blob/main/docs/pi-1.0-compatibility.md) for verification details. The `agent_settled` lifecycle event this extension depends on landed in `0.80.6`.
|
|
42
42
|
|
|
43
43
|
```bash
|
|
44
44
|
pi install npm:@signalridge/pi-goal
|
|
@@ -211,6 +211,8 @@ Elapsed time is accumulated only while status is `active`. Pause, blocked, usage
|
|
|
211
211
|
|
|
212
212
|
## How completion works
|
|
213
213
|
|
|
214
|
+
All three terminal tools use `model-only` exposure: they remain direct model declarations with codemode `on` or `only`, but scripts and nested `ctx.executeTool()` calls cannot invoke them. Nested execution does not propagate `terminate`, so allowing it could change Goal state without ending the enclosing run. Call terminal tools directly and alone.
|
|
215
|
+
|
|
214
216
|
While a goal is active, `pi-goal` injects persistence rules, a `<goal_id>` stale-turn guard, and exposes `goal_complete`. Kickoff, resume, edited-objective, system, and automatic-continuation prompts all place a trust boundary before the escaped objective, identifying it as user-provided task data; they preserve its full scope across turns and require the agent to derive concrete requirements from the objective and referenced artifacts. They treat the current worktree, command output, tests, runtime behavior, PR state, rendered artifacts, and external state as authoritative; previous conversation and plans are context rather than proof.
|
|
215
217
|
|
|
216
218
|
Before completion, the shared audit tells the agent to treat completion as unproven, inspect requirement-by-requirement evidence for every named artifact, command, test, gate, invariant, and deliverable, and match each check's scope to the requirement it supports. Weak, indirect, missing, or merely consistent evidence means work must continue. This prompt wording is a behavioral guardrail, not proof by itself: `pi-goal` can enforce the current goal id and reject empty or plainly contradictory summaries, but it cannot independently prove that external work is complete.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@signalridge/pi-goal",
|
|
3
|
-
"version": "1.4.
|
|
3
|
+
"version": "1.4.6",
|
|
4
4
|
"description": "Pi extension for autonomous /goal completion with opt-in experimental ordered queues.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "MIT",
|
|
@@ -36,22 +36,22 @@
|
|
|
36
36
|
"lint": "biome check ."
|
|
37
37
|
},
|
|
38
38
|
"peerDependencies": {
|
|
39
|
-
"@earendil-works/pi-ai": "
|
|
40
|
-
"@earendil-works/pi-coding-agent": "
|
|
41
|
-
"@earendil-works/pi-tui": "
|
|
42
|
-
"typebox": "
|
|
39
|
+
"@earendil-works/pi-ai": "*",
|
|
40
|
+
"@earendil-works/pi-coding-agent": "*",
|
|
41
|
+
"@earendil-works/pi-tui": "*",
|
|
42
|
+
"typebox": "*"
|
|
43
43
|
},
|
|
44
44
|
"devDependencies": {
|
|
45
45
|
"@biomejs/biome": "2.5.7",
|
|
46
|
-
"@earendil-works/pi-ai": "0.
|
|
47
|
-
"@earendil-works/pi-coding-agent": "0.
|
|
48
|
-
"@earendil-works/pi-tui": "0.
|
|
49
|
-
"typebox": "1.3.
|
|
46
|
+
"@earendil-works/pi-ai": "1.0.4",
|
|
47
|
+
"@earendil-works/pi-coding-agent": "1.0.4",
|
|
48
|
+
"@earendil-works/pi-tui": "1.0.4",
|
|
49
|
+
"typebox": "1.3.27",
|
|
50
50
|
"typescript": "7.0.2"
|
|
51
51
|
},
|
|
52
52
|
"dependencies": {
|
|
53
53
|
"@narumitw/pi-tui-kit": "^0.54.0",
|
|
54
|
-
"@signalridge/pi-ui": "^1.
|
|
54
|
+
"@signalridge/pi-ui": "^1.4.0"
|
|
55
55
|
},
|
|
56
56
|
"repository": {
|
|
57
57
|
"type": "git",
|
package/src/runtime.ts
CHANGED
|
@@ -1088,7 +1088,14 @@ export class GoalRuntime {
|
|
|
1088
1088
|
|
|
1089
1089
|
markContinuationStarted(prompt: string) {
|
|
1090
1090
|
const marker = extractContinuationMarker(prompt);
|
|
1091
|
-
|
|
1091
|
+
const owned = Boolean(
|
|
1092
|
+
marker &&
|
|
1093
|
+
(this.continuationDelivery?.marker === marker ||
|
|
1094
|
+
this.claimedContinuationMarkers.has(marker) ||
|
|
1095
|
+
this.cancelledContinuationMarkers.has(marker)),
|
|
1096
|
+
);
|
|
1097
|
+
if (!owned) {
|
|
1098
|
+
// Marker-shaped user text is ordinary input, not proof of ownership.
|
|
1092
1099
|
// A paused wait is not continuation work. An unrelated prompt can fail
|
|
1093
1100
|
// before agent_settled, so its deadline must remain armed.
|
|
1094
1101
|
if (this.activeGoal?.status === "paused" && this.activeGoal.wait) return undefined;
|
|
@@ -1098,6 +1105,7 @@ export class GoalRuntime {
|
|
|
1098
1105
|
this.cancelContinuationWork();
|
|
1099
1106
|
return undefined;
|
|
1100
1107
|
}
|
|
1108
|
+
if (!marker) return undefined;
|
|
1101
1109
|
if (this.continuationDelivery?.marker === marker) {
|
|
1102
1110
|
this.continuationDelivery = undefined;
|
|
1103
1111
|
this.rememberClaimedContinuationMarker(marker);
|
package/src/tools.ts
CHANGED
|
@@ -59,6 +59,8 @@ const MAX_BLOCKER_EVIDENCE_LENGTH = 4_000;
|
|
|
59
59
|
export function registerGoalTools(pi: ExtensionAPI, runtime: GoalRuntime) {
|
|
60
60
|
const goalCompleteTool = defineTool({
|
|
61
61
|
name: GOAL_COMPLETE_TOOL,
|
|
62
|
+
// Nested execution strips terminate; terminal transitions must be direct model calls.
|
|
63
|
+
exposure: "model-only",
|
|
62
64
|
label: "Goal Complete",
|
|
63
65
|
description:
|
|
64
66
|
"Mark the active /goal as complete after all required work is done and verified, using the current goal_id stale-turn guard. Do not use for partial progress, blockers, failing, or unverified work.",
|
|
@@ -215,6 +217,7 @@ export function registerGoalTools(pi: ExtensionAPI, runtime: GoalRuntime) {
|
|
|
215
217
|
|
|
216
218
|
const goalBlockedTool = defineTool({
|
|
217
219
|
name: GOAL_BLOCKED_TOOL,
|
|
220
|
+
exposure: "model-only",
|
|
218
221
|
label: "Goal Blocked",
|
|
219
222
|
description:
|
|
220
223
|
"Stop the active /goal only at a true impasse after the same blocker recurs for at least three consecutive goal turns, with the current goal_id and concrete evidence that user or external action is required. Do not use for ordinary clarification, uncertainty, or recoverable failures.",
|
|
@@ -304,6 +307,7 @@ export function registerGoalTools(pi: ExtensionAPI, runtime: GoalRuntime) {
|
|
|
304
307
|
|
|
305
308
|
const goalWaitTool = defineTool({
|
|
306
309
|
name: GOAL_WAIT_TOOL,
|
|
310
|
+
exposure: "model-only",
|
|
307
311
|
label: "Goal Wait",
|
|
308
312
|
description: `Keep the active /goal alive but quiet while something outside this session is expected — CI finishing, a review landing, a reply arriving. The goal pauses, stays resumable, and records why. Call it alone, after arranging whatever will wake it, or pass resume_after_ms as a safety deadline. Requests below ${MIN_GOAL_WAIT_DELAY_MS}ms are clamped to ${MIN_GOAL_WAIT_DELAY_MS}ms. Do not use it for ordinary unfinished work: if there is anything left you can do yourself, do it instead.`,
|
|
309
313
|
promptSnippet: "Pause the active /goal while waiting on something outside this session",
|