@livx.cc/agentx 0.99.91 → 0.99.93

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/index.d.ts CHANGED
@@ -978,6 +978,8 @@ interface TaskRecord {
978
978
  budgetSpent?: boolean;
979
979
  /** The budget offer spoken in place of the cut rest — folded into the transcript after the written result. */
980
980
  capOffer?: string;
981
+ /** The live worker — Act `refines` injects a user refinement into it (DuplexAgent.amendTask). */
982
+ worker?: Agent;
981
983
  }
982
984
  type WorkerTier = 'act' | 'think';
983
985
  declare class DuplexAgentOptions {
@@ -1007,6 +1009,10 @@ declare class DuplexAgentOptions {
1007
1009
  host?: HostBridge;
1008
1010
  /** How many recent transcript messages are rendered into a worker's brief. */
1009
1011
  excerptTurns: number;
1012
+ /** A Hold turn whose user says nothing more for this long is answered after all (a re-voice turn told they stopped):
1013
+ * without it a wrong Hold left the turn as a lone "mm-hm" forever. 0 = off. Only for a host that reports the user's
1014
+ * live speech via userActive() — else a slow talker's next words would be spoken over. */
1015
+ holdResumeMs: number;
1010
1016
  /** Voice register: 'neutral' = clean spoken style; 'conversational' = human-like — fillers,
1011
1017
  * backchannels, impulsive first reactions before content (mimics real duplex conversation). */
1012
1018
  voiceStyle: 'neutral' | 'conversational';
@@ -1047,6 +1053,9 @@ declare class DuplexAgentOptions {
1047
1053
  /** Host overrides for QuickLook lookups (keyed by `what`). The engine's defaults go through the
1048
1054
  * (possibly jailed) fs — e.g. `.git/**` is deny-listed, so the CLI supplies 'branch' itself. */
1049
1055
  quickLook?: Record<string, (path?: string) => string | Promise<string>>;
1056
+ /** Extra roots QuickLook ls/file try for a relative path not found under the cwd (the CLI passes ~ and ~/Documents:
1057
+ * a spoken "Projects/X" means ~/Documents/Projects/X far more often than <cwd>/Projects/X). */
1058
+ lookRoots: string[];
1050
1059
  /** Memory directory/directories on the WORKER fs. If set, the voice agent gets Remember + Recall
1051
1060
  * tools directly (no delegation needed) and implicit capture guidance. */
1052
1061
  memoryDir?: string | string[];
@@ -1104,11 +1113,15 @@ declare class DuplexAgent {
1104
1113
  private spokeThisTurn;
1105
1114
  private externalSpeech;
1106
1115
  private heldThisTurn;
1116
+ private holdTimer;
1117
+ private holdResumed;
1107
1118
  private nudging;
1108
1119
  private reflexBuf;
1109
1120
  private reflexForwarded;
1110
1121
  private fabricationCut;
1111
1122
  private leakCuts;
1123
+ private midPhraseBounced;
1124
+ private repeatCuts;
1112
1125
  private leakStep;
1113
1126
  private leakHit;
1114
1127
  private stepMarks;
@@ -1191,10 +1204,11 @@ declare class DuplexAgent {
1191
1204
  * not dead air, and a nudge would run on the same aborted signal (live: the "[reminder]" landed in the
1192
1205
  * transcript as a user turn with no reply, session 20260923-101910 msg 27). */
1193
1206
  private endTurn;
1194
- /** Remove complete stage-direction parentheticals from the UNFORWARDED reflex text (STAGE_DIRECTION_RE).
1195
- * Only the unforwarded region is touched — already-spoken audio can't be unsent, and splicing before
1196
- * reflexForwarded would corrupt the forward offset. */
1197
- private scrubStageDirections;
1207
+ /** Rewrite the UNFORWARDED reflex text: drop complete stage-direction parentheticals (STAGE_DIRECTION_RE) and spoken
1208
+ * junk (scrubSpokenJunk). Only the unforwarded region is touched — already-spoken audio can't be unsent, and
1209
+ * splicing before reflexForwarded would corrupt the forward offset. Rewritten per step segment so the stepMarks
1210
+ * after it move with the text (a mark is a reflexBuf offset); a segment that ends at a step mark is complete. */
1211
+ private scrubUnforwarded;
1198
1212
  /** Clear the per-turn guards. Called at the head of every voice turn (user send + re-voice flush). */
1199
1213
  private resetTurn;
1200
1214
  /** preToolUse guard on the reflex: once it has dispatched this turn, a dispatch is "said my piece,
@@ -1207,6 +1221,11 @@ declare class DuplexAgent {
1207
1221
  * inline turn whose reply came back empty it is NOT — "One sec." followed by permanent silence is
1208
1222
  * still dead air, so silentTurn ignores external speech unless work was dispatched. */
1209
1223
  noteExternalSpeech(): void;
1224
+ /** The user is speaking (a live partial, a barge): a pending Hold expiry waits for them again. */
1225
+ userActive(): void;
1226
+ private clearHoldResume;
1227
+ private armHoldResume;
1228
+ static readonly HOLD_EXPIRED = "[the user stopped there and did not go on \u2014 respond to what they said now; if it is unclear, ask one short question. Do not Hold.]";
1210
1229
  /** True when the just-finished turn voiced NOTHING — dead air to repair. Two ways this happens:
1211
1230
  * (a) a dispatch with no spoken ack, and (b) an INLINE turn whose `final` channel came back empty —
1212
1231
  * gpt-oss harmony sometimes puts the whole reply in `analysis` (→ thinking_delta, suppressed in
@@ -1266,6 +1285,10 @@ declare class DuplexAgent {
1266
1285
  * Called on divergence (send), a stale partial (VoiceEngine.onSpeculateAbort), a side-effect tool
1267
1286
  * attempt (dispatchGuard), or host paths that will never dispatch a final (commands, voice-off). */
1268
1287
  abortSpeculation(): void;
1288
+ /** Fold a refinement into a RUNNING task's worker (Agent.inject — picked up at its next step) instead of cancel +
1289
+ * respawn: live 20261013-085238 one request spoken over three fragments became t5 → cancel → t6 → cancel → t7, each
1290
+ * worker restarting from zero. Returns the id when amended, undefined when the task is not running (→ dispatch new). */
1291
+ amendTask(id: string, brief: string): string | undefined;
1269
1292
  /** Cancel a running background task — shared by the CancelTask tool and the CLI /tasks picker. */
1270
1293
  cancelTask(id: string): string;
1271
1294
  /** Barge-in (or a dispatch-driven supersede): suppress running tasks' remaining SPOKEN delivery so a
@@ -1401,6 +1424,12 @@ declare class DuplexAgent {
1401
1424
  * fs-only (no shell; the engine is VFS-abstracted): time, git branch (.git/HEAD read), ls, file
1402
1425
  * head. Output is hard-capped so a lookup can never bloat the skinny voice context. */
1403
1426
  private quickLookTool;
1427
+ /** Where QuickLook tries a path: as given (cwd-relative or absolute), then — relative only — under each lookRoot. */
1428
+ private lookCandidates;
1429
+ /** A QuickLook path not found anywhere: say where it looked and, at the deepest folder that DID exist, the few closest
1430
+ * names (a mis-heard segment — "Lead Sheets" for "Livshitz" — is usually one of them). Never the whole cwd listing:
1431
+ * live 20261013-085238 dumped it three times for three spellings of the same path. */
1432
+ private lookMiss;
1404
1433
  private answerTaskTool;
1405
1434
  private holdTool;
1406
1435
  private cancelTaskTool;