@letta-ai/letta-code 0.30.8 → 0.30.10
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 +8 -2
- 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/agent/message.d.ts.map +1 -1
- package/dist/types/backend/local/local-store.d.ts.map +1 -1
- package/dist/types/channels/gateway-core.d.ts.map +1 -1
- package/dist/types/cli/helpers/accumulator.d.ts +1 -0
- package/dist/types/cli/helpers/accumulator.d.ts.map +1 -1
- package/dist/types/cli/helpers/stream-terminal-eof-guard.d.ts +14 -0
- package/dist/types/cli/helpers/stream-terminal-eof-guard.d.ts.map +1 -0
- package/dist/types/cli/helpers/stream.d.ts +1 -0
- package/dist/types/cli/helpers/stream.d.ts.map +1 -1
- package/dist/types/mods/mod-engine.d.ts +3 -7
- package/dist/types/mods/mod-engine.d.ts.map +1 -1
- package/dist/types/telemetry/error-reporting.d.ts +7 -0
- package/dist/types/telemetry/error-reporting.d.ts.map +1 -1
- package/dist/types/telemetry/index.d.ts +10 -0
- package/dist/types/telemetry/index.d.ts.map +1 -1
- package/dist/types/tools/impl/shell-runner.d.ts.map +1 -1
- package/dist/types/tools/manager.d.ts.map +1 -1
- package/dist/types/tools/toolset.d.ts +1 -0
- package/dist/types/tools/toolset.d.ts.map +1 -1
- package/dist/types/types/protocol_v2.d.ts +8 -9
- package/dist/types/types/protocol_v2.d.ts.map +1 -1
- package/dist/types/utils/secrets.d.ts.map +1 -1
- package/dist/types/websocket/listener/types.d.ts +1 -0
- package/dist/types/websocket/listener/types.d.ts.map +1 -1
- package/letta.js +367 -97
- package/package.json +1 -1
- package/scripts/dev.cjs +1 -2
- package/scripts/source-file-size-baseline.json +10 -9
- package/scripts/test-home-preload.ts +66 -0
- package/skills/creating-mods/references/ui.md +11 -1
package/dist/gateway-core.js
CHANGED
|
@@ -813,6 +813,9 @@ function uniqueSources(sources) {
|
|
|
813
813
|
byKey.set(sourceKey(source), source);
|
|
814
814
|
return [...byKey.values()];
|
|
815
815
|
}
|
|
816
|
+
function channelTagsForSources(sources) {
|
|
817
|
+
return [...new Set(sources.map((source) => `channel:${source.channel}`))];
|
|
818
|
+
}
|
|
816
819
|
function stopReasonFromDelta(message) {
|
|
817
820
|
const delta = message.delta;
|
|
818
821
|
return delta.message_type === "stop_reason" && "stop_reason" in delta && typeof delta.stop_reason === "string" ? delta.stop_reason : null;
|
|
@@ -1054,9 +1057,11 @@ class ChannelGateway {
|
|
|
1054
1057
|
}
|
|
1055
1058
|
async performRuntimeRegistration(state, delivery) {
|
|
1056
1059
|
const tool = await this.hooks.buildExternalTool(delivery.runtime, delivery.sources);
|
|
1060
|
+
const conversationTags = channelTagsForSources(delivery.sources);
|
|
1057
1061
|
const signature = JSON.stringify({
|
|
1058
1062
|
mode: delivery.defaultPermissionMode ?? null,
|
|
1059
|
-
tool
|
|
1063
|
+
tool,
|
|
1064
|
+
conversationTags
|
|
1060
1065
|
});
|
|
1061
1066
|
if (state.registrationSignature === signature && state.registration) {
|
|
1062
1067
|
return state.registration;
|
|
@@ -1064,6 +1069,7 @@ class ChannelGateway {
|
|
|
1064
1069
|
const registration = this.client.runtimeStart({
|
|
1065
1070
|
agent_id: delivery.runtime.agent_id,
|
|
1066
1071
|
conversation_id: delivery.runtime.conversation_id,
|
|
1072
|
+
...conversationTags.length > 0 ? { conversation_source_tags: conversationTags } : {},
|
|
1067
1073
|
...delivery.defaultPermissionMode ? { mode: delivery.defaultPermissionMode } : {},
|
|
1068
1074
|
recover_approvals: true,
|
|
1069
1075
|
force_device_status: false,
|
|
@@ -2205,4 +2211,4 @@ export {
|
|
|
2205
2211
|
ChannelGateway
|
|
2206
2212
|
};
|
|
2207
2213
|
|
|
2208
|
-
//# debugId=
|
|
2214
|
+
//# debugId=CF539D37E789E01964756E2164756E21
|