@ours.network/fleet 2.0.1 → 2.0.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,9 +1,9 @@
1
1
  {
2
- "version": "2.0.1",
3
- "buildId": "a95d59036b13",
4
- "commit": "c69e410496f65f9526084899a70fcd3e7d1967cf",
2
+ "version": "2.0.2",
3
+ "buildId": "aa0a1f047c8f",
4
+ "commit": "82c290531c7dc6ce4529fd8d7dabd1b36be52113",
5
5
  "dirty": false,
6
- "builtAt": "2026-10-22T09:52:14.193Z",
6
+ "builtAt": "2026-10-23T08:19:17.510Z",
7
7
  "capabilities": [
8
8
  "service.refresh-v1",
9
9
  "managed-cli.codex-reasoning-effort-v1",
@@ -264,6 +264,14 @@ export declare class AcpSession implements AgentSession {
264
264
  * session/cancel and never resolves a pending permission.
265
265
  */
266
266
  submitPromptAfterTool(text: string, options?: SubmitPromptOptions): Promise<TurnResult>;
267
+ /**
268
+ * Start a wake as a turn this client owns when none is running. Steering an
269
+ * idle adapter starts a turn only the adapter knows about: its stopReason
270
+ * never reaches Fleet, so an interrupt could cancel it but never see it
271
+ * settle, and the role stayed `running` for the whole occupancy lease. Like
272
+ * a steered start, the caller learns only that the turn began.
273
+ */
274
+ private startOwnedWake;
267
275
  /**
268
276
  * Accept responsibility for a prompt, then return. The turn itself may run
269
277
  * for minutes behind other queued turns; making an interactive caller wait
@@ -658,6 +658,16 @@ export class AcpSession {
658
658
  return this.submitPrompt(text, { ...options, interrupt: false, steer: false });
659
659
  if (this.stallRecoveryClaimed)
660
660
  return this.submitPrompt(text, { ...options, interrupt: false, steer: false });
661
+ if (!this.activeTurn) {
662
+ try {
663
+ return (await this.startOwnedWake(text, options)).result;
664
+ }
665
+ catch (error) {
666
+ if (error instanceof SessionControlError)
667
+ return turnResult(false, 'failed', error.message);
668
+ throw error;
669
+ }
670
+ }
661
671
  const steered = await this.steerPrompt(text);
662
672
  if (steered.accepted || steered.detail !== 'ACP steering failed'
663
673
  || this.closing || !this.isAlive())
@@ -715,6 +725,18 @@ export class AcpSession {
715
725
  safeBoundary: { state, waitedMs, activeToolCount: remainingToolCount },
716
726
  };
717
727
  }
728
+ /**
729
+ * Start a wake as a turn this client owns when none is running. Steering an
730
+ * idle adapter starts a turn only the adapter knows about: its stopReason
731
+ * never reaches Fleet, so an interrupt could cancel it but never see it
732
+ * settle, and the role stayed `running` for the whole occupancy lease. Like
733
+ * a steered start, the caller learns only that the turn began.
734
+ */
735
+ async startOwnedWake(text, options) {
736
+ const queued = await this.queuePrompt(text, { ...options, interrupt: false, steer: false });
737
+ void queued.completion.catch(() => undefined);
738
+ return { queued, result: turnResult(true, 'inconclusive', 'startedNewTurn') };
739
+ }
718
740
  /**
719
741
  * Accept responsibility for a prompt, then return. The turn itself may run
720
742
  * for minutes behind other queued turns; making an interactive caller wait
@@ -737,6 +759,10 @@ export class AcpSession {
737
759
  // live turn, the extension starts one and acknowledges `startedNewTurn`
738
760
  // immediately; a normal session/prompt would keep the monitor blocked until
739
761
  // the entire wake-triggered turn terminated.
762
+ if (options.steer && this.steeringSupported && !this.activeTurn) {
763
+ const { queued, result } = await this.startOwnedWake(text, options);
764
+ return { ...queued, completion: Promise.resolve(result), ...(delivery ? { delivery } : {}) };
765
+ }
740
766
  if (options.steer && this.steeringSupported) {
741
767
  const promptId = randomUUID();
742
768
  return {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ours.network/fleet",
3
- "version": "2.0.1",
3
+ "version": "2.0.2",
4
4
  "description": "Harness-agnostic fleet of persistent, identity-bound AI agents. Declarative fleet.yaml, managed native/ACP sessions, supervision, and ours.network messaging.",
5
5
  "type": "module",
6
6
  "license": "FSL-1.1-Apache-2.0",