@agent-native/core 0.168.13 → 0.169.0

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.
@@ -15,6 +15,6 @@ export declare function createProgressHandler(): import("h3").EventHandlerWithFe
15
15
  error: string;
16
16
  ok?: undefined;
17
17
  } | {
18
- error?: undefined;
19
18
  ok: boolean;
19
+ error?: undefined;
20
20
  }>>;
@@ -14,6 +14,7 @@ import { SYSTEM_PROMPT_CACHE_SPLIT } from "../agent/engine/prompt-cache.js";
14
14
  import { PROVIDER_TO_ENV } from "../agent/engine/provider-env-vars.js";
15
15
  import { hostedHarnessSystemPrompt } from "../agent/harness/hosted.js";
16
16
  import { createProductionAgentHandler, actionsToEngineTools, executeAgentToolCall, filterActionsByAllowedNames, normalizeAgentActionSurfaceResolution, readPersistedActionSurface, toolCallCacheKey, getActiveRunForThreadAsync, abortRunDurably, abortTurnDurably, subscribeToRun, } from "../agent/production-agent.js";
17
+ import { clientAbortReason } from "../agent/run-loop-with-resume.js";
17
18
  import { callerHasRunAccess, callerHasThreadAccess, } from "../agent/run-ownership.js";
18
19
  import { markTurnAborted, readBackgroundRunClaim } from "../agent/run-store.js";
19
20
  import { buildCurrentTimeUserContext, buildRuntimeContextPrompt, } from "../agent/runtime-context.js";
@@ -4142,10 +4143,7 @@ Non-code requests are still fine on this surface: read data, navigate the UI, su
4142
4143
  let reason = "user";
4143
4144
  try {
4144
4145
  const body = await readBody(event);
4145
- if (typeof body?.reason === "string" &&
4146
- /^[a-z0-9_-]{1,64}$/i.test(body.reason)) {
4147
- reason = body.reason;
4148
- }
4146
+ reason = clientAbortReason(body?.reason);
4149
4147
  }
4150
4148
  catch {
4151
4149
  // Empty/invalid body — keep the default user abort reason.
@@ -26,8 +26,8 @@ export declare function createRealtimeTokenHandler(): import("h3").EventHandlerW
26
26
  expiresAt?: undefined;
27
27
  ttlSeconds?: undefined;
28
28
  } | {
29
- error?: undefined;
30
29
  token: string;
31
30
  expiresAt: string;
32
31
  ttlSeconds: number;
32
+ error?: undefined;
33
33
  }>>;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@agent-native/core",
3
- "version": "0.168.13",
3
+ "version": "0.169.0",
4
4
  "description": "Framework for agent-native application development — where AI agents and UI share SQL state, actions, and context",
5
5
  "homepage": "https://github.com/BuilderIO/agent-native#readme",
6
6
  "bugs": {