omnius 1.0.661 → 1.0.662
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.js
CHANGED
|
@@ -783379,7 +783379,7 @@ function renderTelegramSubAgentError(username, error) {
|
|
|
783379
783379
|
`${c3.red("✘")} ${c3.bold(`@${username}`)}: ${c3.dim(linkifyTerminalReferences(preview))}`
|
|
783380
783380
|
);
|
|
783381
783381
|
}
|
|
783382
|
-
var TELEGRAM_TOOL_ACTION_GROUPS, TELEGRAM_TOOL_ACTION_GROUP, TELEGRAM_TOOL_MUTATING_GROUPS, DEFAULT_TELEGRAM_TOOL_GROUP_POLICY, TELEGRAM_TOOL_BUTTON_LABELS, TELEGRAM_SAFETY_PROMPT, ADMIN_DM_PROMPT, ADMIN_GROUP_PROMPT, TELEGRAM_PUBLIC_SOUL_PROFILE, TELEGRAM_PUBLIC_ORCHESTRATOR_CONTRACT, TELEGRAM_PUBLIC_MEMORY_SCOPE_CONTRACT, TELEGRAM_PUBLIC_VISION_STACK_CONTRACT, TELEGRAM_EVIDENCE_SUFFICIENCY_CONTRACT, GROUP_REPLY_AUTHORIZATION_PROMPT, TELEGRAM_CHAT_STE_COMMUNICATION_PROMPT, TELEGRAM_CHAT_MODE_PROMPT, ADMIN_CHAT_PROFILE_PROMPT, TELEGRAM_ACTION_RESPONSE_CONTRACT, TELEGRAM_EXTERNAL_ACQUISITION_CONTRACT, TELEGRAM_LINK_INTEGRITY_CONTRACT, TELEGRAM_INTERACTION_DECISION_RESPONSE_FORMAT, TELEGRAM_GENERIC_JSON_RESPONSE_FORMAT, TELEGRAM_MODERATION_APPROVAL_RESPONSE_FORMAT, TELEGRAM_MODERATION_APPROVAL_TTL_MS, TELEGRAM_MODERATION_APPROVAL_RETENTION_MS, TELEGRAM_MODERATION_APPROVAL_MAX_RECORDS, TELEGRAM_INTERACTION_DECISION_MINIMAL_SCHEMA, TELEGRAM_CHAT_REPLY_RESPONSE_FORMAT, TelegramEmptyInferenceStreamError, TELEGRAM_SPACED_URL_RE, TELEGRAM_HTTP_URL_RE, TELEGRAM_RUNNER_CONTROL_OPEN_MARKERS, TELEGRAM_RUNNER_CONTROL_CLOSE_MARKERS, TELEGRAM_STUCK_SELF_TALK_PREFIXES, TELEGRAM_CHAT_HISTORY_LIMIT, TELEGRAM_CONTEXT_RECENT_DEFAULT, TELEGRAM_CONTEXT_LINE_LIMIT, TELEGRAM_CONTEXT_SAMPLE_LIMIT, TELEGRAM_MEMORY_CARD_LIMIT, TELEGRAM_MEMORY_NOTE_LIMIT, TELEGRAM_ASSOCIATIVE_FACT_LIMIT, TELEGRAM_ASSOCIATIVE_USER_FACT_LIMIT, TELEGRAM_ASSOCIATIVE_ACTION_LIMIT, TELEGRAM_ASSOCIATIVE_RELATION_LIMIT, TELEGRAM_MEMORY_STOPWORDS, TELEGRAM_MEMORY_GENERIC_QUERY_TOKENS, TELEGRAM_SUB_AGENT_BOUNDED_OPTIONS, TELEGRAM_PUBLIC_FAST_OPTIONS, TELEGRAM_ADMIN_EVIDENCE_OPTIONS, TELEGRAM_SUB_AGENT_DEFAULT_LIMIT, TELEGRAM_SUB_AGENT_MAX_LIMIT, TELEGRAM_SUB_AGENT_BURST_CONTEXT_LIMIT, TELEGRAM_ADMIN_LIVE_PANEL_PAGES, TELEGRAM_ADMIN_LIVE_MUTATION_TOOLS, TELEGRAM_PUBLIC_HELP_COMMANDS2, TELEGRAM_REMINDER_SLASH_COMMANDS, TELEGRAM_REFLECTION_SLASH_COMMANDS, TELEGRAM_PUBLIC_BOT_COMMAND_NAMES, TELEGRAM_IMAGE_EXTENSIONS, MEDIA_CACHE_TTL_MS, TELEGRAM_ACQUIRED_MEDIA_BASENAME_RE, TELEGRAM_CHANNEL_DMN_SWEEP_MS, TELEGRAM_CHANNEL_DMN_IDLE_AFTER_MS, TELEGRAM_CHANNEL_DMN_MIN_INTERVAL_MS, TELEGRAM_CHANNEL_DMN_MIN_MESSAGES, TELEGRAM_ALLOWED_UPDATES, TELEGRAM_DEFAULT_LONG_POLL_TIMEOUT_SECONDS, TelegramStartupError, TELEGRAM_PUBLIC_TOOL_QUOTAS, TelegramBridge;
|
|
783382
|
+
var TELEGRAM_TOOL_ACTION_GROUPS, TELEGRAM_TOOL_ACTION_GROUP, TELEGRAM_TOOL_MUTATING_GROUPS, DEFAULT_TELEGRAM_TOOL_GROUP_POLICY, TELEGRAM_TOOL_BUTTON_LABELS, TELEGRAM_SAFETY_PROMPT, ADMIN_DM_PROMPT, ADMIN_GROUP_PROMPT, TELEGRAM_PUBLIC_SOUL_PROFILE, TELEGRAM_PUBLIC_ORCHESTRATOR_CONTRACT, TELEGRAM_PUBLIC_MEMORY_SCOPE_CONTRACT, TELEGRAM_PUBLIC_VISION_STACK_CONTRACT, TELEGRAM_EVIDENCE_SUFFICIENCY_CONTRACT, GROUP_REPLY_AUTHORIZATION_PROMPT, TELEGRAM_CHAT_STE_COMMUNICATION_PROMPT, TELEGRAM_CHAT_MODE_PROMPT, ADMIN_CHAT_PROFILE_PROMPT, TELEGRAM_ACTION_RESPONSE_CONTRACT, TELEGRAM_EXTERNAL_ACQUISITION_CONTRACT, TELEGRAM_LINK_INTEGRITY_CONTRACT, TELEGRAM_INTERACTION_DECISION_RESPONSE_FORMAT, TELEGRAM_GENERIC_JSON_RESPONSE_FORMAT, TELEGRAM_MODERATION_APPROVAL_RESPONSE_FORMAT, TELEGRAM_MODERATION_APPROVAL_TTL_MS, TELEGRAM_MODERATION_APPROVAL_RETENTION_MS, TELEGRAM_MODERATION_APPROVAL_MAX_RECORDS, TELEGRAM_INTERACTION_DECISION_MINIMAL_SCHEMA, TELEGRAM_CHAT_REPLY_RESPONSE_FORMAT, TelegramEmptyInferenceStreamError, TelegramBridgeStoppedError, TELEGRAM_SPACED_URL_RE, TELEGRAM_HTTP_URL_RE, TELEGRAM_RUNNER_CONTROL_OPEN_MARKERS, TELEGRAM_RUNNER_CONTROL_CLOSE_MARKERS, TELEGRAM_STUCK_SELF_TALK_PREFIXES, TELEGRAM_CHAT_HISTORY_LIMIT, TELEGRAM_CONTEXT_RECENT_DEFAULT, TELEGRAM_CONTEXT_LINE_LIMIT, TELEGRAM_CONTEXT_SAMPLE_LIMIT, TELEGRAM_MEMORY_CARD_LIMIT, TELEGRAM_MEMORY_NOTE_LIMIT, TELEGRAM_ASSOCIATIVE_FACT_LIMIT, TELEGRAM_ASSOCIATIVE_USER_FACT_LIMIT, TELEGRAM_ASSOCIATIVE_ACTION_LIMIT, TELEGRAM_ASSOCIATIVE_RELATION_LIMIT, TELEGRAM_MEMORY_STOPWORDS, TELEGRAM_MEMORY_GENERIC_QUERY_TOKENS, TELEGRAM_SUB_AGENT_BOUNDED_OPTIONS, TELEGRAM_PUBLIC_FAST_OPTIONS, TELEGRAM_ADMIN_EVIDENCE_OPTIONS, TELEGRAM_SUB_AGENT_DEFAULT_LIMIT, TELEGRAM_SUB_AGENT_MAX_LIMIT, TELEGRAM_SUB_AGENT_BURST_CONTEXT_LIMIT, TELEGRAM_ADMIN_LIVE_PANEL_PAGES, TELEGRAM_ADMIN_LIVE_MUTATION_TOOLS, TELEGRAM_PUBLIC_HELP_COMMANDS2, TELEGRAM_REMINDER_SLASH_COMMANDS, TELEGRAM_REFLECTION_SLASH_COMMANDS, TELEGRAM_PUBLIC_BOT_COMMAND_NAMES, TELEGRAM_IMAGE_EXTENSIONS, MEDIA_CACHE_TTL_MS, TELEGRAM_ACQUIRED_MEDIA_BASENAME_RE, TELEGRAM_CHANNEL_DMN_SWEEP_MS, TELEGRAM_CHANNEL_DMN_IDLE_AFTER_MS, TELEGRAM_CHANNEL_DMN_MIN_INTERVAL_MS, TELEGRAM_CHANNEL_DMN_MIN_MESSAGES, TELEGRAM_ALLOWED_UPDATES, TELEGRAM_DEFAULT_LONG_POLL_TIMEOUT_SECONDS, TelegramStartupError, TELEGRAM_PUBLIC_TOOL_QUOTAS, TelegramBridge;
|
|
783383
783383
|
var init_telegram_bridge = __esm({
|
|
783384
783384
|
"packages/cli/src/tui/telegram-bridge.ts"() {
|
|
783385
783385
|
init_conversation_context();
|
|
@@ -783872,6 +783872,12 @@ Telegram link integrity contract:
|
|
|
783872
783872
|
this.name = "TelegramEmptyInferenceStreamError";
|
|
783873
783873
|
}
|
|
783874
783874
|
};
|
|
783875
|
+
TelegramBridgeStoppedError = class extends Error {
|
|
783876
|
+
constructor(message2 = "Telegram bridge stopped during inference") {
|
|
783877
|
+
super(message2);
|
|
783878
|
+
this.name = "TelegramBridgeStoppedError";
|
|
783879
|
+
}
|
|
783880
|
+
};
|
|
783875
783881
|
TELEGRAM_SPACED_URL_RE = /\bhttps?:\/\/\s*[A-Za-z0-9-]+(?:\s*\.\s*[A-Za-z0-9-]+)+(?:\s*:\s*\d+)?(?:[/?#][^\s<>"'()[\]{}]*)?/gi;
|
|
783876
783882
|
TELEGRAM_HTTP_URL_RE = /\bhttps?:\/\/[^\s<>"'()[\]{}]+/gi;
|
|
783877
783883
|
TELEGRAM_RUNNER_CONTROL_OPEN_MARKERS = [
|
|
@@ -790850,6 +790856,7 @@ ${this.quoteTelegramContextBlock(msg.text, 1200)}`
|
|
|
790850
790856
|
});
|
|
790851
790857
|
} catch (err) {
|
|
790852
790858
|
jsonModeError = err;
|
|
790859
|
+
if (err instanceof TelegramBridgeStoppedError) throw err;
|
|
790853
790860
|
if (err instanceof TelegramEmptyInferenceStreamError) {
|
|
790854
790861
|
if (diagnostics) diagnostics.jsonModeStatus = "empty-after-strip";
|
|
790855
790862
|
recordAttempt({
|
|
@@ -790921,6 +790928,7 @@ ${this.quoteTelegramContextBlock(msg.text, 1200)}`
|
|
|
790921
790928
|
}
|
|
790922
790929
|
return plainResult;
|
|
790923
790930
|
} catch (err) {
|
|
790931
|
+
if (err instanceof TelegramBridgeStoppedError) throw err;
|
|
790924
790932
|
if (err instanceof TelegramEmptyInferenceStreamError) {
|
|
790925
790933
|
if (diagnostics) diagnostics.plainStatus = "empty-after-strip";
|
|
790926
790934
|
recordAttempt({
|
|
@@ -790955,8 +790963,7 @@ ${this.quoteTelegramContextBlock(msg.text, 1200)}`
|
|
|
790955
790963
|
// operator can SEE what's happening during a long-running router or
|
|
790956
790964
|
// chat-fast-path call instead of waiting for a router hard-deadline.
|
|
790957
790965
|
// ─────────────────────────────────────────────────────────────────
|
|
790958
|
-
async waitForTelegramBrokerQueueRetry(delayMs) {
|
|
790959
|
-
const signal = this.abortController?.signal;
|
|
790966
|
+
async waitForTelegramBrokerQueueRetry(delayMs, signal = this.abortController?.signal) {
|
|
790960
790967
|
if (!signal) {
|
|
790961
790968
|
await new Promise((resolve92) => setTimeout(resolve92, delayMs));
|
|
790962
790969
|
return;
|
|
@@ -790995,6 +791002,15 @@ ${this.quoteTelegramContextBlock(msg.text, 1200)}`
|
|
|
790995
791002
|
* hard-deadline retire path becomes diagnosable instead of opaque
|
|
790996
791003
|
*/
|
|
790997
791004
|
async telegramObservableInference(backend, request, kind, sessionKey, options2 = {}) {
|
|
791005
|
+
const lifecycleSignal = this.abortController?.signal;
|
|
791006
|
+
if (lifecycleSignal) {
|
|
791007
|
+
backend.setAbortSignal?.(lifecycleSignal);
|
|
791008
|
+
}
|
|
791009
|
+
const throwIfBridgeRequestStopped = () => {
|
|
791010
|
+
if (!lifecycleSignal?.aborted) return;
|
|
791011
|
+
throw lifecycleSignal.reason instanceof Error ? lifecycleSignal.reason : new TelegramBridgeStoppedError();
|
|
791012
|
+
};
|
|
791013
|
+
throwIfBridgeRequestStopped();
|
|
790998
791014
|
const model = options2.modelName ?? this.agentConfig?.model ?? "?";
|
|
790999
791015
|
const promptTokens = estimatePromptTokensFromRequest(request);
|
|
791000
791016
|
const broker = getModelBroker();
|
|
@@ -791037,7 +791053,8 @@ ${this.quoteTelegramContextBlock(msg.text, 1200)}`
|
|
|
791037
791053
|
owner: `telegram-bridge/${kind}`,
|
|
791038
791054
|
sessionKey,
|
|
791039
791055
|
promptTokens,
|
|
791040
|
-
priority: kind === "router" || kind === "router-strict-retry" ? 1 : 0
|
|
791056
|
+
priority: kind === "router" || kind === "router-strict-retry" ? 1 : 0,
|
|
791057
|
+
signal: lifecycleSignal
|
|
791041
791058
|
});
|
|
791042
791059
|
this.telegramInferenceBlocks?.handling(
|
|
791043
791060
|
id2,
|
|
@@ -791071,6 +791088,7 @@ ${this.quoteTelegramContextBlock(msg.text, 1200)}`
|
|
|
791071
791088
|
const streamAllowed = options2.stream !== false;
|
|
791072
791089
|
let brokerQueueRetryAttempt = 0;
|
|
791073
791090
|
for (; ; ) {
|
|
791091
|
+
throwIfBridgeRequestStopped();
|
|
791074
791092
|
try {
|
|
791075
791093
|
if (!streamAllowed) {
|
|
791076
791094
|
result = await backend.chatCompletion(requestWithCtx);
|
|
@@ -791112,8 +791130,10 @@ ${this.quoteTelegramContextBlock(msg.text, 1200)}`
|
|
|
791112
791130
|
);
|
|
791113
791131
|
}
|
|
791114
791132
|
}
|
|
791133
|
+
throwIfBridgeRequestStopped();
|
|
791115
791134
|
break;
|
|
791116
791135
|
} catch (attemptErr) {
|
|
791136
|
+
throwIfBridgeRequestStopped();
|
|
791117
791137
|
const deadline = brokerQueueDeadlineResponse(attemptErr);
|
|
791118
791138
|
if (!deadline || slot !== null) throw attemptErr;
|
|
791119
791139
|
brokerQueueRetryAttempt++;
|
|
@@ -791130,7 +791150,10 @@ ${this.quoteTelegramContextBlock(msg.text, 1200)}`
|
|
|
791130
791150
|
id2,
|
|
791131
791151
|
`broker queue admission deadline expired for ${deadline.request_id}${queueSummary ? ` (${queueSummary})` : ""}; re-entering after ${(delayMs / 1e3).toFixed(1)}s, attempt ${brokerQueueRetryAttempt}`
|
|
791132
791152
|
);
|
|
791133
|
-
await this.waitForTelegramBrokerQueueRetry(
|
|
791153
|
+
await this.waitForTelegramBrokerQueueRetry(
|
|
791154
|
+
delayMs,
|
|
791155
|
+
lifecycleSignal
|
|
791156
|
+
);
|
|
791134
791157
|
}
|
|
791135
791158
|
}
|
|
791136
791159
|
const usage = result.usage;
|
|
@@ -791691,6 +791714,7 @@ ${retryText}`,
|
|
|
791691
791714
|
mentalNote: validated.mentalNote
|
|
791692
791715
|
};
|
|
791693
791716
|
} catch (err) {
|
|
791717
|
+
if (err instanceof TelegramBridgeStoppedError) throw err;
|
|
791694
791718
|
if (diagnostics) {
|
|
791695
791719
|
diagnostics.strictRetryStatus = "threw";
|
|
791696
791720
|
diagnostics.strictRetryError = telegramRouterErrorText(err);
|
|
@@ -792322,6 +792346,7 @@ ${this.quoteTelegramContextBlock(msg.text, 1200)}`
|
|
|
792322
792346
|
);
|
|
792323
792347
|
return withRouterTelemetry(fallback);
|
|
792324
792348
|
} catch (err) {
|
|
792349
|
+
if (err instanceof TelegramBridgeStoppedError) throw err;
|
|
792325
792350
|
const failureNarrative = this.summarizeTelegramRouterFailure(diagnostics);
|
|
792326
792351
|
const errMsg = telegramRouterErrorText(err);
|
|
792327
792352
|
const fallback = this.applyTelegramSilentReflectionNotes(
|
|
@@ -793034,8 +793059,7 @@ ${TELEGRAM_PUBLIC_ORCHESTRATOR_CONTRACT}`
|
|
|
793034
793059
|
stop() {
|
|
793035
793060
|
this.polling = false;
|
|
793036
793061
|
this.state.active = false;
|
|
793037
|
-
this.abortController?.abort();
|
|
793038
|
-
this.abortController = null;
|
|
793062
|
+
this.abortController?.abort(new TelegramBridgeStoppedError());
|
|
793039
793063
|
this.telegramApiGovernor.stop("Telegram bridge stopped");
|
|
793040
793064
|
if (this.mediaCacheCleanupTimer) {
|
|
793041
793065
|
clearInterval(this.mediaCacheCleanupTimer);
|
package/npm-shrinkwrap.json
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "omnius",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.662",
|
|
4
4
|
"lockfileVersion": 3,
|
|
5
5
|
"requires": true,
|
|
6
6
|
"packages": {
|
|
7
7
|
"": {
|
|
8
8
|
"name": "omnius",
|
|
9
|
-
"version": "1.0.
|
|
9
|
+
"version": "1.0.662",
|
|
10
10
|
"bundleDependencies": [
|
|
11
11
|
"image-to-ascii"
|
|
12
12
|
],
|
|
@@ -4333,9 +4333,9 @@
|
|
|
4333
4333
|
"license": "BSD-3-Clause"
|
|
4334
4334
|
},
|
|
4335
4335
|
"node_modules/ignore": {
|
|
4336
|
-
"version": "7.0.
|
|
4337
|
-
"resolved": "https://registry.npmjs.org/ignore/-/ignore-7.0.
|
|
4338
|
-
"integrity": "sha512-
|
|
4336
|
+
"version": "7.0.7",
|
|
4337
|
+
"resolved": "https://registry.npmjs.org/ignore/-/ignore-7.0.7.tgz",
|
|
4338
|
+
"integrity": "sha512-dML0wP6oak21rsNYCJpJB6O1BJIEwNpGrTw0URPfAk4hm0e3pRfCtzkfB6olBcXcVlU2rouCyz7lCyRB0OMVCA==",
|
|
4339
4339
|
"license": "MIT",
|
|
4340
4340
|
"engines": {
|
|
4341
4341
|
"node": ">= 4"
|
package/package.json
CHANGED
|
@@ -16,7 +16,7 @@ Use these rules for an analysis task:
|
|
|
16
16
|
For sustained OSINT research, use `osint_search` to get a small candidate set.
|
|
17
17
|
Use `osint_show` to inspect one selected record.
|
|
18
18
|
Then, select `web_fetch`, `web_crawl`, or `playwright_browser`.
|
|
19
|
-
Treat catalog health as routing
|
|
19
|
+
Treat catalog health as archived routing metadata. Do not use it as source evidence.
|
|
20
20
|
Record the source, retrieval time, and confirmation evidence.
|
|
21
21
|
|
|
22
22
|
Use `web_search` for external research that is not in the OSINT catalog.
|