@segmentstream/agent 0.18.1 → 0.18.2
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/_chunks/{build-metadata-CFvllAYE.mjs → build-metadata-CaihnyGE.mjs} +1 -1
- package/dist/_chunks/{inbound-request-Buuv7b1I.mjs → inbound-request-8xhK7EaW.mjs} +2 -2
- package/dist/_chunks/{principal-Dmm-cXNF.mjs → principal-qyR3jKAr.mjs} +1 -1
- package/dist/extension/hooks/authorization.mjs +1 -1
- package/dist/extension/lib/attachment-tools.mjs +1 -1
- package/dist/extension/lib/build-metadata.mjs +1 -1
- package/dist/extension/lib/confirmations.mjs +1 -1
- package/dist/extension/lib/conversation-runtime.mjs +1 -1
- package/dist/extension/lib/ontology-connection.mjs +1 -1
- package/dist/extension/lib/ontology-file-call.mjs +1 -1
- package/dist/extension/lib/ontology-tools.mjs +1 -1
- package/dist/extension/lib/runtime-envelope.mjs +1 -1
- package/dist/extension/lib/stored-files.mjs +1 -1
- package/dist/extension/lib/telegram/adapter.mjs +3 -3
- package/dist/extension/lib/telegram/attachment-description.mjs +1 -1
- package/dist/extension/lib/telegram/attachments-send.mjs +2 -2
- package/dist/extension/lib/telegram/callbacks.mjs +2 -2
- package/dist/extension/lib/telegram/confirmation-expiry.mjs +1 -1
- package/dist/extension/lib/telegram/confirmations.mjs +2 -2
- package/dist/extension/lib/telegram/conversations.mjs +1 -1
- package/dist/extension/lib/telegram/customer-text.d.ts +1 -1
- package/dist/extension/lib/telegram/customer-text.mjs +1 -1
- package/dist/extension/lib/telegram/deferred-confirmations.mjs +2 -2
- package/dist/extension/lib/telegram/durable-typing.mjs +1 -1
- package/dist/extension/lib/telegram/files.mjs +2 -2
- package/dist/extension/lib/telegram/health.mjs +1 -1
- package/dist/extension/lib/telegram/images.mjs +1 -1
- package/dist/extension/lib/telegram/inbound-request.mjs +1 -1
- package/dist/extension/lib/telegram/inbound.mjs +2 -2
- package/dist/extension/lib/telegram/lifecycle.mjs +3 -3
- package/dist/extension/lib/telegram/media-policy.mjs +1 -1
- package/dist/extension/lib/telegram/principal.mjs +1 -1
- package/dist/extension/lib/telegram/session-recovery.mjs +1 -1
- package/dist/extension/lib/telegram/silent.mjs +2 -2
- package/dist/extension/lib/telegram/structured.mjs +1 -1
- package/dist/extension/lib/telegram/turn-errors.mjs +2 -2
- package/dist/extension/lib/telegram/voice.mjs +1 -1
- package/dist/extension/model.mjs +1 -1
- package/dist/extension/tools/attachments_promote.mjs +1 -1
- package/dist/extension/tools/questions_ask.mjs +1 -1
- package/package.json +2 -2
|
@@ -4,7 +4,7 @@ import { createRequire as __eveCreateRequire } from "node:module";
|
|
|
4
4
|
const __filename = __eveFileURLToPath(import.meta.url);
|
|
5
5
|
__eveDirname(__filename);
|
|
6
6
|
__eveCreateRequire(import.meta.url);
|
|
7
|
-
var version = "0.18.
|
|
7
|
+
var version = "0.18.2";
|
|
8
8
|
function agentBuild(environment = process.env) {
|
|
9
9
|
return {
|
|
10
10
|
agent: version,
|
|
@@ -60,8 +60,8 @@ function reportTelegramError(operation, error, metadata = {}, secrets = new Set(
|
|
|
60
60
|
});
|
|
61
61
|
return errorId;
|
|
62
62
|
}
|
|
63
|
-
function failureText(
|
|
64
|
-
return
|
|
63
|
+
function failureText(_errorId, kind = "failed", _locale = currentLocale()) {
|
|
64
|
+
return customerCopy(_locale)[kind] ?? (kind === "cancelled" ? "⏹" : "⚠️");
|
|
65
65
|
}
|
|
66
66
|
function customerText(text, locale = currentLocale()) {
|
|
67
67
|
if (!isTechnicalText(text)) return text;
|
|
@@ -4,7 +4,7 @@ import { createRequire as __eveCreateRequire } from "node:module";
|
|
|
4
4
|
const __filename = __eveFileURLToPath(import.meta.url);
|
|
5
5
|
__eveDirname(__filename);
|
|
6
6
|
__eveCreateRequire(import.meta.url);
|
|
7
|
-
import { n as currentInboundRequest } from "./inbound-request-
|
|
7
|
+
import { n as currentInboundRequest } from "./inbound-request-8xhK7EaW.mjs";
|
|
8
8
|
import { randomUUID } from "node:crypto";
|
|
9
9
|
function telegramRuntimeSource(message, files, callbackQueryId) {
|
|
10
10
|
const attachments = [];
|
|
@@ -5,7 +5,7 @@ const __filename = __eveFileURLToPath(import.meta.url);
|
|
|
5
5
|
__eveDirname(__filename);
|
|
6
6
|
__eveCreateRequire(import.meta.url);
|
|
7
7
|
import { localizedText } from "../lib/admission.mjs";
|
|
8
|
-
import "../../_chunks/principal-
|
|
8
|
+
import "../../_chunks/principal-qyR3jKAr.mjs";
|
|
9
9
|
import { confirmationLocale } from "../lib/telegram/confirmation-text.mjs";
|
|
10
10
|
import segmentstream from "../extension.mjs";
|
|
11
11
|
import { defineHook } from "eve/hooks";
|
|
@@ -5,7 +5,7 @@ const __filename = __eveFileURLToPath(import.meta.url);
|
|
|
5
5
|
__eveDirname(__filename);
|
|
6
6
|
__eveCreateRequire(import.meta.url);
|
|
7
7
|
import { appOrigin } from "./environment.mjs";
|
|
8
|
-
import { i as memberIdOf } from "../../_chunks/principal-
|
|
8
|
+
import { i as memberIdOf } from "../../_chunks/principal-qyR3jKAr.mjs";
|
|
9
9
|
import { runtimeToken } from "./runtime-token.mjs";
|
|
10
10
|
import { agentAttachments } from "./attachments.mjs";
|
|
11
11
|
import { telegramConversation } from "./telegram/files.mjs";
|
|
@@ -4,5 +4,5 @@ import { createRequire as __eveCreateRequire } from "node:module";
|
|
|
4
4
|
const __filename = __eveFileURLToPath(import.meta.url);
|
|
5
5
|
__eveDirname(__filename);
|
|
6
6
|
__eveCreateRequire(import.meta.url);
|
|
7
|
-
import { t as agentBuild } from "../../_chunks/build-metadata-
|
|
7
|
+
import { t as agentBuild } from "../../_chunks/build-metadata-CaihnyGE.mjs";
|
|
8
8
|
export { agentBuild };
|
|
@@ -5,7 +5,7 @@ const __filename = __eveFileURLToPath(import.meta.url);
|
|
|
5
5
|
__eveDirname(__filename);
|
|
6
6
|
__eveCreateRequire(import.meta.url);
|
|
7
7
|
import { withTelegramTexts } from "./telegram/texts.mjs";
|
|
8
|
-
import { i as memberIdOf } from "../../_chunks/principal-
|
|
8
|
+
import { i as memberIdOf } from "../../_chunks/principal-qyR3jKAr.mjs";
|
|
9
9
|
import { confirmationCopy, confirmationLocale, renderConfirmation } from "./telegram/confirmation-text.mjs";
|
|
10
10
|
import { chatPostCard } from "./telegram/chat-post-card.mjs";
|
|
11
11
|
import { chatPostDigest, isChatPost } from "./chat-post-confirmation.mjs";
|
|
@@ -5,7 +5,7 @@ const __filename = __eveFileURLToPath(import.meta.url);
|
|
|
5
5
|
__eveDirname(__filename);
|
|
6
6
|
__eveCreateRequire(import.meta.url);
|
|
7
7
|
import { ENDS_CONVERSATION_INSTRUCTIONS } from "./group-routing/conversation-prompt.mjs";
|
|
8
|
-
import { i as memberIdOf } from "../../_chunks/principal-
|
|
8
|
+
import { i as memberIdOf } from "../../_chunks/principal-qyR3jKAr.mjs";
|
|
9
9
|
import { n as contentText, t as CONTENT_CAPS } from "../../_chunks/content-TRaZitQZ.mjs";
|
|
10
10
|
import { conversationEvent, conversations, sessionFailureEventId, summarizeArguments } from "./conversations.mjs";
|
|
11
11
|
import { parseAddress } from "./telegram/sessions.mjs";
|
|
@@ -5,7 +5,7 @@ const __filename = __eveFileURLToPath(import.meta.url);
|
|
|
5
5
|
__eveDirname(__filename);
|
|
6
6
|
__eveCreateRequire(import.meta.url);
|
|
7
7
|
import { appOrigin } from "./environment.mjs";
|
|
8
|
-
import { c as compatibleRuntimeEnvelope, i as memberIdOf, r as identityProviderOf, u as runtimeEnvelope } from "../../_chunks/principal-
|
|
8
|
+
import { c as compatibleRuntimeEnvelope, i as memberIdOf, r as identityProviderOf, u as runtimeEnvelope } from "../../_chunks/principal-qyR3jKAr.mjs";
|
|
9
9
|
import { runtimeToken, tokenExpiry } from "./runtime-token.mjs";
|
|
10
10
|
import { CHAT_POST_ENVELOPE, chatPostDigest, chatPostOperationId, isChatPost } from "./chat-post-confirmation.mjs";
|
|
11
11
|
import { actionApproval, confirmations } from "./confirmations.mjs";
|
|
@@ -4,7 +4,7 @@ import { createRequire as __eveCreateRequire } from "node:module";
|
|
|
4
4
|
const __filename = __eveFileURLToPath(import.meta.url);
|
|
5
5
|
__eveDirname(__filename);
|
|
6
6
|
__eveCreateRequire(import.meta.url);
|
|
7
|
-
import { i as memberIdOf, u as runtimeEnvelope } from "../../_chunks/principal-
|
|
7
|
+
import { i as memberIdOf, u as runtimeEnvelope } from "../../_chunks/principal-qyR3jKAr.mjs";
|
|
8
8
|
import { isChatPost } from "./chat-post-confirmation.mjs";
|
|
9
9
|
import { actionApproval, confirmations, inputHash } from "./confirmations.mjs";
|
|
10
10
|
import { ontologyTools } from "./ontology-tools.mjs";
|
|
@@ -5,7 +5,7 @@ const __filename = __eveFileURLToPath(import.meta.url);
|
|
|
5
5
|
__eveDirname(__filename);
|
|
6
6
|
__eveCreateRequire(import.meta.url);
|
|
7
7
|
import { appOrigin } from "./environment.mjs";
|
|
8
|
-
import { c as compatibleRuntimeEnvelope, i as memberIdOf, r as identityProviderOf, s as RUNTIME_SOURCE_PROTOCOL, u as runtimeEnvelope } from "../../_chunks/principal-
|
|
8
|
+
import { c as compatibleRuntimeEnvelope, i as memberIdOf, r as identityProviderOf, s as RUNTIME_SOURCE_PROTOCOL, u as runtimeEnvelope } from "../../_chunks/principal-qyR3jKAr.mjs";
|
|
9
9
|
import { redactDiagnostic } from "./diagnostics.mjs";
|
|
10
10
|
import { describeConfirmation, object } from "./confirmation-description.mjs";
|
|
11
11
|
import { runtimeToken } from "./runtime-token.mjs";
|
|
@@ -4,5 +4,5 @@ import { createRequire as __eveCreateRequire } from "node:module";
|
|
|
4
4
|
const __filename = __eveFileURLToPath(import.meta.url);
|
|
5
5
|
__eveDirname(__filename);
|
|
6
6
|
__eveCreateRequire(import.meta.url);
|
|
7
|
-
import { c as compatibleRuntimeEnvelope, d as telegramRuntimeSource, l as principalRuntimeSource, s as RUNTIME_SOURCE_PROTOCOL, u as runtimeEnvelope } from "../../_chunks/principal-
|
|
7
|
+
import { c as compatibleRuntimeEnvelope, d as telegramRuntimeSource, l as principalRuntimeSource, s as RUNTIME_SOURCE_PROTOCOL, u as runtimeEnvelope } from "../../_chunks/principal-qyR3jKAr.mjs";
|
|
8
8
|
export { RUNTIME_SOURCE_PROTOCOL, compatibleRuntimeEnvelope, principalRuntimeSource, runtimeEnvelope, telegramRuntimeSource };
|
|
@@ -4,7 +4,7 @@ import { createRequire as __eveCreateRequire } from "node:module";
|
|
|
4
4
|
const __filename = __eveFileURLToPath(import.meta.url);
|
|
5
5
|
__eveDirname(__filename);
|
|
6
6
|
__eveCreateRequire(import.meta.url);
|
|
7
|
-
import { i as memberIdOf } from "../../_chunks/principal-
|
|
7
|
+
import { i as memberIdOf } from "../../_chunks/principal-qyR3jKAr.mjs";
|
|
8
8
|
import { redactDiagnostic } from "./diagnostics.mjs";
|
|
9
9
|
import { object } from "./confirmation-description.mjs";
|
|
10
10
|
import { OntologyFileUnavailable, ontologyTools } from "./ontology-tools.mjs";
|
|
@@ -7,13 +7,13 @@ __eveCreateRequire(import.meta.url);
|
|
|
7
7
|
import { telegramText, withTelegramTexts } from "./texts.mjs";
|
|
8
8
|
import { manifestOf } from "../../config.mjs";
|
|
9
9
|
import { appOrigin, channelsEnabled, proxyEnvironment, runtimeIdentityEnvironment, webhookSecret } from "../environment.mjs";
|
|
10
|
-
import { n as conversationLanguage, o as telegramPrincipal } from "../../../_chunks/principal-
|
|
10
|
+
import { n as conversationLanguage, o as telegramPrincipal } from "../../../_chunks/principal-qyR3jKAr.mjs";
|
|
11
11
|
import { confirmationLocale } from "./confirmation-text.mjs";
|
|
12
12
|
import { telegramSendScope } from "./send-queue.mjs";
|
|
13
13
|
import { runtimeToken } from "../runtime-token.mjs";
|
|
14
14
|
import { conversations } from "../conversations.mjs";
|
|
15
15
|
import { withDeliveryDiagnostics } from "./delivery-diagnostics.mjs";
|
|
16
|
-
import { d as failureText, h as withDeliveryLocale, i as withReplacedText, m as safeTelegramFetch, n as currentInboundRequest, o as currentLocale, p as reportTelegramError, r as runInboundRequest, t as InboundRequest } from "../../../_chunks/inbound-request-
|
|
16
|
+
import { d as failureText, h as withDeliveryLocale, i as withReplacedText, m as safeTelegramFetch, n as currentInboundRequest, o as currentLocale, p as reportTelegramError, r as runInboundRequest, t as InboundRequest } from "../../../_chunks/inbound-request-8xhK7EaW.mjs";
|
|
17
17
|
import { chooseModel } from "../../model.mjs";
|
|
18
18
|
import { groupRoutingHealth } from "../group-routing/health.mjs";
|
|
19
19
|
import { decisionRouter } from "../group-routing/router.mjs";
|
|
@@ -22,7 +22,7 @@ import { MAXIMUM_DOWNLOAD_BYTES, connectionProxy } from "../connection-proxy.mjs
|
|
|
22
22
|
import { dispatchStructuredMessage, structuredMessage } from "./structured.mjs";
|
|
23
23
|
import { scopedAddress, sessionPolicy } from "./sessions.mjs";
|
|
24
24
|
import { handleWorkspaceCallback, isWorkspaceCallback } from "./callbacks.mjs";
|
|
25
|
-
import { t as agentBuild } from "../../../_chunks/build-metadata-
|
|
25
|
+
import { t as agentBuild } from "../../../_chunks/build-metadata-CaihnyGE.mjs";
|
|
26
26
|
import { attachmentLifecycle } from "./lifecycle.mjs";
|
|
27
27
|
import { observedMessages } from "./observed.mjs";
|
|
28
28
|
import { expireDeferredCards, handleDeferredCallback, isDeferredCallback } from "./deferred-confirmations.mjs";
|
|
@@ -4,7 +4,7 @@ import { createRequire as __eveCreateRequire } from "node:module";
|
|
|
4
4
|
const __filename = __eveFileURLToPath(import.meta.url);
|
|
5
5
|
__eveDirname(__filename);
|
|
6
6
|
__eveCreateRequire(import.meta.url);
|
|
7
|
-
import { p as reportTelegramError } from "../../../_chunks/inbound-request-
|
|
7
|
+
import { p as reportTelegramError } from "../../../_chunks/inbound-request-8xhK7EaW.mjs";
|
|
8
8
|
import { describableImage } from "./images.mjs";
|
|
9
9
|
import { MAXIMUM_ROUTING_PDF_CHARACTERS, extractRoutingPdf } from "./pdf-text.mjs";
|
|
10
10
|
import { gateway, generateText } from "ai";
|
|
@@ -5,12 +5,12 @@ const __filename = __eveFileURLToPath(import.meta.url);
|
|
|
5
5
|
__eveDirname(__filename);
|
|
6
6
|
__eveCreateRequire(import.meta.url);
|
|
7
7
|
import { appOrigin, channelsEnabled, proxyEnvironment } from "../environment.mjs";
|
|
8
|
-
import "../../../_chunks/principal-
|
|
8
|
+
import "../../../_chunks/principal-qyR3jKAr.mjs";
|
|
9
9
|
import { redactDiagnostic } from "../diagnostics.mjs";
|
|
10
10
|
import { confirmationLocale } from "./confirmation-text.mjs";
|
|
11
11
|
import { inTelegramSendQueue, telegramSendScope } from "./send-queue.mjs";
|
|
12
12
|
import { runtimeToken } from "../runtime-token.mjs";
|
|
13
|
-
import { d as failureText, f as formattingRefused, l as customerMessage, p as reportTelegramError } from "../../../_chunks/inbound-request-
|
|
13
|
+
import { d as failureText, f as formattingRefused, l as customerMessage, p as reportTelegramError } from "../../../_chunks/inbound-request-8xhK7EaW.mjs";
|
|
14
14
|
import { MAXIMUM_PROXY_BODY_BYTES, connectionProxy } from "../connection-proxy.mjs";
|
|
15
15
|
import { ACT_AS_HEADER } from "../ontology-connection.mjs";
|
|
16
16
|
import { AttachmentError, CONVERSATION_HEADER, SESSION_HEADER } from "../attachments.mjs";
|
|
@@ -6,9 +6,9 @@ __eveDirname(__filename);
|
|
|
6
6
|
__eveCreateRequire(import.meta.url);
|
|
7
7
|
import { admitMessage } from "../admission.mjs";
|
|
8
8
|
import { telegramText } from "./texts.mjs";
|
|
9
|
-
import { d as telegramRuntimeSource, i as memberIdOf, o as telegramPrincipal, u as runtimeEnvelope } from "../../../_chunks/principal-
|
|
9
|
+
import { d as telegramRuntimeSource, i as memberIdOf, o as telegramPrincipal, u as runtimeEnvelope } from "../../../_chunks/principal-qyR3jKAr.mjs";
|
|
10
10
|
import { object } from "../confirmation-description.mjs";
|
|
11
|
-
import { n as currentInboundRequest, p as reportTelegramError } from "../../../_chunks/inbound-request-
|
|
11
|
+
import { n as currentInboundRequest, p as reportTelegramError } from "../../../_chunks/inbound-request-8xhK7EaW.mjs";
|
|
12
12
|
import { workspaceAction } from "./workspace-action.mjs";
|
|
13
13
|
import { formatAddress, parseAddress, scopedAddress } from "./sessions.mjs";
|
|
14
14
|
const isWorkspaceCallback = (data) => data?.startsWith("ws:") === true;
|
|
@@ -9,7 +9,7 @@ import { proxyEnvironment } from "../environment.mjs";
|
|
|
9
9
|
import { telegramSendScope } from "./send-queue.mjs";
|
|
10
10
|
import { runtimeToken } from "../runtime-token.mjs";
|
|
11
11
|
import { conversations } from "../conversations.mjs";
|
|
12
|
-
import { m as safeTelegramFetch, p as reportTelegramError } from "../../../_chunks/inbound-request-
|
|
12
|
+
import { m as safeTelegramFetch, p as reportTelegramError } from "../../../_chunks/inbound-request-8xhK7EaW.mjs";
|
|
13
13
|
import { connectionProxy } from "../connection-proxy.mjs";
|
|
14
14
|
import { deferredConfirmations } from "../deferred-confirmations.mjs";
|
|
15
15
|
import { expireDeferredRecord } from "./deferred-confirmations.mjs";
|
|
@@ -5,12 +5,12 @@ const __filename = __eveFileURLToPath(import.meta.url);
|
|
|
5
5
|
__eveDirname(__filename);
|
|
6
6
|
__eveCreateRequire(import.meta.url);
|
|
7
7
|
import { telegramText } from "./texts.mjs";
|
|
8
|
-
import { i as memberIdOf, o as telegramPrincipal } from "../../../_chunks/principal-
|
|
8
|
+
import { i as memberIdOf, o as telegramPrincipal } from "../../../_chunks/principal-qyR3jKAr.mjs";
|
|
9
9
|
import { humanText } from "../confirmation-description.mjs";
|
|
10
10
|
import { renderConfirmation, withConfirmationText } from "./confirmation-text.mjs";
|
|
11
11
|
import { chatPostCard, chatPostCardStatus, chatPostReceipt, withChatPostCard } from "./chat-post-card.mjs";
|
|
12
12
|
import { conversationEvent } from "../conversations.mjs";
|
|
13
|
-
import { n as currentInboundRequest, p as reportTelegramError } from "../../../_chunks/inbound-request-
|
|
13
|
+
import { n as currentInboundRequest, p as reportTelegramError } from "../../../_chunks/inbound-request-8xhK7EaW.mjs";
|
|
14
14
|
import { agentMessage, observedChatKey, withConfirmationPrompt } from "../group-routing/observed.mjs";
|
|
15
15
|
import { chatPostOperationId, isChatPost } from "../chat-post-confirmation.mjs";
|
|
16
16
|
import { confirmations } from "../confirmations.mjs";
|
|
@@ -6,7 +6,7 @@ __eveDirname(__filename);
|
|
|
6
6
|
__eveCreateRequire(import.meta.url);
|
|
7
7
|
import { n as contentText, t as CONTENT_CAPS } from "../../../_chunks/content-TRaZitQZ.mjs";
|
|
8
8
|
import { conversationEvent, sessionFailureEventId } from "../conversations.mjs";
|
|
9
|
-
import { n as currentInboundRequest, p as reportTelegramError, s as currentThreadId } from "../../../_chunks/inbound-request-
|
|
9
|
+
import { n as currentInboundRequest, p as reportTelegramError, s as currentThreadId } from "../../../_chunks/inbound-request-8xhK7EaW.mjs";
|
|
10
10
|
import { currentConfirmationPrompt, observedChatKey } from "../group-routing/observed.mjs";
|
|
11
11
|
import { archivedRoutingMessages } from "../group-routing/routing-context.mjs";
|
|
12
12
|
import { contentShape, messageContent } from "./content.mjs";
|
|
@@ -16,7 +16,7 @@ export declare function customerCopy(locale?: string): {
|
|
|
16
16
|
};
|
|
17
17
|
/** Original failures stay in operator diagnostics, joined to the public notice by a short reference. */
|
|
18
18
|
export declare function reportTelegramError(operation: string, error: unknown, metadata?: Record<string, unknown>, secrets?: ReadonlySet<string>): string;
|
|
19
|
-
export declare function failureText(
|
|
19
|
+
export declare function failureText(_errorId: string, kind?: "failed" | "cancelled" | "recovery" | "attachment" | "authorization" | "response", _locale?: string): string;
|
|
20
20
|
export declare function customerText(text: string, locale?: string): string;
|
|
21
21
|
/** Check what Telegram will display, including hidden link destinations, after removing markup. */
|
|
22
22
|
export declare function customerMessage(text: string, locale?: string): TelegramText;
|
|
@@ -5,5 +5,5 @@ const __filename = __eveFileURLToPath(import.meta.url);
|
|
|
5
5
|
__eveDirname(__filename);
|
|
6
6
|
__eveCreateRequire(import.meta.url);
|
|
7
7
|
import { isTechnicalText } from "../customer-text-safety.mjs";
|
|
8
|
-
import { a as TelegramDeliveryError, c as customerCopy, d as failureText, f as formattingRefused, h as withDeliveryLocale, l as customerMessage, m as safeTelegramFetch, o as currentLocale, p as reportTelegramError, s as currentThreadId, u as customerText } from "../../../_chunks/inbound-request-
|
|
8
|
+
import { a as TelegramDeliveryError, c as customerCopy, d as failureText, f as formattingRefused, h as withDeliveryLocale, l as customerMessage, m as safeTelegramFetch, o as currentLocale, p as reportTelegramError, s as currentThreadId, u as customerText } from "../../../_chunks/inbound-request-8xhK7EaW.mjs";
|
|
9
9
|
export { TelegramDeliveryError, currentLocale, currentThreadId, customerCopy, customerMessage, customerText, failureText, formattingRefused, isTechnicalText, reportTelegramError, safeTelegramFetch, withDeliveryLocale };
|
|
@@ -5,12 +5,12 @@ const __filename = __eveFileURLToPath(import.meta.url);
|
|
|
5
5
|
__eveDirname(__filename);
|
|
6
6
|
__eveCreateRequire(import.meta.url);
|
|
7
7
|
import { telegramText, withTelegramLocale } from "./texts.mjs";
|
|
8
|
-
import { o as telegramPrincipal } from "../../../_chunks/principal-
|
|
8
|
+
import { o as telegramPrincipal } from "../../../_chunks/principal-qyR3jKAr.mjs";
|
|
9
9
|
import { humanText } from "../confirmation-description.mjs";
|
|
10
10
|
import { renderConfirmation, withConfirmationText } from "./confirmation-text.mjs";
|
|
11
11
|
import { chatPostCard, chatPostCardStatus, chatPostReceipt, withChatPostCard } from "./chat-post-card.mjs";
|
|
12
12
|
import { conversationEvent } from "../conversations.mjs";
|
|
13
|
-
import { n as currentInboundRequest, p as reportTelegramError } from "../../../_chunks/inbound-request-
|
|
13
|
+
import { n as currentInboundRequest, p as reportTelegramError } from "../../../_chunks/inbound-request-8xhK7EaW.mjs";
|
|
14
14
|
import { agentMessage, observedChatKey, withConfirmationPrompt } from "../group-routing/observed.mjs";
|
|
15
15
|
import { CONFIRMATION_TTL_MS, inputHash } from "../confirmations.mjs";
|
|
16
16
|
import { OntologyToolRejected } from "../ontology-tools.mjs";
|
|
@@ -8,7 +8,7 @@ import { channelsEnabled, proxyEnvironment } from "../environment.mjs";
|
|
|
8
8
|
import { redactTelegramDiagnostic } from "./diagnostic-redaction.mjs";
|
|
9
9
|
import { runtimeToken } from "../runtime-token.mjs";
|
|
10
10
|
import { conversationEvent, conversations } from "../conversations.mjs";
|
|
11
|
-
import { p as reportTelegramError } from "../../../_chunks/inbound-request-
|
|
11
|
+
import { p as reportTelegramError } from "../../../_chunks/inbound-request-8xhK7EaW.mjs";
|
|
12
12
|
import { connectionProxy } from "../connection-proxy.mjs";
|
|
13
13
|
import { sessions } from "eve/server";
|
|
14
14
|
const object = (value) => value !== null && typeof value === "object" && !Array.isArray(value);
|
|
@@ -4,8 +4,8 @@ import { createRequire as __eveCreateRequire } from "node:module";
|
|
|
4
4
|
const __filename = __eveFileURLToPath(import.meta.url);
|
|
5
5
|
__eveDirname(__filename);
|
|
6
6
|
__eveCreateRequire(import.meta.url);
|
|
7
|
-
import { n as conversationLanguage } from "../../../_chunks/principal-
|
|
8
|
-
import { d as failureText, p as reportTelegramError } from "../../../_chunks/inbound-request-
|
|
7
|
+
import { n as conversationLanguage } from "../../../_chunks/principal-qyR3jKAr.mjs";
|
|
8
|
+
import { d as failureText, p as reportTelegramError } from "../../../_chunks/inbound-request-8xhK7EaW.mjs";
|
|
9
9
|
import { describableImage, describeReceivedImage } from "./images.mjs";
|
|
10
10
|
import { MAXIMUM_ATTACHMENT_BYTES, attachmentUrl } from "../attachments.mjs";
|
|
11
11
|
function telegramConversation(chatId) {
|
|
@@ -4,7 +4,7 @@ import { createRequire as __eveCreateRequire } from "node:module";
|
|
|
4
4
|
const __filename = __eveFileURLToPath(import.meta.url);
|
|
5
5
|
__eveDirname(__filename);
|
|
6
6
|
__eveCreateRequire(import.meta.url);
|
|
7
|
-
import { t as agentBuild } from "../../../_chunks/build-metadata-
|
|
7
|
+
import { t as agentBuild } from "../../../_chunks/build-metadata-CaihnyGE.mjs";
|
|
8
8
|
import { runtimeRequestFailure } from "./runtime-request.mjs";
|
|
9
9
|
import { GET } from "eve/channels";
|
|
10
10
|
const HEALTH_ROUTE = "/eve/v1/telegram/health";
|
|
@@ -4,7 +4,7 @@ import { createRequire as __eveCreateRequire } from "node:module";
|
|
|
4
4
|
const __filename = __eveFileURLToPath(import.meta.url);
|
|
5
5
|
__eveDirname(__filename);
|
|
6
6
|
__eveCreateRequire(import.meta.url);
|
|
7
|
-
import { p as reportTelegramError } from "../../../_chunks/inbound-request-
|
|
7
|
+
import { p as reportTelegramError } from "../../../_chunks/inbound-request-8xhK7EaW.mjs";
|
|
8
8
|
import { gateway, generateText } from "ai";
|
|
9
9
|
const MAXIMUM_IMAGE_DESCRIPTION_BYTES = 5242880;
|
|
10
10
|
const MAXIMUM_NATIVE_IMAGE_BYTES = 3145728;
|
|
@@ -4,5 +4,5 @@ import { createRequire as __eveCreateRequire } from "node:module";
|
|
|
4
4
|
const __filename = __eveFileURLToPath(import.meta.url);
|
|
5
5
|
__eveDirname(__filename);
|
|
6
6
|
__eveCreateRequire(import.meta.url);
|
|
7
|
-
import { i as withReplacedText, n as currentInboundRequest, r as runInboundRequest, t as InboundRequest } from "../../../_chunks/inbound-request-
|
|
7
|
+
import { i as withReplacedText, n as currentInboundRequest, r as runInboundRequest, t as InboundRequest } from "../../../_chunks/inbound-request-8xhK7EaW.mjs";
|
|
8
8
|
export { InboundRequest, currentInboundRequest, runInboundRequest, withReplacedText };
|
|
@@ -6,8 +6,8 @@ __eveDirname(__filename);
|
|
|
6
6
|
__eveCreateRequire(import.meta.url);
|
|
7
7
|
import { effectiveGroupPolicy, groupPolicy } from "../group-routing/policy.mjs";
|
|
8
8
|
import { admitMessage, localizedText } from "../admission.mjs";
|
|
9
|
-
import { d as telegramRuntimeSource, n as conversationLanguage, o as telegramPrincipal, u as runtimeEnvelope } from "../../../_chunks/principal-
|
|
10
|
-
import { p as reportTelegramError } from "../../../_chunks/inbound-request-
|
|
9
|
+
import { d as telegramRuntimeSource, n as conversationLanguage, o as telegramPrincipal, u as runtimeEnvelope } from "../../../_chunks/principal-qyR3jKAr.mjs";
|
|
10
|
+
import { p as reportTelegramError } from "../../../_chunks/inbound-request-8xhK7EaW.mjs";
|
|
11
11
|
import { addressingReason, conversationKey, otherRecipient } from "../group-routing/signals.mjs";
|
|
12
12
|
import { conversationAddressing, conversationState } from "../group-routing/conversation.mjs";
|
|
13
13
|
import { questionInvitation } from "../group-routing/engagement.mjs";
|
|
@@ -4,12 +4,12 @@ import { createRequire as __eveCreateRequire } from "node:module";
|
|
|
4
4
|
const __filename = __eveFileURLToPath(import.meta.url);
|
|
5
5
|
__eveDirname(__filename);
|
|
6
6
|
__eveCreateRequire(import.meta.url);
|
|
7
|
-
import { d as telegramRuntimeSource, l as principalRuntimeSource, u as runtimeEnvelope } from "../../../_chunks/principal-
|
|
7
|
+
import { d as telegramRuntimeSource, l as principalRuntimeSource, u as runtimeEnvelope } from "../../../_chunks/principal-qyR3jKAr.mjs";
|
|
8
8
|
import { object } from "../confirmation-description.mjs";
|
|
9
|
-
import { n as currentInboundRequest, p as reportTelegramError } from "../../../_chunks/inbound-request-
|
|
9
|
+
import { n as currentInboundRequest, p as reportTelegramError } from "../../../_chunks/inbound-request-8xhK7EaW.mjs";
|
|
10
10
|
import { needsConfirmation } from "../confirmations.mjs";
|
|
11
11
|
import { OntologyActionNotPermitted, actionToolName, ontologyTools } from "../ontology-tools.mjs";
|
|
12
|
-
import { t as agentBuild } from "../../../_chunks/build-metadata-
|
|
12
|
+
import { t as agentBuild } from "../../../_chunks/build-metadata-CaihnyGE.mjs";
|
|
13
13
|
var AttachmentLifecycleNotPermitted = class extends Error {
|
|
14
14
|
code = "attachment_lifecycle_not_permitted";
|
|
15
15
|
};
|
|
@@ -5,7 +5,7 @@ const __filename = __eveFileURLToPath(import.meta.url);
|
|
|
5
5
|
__eveDirname(__filename);
|
|
6
6
|
__eveCreateRequire(import.meta.url);
|
|
7
7
|
import { DEFAULT_IMAGE_DESCRIPTION_MODEL } from "../../config.mjs";
|
|
8
|
-
import { p as reportTelegramError } from "../../../_chunks/inbound-request-
|
|
8
|
+
import { p as reportTelegramError } from "../../../_chunks/inbound-request-8xhK7EaW.mjs";
|
|
9
9
|
function planMedia(capabilities, descriptionModel = null) {
|
|
10
10
|
if (typeof descriptionModel === "string") return {
|
|
11
11
|
images: "describe",
|
|
@@ -4,5 +4,5 @@ import { createRequire as __eveCreateRequire } from "node:module";
|
|
|
4
4
|
const __filename = __eveFileURLToPath(import.meta.url);
|
|
5
5
|
__eveDirname(__filename);
|
|
6
6
|
__eveCreateRequire(import.meta.url);
|
|
7
|
-
import { a as rolesOf, i as memberIdOf, n as conversationLanguage, o as telegramPrincipal, r as identityProviderOf, t as TELEGRAM_AUTHENTICATOR } from "../../../_chunks/principal-
|
|
7
|
+
import { a as rolesOf, i as memberIdOf, n as conversationLanguage, o as telegramPrincipal, r as identityProviderOf, t as TELEGRAM_AUTHENTICATOR } from "../../../_chunks/principal-qyR3jKAr.mjs";
|
|
8
8
|
export { TELEGRAM_AUTHENTICATOR, conversationLanguage, identityProviderOf, memberIdOf, rolesOf, telegramPrincipal };
|
|
@@ -4,7 +4,7 @@ import { createRequire as __eveCreateRequire } from "node:module";
|
|
|
4
4
|
const __filename = __eveFileURLToPath(import.meta.url);
|
|
5
5
|
__eveDirname(__filename);
|
|
6
6
|
__eveCreateRequire(import.meta.url);
|
|
7
|
-
import { p as reportTelegramError } from "../../../_chunks/inbound-request-
|
|
7
|
+
import { p as reportTelegramError } from "../../../_chunks/inbound-request-8xhK7EaW.mjs";
|
|
8
8
|
import { createHash } from "node:crypto";
|
|
9
9
|
function missingDeployment(error) {
|
|
10
10
|
if (!(error instanceof Error) || error.name !== "RunKeyFetchError" || !("status" in error) || error.status !== 404) return false;
|
|
@@ -4,11 +4,11 @@ import { createRequire as __eveCreateRequire } from "node:module";
|
|
|
4
4
|
const __filename = __eveFileURLToPath(import.meta.url);
|
|
5
5
|
__eveDirname(__filename);
|
|
6
6
|
__eveCreateRequire(import.meta.url);
|
|
7
|
-
import "../../../_chunks/principal-
|
|
7
|
+
import "../../../_chunks/principal-qyR3jKAr.mjs";
|
|
8
8
|
import { confirmationLocale } from "./confirmation-text.mjs";
|
|
9
9
|
import { splitTelegramText } from "./format.mjs";
|
|
10
10
|
import { inTelegramSendQueue } from "./send-queue.mjs";
|
|
11
|
-
import { a as TelegramDeliveryError, l as customerMessage, o as currentLocale, p as reportTelegramError } from "../../../_chunks/inbound-request-
|
|
11
|
+
import { a as TelegramDeliveryError, l as customerMessage, o as currentLocale, p as reportTelegramError } from "../../../_chunks/inbound-request-8xhK7EaW.mjs";
|
|
12
12
|
import { agentMessage, observedChatKey } from "../group-routing/observed.mjs";
|
|
13
13
|
const SILENT_MARKERS = new Set(["[silent]", "no_reply"]);
|
|
14
14
|
function isSilentReply(text) {
|
|
@@ -5,7 +5,7 @@ const __filename = __eveFileURLToPath(import.meta.url);
|
|
|
5
5
|
__eveDirname(__filename);
|
|
6
6
|
__eveCreateRequire(import.meta.url);
|
|
7
7
|
import { STRUCTURED_KINDS } from "./structured-settings.mjs";
|
|
8
|
-
import { d as telegramRuntimeSource, u as runtimeEnvelope } from "../../../_chunks/principal-
|
|
8
|
+
import { d as telegramRuntimeSource, u as runtimeEnvelope } from "../../../_chunks/principal-qyR3jKAr.mjs";
|
|
9
9
|
import { workspaceAction } from "./workspace-action.mjs";
|
|
10
10
|
const record = (value) => {
|
|
11
11
|
if (value === null || typeof value !== "object" || Array.isArray(value)) throw new Error("Invalid structured Telegram object.");
|
|
@@ -5,9 +5,9 @@ const __filename = __eveFileURLToPath(import.meta.url);
|
|
|
5
5
|
__eveDirname(__filename);
|
|
6
6
|
__eveCreateRequire(import.meta.url);
|
|
7
7
|
import { telegramText } from "./texts.mjs";
|
|
8
|
-
import { i as memberIdOf } from "../../../_chunks/principal-
|
|
8
|
+
import { i as memberIdOf } from "../../../_chunks/principal-qyR3jKAr.mjs";
|
|
9
9
|
import { confirmationLocale } from "./confirmation-text.mjs";
|
|
10
|
-
import { c as customerCopy, d as failureText, o as currentLocale, p as reportTelegramError, s as currentThreadId } from "../../../_chunks/inbound-request-
|
|
10
|
+
import { c as customerCopy, d as failureText, o as currentLocale, p as reportTelegramError, s as currentThreadId } from "../../../_chunks/inbound-request-8xhK7EaW.mjs";
|
|
11
11
|
import { recordSessionFailure } from "./conversations.mjs";
|
|
12
12
|
import { isSilentRoutingCancellation } from "../group-routing/cancellation.mjs";
|
|
13
13
|
function telegramFailureEvents(input) {
|
|
@@ -4,7 +4,7 @@ import { createRequire as __eveCreateRequire } from "node:module";
|
|
|
4
4
|
const __filename = __eveFileURLToPath(import.meta.url);
|
|
5
5
|
__eveDirname(__filename);
|
|
6
6
|
__eveCreateRequire(import.meta.url);
|
|
7
|
-
import { p as reportTelegramError } from "../../../_chunks/inbound-request-
|
|
7
|
+
import { p as reportTelegramError } from "../../../_chunks/inbound-request-8xhK7EaW.mjs";
|
|
8
8
|
import "../connection-proxy.mjs";
|
|
9
9
|
import { gateway, transcribe } from "ai";
|
|
10
10
|
const LABELS = {
|
package/dist/extension/model.mjs
CHANGED
|
@@ -5,7 +5,7 @@ const __filename = __eveFileURLToPath(import.meta.url);
|
|
|
5
5
|
__eveDirname(__filename);
|
|
6
6
|
__eveCreateRequire(import.meta.url);
|
|
7
7
|
import { isPreview } from "./lib/environment.mjs";
|
|
8
|
-
import { a as rolesOf } from "../_chunks/principal-
|
|
8
|
+
import { a as rolesOf } from "../_chunks/principal-qyR3jKAr.mjs";
|
|
9
9
|
import { defineDynamic } from "eve";
|
|
10
10
|
function chooseModel(input) {
|
|
11
11
|
const { choice } = input;
|
|
@@ -4,7 +4,7 @@ import { createRequire as __eveCreateRequire } from "node:module";
|
|
|
4
4
|
const __filename = __eveFileURLToPath(import.meta.url);
|
|
5
5
|
__eveDirname(__filename);
|
|
6
6
|
__eveCreateRequire(import.meta.url);
|
|
7
|
-
import { u as runtimeEnvelope } from "../../_chunks/principal-
|
|
7
|
+
import { u as runtimeEnvelope } from "../../_chunks/principal-qyR3jKAr.mjs";
|
|
8
8
|
import { n as workflowToolResult } from "../../_chunks/workflow-serializable-_g4JRau5.mjs";
|
|
9
9
|
import segmentstream from "../extension.mjs";
|
|
10
10
|
import { actionApproval } from "../lib/confirmations.mjs";
|
|
@@ -4,7 +4,7 @@ import { createRequire as __eveCreateRequire } from "node:module";
|
|
|
4
4
|
const __filename = __eveFileURLToPath(import.meta.url);
|
|
5
5
|
__eveDirname(__filename);
|
|
6
6
|
__eveCreateRequire(import.meta.url);
|
|
7
|
-
import { i as memberIdOf } from "../../_chunks/principal-
|
|
7
|
+
import { i as memberIdOf } from "../../_chunks/principal-qyR3jKAr.mjs";
|
|
8
8
|
import { n as workflowToolResult } from "../../_chunks/workflow-serializable-_g4JRau5.mjs";
|
|
9
9
|
import { pendingQuestions, questionKey } from "../lib/questions.mjs";
|
|
10
10
|
import { stringArgument } from "../lib/attachment-tools.mjs";
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@segmentstream/agent",
|
|
3
|
-
"version": "0.18.
|
|
3
|
+
"version": "0.18.2",
|
|
4
4
|
"description": "Mount a SegmentStream workspace's agent on eve: the ontology as tools, acting as the member who writes, and Telegram through the workspace's connection.",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"author": "SegmentStream",
|
|
@@ -66,7 +66,7 @@
|
|
|
66
66
|
},
|
|
67
67
|
"dependencies": {
|
|
68
68
|
"@chat-adapter/telegram": "4.41.0",
|
|
69
|
-
"@segmentstream-cloud/ontology": "0.
|
|
69
|
+
"@segmentstream-cloud/ontology": "0.60.0",
|
|
70
70
|
"@vercel/oidc": "^3.8.4",
|
|
71
71
|
"ai": "^7.0.128",
|
|
72
72
|
"csv-parse": "^7.0.3",
|