@letta-ai/letta-code 0.30.31 → 0.30.32
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/gateway-core.js +11 -4
- package/dist/gateway-core.js.map +3 -3
- package/dist/mcp-client.js +2 -2
- package/dist/mcp-client.js.map +1 -1
- package/dist/types/backend/api/ephemeral-conversations.d.ts +15 -0
- package/dist/types/backend/api/ephemeral-conversations.d.ts.map +1 -0
- package/dist/types/channels/gateway-core.d.ts.map +1 -1
- package/dist/types/providers/byok-providers.d.ts.map +1 -1
- package/dist/types/tools/impl/exec-command.d.ts.map +1 -1
- package/dist/types/tools/impl/shell-runner.d.ts +1 -0
- package/dist/types/tools/impl/shell-runner.d.ts.map +1 -1
- package/dist/types/tools/toolset.d.ts +1 -1
- package/dist/types/tools/toolset.d.ts.map +1 -1
- package/dist/types/types/external-tool-protocol.d.ts +2 -2
- package/dist/types/types/external-tool-protocol.d.ts.map +1 -1
- package/dist/types/types/protocol_v2.d.ts +27 -46
- package/dist/types/types/protocol_v2.d.ts.map +1 -1
- package/dist/types/types/runtime-scope.d.ts +4 -2
- package/dist/types/types/runtime-scope.d.ts.map +1 -1
- package/dist/types/types/runtime-start-protocol.d.ts +21 -0
- package/dist/types/types/runtime-start-protocol.d.ts.map +1 -0
- package/dist/types/websocket/listener/protocol-outbound.d.ts +1 -1
- package/dist/types/websocket/listener/protocol-outbound.d.ts.map +1 -1
- package/dist/types/websocket/listener/scope.d.ts +1 -1
- package/dist/types/websocket/listener/scope.d.ts.map +1 -1
- package/letta.js +995 -428
- package/package.json +2 -2
- package/scripts/codex-watch/release-analysis.test.ts +8 -16
- package/scripts/codex-watch/release-analysis.ts +1 -3
- package/scripts/codex-watch/tracker.test.ts +7 -28
- package/scripts/codex-watch/tracker.ts +26 -17
- package/scripts/source-file-size-baseline.json +3 -3
- package/skills/self-configuration/SKILL.md +20 -1
package/dist/gateway-core.js
CHANGED
|
@@ -1333,6 +1333,9 @@ var MAX_ACCEPTED_CLIENT_MESSAGE_IDS = 2048;
|
|
|
1333
1333
|
function runtimeKey(runtime) {
|
|
1334
1334
|
return `${runtime.agent_id}:${runtime.conversation_id}`;
|
|
1335
1335
|
}
|
|
1336
|
+
function hasAgentRuntime(value) {
|
|
1337
|
+
return !!value.runtime?.agent_id;
|
|
1338
|
+
}
|
|
1336
1339
|
function sourceRouteKey(source) {
|
|
1337
1340
|
return [
|
|
1338
1341
|
source.channel,
|
|
@@ -1391,7 +1394,7 @@ class ChannelGateway {
|
|
|
1391
1394
|
this.client = client;
|
|
1392
1395
|
this.hooks = hooks;
|
|
1393
1396
|
this.disposers.push(client.onMessage((message) => this.handleMessage(message)), client.onExternalToolCall((request) => {
|
|
1394
|
-
const state = request
|
|
1397
|
+
const state = hasAgentRuntime(request) ? this.states.get(runtimeKey(request.runtime)) : undefined;
|
|
1395
1398
|
const active = state?.active;
|
|
1396
1399
|
const sources = active?.routingSources ?? state?.routedSources ?? [];
|
|
1397
1400
|
return hooks.executeExternalTool(request, sources, active?.idempotencyScope ?? null);
|
|
@@ -1798,14 +1801,18 @@ class ChannelGateway {
|
|
|
1798
1801
|
}
|
|
1799
1802
|
handleMessage(message) {
|
|
1800
1803
|
if (message.type === "update_queue") {
|
|
1801
|
-
|
|
1804
|
+
if (hasAgentRuntime(message))
|
|
1805
|
+
this.handleQueueUpdate(message);
|
|
1802
1806
|
return;
|
|
1803
1807
|
}
|
|
1804
1808
|
if (message.type === "stream_delta") {
|
|
1805
|
-
|
|
1809
|
+
if (hasAgentRuntime(message))
|
|
1810
|
+
this.handleStreamDelta(message);
|
|
1806
1811
|
return;
|
|
1807
1812
|
}
|
|
1808
1813
|
if (message.type === "turn_finished") {
|
|
1814
|
+
if (!hasAgentRuntime(message))
|
|
1815
|
+
return;
|
|
1809
1816
|
this.handleTurnFinished(message.runtime, {
|
|
1810
1817
|
stopReason: message.stop_reason,
|
|
1811
1818
|
runId: message.run_id,
|
|
@@ -3001,4 +3008,4 @@ export {
|
|
|
3001
3008
|
ChannelControlRequestCoordinator
|
|
3002
3009
|
};
|
|
3003
3010
|
|
|
3004
|
-
//# debugId=
|
|
3011
|
+
//# debugId=EEE0C857500478C564756E2164756E21
|