@livx.cc/agentx 0.99.36 → 0.99.37

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
@@ -1,5 +1,5 @@
1
- import { a as AgentOptions, H as Hooks, i as RunResult, A as Agent } from './Agent-Fr8uwN_l.js';
2
- export { C as ChatFragment, b as CompactResult, D as DEFAULT_MUTATING, c as Decision, P as PermissionOptions, d as PermissionPolicy, e as PermissionRule, f as PreToolUseDecision, R as ReasoningEffort, g as RecordingHooks, h as RecordingLifecycle, T as ToolUse, j as ToolUseMeta, k as composeHooks, l as estimateTokens, p as planMode, r as reasoningToChatFragment } from './Agent-Fr8uwN_l.js';
1
+ import { a as AgentOptions, H as Hooks, i as RunResult, A as Agent } from './Agent-B--fZNJy.js';
2
+ export { C as ChatFragment, b as CompactResult, D as DEFAULT_MUTATING, c as Decision, P as PermissionOptions, d as PermissionPolicy, e as PermissionRule, f as PreToolUseDecision, R as ReasoningEffort, g as RecordingHooks, h as RecordingLifecycle, T as ToolUse, j as ToolUseMeta, k as composeHooks, l as estimateTokens, p as planMode, r as reasoningToChatFragment } from './Agent-B--fZNJy.js';
3
3
  export { MODEL_ALIASES, ModelSwitch, ResolveModelSwitchOpts, modelShortLabel, resolveModelAlias, resolveModelSwitch } from './models.js';
4
4
  import { IFilesystem, FileMetadata } from '@livx.cc/wcli/core';
5
5
  export { CommandExecutor, FileMetadata, IFilesystem, IndexedDbFilesystem, MemFilesystem, registerHeadlessCommands } from '@livx.cc/wcli/core';
package/dist/index.js CHANGED
@@ -4203,7 +4203,7 @@ var Agent = class _Agent {
4203
4203
  }
4204
4204
  if (toolCalls.length === 0) {
4205
4205
  if (this.drainInjections()) continue;
4206
- const fabricated = o.catchFabricatedToolUse && !closureNudged && delegatedTools.length === 0 ? this.fabricatedToolNames(contentText(res.content ?? "")) : [];
4206
+ const fabricated = o.catchFabricatedToolUse && !closureNudged ? this.fabricatedToolNames(contentText(res.content ?? "")) : [];
4207
4207
  for (const n of fabricated) this.fabricatedClaims.add(n);
4208
4208
  if (fabricated.length && steps < o.maxSteps) {
4209
4209
  closureNudged = true;
@@ -4379,6 +4379,18 @@ var Agent = class _Agent {
4379
4379
  * - only against the ledger for the WHOLE run, so referring back to a call it genuinely made earlier
4380
4380
  * ("the screenshot showed an empty grid") is honest and stays silent;
4381
4381
  * - only on a turn that made no tool calls of its own — a turn that DID call tools is closing normally.
4382
+ * (That is the enclosing `toolCalls.length === 0` branch. It is NOT extended to delegated activity:
4383
+ * a `cursor/*` turn runs its own tools and then fabricates in the SAME response, which is the exact
4384
+ * reported defect — see the call site.)
4385
+ *
4386
+ * What it deliberately does NOT catch, both verified:
4387
+ * - a fabrication that names no tool at all ("Let me take a look at the running app. The app view did
4388
+ * not respond in time.") — there is nothing to prove it against. Only prose matching could reach it,
4389
+ * and ungating `endsOnAnnouncedAction` for that was tried and reverted (it fires on ordinary English).
4390
+ * - a SECOND invented result for a tool the run genuinely called earlier. The ledger is per-run by
4391
+ * design, because that is the same fact that keeps an honest back-reference ("the screenshot showed
4392
+ * an empty grid") silent. Distinguishing them would need per-claim positional accounting, which buys
4393
+ * a rarer case at the cost of the common honest one.
4382
4394
  */
4383
4395
  fabricatedToolNames(text) {
4384
4396
  const out = [];