impel-cli 0.20.27 → 0.20.28

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/RELEASE_NOTES.md CHANGED
@@ -1,5 +1,15 @@
1
1
  # Release notes
2
2
 
3
+ ## 0.20.28 — Exact opaque answer resumes
4
+
5
+ - Aligns generated Claude and Codex direct-answer adapters with the opaque
6
+ `impel.native-agent-continuation.v1` contract instead of telling them to
7
+ reconstruct the durable fingerprint-bearing handle.
8
+ - Restricts the answer-only resume tool schema to the exact two-field opaque
9
+ continuation and regenerates existing managed agent profiles on update.
10
+ - Keeps durable handle integrity checks strict and rejects altered metadata
11
+ rather than restoring the deprecated direct-answer shape.
12
+
3
13
  ## 0.20.26 — Native task-board navigation
4
14
 
5
15
  - Embeds Tasks in each managed desktop app's content view instead of a
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "impel-cli",
3
- "version": "0.20.27",
3
+ "version": "0.20.28",
4
4
  "description": "Prepare isolated Claude and Codex workspaces for every accessible Impel tenant",
5
5
  "type": "module",
6
6
  "bin": {
package/src/agents.js CHANGED
@@ -53,8 +53,9 @@ export const NATIVE_AGENT_ANSWER_TOOL = "answer_native_agent";
53
53
  export const NATIVE_AGENT_RUN_TOOL = "run_native_agent";
54
54
  export const NATIVE_AGENT_RESUME_TOOL = "resume_native_agent_run";
55
55
  export const NATIVE_AGENT_RECOVER_TOOL = "recover_native_agent_runs";
56
+ export const NATIVE_AGENT_CONTINUATION_SCHEMA = "impel.native-agent-continuation.v1";
56
57
  export const MANAGED_AGENT_MCP_SERVER = "impel_agent";
57
- export const MANAGED_AGENT_MANIFEST_VERSION = 17;
58
+ export const MANAGED_AGENT_MANIFEST_VERSION = 18;
58
59
 
59
60
  // The host model only selects the fixed MCP tool and faithfully returns its
60
61
  // result. Luna preserves deterministic direct-only code-mode routing while the
@@ -620,7 +621,7 @@ function claudeAdapterInstructions(tenantId, agent) {
620
621
  `Confirm that the request fits the synchronized capabilities ${JSON.stringify(agent.capabilities)} and none of the exclusions ${JSON.stringify(agent.exclusions)}.${contextRequirement}`,
621
622
  sideEffectInstruction,
622
623
  `Call ${nativeToolName(NATIVE_AGENT_ANSWER_TOOL)} exactly once with question set to the complete assigned task, optional context set to one string containing all supplied context, and contextKeys naming the fields present in that string.`,
623
- `If the bounded answer returns an ${JSON.stringify("impel.native-agent-run.v1")} continuation handle, call ${nativeToolName(NATIVE_AGENT_RESUME_TOOL)} with exactly that handle until terminal. Never call answer_native_agent again for this request.`,
624
+ `If the bounded answer returns an object whose schema is exactly ${JSON.stringify(NATIVE_AGENT_CONTINUATION_SCHEMA)}, pass that complete object unchanged as the handle to ${nativeToolName(NATIVE_AGENT_RESUME_TOOL)} until terminal. Never change its schema or add handle metadata. Never call answer_native_agent again for this request.`,
624
625
  completionGuidance,
625
626
  ].join(" ");
626
627
  }
@@ -670,7 +671,7 @@ function codexAdapterInstructions(tenantId, agent) {
670
671
  `Confirm that the assigned request fits the cataloged capabilities ${JSON.stringify(agent.capabilities)} and none of the exclusions ${JSON.stringify(agent.exclusions)} before answering.${contextRequirement}`,
671
672
  sideEffectInstruction,
672
673
  `Call ${nativeToolName(NATIVE_AGENT_ANSWER_TOOL)} exactly once with question set to the complete assigned task, optional context set to one string containing all supplied context, and contextKeys naming the fields present in that string.`,
673
- `If the bounded answer returns an ${JSON.stringify("impel.native-agent-run.v1")} continuation handle, call ${nativeToolName(NATIVE_AGENT_RESUME_TOOL)} with exactly that handle until terminal. Never call answer_native_agent again for this request.`,
674
+ `If the bounded answer returns an object whose schema is exactly ${JSON.stringify(NATIVE_AGENT_CONTINUATION_SCHEMA)}, pass that complete object unchanged as the handle to ${nativeToolName(NATIVE_AGENT_RESUME_TOOL)} until terminal. Never change its schema or add handle metadata. Never call answer_native_agent again for this request.`,
674
675
  completionGuidance,
675
676
  ].join("\n\n");
676
677
  }
@@ -10,6 +10,7 @@ import {
10
10
  } from "./config.js";
11
11
  import {
12
12
  NATIVE_AGENT_ANSWER_TOOL,
13
+ NATIVE_AGENT_CONTINUATION_SCHEMA,
13
14
  NATIVE_AGENT_GET_TOOL,
14
15
  NATIVE_AGENT_READ_TOOL,
15
16
  NATIVE_AGENT_RECOVER_TOOL,
@@ -29,12 +30,12 @@ import { renameWithWindowsRetry } from "./windowsFs.js";
29
30
 
30
31
  export {
31
32
  NATIVE_AGENT_ANSWER_TOOL,
33
+ NATIVE_AGENT_CONTINUATION_SCHEMA,
32
34
  NATIVE_AGENT_RECOVER_TOOL,
33
35
  NATIVE_AGENT_RESUME_TOOL,
34
36
  NATIVE_AGENT_RUN_TOOL,
35
37
  };
36
38
  export const NATIVE_AGENT_HANDLE_SCHEMA = "impel.native-agent-run.v1";
37
- export const NATIVE_AGENT_CONTINUATION_SCHEMA = "impel.native-agent-continuation.v1";
38
39
  export const NATIVE_AGENT_RESULT_SCHEMA = "impel.native-agent-result.v1";
39
40
  export const NATIVE_AGENT_RECOVERY_SCHEMA = "impel.native-agent-recovery.v1";
40
41
 
@@ -2220,11 +2221,8 @@ const ANSWER_RESUME_SCHEMA = {
2220
2221
  additionalProperties: false,
2221
2222
  required: ["schema", "invocationId"],
2222
2223
  properties: {
2223
- ...HANDLE_SCHEMA.properties,
2224
- schema: {
2225
- type: "string",
2226
- enum: [NATIVE_AGENT_CONTINUATION_SCHEMA, NATIVE_AGENT_HANDLE_SCHEMA],
2227
- },
2224
+ schema: { type: "string", const: NATIVE_AGENT_CONTINUATION_SCHEMA },
2225
+ invocationId: { type: "string" },
2228
2226
  },
2229
2227
  };
2230
2228