@rayu-dev/rayu-cli 1.3.227 → 1.3.327
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/rayu.js +1321 -509
- package/package.json +1 -1
package/dist/rayu.js
CHANGED
|
@@ -649,6 +649,26 @@ var init_memoize = __esm(() => {
|
|
|
649
649
|
});
|
|
650
650
|
|
|
651
651
|
// src/utils/envUtils.ts
|
|
652
|
+
var exports_envUtils = {};
|
|
653
|
+
__export(exports_envUtils, {
|
|
654
|
+
shouldMaintainProjectWorkingDir: () => shouldMaintainProjectWorkingDir,
|
|
655
|
+
resolveRayuConfigHomeDir: () => resolveRayuConfigHomeDir,
|
|
656
|
+
resolveConfigHomeDir: () => resolveConfigHomeDir,
|
|
657
|
+
parseEnvVars: () => parseEnvVars,
|
|
658
|
+
loadDotEnv: () => loadDotEnv,
|
|
659
|
+
isRunningOnHomespace: () => isRunningOnHomespace,
|
|
660
|
+
isInProtectedNamespace: () => isInProtectedNamespace,
|
|
661
|
+
isEnvTruthy: () => isEnvTruthy,
|
|
662
|
+
isEnvDefinedFalsy: () => isEnvDefinedFalsy,
|
|
663
|
+
isBareMode: () => isBareMode,
|
|
664
|
+
hasNodeOption: () => hasNodeOption,
|
|
665
|
+
getVertexRegionForModel: () => getVertexRegionForModel,
|
|
666
|
+
getTeamsDir: () => getTeamsDir,
|
|
667
|
+
getRayuConfigHomeDir: () => getRayuConfigHomeDir,
|
|
668
|
+
getDefaultVertexRegion: () => getDefaultVertexRegion,
|
|
669
|
+
getClaudeConfigHomeDir: () => getClaudeConfigHomeDir,
|
|
670
|
+
getAWSRegion: () => getAWSRegion
|
|
671
|
+
});
|
|
652
672
|
import { existsSync, readFileSync } from "fs";
|
|
653
673
|
import { homedir } from "os";
|
|
654
674
|
import { join, dirname } from "path";
|
|
@@ -845,12 +865,14 @@ function getVertexRegionForModel(model) {
|
|
|
845
865
|
}
|
|
846
866
|
return getDefaultVertexRegion();
|
|
847
867
|
}
|
|
848
|
-
var getRayuConfigHomeDir, VERTEX_REGION_OVERRIDES;
|
|
868
|
+
var resolveConfigHomeDir, getRayuConfigHomeDir, getClaudeConfigHomeDir, VERTEX_REGION_OVERRIDES;
|
|
849
869
|
var init_envUtils = __esm(() => {
|
|
850
870
|
init_memoize();
|
|
871
|
+
resolveConfigHomeDir = resolveRayuConfigHomeDir;
|
|
851
872
|
getRayuConfigHomeDir = memoize_default(() => {
|
|
852
873
|
return resolveRayuConfigHomeDir(homedir(), process.env.RAYU_CONFIG_DIR, existsSync).normalize("NFC");
|
|
853
874
|
}, () => process.env.RAYU_CONFIG_DIR);
|
|
875
|
+
getClaudeConfigHomeDir = getRayuConfigHomeDir;
|
|
854
876
|
VERTEX_REGION_OVERRIDES = [
|
|
855
877
|
["claude-haiku-4-5", "VERTEX_REGION_CLAUDE_HAIKU_4_5"],
|
|
856
878
|
["claude-3-5-haiku", "VERTEX_REGION_CLAUDE_3_5_HAIKU"],
|
|
@@ -35744,7 +35766,7 @@ __export(exports_rayuProviders, {
|
|
|
35744
35766
|
});
|
|
35745
35767
|
function bedrockBaseURL(region) {
|
|
35746
35768
|
const r2 = (region || DEFAULT_BEDROCK_REGION).trim();
|
|
35747
|
-
return `https://bedrock-
|
|
35769
|
+
return `https://bedrock-mantle.${r2}.api.aws/v1`;
|
|
35748
35770
|
}
|
|
35749
35771
|
function vertexHost(region) {
|
|
35750
35772
|
const r2 = (region || DEFAULT_VERTEX_REGION).trim();
|
|
@@ -35921,13 +35943,76 @@ var init_rayuProviders = __esm(() => {
|
|
|
35921
35943
|
smallFastModel: "openai/gpt-4o-mini",
|
|
35922
35944
|
envKeys: ["OPENROUTER_API_KEY"]
|
|
35923
35945
|
},
|
|
35946
|
+
{
|
|
35947
|
+
id: "xai",
|
|
35948
|
+
label: "xAI / Grok (api.x.ai)",
|
|
35949
|
+
kind: "openai-compatible",
|
|
35950
|
+
baseURL: "https://api.x.ai/v1",
|
|
35951
|
+
defaultModel: "grok-4",
|
|
35952
|
+
smallFastModel: "grok-3-mini",
|
|
35953
|
+
envKeys: ["XAI_API_KEY"]
|
|
35954
|
+
},
|
|
35955
|
+
{
|
|
35956
|
+
id: "groq",
|
|
35957
|
+
label: "Groq (api.groq.com)",
|
|
35958
|
+
kind: "openai-compatible",
|
|
35959
|
+
baseURL: "https://api.groq.com/openai/v1",
|
|
35960
|
+
defaultModel: "llama-3.3-70b-versatile",
|
|
35961
|
+
smallFastModel: "llama-3.1-8b-instant",
|
|
35962
|
+
envKeys: ["GROQ_API_KEY"]
|
|
35963
|
+
},
|
|
35964
|
+
{
|
|
35965
|
+
id: "fireworks",
|
|
35966
|
+
label: "Fireworks AI (api.fireworks.ai)",
|
|
35967
|
+
kind: "openai-compatible",
|
|
35968
|
+
baseURL: "https://api.fireworks.ai/inference/v1",
|
|
35969
|
+
defaultModel: "accounts/fireworks/models/llama-v3p3-70b-instruct",
|
|
35970
|
+
envKeys: ["FIREWORKS_API_KEY"]
|
|
35971
|
+
},
|
|
35972
|
+
{
|
|
35973
|
+
id: "togetherai",
|
|
35974
|
+
label: "Together AI (api.together.xyz)",
|
|
35975
|
+
kind: "openai-compatible",
|
|
35976
|
+
baseURL: "https://api.together.xyz/v1",
|
|
35977
|
+
defaultModel: "meta-llama/Llama-3.3-70B-Instruct-Turbo",
|
|
35978
|
+
envKeys: ["TOGETHER_API_KEY", "TOGETHERAI_API_KEY"]
|
|
35979
|
+
},
|
|
35980
|
+
{
|
|
35981
|
+
id: "cerebras",
|
|
35982
|
+
label: "Cerebras (api.cerebras.ai)",
|
|
35983
|
+
kind: "openai-compatible",
|
|
35984
|
+
baseURL: "https://api.cerebras.ai/v1",
|
|
35985
|
+
defaultModel: "llama-3.3-70b",
|
|
35986
|
+
envKeys: ["CEREBRAS_API_KEY"]
|
|
35987
|
+
},
|
|
35988
|
+
{
|
|
35989
|
+
id: "baseten",
|
|
35990
|
+
label: "Baseten (inference.baseten.co)",
|
|
35991
|
+
kind: "openai-compatible",
|
|
35992
|
+
baseURL: "https://inference.baseten.co/v1",
|
|
35993
|
+
envKeys: ["BASETEN_API_KEY"]
|
|
35994
|
+
},
|
|
35995
|
+
{
|
|
35996
|
+
id: "deepinfra",
|
|
35997
|
+
label: "DeepInfra (api.deepinfra.com)",
|
|
35998
|
+
kind: "openai-compatible",
|
|
35999
|
+
baseURL: "https://api.deepinfra.com/v1/openai",
|
|
36000
|
+
defaultModel: "meta-llama/Llama-3.3-70B-Instruct",
|
|
36001
|
+
envKeys: ["DEEPINFRA_API_KEY"]
|
|
36002
|
+
},
|
|
35924
36003
|
{
|
|
35925
36004
|
id: "bedrock",
|
|
35926
|
-
label: "AWS Bedrock —
|
|
36005
|
+
label: "AWS Bedrock — all models (Converse API: Claude, Kimi, DeepSeek, …)",
|
|
35927
36006
|
kind: "bedrock",
|
|
35928
|
-
bedrockApi: "
|
|
36007
|
+
bedrockApi: "converse",
|
|
35929
36008
|
envKeys: ["AWS_BEARER_TOKEN_BEDROCK"]
|
|
35930
36009
|
},
|
|
36010
|
+
{
|
|
36011
|
+
id: "bedrock-openai",
|
|
36012
|
+
label: "AWS Bedrock — OpenAI-compatible (bedrock-mantle: gpt-oss, qwen, …)",
|
|
36013
|
+
kind: "bedrock",
|
|
36014
|
+
bedrockApi: "openai"
|
|
36015
|
+
},
|
|
35931
36016
|
{
|
|
35932
36017
|
id: "bedrock-anthropic",
|
|
35933
36018
|
label: "AWS Bedrock — Claude (Anthropic Messages API)",
|
|
@@ -36209,8 +36294,8 @@ function getRayuModelContextWindow(model) {
|
|
|
36209
36294
|
function bedrockRegionOf(p) {
|
|
36210
36295
|
if (p.awsRegion)
|
|
36211
36296
|
return p.awsRegion;
|
|
36212
|
-
const m2 = p.baseURL?.match(/bedrock-runtime\.([a-z0-9-]+)\.amazonaws\.com/i);
|
|
36213
|
-
return m2?.[1] ?? "us-east-1";
|
|
36297
|
+
const m2 = p.baseURL?.match(/bedrock-mantle\.([a-z0-9-]+)\.api\.aws|bedrock-runtime\.([a-z0-9-]+)\.amazonaws\.com/i);
|
|
36298
|
+
return m2?.[1] ?? m2?.[2] ?? "us-east-1";
|
|
36214
36299
|
}
|
|
36215
36300
|
async function fetchBedrockModels(p) {
|
|
36216
36301
|
if (!p.apiKey)
|
|
@@ -36610,7 +36695,7 @@ function isOpenAICompatibleActive() {
|
|
|
36610
36695
|
const p = getActiveProvider2();
|
|
36611
36696
|
if (p?.kind === "openai-compatible")
|
|
36612
36697
|
return true;
|
|
36613
|
-
if (p?.kind === "bedrock" && p.bedrockApi !== "anthropic" && !!p.apiKey && !!p.baseURL) {
|
|
36698
|
+
if (p?.kind === "bedrock" && p.bedrockApi !== "anthropic" && p.bedrockApi !== "converse" && !!p.apiKey && !!p.baseURL) {
|
|
36614
36699
|
return true;
|
|
36615
36700
|
}
|
|
36616
36701
|
return false;
|
|
@@ -143458,10 +143543,13 @@ async function createBedrockClient() {
|
|
|
143458
143543
|
}
|
|
143459
143544
|
return new BedrockClient(clientConfig);
|
|
143460
143545
|
}
|
|
143461
|
-
async function createBedrockRuntimeClient() {
|
|
143546
|
+
async function createBedrockRuntimeClient(opts) {
|
|
143462
143547
|
const { BedrockRuntimeClient } = await Promise.resolve().then(() => __toESM(require_dist_cjs27(), 1));
|
|
143463
|
-
const region = getAWSRegion();
|
|
143548
|
+
const region = opts?.region || getAWSRegion();
|
|
143464
143549
|
const skipAuth = isEnvTruthy(process.env.RAYU_SKIP_BEDROCK_AUTH);
|
|
143550
|
+
if (opts?.apiKey && !process.env.AWS_BEARER_TOKEN_BEDROCK) {
|
|
143551
|
+
process.env.AWS_BEARER_TOKEN_BEDROCK = opts.apiKey;
|
|
143552
|
+
}
|
|
143465
143553
|
const clientConfig = {
|
|
143466
143554
|
region,
|
|
143467
143555
|
...process.env.ANTHROPIC_BEDROCK_BASE_URL && {
|
|
@@ -147982,7 +148070,7 @@ var init_auth = __esm(() => {
|
|
|
147982
148070
|
|
|
147983
148071
|
// src/utils/userAgent.ts
|
|
147984
148072
|
function getRayuUserAgent() {
|
|
147985
|
-
return `rayu/${"1.3.
|
|
148073
|
+
return `rayu/${"1.3.327"}`;
|
|
147986
148074
|
}
|
|
147987
148075
|
var getClaudeCodeUserAgent;
|
|
147988
148076
|
var init_userAgent = __esm(() => {
|
|
@@ -148008,7 +148096,7 @@ function getUserAgent() {
|
|
|
148008
148096
|
const clientApp = process.env.RAYU_AGENT_SDK_CLIENT_APP ? `, client-app/${process.env.RAYU_AGENT_SDK_CLIENT_APP}` : "";
|
|
148009
148097
|
const workload = getWorkload();
|
|
148010
148098
|
const workloadSuffix = workload ? `, workload/${workload}` : "";
|
|
148011
|
-
return `rayu/${"1.3.
|
|
148099
|
+
return `rayu/${"1.3.327"} (${"external"}, ${process.env.RAYU_ENTRYPOINT ?? "cli"}${agentSdkVersion}${clientApp}${workloadSuffix})`;
|
|
148012
148100
|
}
|
|
148013
148101
|
function getMCPUserAgent() {
|
|
148014
148102
|
const parts = [];
|
|
@@ -148022,7 +148110,7 @@ function getMCPUserAgent() {
|
|
|
148022
148110
|
parts.push(`client-app/${process.env.RAYU_AGENT_SDK_CLIENT_APP}`);
|
|
148023
148111
|
}
|
|
148024
148112
|
const suffix = parts.length > 0 ? ` (${parts.join(", ")})` : "";
|
|
148025
|
-
return `rayu/${"1.3.
|
|
148113
|
+
return `rayu/${"1.3.327"}${suffix}`;
|
|
148026
148114
|
}
|
|
148027
148115
|
function getWebFetchUserAgent() {
|
|
148028
148116
|
return `Rayu-User (${getRayuUserAgent()})`;
|
|
@@ -148145,7 +148233,7 @@ var init_user = __esm(() => {
|
|
|
148145
148233
|
deviceId,
|
|
148146
148234
|
sessionId: getSessionId(),
|
|
148147
148235
|
email: getEmail(),
|
|
148148
|
-
appVersion: "1.3.
|
|
148236
|
+
appVersion: "1.3.327",
|
|
148149
148237
|
platform: getHostPlatformForAnalytics(),
|
|
148150
148238
|
organizationUuid,
|
|
148151
148239
|
accountUuid,
|
|
@@ -164227,11 +164315,29 @@ __export(exports_openaiAdapter, {
|
|
|
164227
164315
|
usesMaxCompletionTokens: () => usesMaxCompletionTokens,
|
|
164228
164316
|
translateStream: () => translateStream,
|
|
164229
164317
|
toBetaMessage: () => toBetaMessage,
|
|
164318
|
+
splitInlineThink: () => splitInlineThink,
|
|
164319
|
+
processInlineThink: () => processInlineThink,
|
|
164230
164320
|
isReasoningModel: () => isReasoningModel,
|
|
164321
|
+
initialInlineThinkState: () => initialInlineThinkState,
|
|
164322
|
+
extractReasoningText: () => extractReasoningText,
|
|
164231
164323
|
createOpenAICompatibleClient: () => createOpenAICompatibleClient,
|
|
164232
164324
|
buildOpenAIRequest: () => buildOpenAIRequest,
|
|
164233
164325
|
_resetOpenAIAdapterUnsupportedParamCacheForTesting: () => _resetOpenAIAdapterUnsupportedParamCacheForTesting
|
|
164234
164326
|
});
|
|
164327
|
+
function debugCaptureDelta(model, chunk) {
|
|
164328
|
+
if (!process.env.RAYU_DEBUG_REASONING || debugReasoningCount >= 60)
|
|
164329
|
+
return;
|
|
164330
|
+
debugReasoningCount++;
|
|
164331
|
+
try {
|
|
164332
|
+
const fs3 = __require("fs");
|
|
164333
|
+
const path9 = __require("path");
|
|
164334
|
+
const { getRayuConfigHomeDir: getRayuConfigHomeDir3 } = (init_envUtils(), __toCommonJS(exports_envUtils));
|
|
164335
|
+
const dir = getRayuConfigHomeDir3();
|
|
164336
|
+
fs3.mkdirSync(dir, { recursive: true });
|
|
164337
|
+
fs3.appendFileSync(path9.join(dir, "debug-reasoning.jsonl"), JSON.stringify({ t: Date.now(), model, chunk }) + `
|
|
164338
|
+
`);
|
|
164339
|
+
} catch {}
|
|
164340
|
+
}
|
|
164235
164341
|
function systemToText(system) {
|
|
164236
164342
|
if (!system)
|
|
164237
164343
|
return;
|
|
@@ -164427,6 +164533,9 @@ function buildOpenAIRequest(params, options = {}) {
|
|
|
164427
164533
|
if (options.reasoningEffort) {
|
|
164428
164534
|
req.reasoning_effort = options.reasoningEffort;
|
|
164429
164535
|
}
|
|
164536
|
+
if (/kimi/i.test(params.model)) {
|
|
164537
|
+
req.chat_template_kwargs = { thinking: true };
|
|
164538
|
+
}
|
|
164430
164539
|
return req;
|
|
164431
164540
|
}
|
|
164432
164541
|
function mapFinishReason(reason) {
|
|
@@ -164448,16 +164557,57 @@ function mapUsage(usage) {
|
|
|
164448
164557
|
cache_read_input_tokens: 0
|
|
164449
164558
|
};
|
|
164450
164559
|
}
|
|
164560
|
+
function extractReasoningText(o2) {
|
|
164561
|
+
if (!o2 || typeof o2 !== "object")
|
|
164562
|
+
return;
|
|
164563
|
+
const direct = o2.reasoning_content ?? o2.reasoning;
|
|
164564
|
+
if (typeof direct === "string")
|
|
164565
|
+
return direct.length ? direct : undefined;
|
|
164566
|
+
if (direct && typeof direct === "object" && !Array.isArray(direct)) {
|
|
164567
|
+
const obj = direct;
|
|
164568
|
+
const t2 = obj.text ?? obj.content;
|
|
164569
|
+
if (typeof t2 === "string" && t2.length)
|
|
164570
|
+
return t2;
|
|
164571
|
+
}
|
|
164572
|
+
const arr = Array.isArray(o2.reasoning_details) ? o2.reasoning_details : Array.isArray(direct) ? direct : undefined;
|
|
164573
|
+
if (arr) {
|
|
164574
|
+
const joined = arr.map((d) => {
|
|
164575
|
+
if (typeof d === "string")
|
|
164576
|
+
return d;
|
|
164577
|
+
const item = d;
|
|
164578
|
+
if (typeof item?.text === "string")
|
|
164579
|
+
return item.text;
|
|
164580
|
+
if (typeof item?.content === "string")
|
|
164581
|
+
return item.content;
|
|
164582
|
+
return "";
|
|
164583
|
+
}).join("");
|
|
164584
|
+
if (joined.length)
|
|
164585
|
+
return joined;
|
|
164586
|
+
}
|
|
164587
|
+
return;
|
|
164588
|
+
}
|
|
164451
164589
|
function toBetaMessage(completion, model) {
|
|
164452
164590
|
const choice = completion.choices?.[0] ?? {};
|
|
164453
164591
|
const msg = choice.message ?? {};
|
|
164454
164592
|
const content = [];
|
|
164455
|
-
const reasoning = msg
|
|
164593
|
+
const reasoning = extractReasoningText(msg);
|
|
164456
164594
|
if (typeof reasoning === "string" && reasoning.length) {
|
|
164457
164595
|
content.push({ type: "thinking", thinking: reasoning, signature: "" });
|
|
164458
164596
|
}
|
|
164459
|
-
if (msg.content)
|
|
164597
|
+
if (typeof msg.content === "string" && msg.content.length) {
|
|
164598
|
+
let text = msg.content;
|
|
164599
|
+
if (!reasoning) {
|
|
164600
|
+
const split = splitInlineThink(text);
|
|
164601
|
+
if (split.thinking) {
|
|
164602
|
+
content.push({ type: "thinking", thinking: split.thinking, signature: "" });
|
|
164603
|
+
text = split.text;
|
|
164604
|
+
}
|
|
164605
|
+
}
|
|
164606
|
+
if (text.length)
|
|
164607
|
+
content.push({ type: "text", text });
|
|
164608
|
+
} else if (msg.content) {
|
|
164460
164609
|
content.push({ type: "text", text: msg.content });
|
|
164610
|
+
}
|
|
164461
164611
|
let toolCallIdx = 0;
|
|
164462
164612
|
for (const tc of msg.tool_calls ?? []) {
|
|
164463
164613
|
const fn = tc.function ?? {};
|
|
@@ -164482,6 +164632,82 @@ function toBetaMessage(completion, model) {
|
|
|
164482
164632
|
usage: mapUsage(completion.usage)
|
|
164483
164633
|
};
|
|
164484
164634
|
}
|
|
164635
|
+
function splitInlineThink(text) {
|
|
164636
|
+
const lead = text.replace(/^\s+/, "");
|
|
164637
|
+
for (let i3 = 0;i3 < THINK_OPEN.length; i3++) {
|
|
164638
|
+
const open4 = THINK_OPEN[i3];
|
|
164639
|
+
if (lead.startsWith(open4)) {
|
|
164640
|
+
const close = THINK_CLOSE[i3];
|
|
164641
|
+
const end = lead.indexOf(close, open4.length);
|
|
164642
|
+
if (end === -1)
|
|
164643
|
+
return { text };
|
|
164644
|
+
const thinking = lead.slice(open4.length, end).trim();
|
|
164645
|
+
const rest = lead.slice(end + close.length).replace(/^\s+/, "");
|
|
164646
|
+
return { thinking, text: rest };
|
|
164647
|
+
}
|
|
164648
|
+
}
|
|
164649
|
+
return { text };
|
|
164650
|
+
}
|
|
164651
|
+
function processInlineThink(state, chunk, flush = false) {
|
|
164652
|
+
const segments = [];
|
|
164653
|
+
let phase = state.phase;
|
|
164654
|
+
let buffer = state.buffer + chunk;
|
|
164655
|
+
for (;; ) {
|
|
164656
|
+
if (phase === "text") {
|
|
164657
|
+
if (buffer)
|
|
164658
|
+
segments.push({ kind: "text", text: buffer });
|
|
164659
|
+
buffer = "";
|
|
164660
|
+
break;
|
|
164661
|
+
}
|
|
164662
|
+
if (phase === "detect") {
|
|
164663
|
+
const lead = buffer.replace(/^\s+/, "");
|
|
164664
|
+
const open4 = THINK_OPEN.find((m2) => lead.startsWith(m2));
|
|
164665
|
+
if (open4) {
|
|
164666
|
+
phase = "thinking";
|
|
164667
|
+
buffer = lead.slice(open4.length);
|
|
164668
|
+
continue;
|
|
164669
|
+
}
|
|
164670
|
+
const couldBeMarker = lead.length === 0 || THINK_OPEN.some((m2) => m2.startsWith(lead) && lead.length < m2.length);
|
|
164671
|
+
if (!flush && couldBeMarker && lead.length < MAX_THINK_OPEN_LEN)
|
|
164672
|
+
break;
|
|
164673
|
+
phase = "text";
|
|
164674
|
+
continue;
|
|
164675
|
+
}
|
|
164676
|
+
let closeIdx = -1;
|
|
164677
|
+
let closeLen = 0;
|
|
164678
|
+
for (const m2 of THINK_CLOSE) {
|
|
164679
|
+
const i3 = buffer.indexOf(m2);
|
|
164680
|
+
if (i3 !== -1 && (closeIdx === -1 || i3 < closeIdx)) {
|
|
164681
|
+
closeIdx = i3;
|
|
164682
|
+
closeLen = m2.length;
|
|
164683
|
+
}
|
|
164684
|
+
}
|
|
164685
|
+
if (closeIdx !== -1) {
|
|
164686
|
+
const before = buffer.slice(0, closeIdx);
|
|
164687
|
+
if (before)
|
|
164688
|
+
segments.push({ kind: "thinking", text: before });
|
|
164689
|
+
buffer = buffer.slice(closeIdx + closeLen);
|
|
164690
|
+
phase = "text";
|
|
164691
|
+
continue;
|
|
164692
|
+
}
|
|
164693
|
+
let hold = 0;
|
|
164694
|
+
if (!flush) {
|
|
164695
|
+
for (let n2 = Math.min(MAX_THINK_CLOSE_LEN - 1, buffer.length);n2 > 0; n2--) {
|
|
164696
|
+
const tail = buffer.slice(buffer.length - n2);
|
|
164697
|
+
if (THINK_CLOSE.some((m2) => m2.startsWith(tail) && n2 < m2.length)) {
|
|
164698
|
+
hold = n2;
|
|
164699
|
+
break;
|
|
164700
|
+
}
|
|
164701
|
+
}
|
|
164702
|
+
}
|
|
164703
|
+
const emit = hold ? buffer.slice(0, buffer.length - hold) : buffer;
|
|
164704
|
+
if (emit)
|
|
164705
|
+
segments.push({ kind: "thinking", text: emit });
|
|
164706
|
+
buffer = hold ? buffer.slice(buffer.length - hold) : "";
|
|
164707
|
+
break;
|
|
164708
|
+
}
|
|
164709
|
+
return { segments, state: { phase, buffer } };
|
|
164710
|
+
}
|
|
164485
164711
|
async function* translateStream(openaiStream, model) {
|
|
164486
164712
|
const messageId = `rayu_${Date.now()}`;
|
|
164487
164713
|
yield {
|
|
@@ -164503,7 +164729,49 @@ async function* translateStream(openaiStream, model) {
|
|
|
164503
164729
|
let usage;
|
|
164504
164730
|
const toolIndexByOaIndex = new Map;
|
|
164505
164731
|
let nextIndex = 0;
|
|
164732
|
+
let inlineThink = initialInlineThinkState();
|
|
164733
|
+
const emitThinking = function* (text) {
|
|
164734
|
+
if (thinkingIndex === null) {
|
|
164735
|
+
thinkingIndex = nextIndex++;
|
|
164736
|
+
yield {
|
|
164737
|
+
type: "content_block_start",
|
|
164738
|
+
index: thinkingIndex,
|
|
164739
|
+
content_block: { type: "thinking", thinking: "", signature: "" }
|
|
164740
|
+
};
|
|
164741
|
+
}
|
|
164742
|
+
yield {
|
|
164743
|
+
type: "content_block_delta",
|
|
164744
|
+
index: thinkingIndex,
|
|
164745
|
+
delta: { type: "thinking_delta", thinking: text }
|
|
164746
|
+
};
|
|
164747
|
+
};
|
|
164748
|
+
const emitText = function* (text) {
|
|
164749
|
+
if (textIndex === null) {
|
|
164750
|
+
textIndex = nextIndex++;
|
|
164751
|
+
yield {
|
|
164752
|
+
type: "content_block_start",
|
|
164753
|
+
index: textIndex,
|
|
164754
|
+
content_block: { type: "text", text: "" }
|
|
164755
|
+
};
|
|
164756
|
+
}
|
|
164757
|
+
yield {
|
|
164758
|
+
type: "content_block_delta",
|
|
164759
|
+
index: textIndex,
|
|
164760
|
+
delta: { type: "text_delta", text }
|
|
164761
|
+
};
|
|
164762
|
+
};
|
|
164763
|
+
const emitSegments = function* (segs) {
|
|
164764
|
+
for (const s2 of segs) {
|
|
164765
|
+
if (!s2.text.length)
|
|
164766
|
+
continue;
|
|
164767
|
+
if (s2.kind === "thinking")
|
|
164768
|
+
yield* emitThinking(s2.text);
|
|
164769
|
+
else
|
|
164770
|
+
yield* emitText(s2.text);
|
|
164771
|
+
}
|
|
164772
|
+
};
|
|
164506
164773
|
for await (const chunk of openaiStream) {
|
|
164774
|
+
debugCaptureDelta(model, chunk);
|
|
164507
164775
|
const choice = chunk.choices?.[0];
|
|
164508
164776
|
if (!choice) {
|
|
164509
164777
|
if (chunk.usage)
|
|
@@ -164511,36 +164779,14 @@ async function* translateStream(openaiStream, model) {
|
|
|
164511
164779
|
continue;
|
|
164512
164780
|
}
|
|
164513
164781
|
const delta = choice.delta ?? {};
|
|
164514
|
-
const reasoning = delta
|
|
164782
|
+
const reasoning = extractReasoningText(delta);
|
|
164515
164783
|
if (typeof reasoning === "string" && reasoning.length) {
|
|
164516
|
-
|
|
164517
|
-
thinkingIndex = nextIndex++;
|
|
164518
|
-
yield {
|
|
164519
|
-
type: "content_block_start",
|
|
164520
|
-
index: thinkingIndex,
|
|
164521
|
-
content_block: { type: "thinking", thinking: "", signature: "" }
|
|
164522
|
-
};
|
|
164523
|
-
}
|
|
164524
|
-
yield {
|
|
164525
|
-
type: "content_block_delta",
|
|
164526
|
-
index: thinkingIndex,
|
|
164527
|
-
delta: { type: "thinking_delta", thinking: reasoning }
|
|
164528
|
-
};
|
|
164784
|
+
yield* emitThinking(reasoning);
|
|
164529
164785
|
}
|
|
164530
164786
|
if (typeof delta.content === "string" && delta.content.length) {
|
|
164531
|
-
|
|
164532
|
-
|
|
164533
|
-
|
|
164534
|
-
type: "content_block_start",
|
|
164535
|
-
index: textIndex,
|
|
164536
|
-
content_block: { type: "text", text: "" }
|
|
164537
|
-
};
|
|
164538
|
-
}
|
|
164539
|
-
yield {
|
|
164540
|
-
type: "content_block_delta",
|
|
164541
|
-
index: textIndex,
|
|
164542
|
-
delta: { type: "text_delta", text: delta.content }
|
|
164543
|
-
};
|
|
164787
|
+
const r2 = processInlineThink(inlineThink, delta.content);
|
|
164788
|
+
inlineThink = r2.state;
|
|
164789
|
+
yield* emitSegments(r2.segments);
|
|
164544
164790
|
}
|
|
164545
164791
|
for (const tc of delta.tool_calls ?? []) {
|
|
164546
164792
|
const oaIndex = tc.index ?? 0;
|
|
@@ -164574,6 +164820,11 @@ async function* translateStream(openaiStream, model) {
|
|
|
164574
164820
|
if (chunk.usage)
|
|
164575
164821
|
usage = chunk.usage;
|
|
164576
164822
|
}
|
|
164823
|
+
{
|
|
164824
|
+
const r2 = processInlineThink(inlineThink, "", true);
|
|
164825
|
+
inlineThink = r2.state;
|
|
164826
|
+
yield* emitSegments(r2.segments);
|
|
164827
|
+
}
|
|
164577
164828
|
if (thinkingIndex !== null)
|
|
164578
164829
|
yield { type: "content_block_stop", index: thinkingIndex };
|
|
164579
164830
|
if (textIndex !== null)
|
|
@@ -164638,6 +164889,8 @@ function optionalParamsIn(req) {
|
|
|
164638
164889
|
params.push("stream_options");
|
|
164639
164890
|
if ("reasoning_effort" in req)
|
|
164640
164891
|
params.push("reasoning_effort");
|
|
164892
|
+
if ("chat_template_kwargs" in req)
|
|
164893
|
+
params.push("chat_template_kwargs");
|
|
164641
164894
|
return params;
|
|
164642
164895
|
}
|
|
164643
164896
|
function withoutOptionalParams(req, params) {
|
|
@@ -164679,6 +164932,10 @@ function rejectedOptionalParams(e2, candidates) {
|
|
|
164679
164932
|
if (candidates.includes("reasoning_effort"))
|
|
164680
164933
|
rejected.add("reasoning_effort");
|
|
164681
164934
|
}
|
|
164935
|
+
if (/chat_template_kwargs|thinking/i.test(msg)) {
|
|
164936
|
+
if (candidates.includes("chat_template_kwargs"))
|
|
164937
|
+
rejected.add("chat_template_kwargs");
|
|
164938
|
+
}
|
|
164682
164939
|
if (rejected.size > 0)
|
|
164683
164940
|
return rejected;
|
|
164684
164941
|
if (/unrecognized|unexpected|unknown|unsupported|invalid.*(param|argument)|extra_forbidden/i.test(msg)) {
|
|
@@ -164843,13 +165100,15 @@ function createOpenAICompatibleClientUncached(config2) {
|
|
|
164843
165100
|
messages: { create: create2 }
|
|
164844
165101
|
};
|
|
164845
165102
|
}
|
|
164846
|
-
var import_sdk2, NEEDS_MAX_COMPLETION_RE, REASONING_RE, unsupportedOptionalParams, clientCache;
|
|
165103
|
+
var import_sdk2, debugReasoningCount = 0, NEEDS_MAX_COMPLETION_RE, REASONING_RE, THINK_OPEN, THINK_CLOSE, initialInlineThinkState = () => ({ phase: "detect", buffer: "" }), MAX_THINK_OPEN_LEN = 7, MAX_THINK_CLOSE_LEN = 8, unsupportedOptionalParams, clientCache;
|
|
164847
165104
|
var init_openaiAdapter = __esm(() => {
|
|
164848
165105
|
init_openai();
|
|
164849
165106
|
init_rayuDiagnostics();
|
|
164850
165107
|
import_sdk2 = __toESM(require_sdk(), 1);
|
|
164851
165108
|
NEEDS_MAX_COMPLETION_RE = /(?:^|[/_-])(o1|o3|o4|gpt-5)(?:[.\-_]|$)/i;
|
|
164852
165109
|
REASONING_RE = /(?:^|[/_-])(o1|o3|o4|gpt-5|gpt-oss)(?:[.\-_]|$)|reason|thinking/i;
|
|
165110
|
+
THINK_OPEN = ["<think>", "◁think▷"];
|
|
165111
|
+
THINK_CLOSE = ["</think>", "◁/think▷"];
|
|
164853
165112
|
unsupportedOptionalParams = new Map;
|
|
164854
165113
|
clientCache = new Map;
|
|
164855
165114
|
});
|
|
@@ -178805,6 +179064,451 @@ var init_bedrock_sdk = __esm(() => {
|
|
|
178805
179064
|
init_client3();
|
|
178806
179065
|
});
|
|
178807
179066
|
|
|
179067
|
+
// src/services/api/bedrockConverseAdapter.ts
|
|
179068
|
+
var exports_bedrockConverseAdapter = {};
|
|
179069
|
+
__export(exports_bedrockConverseAdapter, {
|
|
179070
|
+
translateConverseStream: () => translateConverseStream,
|
|
179071
|
+
toConverseInput: () => toConverseInput,
|
|
179072
|
+
toBetaMessageFromConverse: () => toBetaMessageFromConverse,
|
|
179073
|
+
createBedrockConverseClient: () => createBedrockConverseClient,
|
|
179074
|
+
_resetBedrockConverseClientCacheForTesting: () => _resetBedrockConverseClientCacheForTesting
|
|
179075
|
+
});
|
|
179076
|
+
function systemToConverse(system) {
|
|
179077
|
+
if (!system)
|
|
179078
|
+
return;
|
|
179079
|
+
const text = typeof system === "string" ? system : system.map((b) => typeof b === "string" ? b : b.text ?? "").join(`
|
|
179080
|
+
`);
|
|
179081
|
+
return text ? [{ text }] : undefined;
|
|
179082
|
+
}
|
|
179083
|
+
function imageFormat(mediaType) {
|
|
179084
|
+
const mt = (mediaType ?? "image/png").toLowerCase();
|
|
179085
|
+
if (mt.includes("jpeg") || mt.includes("jpg"))
|
|
179086
|
+
return "jpeg";
|
|
179087
|
+
if (mt.includes("gif"))
|
|
179088
|
+
return "gif";
|
|
179089
|
+
if (mt.includes("webp"))
|
|
179090
|
+
return "webp";
|
|
179091
|
+
return "png";
|
|
179092
|
+
}
|
|
179093
|
+
function imageBlockToConverse(block) {
|
|
179094
|
+
if (!block || block.type !== "image")
|
|
179095
|
+
return null;
|
|
179096
|
+
const src = block.source ?? {};
|
|
179097
|
+
if (src.type === "base64" && typeof src.data === "string") {
|
|
179098
|
+
return {
|
|
179099
|
+
image: {
|
|
179100
|
+
format: imageFormat(src.media_type),
|
|
179101
|
+
source: { bytes: Buffer.from(src.data, "base64") }
|
|
179102
|
+
}
|
|
179103
|
+
};
|
|
179104
|
+
}
|
|
179105
|
+
return null;
|
|
179106
|
+
}
|
|
179107
|
+
function toolResultContent(content) {
|
|
179108
|
+
if (typeof content === "string")
|
|
179109
|
+
return [{ text: content }];
|
|
179110
|
+
if (!Array.isArray(content))
|
|
179111
|
+
return [{ text: "" }];
|
|
179112
|
+
const out = [];
|
|
179113
|
+
for (const item of content) {
|
|
179114
|
+
if (item?.type === "text" && typeof item.text === "string")
|
|
179115
|
+
out.push({ text: item.text });
|
|
179116
|
+
else {
|
|
179117
|
+
const img = imageBlockToConverse(item);
|
|
179118
|
+
if (img)
|
|
179119
|
+
out.push(img);
|
|
179120
|
+
}
|
|
179121
|
+
}
|
|
179122
|
+
return out.length ? out : [{ text: "" }];
|
|
179123
|
+
}
|
|
179124
|
+
function toConverseMessages(messages) {
|
|
179125
|
+
const out = [];
|
|
179126
|
+
for (const msg of messages) {
|
|
179127
|
+
const role = msg.role;
|
|
179128
|
+
const content = msg.content;
|
|
179129
|
+
const blocks = [];
|
|
179130
|
+
if (typeof content === "string") {
|
|
179131
|
+
if (content)
|
|
179132
|
+
blocks.push({ text: content });
|
|
179133
|
+
} else if (Array.isArray(content)) {
|
|
179134
|
+
for (const b of content) {
|
|
179135
|
+
if (b.type === "text" && b.text) {
|
|
179136
|
+
blocks.push({ text: b.text });
|
|
179137
|
+
} else if (b.type === "thinking" && b.thinking) {
|
|
179138
|
+
blocks.push({
|
|
179139
|
+
reasoningContent: {
|
|
179140
|
+
reasoningText: {
|
|
179141
|
+
text: b.thinking,
|
|
179142
|
+
...typeof b.signature === "string" && b.signature ? { signature: b.signature } : {}
|
|
179143
|
+
}
|
|
179144
|
+
}
|
|
179145
|
+
});
|
|
179146
|
+
} else if (b.type === "tool_use") {
|
|
179147
|
+
blocks.push({
|
|
179148
|
+
toolUse: { toolUseId: b.id, name: b.name, input: b.input ?? {} }
|
|
179149
|
+
});
|
|
179150
|
+
} else if (b.type === "tool_result") {
|
|
179151
|
+
blocks.push({
|
|
179152
|
+
toolResult: {
|
|
179153
|
+
toolUseId: b.tool_use_id,
|
|
179154
|
+
content: toolResultContent(b.content),
|
|
179155
|
+
status: b.is_error ? "error" : "success"
|
|
179156
|
+
}
|
|
179157
|
+
});
|
|
179158
|
+
} else {
|
|
179159
|
+
const img = imageBlockToConverse(b);
|
|
179160
|
+
if (img)
|
|
179161
|
+
blocks.push(img);
|
|
179162
|
+
}
|
|
179163
|
+
}
|
|
179164
|
+
}
|
|
179165
|
+
if (blocks.length === 0)
|
|
179166
|
+
continue;
|
|
179167
|
+
out.push({ role: role === "assistant" ? "assistant" : "user", content: blocks });
|
|
179168
|
+
}
|
|
179169
|
+
return out;
|
|
179170
|
+
}
|
|
179171
|
+
function toConverseTools(tools) {
|
|
179172
|
+
if (!tools?.length)
|
|
179173
|
+
return;
|
|
179174
|
+
const specs = tools.filter((t2) => {
|
|
179175
|
+
if (!t2)
|
|
179176
|
+
return false;
|
|
179177
|
+
if (typeof t2.type === "string" && t2.type !== "custom" && !t2.input_schema)
|
|
179178
|
+
return false;
|
|
179179
|
+
return !!t2.name;
|
|
179180
|
+
}).map((t2) => ({
|
|
179181
|
+
toolSpec: {
|
|
179182
|
+
name: t2.name,
|
|
179183
|
+
description: t2.description ?? "",
|
|
179184
|
+
inputSchema: { json: t2.input_schema ?? { type: "object", properties: {} } }
|
|
179185
|
+
}
|
|
179186
|
+
}));
|
|
179187
|
+
return specs.length ? specs : undefined;
|
|
179188
|
+
}
|
|
179189
|
+
function toConverseToolChoice(tc) {
|
|
179190
|
+
if (!tc)
|
|
179191
|
+
return;
|
|
179192
|
+
switch (tc.type) {
|
|
179193
|
+
case "auto":
|
|
179194
|
+
return { auto: {} };
|
|
179195
|
+
case "any":
|
|
179196
|
+
return { any: {} };
|
|
179197
|
+
case "tool":
|
|
179198
|
+
return tc.name ? { tool: { name: tc.name } } : { any: {} };
|
|
179199
|
+
default:
|
|
179200
|
+
return;
|
|
179201
|
+
}
|
|
179202
|
+
}
|
|
179203
|
+
function isClaudeModel(model) {
|
|
179204
|
+
return /claude|anthropic/i.test(model);
|
|
179205
|
+
}
|
|
179206
|
+
function toConverseInput(params, opts = {}) {
|
|
179207
|
+
const messages = toConverseMessages(params.messages);
|
|
179208
|
+
const system = systemToConverse(params.system);
|
|
179209
|
+
const tools = toConverseTools(params.tools);
|
|
179210
|
+
const toolChoice = params.tool_choice?.type === "none" ? undefined : toConverseToolChoice(params.tool_choice);
|
|
179211
|
+
const inferenceConfig = {};
|
|
179212
|
+
if (typeof params.max_tokens === "number")
|
|
179213
|
+
inferenceConfig.maxTokens = params.max_tokens;
|
|
179214
|
+
if (typeof params.temperature === "number")
|
|
179215
|
+
inferenceConfig.temperature = params.temperature;
|
|
179216
|
+
if (typeof params.top_p === "number")
|
|
179217
|
+
inferenceConfig.topP = params.top_p;
|
|
179218
|
+
if (params.stop_sequences?.length)
|
|
179219
|
+
inferenceConfig.stopSequences = params.stop_sequences;
|
|
179220
|
+
const input = {
|
|
179221
|
+
modelId: params.model,
|
|
179222
|
+
messages,
|
|
179223
|
+
...system ? { system } : {},
|
|
179224
|
+
...Object.keys(inferenceConfig).length ? { inferenceConfig } : {},
|
|
179225
|
+
...tools ? { toolConfig: { tools, ...toolChoice ? { toolChoice } : {} } } : {}
|
|
179226
|
+
};
|
|
179227
|
+
const wantThinking = !!params.thinking && params.thinking.type !== "disabled";
|
|
179228
|
+
if (opts.includeReasoningConfig && wantThinking && isClaudeModel(params.model)) {
|
|
179229
|
+
const max = params.max_tokens ?? 8192;
|
|
179230
|
+
const budget = params.thinking?.budget_tokens ?? 4096;
|
|
179231
|
+
input.additionalModelRequestFields = {
|
|
179232
|
+
reasoning_config: {
|
|
179233
|
+
type: "enabled",
|
|
179234
|
+
budget_tokens: Math.max(1024, Math.min(budget, max - 1))
|
|
179235
|
+
}
|
|
179236
|
+
};
|
|
179237
|
+
}
|
|
179238
|
+
return input;
|
|
179239
|
+
}
|
|
179240
|
+
function mapStopReason(reason) {
|
|
179241
|
+
switch (reason) {
|
|
179242
|
+
case "max_tokens":
|
|
179243
|
+
return "max_tokens";
|
|
179244
|
+
case "tool_use":
|
|
179245
|
+
return "tool_use";
|
|
179246
|
+
case "stop_sequence":
|
|
179247
|
+
return "stop_sequence";
|
|
179248
|
+
case "content_filtered":
|
|
179249
|
+
case "guardrail_intervened":
|
|
179250
|
+
return "end_turn";
|
|
179251
|
+
default:
|
|
179252
|
+
return "end_turn";
|
|
179253
|
+
}
|
|
179254
|
+
}
|
|
179255
|
+
function mapUsage2(usage) {
|
|
179256
|
+
return {
|
|
179257
|
+
input_tokens: usage?.inputTokens ?? 0,
|
|
179258
|
+
output_tokens: usage?.outputTokens ?? 0,
|
|
179259
|
+
cache_creation_input_tokens: usage?.cacheWriteInputTokens ?? 0,
|
|
179260
|
+
cache_read_input_tokens: usage?.cacheReadInputTokens ?? 0
|
|
179261
|
+
};
|
|
179262
|
+
}
|
|
179263
|
+
function toBetaMessageFromConverse(response, model) {
|
|
179264
|
+
const output = response.output ?? {};
|
|
179265
|
+
const message = output.message ?? {};
|
|
179266
|
+
const blocks = message.content ?? [];
|
|
179267
|
+
const content = [];
|
|
179268
|
+
for (const block of blocks) {
|
|
179269
|
+
if (block.reasoningContent) {
|
|
179270
|
+
const rt = block.reasoningContent.reasoningText ?? {};
|
|
179271
|
+
if (typeof rt.text === "string" && rt.text.length) {
|
|
179272
|
+
content.push({
|
|
179273
|
+
type: "thinking",
|
|
179274
|
+
thinking: rt.text,
|
|
179275
|
+
signature: rt.signature ?? ""
|
|
179276
|
+
});
|
|
179277
|
+
}
|
|
179278
|
+
} else if (typeof block.text === "string" && block.text.length) {
|
|
179279
|
+
content.push({ type: "text", text: block.text });
|
|
179280
|
+
} else if (block.toolUse) {
|
|
179281
|
+
const tu = block.toolUse;
|
|
179282
|
+
content.push({ type: "tool_use", id: tu.toolUseId, name: tu.name, input: tu.input ?? {} });
|
|
179283
|
+
}
|
|
179284
|
+
}
|
|
179285
|
+
return {
|
|
179286
|
+
id: `rayu_bedrock_${Date.now()}`,
|
|
179287
|
+
type: "message",
|
|
179288
|
+
role: "assistant",
|
|
179289
|
+
model,
|
|
179290
|
+
content,
|
|
179291
|
+
stop_reason: mapStopReason(response.stopReason),
|
|
179292
|
+
stop_sequence: null,
|
|
179293
|
+
usage: mapUsage2(response.usage)
|
|
179294
|
+
};
|
|
179295
|
+
}
|
|
179296
|
+
async function* translateConverseStream(stream4, model) {
|
|
179297
|
+
yield {
|
|
179298
|
+
type: "message_start",
|
|
179299
|
+
message: {
|
|
179300
|
+
id: `rayu_bedrock_${Date.now()}`,
|
|
179301
|
+
type: "message",
|
|
179302
|
+
role: "assistant",
|
|
179303
|
+
model,
|
|
179304
|
+
content: [],
|
|
179305
|
+
stop_reason: null,
|
|
179306
|
+
stop_sequence: null,
|
|
179307
|
+
usage: { input_tokens: 0, output_tokens: 0 }
|
|
179308
|
+
}
|
|
179309
|
+
};
|
|
179310
|
+
const started = new Set;
|
|
179311
|
+
const blockType = new Map;
|
|
179312
|
+
let stopReason = "end_turn";
|
|
179313
|
+
let usage = { input_tokens: 0, output_tokens: 0 };
|
|
179314
|
+
const ensureStart = function* (index, type, toolUse) {
|
|
179315
|
+
if (started.has(index))
|
|
179316
|
+
return;
|
|
179317
|
+
started.add(index);
|
|
179318
|
+
blockType.set(index, type);
|
|
179319
|
+
const content_block = type === "tool_use" ? { type: "tool_use", id: toolUse?.toolUseId, name: toolUse?.name, input: {} } : type === "thinking" ? { type: "thinking", thinking: "", signature: "" } : { type: "text", text: "" };
|
|
179320
|
+
yield { type: "content_block_start", index, content_block };
|
|
179321
|
+
};
|
|
179322
|
+
for await (const event of stream4) {
|
|
179323
|
+
if (event.contentBlockStart) {
|
|
179324
|
+
const cb = event.contentBlockStart;
|
|
179325
|
+
const index = cb.contentBlockIndex ?? 0;
|
|
179326
|
+
const tu = cb.start?.toolUse;
|
|
179327
|
+
if (tu)
|
|
179328
|
+
yield* ensureStart(index, "tool_use", tu);
|
|
179329
|
+
continue;
|
|
179330
|
+
}
|
|
179331
|
+
if (event.contentBlockDelta) {
|
|
179332
|
+
const cbd = event.contentBlockDelta;
|
|
179333
|
+
const index = cbd.contentBlockIndex ?? 0;
|
|
179334
|
+
const delta = cbd.delta ?? {};
|
|
179335
|
+
const reasoning = delta.reasoningContent;
|
|
179336
|
+
if (reasoning && (typeof reasoning.text === "string" || typeof reasoning.signature === "string")) {
|
|
179337
|
+
yield* ensureStart(index, "thinking");
|
|
179338
|
+
if (typeof reasoning.text === "string" && reasoning.text.length) {
|
|
179339
|
+
yield {
|
|
179340
|
+
type: "content_block_delta",
|
|
179341
|
+
index,
|
|
179342
|
+
delta: { type: "thinking_delta", thinking: reasoning.text }
|
|
179343
|
+
};
|
|
179344
|
+
}
|
|
179345
|
+
if (typeof reasoning.signature === "string" && reasoning.signature.length) {
|
|
179346
|
+
yield {
|
|
179347
|
+
type: "content_block_delta",
|
|
179348
|
+
index,
|
|
179349
|
+
delta: { type: "signature_delta", signature: reasoning.signature }
|
|
179350
|
+
};
|
|
179351
|
+
}
|
|
179352
|
+
continue;
|
|
179353
|
+
}
|
|
179354
|
+
if (typeof delta.text === "string" && delta.text.length) {
|
|
179355
|
+
yield* ensureStart(index, "text");
|
|
179356
|
+
yield {
|
|
179357
|
+
type: "content_block_delta",
|
|
179358
|
+
index,
|
|
179359
|
+
delta: { type: "text_delta", text: delta.text }
|
|
179360
|
+
};
|
|
179361
|
+
continue;
|
|
179362
|
+
}
|
|
179363
|
+
const toolUse = delta.toolUse;
|
|
179364
|
+
if (toolUse && typeof toolUse.input === "string") {
|
|
179365
|
+
if (!started.has(index))
|
|
179366
|
+
yield* ensureStart(index, "tool_use", {});
|
|
179367
|
+
yield {
|
|
179368
|
+
type: "content_block_delta",
|
|
179369
|
+
index,
|
|
179370
|
+
delta: { type: "input_json_delta", partial_json: toolUse.input }
|
|
179371
|
+
};
|
|
179372
|
+
}
|
|
179373
|
+
continue;
|
|
179374
|
+
}
|
|
179375
|
+
if (event.contentBlockStop) {
|
|
179376
|
+
const index = event.contentBlockStop.contentBlockIndex ?? 0;
|
|
179377
|
+
if (started.has(index))
|
|
179378
|
+
yield { type: "content_block_stop", index };
|
|
179379
|
+
continue;
|
|
179380
|
+
}
|
|
179381
|
+
if (event.messageStop) {
|
|
179382
|
+
stopReason = mapStopReason(event.messageStop.stopReason);
|
|
179383
|
+
continue;
|
|
179384
|
+
}
|
|
179385
|
+
if (event.metadata) {
|
|
179386
|
+
usage = mapUsage2(event.metadata.usage);
|
|
179387
|
+
continue;
|
|
179388
|
+
}
|
|
179389
|
+
const exception = event.internalServerException ?? event.modelStreamErrorException ?? event.throttlingException ?? event.validationException ?? event.serviceUnavailableException;
|
|
179390
|
+
if (exception) {
|
|
179391
|
+
throw new Error(exception.message ?? "Bedrock Converse stream error");
|
|
179392
|
+
}
|
|
179393
|
+
}
|
|
179394
|
+
for (const index of started) {
|
|
179395
|
+
yield { type: "content_block_stop", index };
|
|
179396
|
+
}
|
|
179397
|
+
yield {
|
|
179398
|
+
type: "message_delta",
|
|
179399
|
+
delta: { stop_reason: stopReason, stop_sequence: null },
|
|
179400
|
+
usage
|
|
179401
|
+
};
|
|
179402
|
+
yield { type: "message_stop" };
|
|
179403
|
+
}
|
|
179404
|
+
function normalizeError2(e2) {
|
|
179405
|
+
const err = e2;
|
|
179406
|
+
const status = err?.$metadata?.httpStatusCode;
|
|
179407
|
+
const name = err?.name;
|
|
179408
|
+
if (name === "TimeoutError" || /ECONNRESET|ETIMEDOUT|ENOTFOUND|fetch failed/i.test(String(err?.message ?? ""))) {
|
|
179409
|
+
return new import_sdk4.APIConnectionError({
|
|
179410
|
+
message: String(err?.message ?? "connection error"),
|
|
179411
|
+
cause: e2
|
|
179412
|
+
});
|
|
179413
|
+
}
|
|
179414
|
+
if (typeof status === "number") {
|
|
179415
|
+
return import_sdk4.APIError.generate(status, { error: err }, String(err?.message ?? ""), undefined);
|
|
179416
|
+
}
|
|
179417
|
+
return e2;
|
|
179418
|
+
}
|
|
179419
|
+
function isReasoningFieldRejection(e2) {
|
|
179420
|
+
const err = e2;
|
|
179421
|
+
const status = err?.$metadata?.httpStatusCode;
|
|
179422
|
+
const msg = String(err?.message ?? "");
|
|
179423
|
+
return (status === 400 || err?.name === "ValidationException") && /reasoning_config|additionalModelRequestFields|reasoning|unsupported|unknown|unexpected/i.test(msg);
|
|
179424
|
+
}
|
|
179425
|
+
function createBedrockConverseClient(config2) {
|
|
179426
|
+
const key = JSON.stringify({ region: config2.region ?? "", hasKey: !!config2.apiKey, maxRetries: config2.maxRetries ?? 2 });
|
|
179427
|
+
const cached2 = clientCache2.get(key);
|
|
179428
|
+
if (cached2)
|
|
179429
|
+
return cached2;
|
|
179430
|
+
const client3 = createBedrockConverseClientUncached(config2);
|
|
179431
|
+
clientCache2.set(key, client3);
|
|
179432
|
+
return client3;
|
|
179433
|
+
}
|
|
179434
|
+
function _resetBedrockConverseClientCacheForTesting() {
|
|
179435
|
+
clientCache2.clear();
|
|
179436
|
+
}
|
|
179437
|
+
function createBedrockConverseClientUncached(config2) {
|
|
179438
|
+
let runtimePromise;
|
|
179439
|
+
const getRuntime = () => {
|
|
179440
|
+
if (!runtimePromise) {
|
|
179441
|
+
runtimePromise = createBedrockRuntimeClient({ region: config2.region, apiKey: config2.apiKey });
|
|
179442
|
+
}
|
|
179443
|
+
return runtimePromise;
|
|
179444
|
+
};
|
|
179445
|
+
async function send(commandName, params, signal) {
|
|
179446
|
+
const runtime = await getRuntime();
|
|
179447
|
+
const sdk = await Promise.resolve().then(() => __toESM(require_dist_cjs27(), 1));
|
|
179448
|
+
const Command = sdk[`${commandName}Command`];
|
|
179449
|
+
const sendOnce = (includeReasoningConfig) => {
|
|
179450
|
+
const input = toConverseInput(params, { includeReasoningConfig });
|
|
179451
|
+
return runtime.send(new Command(input), signal ? { abortSignal: signal } : undefined);
|
|
179452
|
+
};
|
|
179453
|
+
try {
|
|
179454
|
+
return await sendOnce(true);
|
|
179455
|
+
} catch (e2) {
|
|
179456
|
+
if (isReasoningFieldRejection(e2)) {
|
|
179457
|
+
try {
|
|
179458
|
+
return await sendOnce(false);
|
|
179459
|
+
} catch (e22) {
|
|
179460
|
+
reportIssue("bedrock_converse.request_failed", "Bedrock Converse request failed", {
|
|
179461
|
+
model: params.model,
|
|
179462
|
+
error: e22 instanceof Error ? e22.message : String(e22)
|
|
179463
|
+
});
|
|
179464
|
+
throw normalizeError2(e22);
|
|
179465
|
+
}
|
|
179466
|
+
}
|
|
179467
|
+
reportIssue("bedrock_converse.request_failed", "Bedrock Converse request failed", {
|
|
179468
|
+
model: params.model,
|
|
179469
|
+
error: e2 instanceof Error ? e2.message : String(e2)
|
|
179470
|
+
});
|
|
179471
|
+
throw normalizeError2(e2);
|
|
179472
|
+
}
|
|
179473
|
+
}
|
|
179474
|
+
async function runNonStreaming(params, signal) {
|
|
179475
|
+
const response = await send("Converse", params, signal);
|
|
179476
|
+
return toBetaMessageFromConverse(response, params.model);
|
|
179477
|
+
}
|
|
179478
|
+
async function runStreamingWithResponse(params, signal) {
|
|
179479
|
+
const response = await send("ConverseStream", params, signal);
|
|
179480
|
+
const stream4 = response.stream ?? async function* () {}();
|
|
179481
|
+
return {
|
|
179482
|
+
data: translateConverseStream(stream4, params.model),
|
|
179483
|
+
request_id: null,
|
|
179484
|
+
response: new Response(null, { status: 200 })
|
|
179485
|
+
};
|
|
179486
|
+
}
|
|
179487
|
+
function create2(params, opts) {
|
|
179488
|
+
const signal = opts?.signal;
|
|
179489
|
+
return {
|
|
179490
|
+
then(onFulfilled, onRejected) {
|
|
179491
|
+
return runNonStreaming(params, signal).then(onFulfilled, onRejected);
|
|
179492
|
+
},
|
|
179493
|
+
catch(onRejected) {
|
|
179494
|
+
return runNonStreaming(params, signal).catch(onRejected);
|
|
179495
|
+
},
|
|
179496
|
+
withResponse: () => runStreamingWithResponse(params, signal)
|
|
179497
|
+
};
|
|
179498
|
+
}
|
|
179499
|
+
return {
|
|
179500
|
+
beta: { messages: { create: create2 } },
|
|
179501
|
+
messages: { create: create2 }
|
|
179502
|
+
};
|
|
179503
|
+
}
|
|
179504
|
+
var import_sdk4, clientCache2;
|
|
179505
|
+
var init_bedrockConverseAdapter = __esm(() => {
|
|
179506
|
+
init_bedrock();
|
|
179507
|
+
init_rayuDiagnostics();
|
|
179508
|
+
import_sdk4 = __toESM(require_sdk(), 1);
|
|
179509
|
+
clientCache2 = new Map;
|
|
179510
|
+
});
|
|
179511
|
+
|
|
178808
179512
|
// src/utils/browser.ts
|
|
178809
179513
|
function validateUrl(url3) {
|
|
178810
179514
|
let parsedUrl;
|
|
@@ -179273,7 +179977,7 @@ function partsOf(resp) {
|
|
|
179273
179977
|
const content = cand.content ?? {};
|
|
179274
179978
|
return content.parts ?? [];
|
|
179275
179979
|
}
|
|
179276
|
-
function
|
|
179980
|
+
function mapUsage3(resp) {
|
|
179277
179981
|
const u4 = resp.usageMetadata ?? {};
|
|
179278
179982
|
return {
|
|
179279
179983
|
input_tokens: u4.promptTokenCount ?? 0,
|
|
@@ -179294,7 +179998,9 @@ function toBetaMessageFromGenAI(resp, model) {
|
|
|
179294
179998
|
let idx = 0;
|
|
179295
179999
|
let hadToolUse = false;
|
|
179296
180000
|
for (const part of partsOf(resp)) {
|
|
179297
|
-
if (typeof part.text === "string" && part.text.length) {
|
|
180001
|
+
if (part.thought === true && typeof part.text === "string" && part.text.length) {
|
|
180002
|
+
content.push({ type: "thinking", thinking: part.text, signature: "" });
|
|
180003
|
+
} else if (typeof part.text === "string" && part.text.length) {
|
|
179298
180004
|
content.push({ type: "text", text: part.text });
|
|
179299
180005
|
} else if (part.functionCall) {
|
|
179300
180006
|
const fc = part.functionCall;
|
|
@@ -179317,7 +180023,7 @@ function toBetaMessageFromGenAI(resp, model) {
|
|
|
179317
180023
|
content,
|
|
179318
180024
|
stop_reason: mapFinish(resp, hadToolUse),
|
|
179319
180025
|
stop_sequence: null,
|
|
179320
|
-
usage:
|
|
180026
|
+
usage: mapUsage3(resp)
|
|
179321
180027
|
};
|
|
179322
180028
|
}
|
|
179323
180029
|
async function* translateGenAIStream(stream4, model) {
|
|
@@ -179334,32 +180040,45 @@ async function* translateGenAIStream(stream4, model) {
|
|
|
179334
180040
|
usage: { input_tokens: 0, output_tokens: 0 }
|
|
179335
180041
|
}
|
|
179336
180042
|
};
|
|
179337
|
-
let
|
|
179338
|
-
let blockIsText = false;
|
|
180043
|
+
let openType = null;
|
|
179339
180044
|
let usage = { input_tokens: 0, output_tokens: 0 };
|
|
179340
180045
|
let hadToolUse = false;
|
|
179341
180046
|
let idx = 0;
|
|
179342
180047
|
const closeBlock = function* () {
|
|
179343
|
-
if (
|
|
180048
|
+
if (openType !== null) {
|
|
179344
180049
|
yield { type: "content_block_stop", index: idx };
|
|
179345
180050
|
idx++;
|
|
179346
|
-
|
|
180051
|
+
openType = null;
|
|
179347
180052
|
}
|
|
179348
180053
|
};
|
|
179349
180054
|
for await (const chunk of stream4) {
|
|
179350
180055
|
if (chunk.usageMetadata)
|
|
179351
|
-
usage =
|
|
180056
|
+
usage = mapUsage3(chunk);
|
|
179352
180057
|
for (const part of partsOf(chunk)) {
|
|
179353
|
-
if (typeof part.text === "string" && part.text.length) {
|
|
179354
|
-
if (
|
|
180058
|
+
if (part.thought === true && typeof part.text === "string" && part.text.length) {
|
|
180059
|
+
if (openType !== "thinking") {
|
|
180060
|
+
yield* closeBlock();
|
|
180061
|
+
yield {
|
|
180062
|
+
type: "content_block_start",
|
|
180063
|
+
index: idx,
|
|
180064
|
+
content_block: { type: "thinking", thinking: "", signature: "" }
|
|
180065
|
+
};
|
|
180066
|
+
openType = "thinking";
|
|
180067
|
+
}
|
|
180068
|
+
yield {
|
|
180069
|
+
type: "content_block_delta",
|
|
180070
|
+
index: idx,
|
|
180071
|
+
delta: { type: "thinking_delta", thinking: part.text }
|
|
180072
|
+
};
|
|
180073
|
+
} else if (typeof part.text === "string" && part.text.length) {
|
|
180074
|
+
if (openType !== "text") {
|
|
179355
180075
|
yield* closeBlock();
|
|
179356
180076
|
yield {
|
|
179357
180077
|
type: "content_block_start",
|
|
179358
180078
|
index: idx,
|
|
179359
180079
|
content_block: { type: "text", text: "" }
|
|
179360
180080
|
};
|
|
179361
|
-
|
|
179362
|
-
blockIsText = true;
|
|
180081
|
+
openType = "text";
|
|
179363
180082
|
}
|
|
179364
180083
|
yield {
|
|
179365
180084
|
type: "content_block_delta",
|
|
@@ -179390,8 +180109,7 @@ async function* translateGenAIStream(stream4, model) {
|
|
|
179390
180109
|
partial_json: JSON.stringify(fc.args ?? {})
|
|
179391
180110
|
}
|
|
179392
180111
|
};
|
|
179393
|
-
|
|
179394
|
-
blockIsText = false;
|
|
180112
|
+
openType = "tool";
|
|
179395
180113
|
}
|
|
179396
180114
|
}
|
|
179397
180115
|
}
|
|
@@ -179423,14 +180141,18 @@ function buildGenAIBody(params) {
|
|
|
179423
180141
|
}
|
|
179424
180142
|
function geminiThinkingConfig() {
|
|
179425
180143
|
const level = process.env.RAYU_GEMINI_THINKING_LEVEL?.trim().toLowerCase();
|
|
180144
|
+
const disable = process.env.CLAUDE_CODE_DISABLE_THINKING;
|
|
180145
|
+
if (level === "off" || level === "none" || level === "disabled" || disable === "1" || disable === "true") {
|
|
180146
|
+
return { thinkingBudget: 0, includeThoughts: false };
|
|
180147
|
+
}
|
|
179426
180148
|
const budget = parseInt(process.env.RAYU_GEMINI_THINKING_BUDGET || "", 10);
|
|
179427
|
-
const cfg = {};
|
|
180149
|
+
const cfg = { includeThoughts: true };
|
|
179428
180150
|
if (level === "low" || level === "medium" || level === "high") {
|
|
179429
180151
|
cfg.thinkingLevel = level;
|
|
179430
180152
|
}
|
|
179431
180153
|
if (!isNaN(budget) && budget >= 0)
|
|
179432
180154
|
cfg.thinkingBudget = budget;
|
|
179433
|
-
return
|
|
180155
|
+
return cfg;
|
|
179434
180156
|
}
|
|
179435
180157
|
var thoughtSignatures, GEMINI_SCHEMA_KEYS;
|
|
179436
180158
|
var init_genaiTranslate = __esm(() => {
|
|
@@ -179639,7 +180361,7 @@ async function* parseSSEResponses(body) {
|
|
|
179639
180361
|
reader.releaseLock();
|
|
179640
180362
|
}
|
|
179641
180363
|
}
|
|
179642
|
-
function
|
|
180364
|
+
function normalizeError3(e2, model) {
|
|
179643
180365
|
reportIssue("code_assist.request_failed", "Code Assist request failed", {
|
|
179644
180366
|
model,
|
|
179645
180367
|
error: e2 instanceof Error ? e2.message : String(e2)
|
|
@@ -179667,7 +180389,7 @@ function createCodeAssistClient(config2) {
|
|
|
179667
180389
|
const json2 = await res.json();
|
|
179668
180390
|
return toBetaMessageFromGenAI(json2.response ?? json2, params.model);
|
|
179669
180391
|
} catch (e2) {
|
|
179670
|
-
throw
|
|
180392
|
+
throw normalizeError3(e2, params.model);
|
|
179671
180393
|
}
|
|
179672
180394
|
}
|
|
179673
180395
|
async function runStreaming(params) {
|
|
@@ -179686,7 +180408,7 @@ function createCodeAssistClient(config2) {
|
|
|
179686
180408
|
response: new Response(null, { status: 200 })
|
|
179687
180409
|
};
|
|
179688
180410
|
} catch (e2) {
|
|
179689
|
-
throw
|
|
180411
|
+
throw normalizeError3(e2, params.model);
|
|
179690
180412
|
}
|
|
179691
180413
|
}
|
|
179692
180414
|
return {
|
|
@@ -179737,7 +180459,7 @@ function buildVertexGenaiBody(params) {
|
|
|
179737
180459
|
body.generationConfig = b.config;
|
|
179738
180460
|
return body;
|
|
179739
180461
|
}
|
|
179740
|
-
function
|
|
180462
|
+
function normalizeError4(e2, model) {
|
|
179741
180463
|
reportIssue("vertex_genai.request_failed", "Vertex genai request failed", {
|
|
179742
180464
|
model,
|
|
179743
180465
|
error: e2 instanceof Error ? e2.message : String(e2)
|
|
@@ -179794,7 +180516,7 @@ function createVertexGenaiClient(provider, maxRetries) {
|
|
|
179794
180516
|
const json2 = await res.json();
|
|
179795
180517
|
return toBetaMessageFromGenAI(json2, params.model);
|
|
179796
180518
|
} catch (e2) {
|
|
179797
|
-
throw
|
|
180519
|
+
throw normalizeError4(e2, params.model);
|
|
179798
180520
|
}
|
|
179799
180521
|
}
|
|
179800
180522
|
async function runStreaming(params) {
|
|
@@ -179812,7 +180534,7 @@ function createVertexGenaiClient(provider, maxRetries) {
|
|
|
179812
180534
|
response: new Response(null, { status: 200 })
|
|
179813
180535
|
};
|
|
179814
180536
|
} catch (e2) {
|
|
179815
|
-
throw
|
|
180537
|
+
throw normalizeError4(e2, params.model);
|
|
179816
180538
|
}
|
|
179817
180539
|
}
|
|
179818
180540
|
return {
|
|
@@ -179879,6 +180601,19 @@ async function getRayuBedrockAnthropicClient(maxRetries) {
|
|
|
179879
180601
|
maxRetries
|
|
179880
180602
|
});
|
|
179881
180603
|
}
|
|
180604
|
+
async function getRayuBedrockConverseClient(maxRetries) {
|
|
180605
|
+
const { getActiveProvider: getActiveProvider2 } = await Promise.resolve().then(() => (init_rayuConfig(), exports_rayuConfig));
|
|
180606
|
+
const active = getActiveProvider2();
|
|
180607
|
+
if (active?.kind !== "bedrock" || active.bedrockApi !== "converse") {
|
|
180608
|
+
return null;
|
|
180609
|
+
}
|
|
180610
|
+
const { createBedrockConverseClient: createBedrockConverseClient2 } = await Promise.resolve().then(() => (init_bedrockConverseAdapter(), exports_bedrockConverseAdapter));
|
|
180611
|
+
return createBedrockConverseClient2({
|
|
180612
|
+
apiKey: active.apiKey,
|
|
180613
|
+
region: active.awsRegion,
|
|
180614
|
+
maxRetries
|
|
180615
|
+
});
|
|
180616
|
+
}
|
|
179882
180617
|
async function getRayuVertexClient(maxRetries) {
|
|
179883
180618
|
const { getActiveProvider: getActiveProvider2 } = await Promise.resolve().then(() => (init_rayuConfig(), exports_rayuConfig));
|
|
179884
180619
|
const active = getActiveProvider2();
|
|
@@ -179919,6 +180654,14 @@ async function buildClientForProvider(provider, maxRetries) {
|
|
|
179919
180654
|
maxRetries
|
|
179920
180655
|
});
|
|
179921
180656
|
}
|
|
180657
|
+
if (provider.kind === "bedrock" && provider.bedrockApi === "converse") {
|
|
180658
|
+
const { createBedrockConverseClient: createBedrockConverseClient2 } = await Promise.resolve().then(() => (init_bedrockConverseAdapter(), exports_bedrockConverseAdapter));
|
|
180659
|
+
return createBedrockConverseClient2({
|
|
180660
|
+
apiKey: provider.apiKey,
|
|
180661
|
+
region: provider.awsRegion,
|
|
180662
|
+
maxRetries
|
|
180663
|
+
});
|
|
180664
|
+
}
|
|
179922
180665
|
if (provider.kind === "vertex") {
|
|
179923
180666
|
const { createVertexGenaiClient: createVertexGenaiClient2 } = await Promise.resolve().then(() => (init_vertexGenaiClient(), exports_vertexGenaiClient));
|
|
179924
180667
|
return createVertexGenaiClient2(provider, maxRetries);
|
|
@@ -179964,6 +180707,10 @@ async function getAnthropicClient({
|
|
|
179964
180707
|
if (bedrockAnthropicClient) {
|
|
179965
180708
|
return bedrockAnthropicClient;
|
|
179966
180709
|
}
|
|
180710
|
+
const bedrockConverseClient = await getRayuBedrockConverseClient(maxRetries);
|
|
180711
|
+
if (bedrockConverseClient) {
|
|
180712
|
+
return bedrockConverseClient;
|
|
180713
|
+
}
|
|
179967
180714
|
const genaiClient = await getRayuGenAIClient(maxRetries);
|
|
179968
180715
|
if (genaiClient) {
|
|
179969
180716
|
return genaiClient;
|
|
@@ -180019,7 +180766,7 @@ async function getAnthropicClient({
|
|
|
180019
180766
|
...ARGS,
|
|
180020
180767
|
...isDebugToStdErr() && { logger: createStderrLogger() }
|
|
180021
180768
|
};
|
|
180022
|
-
return new
|
|
180769
|
+
return new import_sdk5.default(clientConfig);
|
|
180023
180770
|
}
|
|
180024
180771
|
async function configureApiKeyHeaders(headers, isNonInteractiveSession) {
|
|
180025
180772
|
const token = process.env.RAYU_ANTHROPIC_AUTH_TOKEN;
|
|
@@ -180063,7 +180810,7 @@ function buildFetch(fetchOverride, source) {
|
|
|
180063
180810
|
return inner(input, { ...init, headers });
|
|
180064
180811
|
};
|
|
180065
180812
|
}
|
|
180066
|
-
var
|
|
180813
|
+
var import_sdk5, CLIENT_REQUEST_ID_HEADER = "x-client-request-id";
|
|
180067
180814
|
var init_client4 = __esm(() => {
|
|
180068
180815
|
init_auth();
|
|
180069
180816
|
init_http2();
|
|
@@ -180073,7 +180820,7 @@ var init_client4 = __esm(() => {
|
|
|
180073
180820
|
init_oauth();
|
|
180074
180821
|
init_debug();
|
|
180075
180822
|
init_envUtils();
|
|
180076
|
-
|
|
180823
|
+
import_sdk5 = __toESM(require_sdk(), 1);
|
|
180077
180824
|
});
|
|
180078
180825
|
|
|
180079
180826
|
// src/utils/model/modelCapabilities.ts
|
|
@@ -181215,7 +181962,7 @@ var init_metadata = __esm(() => {
|
|
|
181215
181962
|
COMPOUND_OPERATOR_REGEX = /\s*(?:&&|\|\||[;|])\s*/;
|
|
181216
181963
|
WHITESPACE_REGEX = /\s+/;
|
|
181217
181964
|
getVersionBase = memoize_default(() => {
|
|
181218
|
-
const match = "1.3.
|
|
181965
|
+
const match = "1.3.327".match(/^\d+\.\d+\.\d+(?:-[a-z]+)?/);
|
|
181219
181966
|
return match ? match[0] : undefined;
|
|
181220
181967
|
});
|
|
181221
181968
|
buildEnvContext = memoize_default(async () => {
|
|
@@ -181254,7 +182001,7 @@ var init_metadata = __esm(() => {
|
|
|
181254
182001
|
},
|
|
181255
182002
|
isGithubAction: isEnvTruthy(process.env.GITHUB_ACTIONS),
|
|
181256
182003
|
isRayuAction: isEnvTruthy(process.env.RAYU_ACTION),
|
|
181257
|
-
version: "1.3.
|
|
182004
|
+
version: "1.3.327",
|
|
181258
182005
|
versionBase: getVersionBase(),
|
|
181259
182006
|
buildTime: "",
|
|
181260
182007
|
deploymentEnvironment: env4.detectDeploymentEnvironment(),
|
|
@@ -181868,7 +182615,7 @@ function initialize1PEventLogging() {
|
|
|
181868
182615
|
const platform2 = getPlatform();
|
|
181869
182616
|
const attributes = {
|
|
181870
182617
|
[import_semantic_conventions.ATTR_SERVICE_NAME]: "rayu",
|
|
181871
|
-
[import_semantic_conventions.ATTR_SERVICE_VERSION]: "1.3.
|
|
182618
|
+
[import_semantic_conventions.ATTR_SERVICE_VERSION]: "1.3.327"
|
|
181872
182619
|
};
|
|
181873
182620
|
if (platform2 === "wsl") {
|
|
181874
182621
|
const wslVersion = getWslVersion();
|
|
@@ -181895,7 +182642,7 @@ function initialize1PEventLogging() {
|
|
|
181895
182642
|
})
|
|
181896
182643
|
]
|
|
181897
182644
|
});
|
|
181898
|
-
firstPartyEventLogger = firstPartyEventLoggerProvider.getLogger("io.rayu.events", "1.3.
|
|
182645
|
+
firstPartyEventLogger = firstPartyEventLoggerProvider.getLogger("io.rayu.events", "1.3.327");
|
|
181899
182646
|
}
|
|
181900
182647
|
async function reinitialize1PEventLoggingIfConfigChanged() {
|
|
181901
182648
|
if (!is1PEventLoggingEnabled() || !firstPartyEventLoggerProvider) {
|
|
@@ -217811,7 +218558,7 @@ function getAttributionHeader(fingerprint) {
|
|
|
217811
218558
|
if (!isAttributionHeaderEnabled()) {
|
|
217812
218559
|
return "";
|
|
217813
218560
|
}
|
|
217814
|
-
const version2 = `${"1.3.
|
|
218561
|
+
const version2 = `${"1.3.327"}.${fingerprint}`;
|
|
217815
218562
|
const entrypoint = process.env.CLAUDE_CODE_ENTRYPOINT ?? "unknown";
|
|
217816
218563
|
const cch = "";
|
|
217817
218564
|
const workload = getWorkload();
|
|
@@ -271289,10 +272036,10 @@ function shouldProcessRateLimits(isSubscriber) {
|
|
|
271289
272036
|
function isMockRateLimitError(error54) {
|
|
271290
272037
|
return shouldProcessMockLimits() && error54.status === 429;
|
|
271291
272038
|
}
|
|
271292
|
-
var
|
|
272039
|
+
var import_sdk6;
|
|
271293
272040
|
var init_rateLimitMocking = __esm(() => {
|
|
271294
272041
|
init_mockRateLimits();
|
|
271295
|
-
|
|
272042
|
+
import_sdk6 = __toESM(require_sdk(), 1);
|
|
271296
272043
|
});
|
|
271297
272044
|
|
|
271298
272045
|
// src/services/rateLimitMessages.ts
|
|
@@ -271552,7 +272299,7 @@ async function checkQuotaStatus() {
|
|
|
271552
272299
|
const raw = await makeTestQuery();
|
|
271553
272300
|
extractQuotaStatusFromHeaders(raw.headers);
|
|
271554
272301
|
} catch (error54) {
|
|
271555
|
-
if (error54 instanceof
|
|
272302
|
+
if (error54 instanceof import_sdk7.APIError) {
|
|
271556
272303
|
extractQuotaStatusFromError(error54);
|
|
271557
272304
|
}
|
|
271558
272305
|
}
|
|
@@ -271696,7 +272443,7 @@ function extractQuotaStatusFromError(error54) {
|
|
|
271696
272443
|
logError2(e2);
|
|
271697
272444
|
}
|
|
271698
272445
|
}
|
|
271699
|
-
var
|
|
272446
|
+
var import_sdk7, EARLY_WARNING_CONFIGS, EARLY_WARNING_CLAIM_MAP, currentLimits, rawUtilization, statusListeners;
|
|
271700
272447
|
var init_claudeAiLimits = __esm(() => {
|
|
271701
272448
|
init_isEqual();
|
|
271702
272449
|
init_state();
|
|
@@ -271710,7 +272457,7 @@ var init_claudeAiLimits = __esm(() => {
|
|
|
271710
272457
|
init_client4();
|
|
271711
272458
|
init_rateLimitMocking();
|
|
271712
272459
|
init_rateLimitMessages();
|
|
271713
|
-
|
|
272460
|
+
import_sdk7 = __toESM(require_sdk(), 1);
|
|
271714
272461
|
EARLY_WARNING_CONFIGS = [
|
|
271715
272462
|
{
|
|
271716
272463
|
rateLimitType: "five_hour",
|
|
@@ -272065,7 +272812,7 @@ function logToolUseToolResultMismatch(toolUseId, messages, messagesForAPI) {
|
|
|
272065
272812
|
} catch (_) {}
|
|
272066
272813
|
}
|
|
272067
272814
|
function getAssistantMessageFromError(error54, model, options) {
|
|
272068
|
-
if (error54 instanceof
|
|
272815
|
+
if (error54 instanceof import_sdk8.APIConnectionTimeoutError || error54 instanceof import_sdk8.APIConnectionError && error54.message.toLowerCase().includes("timeout")) {
|
|
272069
272816
|
return createAssistantAPIErrorMessage({
|
|
272070
272817
|
content: API_TIMEOUT_ERROR_MESSAGE,
|
|
272071
272818
|
error: "unknown"
|
|
@@ -272082,7 +272829,7 @@ function getAssistantMessageFromError(error54, model, options) {
|
|
|
272082
272829
|
error: "rate_limit"
|
|
272083
272830
|
});
|
|
272084
272831
|
}
|
|
272085
|
-
if (error54 instanceof
|
|
272832
|
+
if (error54 instanceof import_sdk8.APIError && error54.status === 429 && shouldProcessRateLimits(false)) {
|
|
272086
272833
|
const rateLimitType = error54.headers?.get?.("anthropic-ratelimit-unified-representative-claim");
|
|
272087
272834
|
const overageStatus = error54.headers?.get?.("anthropic-ratelimit-unified-overage-status");
|
|
272088
272835
|
if (rateLimitType || overageStatus) {
|
|
@@ -272162,32 +272909,32 @@ function getAssistantMessageFromError(error54, model, options) {
|
|
|
272162
272909
|
error: "invalid_request"
|
|
272163
272910
|
});
|
|
272164
272911
|
}
|
|
272165
|
-
if (error54 instanceof
|
|
272912
|
+
if (error54 instanceof import_sdk8.APIError && error54.status === 400 && error54.message.includes("image exceeds") && error54.message.includes("maximum")) {
|
|
272166
272913
|
return createAssistantAPIErrorMessage({
|
|
272167
272914
|
content: getImageTooLargeErrorMessage(),
|
|
272168
272915
|
errorDetails: error54.message
|
|
272169
272916
|
});
|
|
272170
272917
|
}
|
|
272171
|
-
if (error54 instanceof
|
|
272918
|
+
if (error54 instanceof import_sdk8.APIError && error54.status === 400 && error54.message.includes("image dimensions exceed") && error54.message.includes("many-image")) {
|
|
272172
272919
|
return createAssistantAPIErrorMessage({
|
|
272173
272920
|
content: getIsNonInteractiveSession() ? "An image in the conversation exceeds the dimension limit for many-image requests (2000px). Start a new session with fewer images." : "An image in the conversation exceeds the dimension limit for many-image requests (2000px). Run /compact to remove old images from context, or start a new session.",
|
|
272174
272921
|
error: "invalid_request",
|
|
272175
272922
|
errorDetails: error54.message
|
|
272176
272923
|
});
|
|
272177
272924
|
}
|
|
272178
|
-
if (AFK_MODE_BETA_HEADER && error54 instanceof
|
|
272925
|
+
if (AFK_MODE_BETA_HEADER && error54 instanceof import_sdk8.APIError && error54.status === 400 && error54.message.includes(AFK_MODE_BETA_HEADER) && error54.message.includes("anthropic-beta")) {
|
|
272179
272926
|
return createAssistantAPIErrorMessage({
|
|
272180
272927
|
content: "Auto mode is unavailable for your plan",
|
|
272181
272928
|
error: "invalid_request"
|
|
272182
272929
|
});
|
|
272183
272930
|
}
|
|
272184
|
-
if (error54 instanceof
|
|
272931
|
+
if (error54 instanceof import_sdk8.APIError && error54.status === 413) {
|
|
272185
272932
|
return createAssistantAPIErrorMessage({
|
|
272186
272933
|
content: getRequestTooLargeErrorMessage(),
|
|
272187
272934
|
error: "invalid_request"
|
|
272188
272935
|
});
|
|
272189
272936
|
}
|
|
272190
|
-
if (error54 instanceof
|
|
272937
|
+
if (error54 instanceof import_sdk8.APIError && error54.status === 400 && error54.message.includes("`tool_use` ids were found without `tool_result` blocks immediately after")) {
|
|
272191
272938
|
if (options?.messages && options?.messagesForAPI) {
|
|
272192
272939
|
const toolUseIdMatch = error54.message.match(/toolu_[a-zA-Z0-9]+/);
|
|
272193
272940
|
const toolUseId = toolUseIdMatch ? toolUseIdMatch[0] : null;
|
|
@@ -272204,10 +272951,10 @@ function getAssistantMessageFromError(error54, model, options) {
|
|
|
272204
272951
|
});
|
|
272205
272952
|
}
|
|
272206
272953
|
}
|
|
272207
|
-
if (error54 instanceof
|
|
272954
|
+
if (error54 instanceof import_sdk8.APIError && error54.status === 400 && error54.message.includes("unexpected `tool_use_id` found in `tool_result`")) {
|
|
272208
272955
|
logEvent("tengu_unexpected_tool_result", {});
|
|
272209
272956
|
}
|
|
272210
|
-
if (error54 instanceof
|
|
272957
|
+
if (error54 instanceof import_sdk8.APIError && error54.status === 400 && error54.message.includes("`tool_use` ids must be unique")) {
|
|
272211
272958
|
logEvent("tengu_duplicate_tool_use_id", {});
|
|
272212
272959
|
const rewindInstruction = getIsNonInteractiveSession() ? "" : " Run /rewind to recover the conversation.";
|
|
272213
272960
|
return createAssistantAPIErrorMessage({
|
|
@@ -272223,7 +272970,7 @@ function getAssistantMessageFromError(error54, model, options) {
|
|
|
272223
272970
|
error: "billing_error"
|
|
272224
272971
|
});
|
|
272225
272972
|
}
|
|
272226
|
-
if (error54 instanceof
|
|
272973
|
+
if (error54 instanceof import_sdk8.APIError && error54.status === 400 && error54.message.toLowerCase().includes("organization has been disabled")) {
|
|
272227
272974
|
const { source } = getAnthropicApiKeyWithSource();
|
|
272228
272975
|
if (source === "RAYU_ANTHROPIC_API_KEY" && process.env.RAYU_ANTHROPIC_API_KEY && !isClaudeAISubscriber()) {
|
|
272229
272976
|
const hasStoredOAuth = getClaudeAIOAuthTokens()?.accessToken != null;
|
|
@@ -272247,19 +272994,19 @@ function getAssistantMessageFromError(error54, model, options) {
|
|
|
272247
272994
|
content: isExternalSource ? INVALID_API_KEY_ERROR_MESSAGE_EXTERNAL : INVALID_API_KEY_ERROR_MESSAGE
|
|
272248
272995
|
});
|
|
272249
272996
|
}
|
|
272250
|
-
if (error54 instanceof
|
|
272997
|
+
if (error54 instanceof import_sdk8.APIError && error54.status === 403 && error54.message.includes("OAuth token has been revoked")) {
|
|
272251
272998
|
return createAssistantAPIErrorMessage({
|
|
272252
272999
|
error: "authentication_failed",
|
|
272253
273000
|
content: getTokenRevokedErrorMessage()
|
|
272254
273001
|
});
|
|
272255
273002
|
}
|
|
272256
|
-
if (error54 instanceof
|
|
273003
|
+
if (error54 instanceof import_sdk8.APIError && (error54.status === 401 || error54.status === 403) && error54.message.includes("OAuth authentication is currently not allowed for this organization")) {
|
|
272257
273004
|
return createAssistantAPIErrorMessage({
|
|
272258
273005
|
error: "authentication_failed",
|
|
272259
273006
|
content: getOauthOrgNotAllowedErrorMessage()
|
|
272260
273007
|
});
|
|
272261
273008
|
}
|
|
272262
|
-
if (error54 instanceof
|
|
273009
|
+
if (error54 instanceof import_sdk8.APIError && (error54.status === 401 || error54.status === 403)) {
|
|
272263
273010
|
if (isCCRMode()) {
|
|
272264
273011
|
return createAssistantAPIErrorMessage({
|
|
272265
273012
|
error: "authentication_failed",
|
|
@@ -272279,7 +273026,7 @@ function getAssistantMessageFromError(error54, model, options) {
|
|
|
272279
273026
|
error: "invalid_request"
|
|
272280
273027
|
});
|
|
272281
273028
|
}
|
|
272282
|
-
if (error54 instanceof
|
|
273029
|
+
if (error54 instanceof import_sdk8.APIError && error54.status === 404) {
|
|
272283
273030
|
const switchCmd = getIsNonInteractiveSession() ? "--model" : "/model";
|
|
272284
273031
|
if (isRayuNonAnthropicActive()) {
|
|
272285
273032
|
return createAssistantAPIErrorMessage({
|
|
@@ -272293,7 +273040,7 @@ function getAssistantMessageFromError(error54, model, options) {
|
|
|
272293
273040
|
error: "invalid_request"
|
|
272294
273041
|
});
|
|
272295
273042
|
}
|
|
272296
|
-
if (error54 instanceof
|
|
273043
|
+
if (error54 instanceof import_sdk8.APIConnectionError) {
|
|
272297
273044
|
return createAssistantAPIErrorMessage({
|
|
272298
273045
|
content: `${API_ERROR_MESSAGE_PREFIX}: ${formatAPIError(error54)}`,
|
|
272299
273046
|
error: "unknown"
|
|
@@ -272330,7 +273077,7 @@ function classifyAPIError(error54) {
|
|
|
272330
273077
|
if (error54 instanceof Error && error54.message === "Request was aborted.") {
|
|
272331
273078
|
return "aborted";
|
|
272332
273079
|
}
|
|
272333
|
-
if (error54 instanceof
|
|
273080
|
+
if (error54 instanceof import_sdk8.APIConnectionTimeoutError || error54 instanceof import_sdk8.APIConnectionError && error54.message.toLowerCase().includes("timeout")) {
|
|
272334
273081
|
return "api_timeout";
|
|
272335
273082
|
}
|
|
272336
273083
|
if (error54 instanceof Error && error54.message.includes(REPEATED_529_ERROR_MESSAGE)) {
|
|
@@ -272339,10 +273086,10 @@ function classifyAPIError(error54) {
|
|
|
272339
273086
|
if (error54 instanceof Error && error54.message.includes(CUSTOM_OFF_SWITCH_MESSAGE)) {
|
|
272340
273087
|
return "capacity_off_switch";
|
|
272341
273088
|
}
|
|
272342
|
-
if (error54 instanceof
|
|
273089
|
+
if (error54 instanceof import_sdk8.APIError && error54.status === 429) {
|
|
272343
273090
|
return "rate_limit";
|
|
272344
273091
|
}
|
|
272345
|
-
if (error54 instanceof
|
|
273092
|
+
if (error54 instanceof import_sdk8.APIError && (error54.status === 529 || error54.message?.includes('"type":"overloaded_error"'))) {
|
|
272346
273093
|
return "server_overload";
|
|
272347
273094
|
}
|
|
272348
273095
|
if (error54 instanceof Error && error54.message.toLowerCase().includes(PROMPT_TOO_LONG_ERROR_MESSAGE.toLowerCase())) {
|
|
@@ -272354,22 +273101,22 @@ function classifyAPIError(error54) {
|
|
|
272354
273101
|
if (error54 instanceof Error && error54.message.includes("The PDF specified is password protected")) {
|
|
272355
273102
|
return "pdf_password_protected";
|
|
272356
273103
|
}
|
|
272357
|
-
if (error54 instanceof
|
|
273104
|
+
if (error54 instanceof import_sdk8.APIError && error54.status === 400 && error54.message.includes("image exceeds") && error54.message.includes("maximum")) {
|
|
272358
273105
|
return "image_too_large";
|
|
272359
273106
|
}
|
|
272360
|
-
if (error54 instanceof
|
|
273107
|
+
if (error54 instanceof import_sdk8.APIError && error54.status === 400 && error54.message.includes("image dimensions exceed") && error54.message.includes("many-image")) {
|
|
272361
273108
|
return "image_too_large";
|
|
272362
273109
|
}
|
|
272363
|
-
if (error54 instanceof
|
|
273110
|
+
if (error54 instanceof import_sdk8.APIError && error54.status === 400 && error54.message.includes("`tool_use` ids were found without `tool_result` blocks immediately after")) {
|
|
272364
273111
|
return "tool_use_mismatch";
|
|
272365
273112
|
}
|
|
272366
|
-
if (error54 instanceof
|
|
273113
|
+
if (error54 instanceof import_sdk8.APIError && error54.status === 400 && error54.message.includes("unexpected `tool_use_id` found in `tool_result`")) {
|
|
272367
273114
|
return "unexpected_tool_result";
|
|
272368
273115
|
}
|
|
272369
|
-
if (error54 instanceof
|
|
273116
|
+
if (error54 instanceof import_sdk8.APIError && error54.status === 400 && error54.message.includes("`tool_use` ids must be unique")) {
|
|
272370
273117
|
return "duplicate_tool_use_id";
|
|
272371
273118
|
}
|
|
272372
|
-
if (error54 instanceof
|
|
273119
|
+
if (error54 instanceof import_sdk8.APIError && error54.status === 400 && error54.message.toLowerCase().includes("invalid model name")) {
|
|
272373
273120
|
return "invalid_model";
|
|
272374
273121
|
}
|
|
272375
273122
|
if (error54 instanceof Error && error54.message.toLowerCase().includes(CREDIT_BALANCE_TOO_LOW_ERROR_MESSAGE.toLowerCase())) {
|
|
@@ -272378,26 +273125,26 @@ function classifyAPIError(error54) {
|
|
|
272378
273125
|
if (error54 instanceof Error && error54.message.toLowerCase().includes("x-api-key")) {
|
|
272379
273126
|
return "invalid_api_key";
|
|
272380
273127
|
}
|
|
272381
|
-
if (error54 instanceof
|
|
273128
|
+
if (error54 instanceof import_sdk8.APIError && error54.status === 403 && error54.message.includes("OAuth token has been revoked")) {
|
|
272382
273129
|
return "token_revoked";
|
|
272383
273130
|
}
|
|
272384
|
-
if (error54 instanceof
|
|
273131
|
+
if (error54 instanceof import_sdk8.APIError && (error54.status === 401 || error54.status === 403) && error54.message.includes("OAuth authentication is currently not allowed for this organization")) {
|
|
272385
273132
|
return "oauth_org_not_allowed";
|
|
272386
273133
|
}
|
|
272387
|
-
if (error54 instanceof
|
|
273134
|
+
if (error54 instanceof import_sdk8.APIError && (error54.status === 401 || error54.status === 403)) {
|
|
272388
273135
|
return "auth_error";
|
|
272389
273136
|
}
|
|
272390
273137
|
if (isEnvTruthy(process.env.RAYU_USE_BEDROCK) && error54 instanceof Error && error54.message.toLowerCase().includes("model id")) {
|
|
272391
273138
|
return "bedrock_model_access";
|
|
272392
273139
|
}
|
|
272393
|
-
if (error54 instanceof
|
|
273140
|
+
if (error54 instanceof import_sdk8.APIError) {
|
|
272394
273141
|
const status = error54.status;
|
|
272395
273142
|
if (status >= 500)
|
|
272396
273143
|
return "server_error";
|
|
272397
273144
|
if (status >= 400)
|
|
272398
273145
|
return "client_error";
|
|
272399
273146
|
}
|
|
272400
|
-
if (error54 instanceof
|
|
273147
|
+
if (error54 instanceof import_sdk8.APIConnectionError) {
|
|
272401
273148
|
const connectionDetails = extractConnectionErrorDetails(error54);
|
|
272402
273149
|
if (connectionDetails?.isSSLError) {
|
|
272403
273150
|
return "ssl_cert_error";
|
|
@@ -272433,7 +273180,7 @@ function getErrorMessageIfRefusal(stopReason, model) {
|
|
|
272433
273180
|
error: "invalid_request"
|
|
272434
273181
|
});
|
|
272435
273182
|
}
|
|
272436
|
-
var
|
|
273183
|
+
var import_sdk8, API_ERROR_MESSAGE_PREFIX = "API Error", PROMPT_TOO_LONG_ERROR_MESSAGE = "Prompt is too long", CREDIT_BALANCE_TOO_LOW_ERROR_MESSAGE = "Credit balance is too low", INVALID_API_KEY_ERROR_MESSAGE = "No valid provider API key · Configure Rayu with /connect or ~/.rayu/providers.json", INVALID_API_KEY_ERROR_MESSAGE_EXTERNAL = "Invalid provider API key · Update your Rayu provider configuration", ORG_DISABLED_ERROR_MESSAGE_ENV_KEY_WITH_OAUTH = "Your RAYU_ANTHROPIC_API_KEY belongs to a disabled organization · Unset the environment variable to use your configured Rayu provider instead", ORG_DISABLED_ERROR_MESSAGE_ENV_KEY = "Your RAYU_ANTHROPIC_API_KEY belongs to a disabled organization · Update or unset the environment variable", TOKEN_REVOKED_ERROR_MESSAGE = "Provider token revoked · Update your Rayu provider configuration", CCR_AUTH_ERROR_MESSAGE = "Authentication error · This may be a temporary network issue, please try again", REPEATED_529_ERROR_MESSAGE = "Repeated 529 Overloaded errors", CUSTOM_OFF_SWITCH_MESSAGE = "Opus is experiencing high load, please use /model to switch to Sonnet", API_TIMEOUT_ERROR_MESSAGE = "Request timed out", OAUTH_ORG_NOT_ALLOWED_ERROR_MESSAGE = "Your configured provider account does not have access to Rayu.";
|
|
272437
273184
|
var init_errors7 = __esm(() => {
|
|
272438
273185
|
init_betas();
|
|
272439
273186
|
init_auth();
|
|
@@ -272451,7 +273198,7 @@ var init_errors7 = __esm(() => {
|
|
|
272451
273198
|
init_claudeAiLimits();
|
|
272452
273199
|
init_rateLimitMocking();
|
|
272453
273200
|
init_errorUtils();
|
|
272454
|
-
|
|
273201
|
+
import_sdk8 = __toESM(require_sdk(), 1);
|
|
272455
273202
|
});
|
|
272456
273203
|
|
|
272457
273204
|
// src/utils/advisor.ts
|
|
@@ -272887,10 +273634,10 @@ function isPersistentRetryEnabled() {
|
|
|
272887
273634
|
return false;
|
|
272888
273635
|
}
|
|
272889
273636
|
function isTransientCapacityError(error54) {
|
|
272890
|
-
return is529Error(error54) || error54 instanceof
|
|
273637
|
+
return is529Error(error54) || error54 instanceof import_sdk9.APIError && error54.status === 429;
|
|
272891
273638
|
}
|
|
272892
273639
|
function isStaleConnectionError(error54) {
|
|
272893
|
-
if (!(error54 instanceof
|
|
273640
|
+
if (!(error54 instanceof import_sdk9.APIConnectionError)) {
|
|
272894
273641
|
return false;
|
|
272895
273642
|
}
|
|
272896
273643
|
const details = extractConnectionErrorDetails(error54);
|
|
@@ -272909,7 +273656,7 @@ async function* withRetry(getClient, operation, options) {
|
|
|
272909
273656
|
let persistentAttempt = 0;
|
|
272910
273657
|
for (let attempt = 1;attempt <= maxRetries + 1; attempt++) {
|
|
272911
273658
|
if (options.signal?.aborted) {
|
|
272912
|
-
throw new
|
|
273659
|
+
throw new import_sdk9.APIUserAbortError;
|
|
272913
273660
|
}
|
|
272914
273661
|
const wasFastModeActive = isFastModeEnabled() ? retryContext.fastMode && !isFastModeCooldown() : false;
|
|
272915
273662
|
try {
|
|
@@ -272919,8 +273666,8 @@ async function* withRetry(getClient, operation, options) {
|
|
|
272919
273666
|
logForDebugging("Stale connection (ECONNRESET/EPIPE) — disabling keep-alive for retry");
|
|
272920
273667
|
disableKeepAlive();
|
|
272921
273668
|
}
|
|
272922
|
-
if (client4 === null || lastError instanceof
|
|
272923
|
-
if (lastError instanceof
|
|
273669
|
+
if (client4 === null || lastError instanceof import_sdk9.APIError && lastError.status === 401 || isOAuthTokenRevokedError(lastError) || isBedrockAuthError(lastError) || isVertexAuthError(lastError) || isStaleConnection) {
|
|
273670
|
+
if (lastError instanceof import_sdk9.APIError && lastError.status === 401 || isOAuthTokenRevokedError(lastError)) {
|
|
272924
273671
|
const failedAccessToken = getClaudeAIOAuthTokens()?.accessToken;
|
|
272925
273672
|
if (failedAccessToken) {
|
|
272926
273673
|
await handleOAuth401Error(failedAccessToken);
|
|
@@ -272931,8 +273678,8 @@ async function* withRetry(getClient, operation, options) {
|
|
|
272931
273678
|
return await operation(client4, attempt, retryContext);
|
|
272932
273679
|
} catch (error54) {
|
|
272933
273680
|
lastError = error54;
|
|
272934
|
-
logForDebugging(`API error (attempt ${attempt}/${maxRetries + 1}): ${error54 instanceof
|
|
272935
|
-
if (wasFastModeActive && !isPersistentRetryEnabled() && error54 instanceof
|
|
273681
|
+
logForDebugging(`API error (attempt ${attempt}/${maxRetries + 1}): ${error54 instanceof import_sdk9.APIError ? `${error54.status} ${error54.message}` : errorMessage(error54)}`, { level: "error" });
|
|
273682
|
+
if (wasFastModeActive && !isPersistentRetryEnabled() && error54 instanceof import_sdk9.APIError && (error54.status === 429 || is529Error(error54))) {
|
|
272936
273683
|
const overageReason = error54.headers?.get("anthropic-ratelimit-unified-overage-disabled-reason");
|
|
272937
273684
|
if (overageReason !== null && overageReason !== undefined) {
|
|
272938
273685
|
handleFastModeOverageRejection(overageReason);
|
|
@@ -272985,10 +273732,10 @@ async function* withRetry(getClient, operation, options) {
|
|
|
272985
273732
|
throw new CannotRetryError(error54, retryContext);
|
|
272986
273733
|
}
|
|
272987
273734
|
const handledCloudAuthError = handleAwsCredentialError(error54) || handleGcpCredentialError(error54);
|
|
272988
|
-
if (!handledCloudAuthError && (!(error54 instanceof
|
|
273735
|
+
if (!handledCloudAuthError && (!(error54 instanceof import_sdk9.APIError) || !shouldRetry(error54))) {
|
|
272989
273736
|
throw new CannotRetryError(error54, retryContext);
|
|
272990
273737
|
}
|
|
272991
|
-
if (error54 instanceof
|
|
273738
|
+
if (error54 instanceof import_sdk9.APIError) {
|
|
272992
273739
|
const overflowData = parseMaxTokensContextOverflowError(error54);
|
|
272993
273740
|
if (overflowData) {
|
|
272994
273741
|
const { inputTokens, contextLimit } = overflowData;
|
|
@@ -273012,7 +273759,7 @@ async function* withRetry(getClient, operation, options) {
|
|
|
273012
273759
|
}
|
|
273013
273760
|
const retryAfter = getRetryAfter(error54);
|
|
273014
273761
|
let delayMs;
|
|
273015
|
-
if (persistent && error54 instanceof
|
|
273762
|
+
if (persistent && error54 instanceof import_sdk9.APIError && error54.status === 429) {
|
|
273016
273763
|
persistentAttempt++;
|
|
273017
273764
|
const resetDelay = getRateLimitResetDelayMs(error54);
|
|
273018
273765
|
delayMs = resetDelay ?? Math.min(getRetryDelay(persistentAttempt, retryAfter, PERSISTENT_MAX_BACKOFF_MS), PERSISTENT_RESET_CAP_MS);
|
|
@@ -273042,8 +273789,8 @@ async function* withRetry(getClient, operation, options) {
|
|
|
273042
273789
|
let remaining = delayMs;
|
|
273043
273790
|
while (remaining > 0) {
|
|
273044
273791
|
if (options.signal?.aborted)
|
|
273045
|
-
throw new
|
|
273046
|
-
if (error54 instanceof
|
|
273792
|
+
throw new import_sdk9.APIUserAbortError;
|
|
273793
|
+
if (error54 instanceof import_sdk9.APIError) {
|
|
273047
273794
|
yield createSystemAPIErrorMessage(error54, remaining, reportedAttempt, maxRetries);
|
|
273048
273795
|
}
|
|
273049
273796
|
const chunk = Math.min(remaining, HEARTBEAT_INTERVAL_MS);
|
|
@@ -273053,7 +273800,7 @@ async function* withRetry(getClient, operation, options) {
|
|
|
273053
273800
|
if (attempt >= maxRetries)
|
|
273054
273801
|
attempt = maxRetries;
|
|
273055
273802
|
} else {
|
|
273056
|
-
if (error54 instanceof
|
|
273803
|
+
if (error54 instanceof import_sdk9.APIError) {
|
|
273057
273804
|
yield createSystemAPIErrorMessage(error54, delayMs, attempt, maxRetries);
|
|
273058
273805
|
}
|
|
273059
273806
|
await sleep(delayMs, options.signal, { abortError });
|
|
@@ -273101,23 +273848,23 @@ function parseMaxTokensContextOverflowError(error54) {
|
|
|
273101
273848
|
return { inputTokens, maxTokens, contextLimit };
|
|
273102
273849
|
}
|
|
273103
273850
|
function isFastModeNotEnabledError(error54) {
|
|
273104
|
-
if (!(error54 instanceof
|
|
273851
|
+
if (!(error54 instanceof import_sdk9.APIError)) {
|
|
273105
273852
|
return false;
|
|
273106
273853
|
}
|
|
273107
273854
|
return error54.status === 400 && (error54.message?.includes("Fast mode is not enabled") ?? false);
|
|
273108
273855
|
}
|
|
273109
273856
|
function is529Error(error54) {
|
|
273110
|
-
if (!(error54 instanceof
|
|
273857
|
+
if (!(error54 instanceof import_sdk9.APIError)) {
|
|
273111
273858
|
return false;
|
|
273112
273859
|
}
|
|
273113
273860
|
return error54.status === 529 || (error54.message?.includes('"type":"overloaded_error"') ?? false);
|
|
273114
273861
|
}
|
|
273115
273862
|
function isOAuthTokenRevokedError(error54) {
|
|
273116
|
-
return error54 instanceof
|
|
273863
|
+
return error54 instanceof import_sdk9.APIError && error54.status === 403 && (error54.message?.includes("OAuth token has been revoked") ?? false);
|
|
273117
273864
|
}
|
|
273118
273865
|
function isBedrockAuthError(error54) {
|
|
273119
273866
|
if (isEnvTruthy(process.env.RAYU_USE_BEDROCK)) {
|
|
273120
|
-
if (isAwsCredentialsProviderError(error54) || error54 instanceof
|
|
273867
|
+
if (isAwsCredentialsProviderError(error54) || error54 instanceof import_sdk9.APIError && error54.status === 403) {
|
|
273121
273868
|
return true;
|
|
273122
273869
|
}
|
|
273123
273870
|
}
|
|
@@ -273141,7 +273888,7 @@ function isVertexAuthError(error54) {
|
|
|
273141
273888
|
if (isGoogleAuthLibraryCredentialError(error54)) {
|
|
273142
273889
|
return true;
|
|
273143
273890
|
}
|
|
273144
|
-
if (error54 instanceof
|
|
273891
|
+
if (error54 instanceof import_sdk9.APIError && error54.status === 401) {
|
|
273145
273892
|
return true;
|
|
273146
273893
|
}
|
|
273147
273894
|
}
|
|
@@ -273180,7 +273927,7 @@ function shouldRetry(error54) {
|
|
|
273180
273927
|
return false;
|
|
273181
273928
|
}
|
|
273182
273929
|
}
|
|
273183
|
-
if (error54 instanceof
|
|
273930
|
+
if (error54 instanceof import_sdk9.APIConnectionError) {
|
|
273184
273931
|
return true;
|
|
273185
273932
|
}
|
|
273186
273933
|
if (!error54.status)
|
|
@@ -273234,7 +273981,7 @@ function getRateLimitResetDelayMs(error54) {
|
|
|
273234
273981
|
return null;
|
|
273235
273982
|
return Math.min(delayMs, PERSISTENT_RESET_CAP_MS);
|
|
273236
273983
|
}
|
|
273237
|
-
var
|
|
273984
|
+
var import_sdk9, abortError = () => new import_sdk9.APIUserAbortError, DEFAULT_MAX_RETRIES = 10, FLOOR_OUTPUT_TOKENS = 3000, MAX_529_RETRIES = 3, BASE_DELAY_MS = 500, FOREGROUND_529_RETRY_SOURCES, PERSISTENT_MAX_BACKOFF_MS, PERSISTENT_RESET_CAP_MS, HEARTBEAT_INTERVAL_MS = 30000, CannotRetryError, FallbackTriggeredError, DEFAULT_FAST_MODE_FALLBACK_HOLD_MS, SHORT_RETRY_THRESHOLD_MS, MIN_COOLDOWN_MS;
|
|
273238
273985
|
var init_withRetry = __esm(() => {
|
|
273239
273986
|
init_aws();
|
|
273240
273987
|
init_debug();
|
|
@@ -273252,7 +273999,7 @@ var init_withRetry = __esm(() => {
|
|
|
273252
273999
|
init_rateLimitMocking();
|
|
273253
274000
|
init_errors7();
|
|
273254
274001
|
init_errorUtils();
|
|
273255
|
-
|
|
274002
|
+
import_sdk9 = __toESM(require_sdk(), 1);
|
|
273256
274003
|
FOREGROUND_529_RETRY_SOURCES = new Set([
|
|
273257
274004
|
"repl_main_thread",
|
|
273258
274005
|
"repl_main_thread:outputStyle:custom",
|
|
@@ -295891,7 +296638,7 @@ async function streamCompactSummary({
|
|
|
295891
296638
|
hasStartedStreaming
|
|
295892
296639
|
});
|
|
295893
296640
|
await sleep(getRetryDelay(attempt), context.abortController.signal, {
|
|
295894
|
-
abortError: () => new
|
|
296641
|
+
abortError: () => new import_sdk10.APIUserAbortError
|
|
295895
296642
|
});
|
|
295896
296643
|
continue;
|
|
295897
296644
|
}
|
|
@@ -296061,7 +296808,7 @@ function shouldExcludeFromPostCompactRestore(filename, agentId) {
|
|
|
296061
296808
|
} catch {}
|
|
296062
296809
|
return false;
|
|
296063
296810
|
}
|
|
296064
|
-
var
|
|
296811
|
+
var import_sdk10, POST_COMPACT_MAX_FILES_TO_RESTORE = 5, POST_COMPACT_TOKEN_BUDGET = 50000, POST_COMPACT_MAX_TOKENS_PER_FILE = 5000, POST_COMPACT_MAX_TOKENS_PER_SKILL = 5000, POST_COMPACT_SKILLS_TOKEN_BUDGET = 25000, MAX_COMPACT_STREAMING_RETRIES = 2, ERROR_MESSAGE_NOT_ENOUGH_MESSAGES = "Not enough messages to compact.", MAX_PTL_RETRIES = 3, PTL_RETRY_MARKER = "[earlier conversation truncated for compaction retry]", ERROR_MESSAGE_PROMPT_TOO_LONG = "Conversation too long. Press esc twice to go up a few messages and try again.", ERROR_MESSAGE_USER_ABORT = "API Error: Request was aborted.", ERROR_MESSAGE_INCOMPLETE_RESPONSE = "Compaction interrupted · This may be due to network issues — please try again.", SKILL_TRUNCATION_MARKER = `
|
|
296065
296812
|
|
|
296066
296813
|
[... skill content truncated for compaction; use Read on the skill path if you need the full text]`;
|
|
296067
296814
|
var init_compact = __esm(() => {
|
|
@@ -296101,7 +296848,7 @@ var init_compact = __esm(() => {
|
|
|
296101
296848
|
init_internalLogging();
|
|
296102
296849
|
init_tokenEstimation();
|
|
296103
296850
|
init_prompt10();
|
|
296104
|
-
|
|
296851
|
+
import_sdk10 = __toESM(require_sdk(), 1);
|
|
296105
296852
|
});
|
|
296106
296853
|
|
|
296107
296854
|
// src/constants/systemPromptSections.ts
|
|
@@ -302083,7 +302830,7 @@ function isNormalizedCdCommand(command) {
|
|
|
302083
302830
|
function commandHasAnyCd(command) {
|
|
302084
302831
|
return splitCommand(command).some((subcmd) => isNormalizedCdCommand(subcmd.trim()));
|
|
302085
302832
|
}
|
|
302086
|
-
var
|
|
302833
|
+
var import_sdk11, bashCommandIsSafeAsync, splitCommand, ENV_VAR_ASSIGN_RE, MAX_SUBCOMMANDS_FOR_SECURITY_CHECK = 50, MAX_SUGGESTED_RULES_FOR_COMPOUND = 5, BARE_SHELL_PREFIXES, permissionRuleExtractPrefix3, bashPermissionRule, SAFE_ENV_VARS2, ANT_ONLY_SAFE_ENV_VARS, BINARY_HIJACK_VARS, bashToolCheckExactMatchPermission = (input, toolPermissionContext) => {
|
|
302087
302834
|
const command = input.command.trim();
|
|
302088
302835
|
const { matchingDenyRules, matchingAskRules, matchingAllowRules } = matchingRulesForInput2(input, toolPermissionContext, "exact");
|
|
302089
302836
|
if (matchingDenyRules[0] !== undefined) {
|
|
@@ -302227,7 +302974,7 @@ var init_bashPermissions = __esm(() => {
|
|
|
302227
302974
|
init_pathValidation3();
|
|
302228
302975
|
init_sedValidation();
|
|
302229
302976
|
init_shouldUseSandbox();
|
|
302230
|
-
|
|
302977
|
+
import_sdk11 = __toESM(require_sdk(), 1);
|
|
302231
302978
|
bashCommandIsSafeAsync = bashCommandIsSafeAsync_DEPRECATED;
|
|
302232
302979
|
splitCommand = splitCommand_DEPRECATED;
|
|
302233
302980
|
ENV_VAR_ASSIGN_RE = /^[A-Za-z_]\w*=/;
|
|
@@ -302416,7 +303163,7 @@ function getTelemetryAttributes() {
|
|
|
302416
303163
|
attributes["session.id"] = sessionId;
|
|
302417
303164
|
}
|
|
302418
303165
|
if (shouldIncludeAttribute("OTEL_METRICS_INCLUDE_VERSION")) {
|
|
302419
|
-
attributes["app.version"] = "1.3.
|
|
303166
|
+
attributes["app.version"] = "1.3.327";
|
|
302420
303167
|
}
|
|
302421
303168
|
const oauthAccount = getOauthAccountInfo();
|
|
302422
303169
|
if (oauthAccount) {
|
|
@@ -412774,7 +413521,7 @@ function getInstallationEnv() {
|
|
|
412774
413521
|
return;
|
|
412775
413522
|
}
|
|
412776
413523
|
function getClaudeCodeVersion() {
|
|
412777
|
-
return "1.3.
|
|
413524
|
+
return "1.3.327";
|
|
412778
413525
|
}
|
|
412779
413526
|
async function getInstalledVSCodeExtensionVersion(command) {
|
|
412780
413527
|
const { stdout } = await execFileNoThrow(command, ["--list-extensions", "--show-versions"], {
|
|
@@ -418012,7 +418759,7 @@ async function setupSdkMcpClients(sdkMcpConfigs, sendMcpMessage) {
|
|
|
418012
418759
|
const client4 = new Client({
|
|
418013
418760
|
name: "claude-code",
|
|
418014
418761
|
title: "RAYU",
|
|
418015
|
-
version: "1.3.
|
|
418762
|
+
version: "1.3.327",
|
|
418016
418763
|
description: "Anthropic's agentic coding tool",
|
|
418017
418764
|
websiteUrl: PRODUCT_URL
|
|
418018
418765
|
}, {
|
|
@@ -418329,7 +419076,7 @@ var init_client7 = __esm(() => {
|
|
|
418329
419076
|
const client4 = new Client({
|
|
418330
419077
|
name: "claude-code",
|
|
418331
419078
|
title: "RAYU",
|
|
418332
|
-
version: "1.3.
|
|
419079
|
+
version: "1.3.327",
|
|
418333
419080
|
description: "Anthropic's agentic coding tool",
|
|
418334
419081
|
websiteUrl: PRODUCT_URL
|
|
418335
419082
|
}, {
|
|
@@ -425093,7 +425840,8 @@ function recordPendingFileChange(context, input) {
|
|
|
425093
425840
|
structuredPatch: input.structuredPatch,
|
|
425094
425841
|
status: "pending"
|
|
425095
425842
|
};
|
|
425096
|
-
context.
|
|
425843
|
+
const applyChange = context.recordFileChangeSetAppState ?? context.setAppState;
|
|
425844
|
+
applyChange((prev) => ({
|
|
425097
425845
|
...prev,
|
|
425098
425846
|
pendingFileChanges: [...prev.pendingFileChanges, change].slice(-MAX_PENDING_FILE_CHANGES)
|
|
425099
425847
|
}));
|
|
@@ -431627,7 +432375,8 @@ function createProgressTracker() {
|
|
|
431627
432375
|
toolUseCount: 0,
|
|
431628
432376
|
latestInputTokens: 0,
|
|
431629
432377
|
cumulativeOutputTokens: 0,
|
|
431630
|
-
recentActivities: []
|
|
432378
|
+
recentActivities: [],
|
|
432379
|
+
isThinking: false
|
|
431631
432380
|
};
|
|
431632
432381
|
}
|
|
431633
432382
|
function getTokenCountFromTracker(tracker) {
|
|
@@ -431640,6 +432389,7 @@ function updateProgressFromMessage(tracker, message, resolveActivityDescription,
|
|
|
431640
432389
|
const usage = message.message.usage;
|
|
431641
432390
|
tracker.latestInputTokens = usage.input_tokens + (usage.cache_creation_input_tokens ?? 0) + (usage.cache_read_input_tokens ?? 0);
|
|
431642
432391
|
tracker.cumulativeOutputTokens += usage.output_tokens;
|
|
432392
|
+
tracker.isThinking = message.message.content.some((c4) => c4.type === "thinking" || c4.type === "redacted_thinking") && !message.message.content.some((c4) => c4.type === "tool_use");
|
|
431643
432393
|
for (const content of message.message.content) {
|
|
431644
432394
|
if (content.type === "tool_use") {
|
|
431645
432395
|
tracker.toolUseCount++;
|
|
@@ -431665,7 +432415,8 @@ function getProgressUpdate(tracker) {
|
|
|
431665
432415
|
toolUseCount: tracker.toolUseCount,
|
|
431666
432416
|
tokenCount: getTokenCountFromTracker(tracker),
|
|
431667
432417
|
lastActivity: tracker.recentActivities.length > 0 ? tracker.recentActivities[tracker.recentActivities.length - 1] : undefined,
|
|
431668
|
-
recentActivities: [...tracker.recentActivities]
|
|
432418
|
+
recentActivities: [...tracker.recentActivities],
|
|
432419
|
+
isThinking: tracker.isThinking
|
|
431669
432420
|
};
|
|
431670
432421
|
}
|
|
431671
432422
|
function createActivityDescriptionResolver(tools) {
|
|
@@ -433130,7 +433881,7 @@ function computeFingerprint(messageText, version2) {
|
|
|
433130
433881
|
}
|
|
433131
433882
|
function computeFingerprintFromMessages(messages) {
|
|
433132
433883
|
const firstMessageText = extractFirstMessageText(messages);
|
|
433133
|
-
return computeFingerprint(firstMessageText, "1.3.
|
|
433884
|
+
return computeFingerprint(firstMessageText, "1.3.327");
|
|
433134
433885
|
}
|
|
433135
433886
|
var FINGERPRINT_SALT = "59cf53e54c78";
|
|
433136
433887
|
var init_fingerprint = () => {};
|
|
@@ -433172,7 +433923,7 @@ async function sideQuery(opts) {
|
|
|
433172
433923
|
betas.push(STRUCTURED_OUTPUTS_BETA_HEADER);
|
|
433173
433924
|
}
|
|
433174
433925
|
const messageText = extractFirstUserMessageText(messages);
|
|
433175
|
-
const fingerprint = computeFingerprint(messageText, "1.3.
|
|
433926
|
+
const fingerprint = computeFingerprint(messageText, "1.3.327");
|
|
433176
433927
|
const attributionHeader = getAttributionHeader(fingerprint);
|
|
433177
433928
|
const systemBlocks = [
|
|
433178
433929
|
attributionHeader ? { type: "text", text: attributionHeader } : null,
|
|
@@ -445575,6 +446326,29 @@ function hasProgressMessage(data) {
|
|
|
445575
446326
|
const msg = data.message;
|
|
445576
446327
|
return msg != null && typeof msg === "object" && "type" in msg;
|
|
445577
446328
|
}
|
|
446329
|
+
function isAgentCurrentlyThinking(progressMessages) {
|
|
446330
|
+
const last2 = progressMessages.findLast((m3) => hasProgressMessage(m3.data));
|
|
446331
|
+
if (!last2 || !hasProgressMessage(last2.data)) {
|
|
446332
|
+
return false;
|
|
446333
|
+
}
|
|
446334
|
+
const message = last2.data.message;
|
|
446335
|
+
if (message.type !== "assistant") {
|
|
446336
|
+
return false;
|
|
446337
|
+
}
|
|
446338
|
+
const content = message.message.content;
|
|
446339
|
+
return content.some((c4) => c4.type === "thinking" || c4.type === "redacted_thinking") && !content.some((c4) => c4.type === "tool_use");
|
|
446340
|
+
}
|
|
446341
|
+
function isThinkingOnlyAssistantMessage(m3) {
|
|
446342
|
+
if (!hasProgressMessage(m3.data)) {
|
|
446343
|
+
return false;
|
|
446344
|
+
}
|
|
446345
|
+
const message = m3.data.message;
|
|
446346
|
+
if (message.type !== "assistant") {
|
|
446347
|
+
return false;
|
|
446348
|
+
}
|
|
446349
|
+
const content = message.message.content;
|
|
446350
|
+
return content.length > 0 && content.every((c4) => c4.type === "thinking" || c4.type === "redacted_thinking");
|
|
446351
|
+
}
|
|
445578
446352
|
function getSearchOrReadInfo(progressMessage, tools, toolUseByID) {
|
|
445579
446353
|
if (!hasProgressMessage(progressMessage.data)) {
|
|
445580
446354
|
return null;
|
|
@@ -445596,7 +446370,7 @@ function getSearchOrReadInfo(progressMessage, tools, toolUseByID) {
|
|
|
445596
446370
|
}
|
|
445597
446371
|
function processProgressMessages(messages, tools, isAgentRunning) {
|
|
445598
446372
|
if (true) {
|
|
445599
|
-
return messages.filter((m3) => hasProgressMessage(m3.data) && m3.data.message.type !== "user").map((m3) => ({
|
|
446373
|
+
return messages.filter((m3) => hasProgressMessage(m3.data) && m3.data.message.type !== "user" && !isThinkingOnlyAssistantMessage(m3)).map((m3) => ({
|
|
445600
446374
|
type: "original",
|
|
445601
446375
|
message: m3
|
|
445602
446376
|
}));
|
|
@@ -446152,7 +446926,7 @@ function renderToolUseProgressMessage5(progressMessages, {
|
|
|
446152
446926
|
height: 1,
|
|
446153
446927
|
children: /* @__PURE__ */ jsx_dev_runtime108.jsxDEV(ThemedText, {
|
|
446154
446928
|
dimColor: true,
|
|
446155
|
-
children: INITIALIZING_TEXT
|
|
446929
|
+
children: isAgentCurrentlyThinking(progressMessages) ? THINKING_TEXT : INITIALIZING_TEXT
|
|
446156
446930
|
}, undefined, false, undefined, this)
|
|
446157
446931
|
}, undefined, false, undefined, this);
|
|
446158
446932
|
}
|
|
@@ -446438,6 +447212,9 @@ function userFacingNameBackgroundColor(input) {
|
|
|
446438
447212
|
return getAgentColor(input.subagent_type);
|
|
446439
447213
|
}
|
|
446440
447214
|
function extractLastToolInfo(progressMessages, tools) {
|
|
447215
|
+
if (isAgentCurrentlyThinking(progressMessages)) {
|
|
447216
|
+
return THINKING_TEXT;
|
|
447217
|
+
}
|
|
446441
447218
|
const toolUseByID = new Map;
|
|
446442
447219
|
for (const pm of progressMessages) {
|
|
446443
447220
|
if (!hasProgressMessage(pm.data)) {
|
|
@@ -446508,7 +447285,7 @@ function extractLastToolInfo(progressMessages, tools) {
|
|
|
446508
447285
|
function isCustomSubagentType(subagentType) {
|
|
446509
447286
|
return !!subagentType && subagentType !== GENERAL_PURPOSE_AGENT.agentType && subagentType !== "worker";
|
|
446510
447287
|
}
|
|
446511
|
-
var import_compiler_runtime92, jsx_dev_runtime108, MAX_PROGRESS_MESSAGES_TO_SHOW = 3, ESTIMATED_LINES_PER_TOOL = 9, TERMINAL_BUFFER_LINES = 7, INITIALIZING_TEXT = "Initializing…";
|
|
447288
|
+
var import_compiler_runtime92, jsx_dev_runtime108, MAX_PROGRESS_MESSAGES_TO_SHOW = 3, THINKING_TEXT = "thinking…", ESTIMATED_LINES_PER_TOOL = 9, TERMINAL_BUFFER_LINES = 7, INITIALIZING_TEXT = "Initializing…";
|
|
446512
447289
|
var init_UI11 = __esm(() => {
|
|
446513
447290
|
init_ConfigurableShortcutHint();
|
|
446514
447291
|
init_CtrlOToExpand();
|
|
@@ -447470,6 +448247,13 @@ async function initializeAgentMcpServers(agentDefinition, parentClients) {
|
|
|
447470
448247
|
function isRecordableMessage(msg) {
|
|
447471
448248
|
return msg.type === "assistant" || msg.type === "user" || msg.type === "progress" || msg.type === "system" && "subtype" in msg && msg.subtype === "compact_boundary";
|
|
447472
448249
|
}
|
|
448250
|
+
function resolveFileChangeRecorder(opts) {
|
|
448251
|
+
if (opts.worktreePath)
|
|
448252
|
+
return () => {};
|
|
448253
|
+
if (opts.parentRecorder !== undefined)
|
|
448254
|
+
return opts.parentRecorder;
|
|
448255
|
+
return opts.rootSetAppState;
|
|
448256
|
+
}
|
|
447473
448257
|
async function* runAgent({
|
|
447474
448258
|
agentDefinition,
|
|
447475
448259
|
promptMessages,
|
|
@@ -447630,7 +448414,7 @@ async function* runAgent({
|
|
|
447630
448414
|
debug: toolUseContext.options.debug,
|
|
447631
448415
|
verbose: toolUseContext.options.verbose,
|
|
447632
448416
|
mainLoopModel: resolvedAgentModel,
|
|
447633
|
-
thinkingConfig: useExactTools ? toolUseContext.options.thinkingConfig : { type: "disabled" },
|
|
448417
|
+
thinkingConfig: useExactTools || SUBAGENT_TYPES.includes(agentDefinition.agentType) || COLLABORATOR_AGENT_TYPES.includes(agentDefinition.agentType) ? toolUseContext.options.thinkingConfig : { type: "disabled" },
|
|
447634
448418
|
mcpClients: mergedMcpClients,
|
|
447635
448419
|
mcpResources: toolUseContext.options.mcpResources,
|
|
447636
448420
|
agentDefinitions: toolUseContext.options.agentDefinitions,
|
|
@@ -447652,6 +448436,11 @@ async function* runAgent({
|
|
|
447652
448436
|
if (preserveToolUseResults) {
|
|
447653
448437
|
agentToolUseContext.preserveToolUseResults = true;
|
|
447654
448438
|
}
|
|
448439
|
+
agentToolUseContext.recordFileChangeSetAppState = resolveFileChangeRecorder({
|
|
448440
|
+
worktreePath,
|
|
448441
|
+
parentRecorder: toolUseContext.recordFileChangeSetAppState,
|
|
448442
|
+
rootSetAppState
|
|
448443
|
+
});
|
|
447655
448444
|
if (onCacheSafeParams) {
|
|
447656
448445
|
onCacheSafeParams({
|
|
447657
448446
|
systemPrompt: agentSystemPrompt,
|
|
@@ -447820,6 +448609,8 @@ var init_runAgent = __esm(() => {
|
|
|
447820
448609
|
init_uuid();
|
|
447821
448610
|
init_agentToolUtils();
|
|
447822
448611
|
init_loadAgentsDir();
|
|
448612
|
+
init_collaborators();
|
|
448613
|
+
init_subagents();
|
|
447823
448614
|
});
|
|
447824
448615
|
|
|
447825
448616
|
// src/services/AgentSummary/agentSummary.ts
|
|
@@ -492988,7 +493779,7 @@ async function validateModel(model) {
|
|
|
492988
493779
|
}
|
|
492989
493780
|
}
|
|
492990
493781
|
function handleValidationError(error54, modelName) {
|
|
492991
|
-
if (error54 instanceof
|
|
493782
|
+
if (error54 instanceof import_sdk12.NotFoundError) {
|
|
492992
493783
|
const fallback = get3PFallbackSuggestion(modelName);
|
|
492993
493784
|
const suggestion = fallback ? `. Try '${fallback}' instead` : "";
|
|
492994
493785
|
return {
|
|
@@ -492996,14 +493787,14 @@ function handleValidationError(error54, modelName) {
|
|
|
492996
493787
|
error: `Model '${modelName}' not found${suggestion}`
|
|
492997
493788
|
};
|
|
492998
493789
|
}
|
|
492999
|
-
if (error54 instanceof
|
|
493000
|
-
if (error54 instanceof
|
|
493790
|
+
if (error54 instanceof import_sdk12.APIError) {
|
|
493791
|
+
if (error54 instanceof import_sdk12.AuthenticationError) {
|
|
493001
493792
|
return {
|
|
493002
493793
|
valid: false,
|
|
493003
493794
|
error: "Authentication failed. Please check your API credentials."
|
|
493004
493795
|
};
|
|
493005
493796
|
}
|
|
493006
|
-
if (error54 instanceof
|
|
493797
|
+
if (error54 instanceof import_sdk12.APIConnectionError) {
|
|
493007
493798
|
return {
|
|
493008
493799
|
valid: false,
|
|
493009
493800
|
error: "Network error. Please check your internet connection."
|
|
@@ -493037,14 +493828,14 @@ function get3PFallbackSuggestion(model) {
|
|
|
493037
493828
|
}
|
|
493038
493829
|
return;
|
|
493039
493830
|
}
|
|
493040
|
-
var
|
|
493831
|
+
var import_sdk12, validModelCache;
|
|
493041
493832
|
var init_validateModel = __esm(() => {
|
|
493042
493833
|
init_aliases();
|
|
493043
493834
|
init_modelAllowlist();
|
|
493044
493835
|
init_providers();
|
|
493045
493836
|
init_sideQuery();
|
|
493046
493837
|
init_modelStrings();
|
|
493047
|
-
|
|
493838
|
+
import_sdk12 = __toESM(require_sdk(), 1);
|
|
493048
493839
|
validModelCache = new Map;
|
|
493049
493840
|
});
|
|
493050
493841
|
|
|
@@ -500588,7 +501379,7 @@ var init_emptyUsage = __esm(() => {
|
|
|
500588
501379
|
|
|
500589
501380
|
// src/services/api/logging.ts
|
|
500590
501381
|
function getErrorMessage2(error54) {
|
|
500591
|
-
if (error54 instanceof
|
|
501382
|
+
if (error54 instanceof import_sdk13.APIError) {
|
|
500592
501383
|
const body = error54.error;
|
|
500593
501384
|
if (body?.error?.message)
|
|
500594
501385
|
return body.error.message;
|
|
@@ -500698,11 +501489,11 @@ function logAPIError({
|
|
|
500698
501489
|
previousRequestId
|
|
500699
501490
|
}) {
|
|
500700
501491
|
const gateway = detectGateway({
|
|
500701
|
-
headers: error54 instanceof
|
|
501492
|
+
headers: error54 instanceof import_sdk13.APIError && error54.headers ? error54.headers : headers,
|
|
500702
501493
|
baseUrl: process.env.ANTHROPIC_BASE_URL
|
|
500703
501494
|
});
|
|
500704
501495
|
const errStr = getErrorMessage2(error54);
|
|
500705
|
-
const status = error54 instanceof
|
|
501496
|
+
const status = error54 instanceof import_sdk13.APIError ? String(error54.status) : undefined;
|
|
500706
501497
|
const errorType = classifyAPIError(error54);
|
|
500707
501498
|
const connectionDetails = extractConnectionErrorDetails(error54);
|
|
500708
501499
|
if (connectionDetails) {
|
|
@@ -501005,7 +501796,7 @@ function logAPISuccessAndDuration({
|
|
|
501005
501796
|
markFirstTeleportMessageLogged();
|
|
501006
501797
|
}
|
|
501007
501798
|
}
|
|
501008
|
-
var
|
|
501799
|
+
var import_sdk13, GATEWAY_FINGERPRINTS, GATEWAY_HOST_SUFFIXES;
|
|
501009
501800
|
var init_logging = __esm(() => {
|
|
501010
501801
|
init_state();
|
|
501011
501802
|
init_debug();
|
|
@@ -501020,7 +501811,7 @@ var init_logging = __esm(() => {
|
|
|
501020
501811
|
init_emptyUsage();
|
|
501021
501812
|
init_errors7();
|
|
501022
501813
|
init_errorUtils();
|
|
501023
|
-
|
|
501814
|
+
import_sdk13 = __toESM(require_sdk(), 1);
|
|
501024
501815
|
GATEWAY_FINGERPRINTS = {
|
|
501025
501816
|
litellm: {
|
|
501026
501817
|
prefixes: ["x-litellm-"]
|
|
@@ -501153,6 +501944,7 @@ function createSubagentContext(parentContext, overrides) {
|
|
|
501153
501944
|
getAppState,
|
|
501154
501945
|
setAppState: overrides?.shareSetAppState ? parentContext.setAppState : () => {},
|
|
501155
501946
|
setAppStateForTasks: parentContext.setAppStateForTasks ?? parentContext.setAppState,
|
|
501947
|
+
recordFileChangeSetAppState: parentContext.recordFileChangeSetAppState,
|
|
501156
501948
|
localDenialTracking: overrides?.shareSetAppState ? parentContext.localDenialTracking : createDenialTrackingState(),
|
|
501157
501949
|
setInProgressToolUseIDs: () => {},
|
|
501158
501950
|
setResponseLength: overrides?.shareSetResponseLength ? parentContext.setResponseLength : () => {},
|
|
@@ -520031,7 +520823,7 @@ ${deferredToolList}
|
|
|
520031
520823
|
betasParams.push(cacheEditingBetaHeader);
|
|
520032
520824
|
logForDebugging("Cache editing beta header enabled for cached microcompact");
|
|
520033
520825
|
}
|
|
520034
|
-
const temperature = !hasThinking ? options.temperatureOverride ?? 1 : undefined;
|
|
520826
|
+
const temperature = !hasThinking || isOpenAICompatibleActive() ? options.temperatureOverride ?? 1 : undefined;
|
|
520035
520827
|
lastRequestBetas = betasParams;
|
|
520036
520828
|
return {
|
|
520037
520829
|
model: normalizeModelStringForAPI(options.model),
|
|
@@ -522224,7 +523016,7 @@ async function checkRuleBasedPermissions(tool, input, context) {
|
|
|
522224
523016
|
const parsedInput = tool.inputSchema.parse(input);
|
|
522225
523017
|
toolPermissionResult = await tool.checkPermissions(parsedInput, context);
|
|
522226
523018
|
} catch (e2) {
|
|
522227
|
-
if (e2 instanceof AbortError || e2 instanceof
|
|
523019
|
+
if (e2 instanceof AbortError || e2 instanceof import_sdk14.APIUserAbortError) {
|
|
522228
523020
|
throw e2;
|
|
522229
523021
|
}
|
|
522230
523022
|
logError2(e2);
|
|
@@ -522288,7 +523080,7 @@ async function hasPermissionsToUseToolInner(tool, input, context) {
|
|
|
522288
523080
|
const parsedInput = tool.inputSchema.parse(input);
|
|
522289
523081
|
toolPermissionResult = await tool.checkPermissions(parsedInput, context);
|
|
522290
523082
|
} catch (e2) {
|
|
522291
|
-
if (e2 instanceof AbortError || e2 instanceof
|
|
523083
|
+
if (e2 instanceof AbortError || e2 instanceof import_sdk14.APIUserAbortError) {
|
|
522292
523084
|
throw e2;
|
|
522293
523085
|
}
|
|
522294
523086
|
logError2(e2);
|
|
@@ -522435,7 +523227,7 @@ function syncPermissionRulesFromDisk(toolPermissionContext, rules) {
|
|
|
522435
523227
|
function getUpdatedInputOrFallback(permissionResult, fallback) {
|
|
522436
523228
|
return ("updatedInput" in permissionResult ? permissionResult.updatedInput : undefined) ?? fallback;
|
|
522437
523229
|
}
|
|
522438
|
-
var
|
|
523230
|
+
var import_sdk14, CLASSIFIER_FAIL_CLOSED_REFRESH_MS, PERMISSION_RULE_SOURCES, hasPermissionsToUseTool = async (tool, input, context, assistantMessage, toolUseID) => {
|
|
522439
523231
|
const result = await hasPermissionsToUseToolInner(tool, input, context);
|
|
522440
523232
|
if (result.behavior === "allow") {
|
|
522441
523233
|
const appState = context.getAppState();
|
|
@@ -522500,7 +523292,7 @@ var init_permissions3 = __esm(() => {
|
|
|
522500
523292
|
init_slowOperations();
|
|
522501
523293
|
init_denialTracking();
|
|
522502
523294
|
init_yoloClassifier();
|
|
522503
|
-
|
|
523295
|
+
import_sdk14 = __toESM(require_sdk(), 1);
|
|
522504
523296
|
CLASSIFIER_FAIL_CLOSED_REFRESH_MS = 30 * 60 * 1000;
|
|
522505
523297
|
PERMISSION_RULE_SOURCES = [
|
|
522506
523298
|
...SETTING_SOURCES,
|
|
@@ -528137,7 +528929,7 @@ function Feedback({
|
|
|
528137
528929
|
platform: env4.platform,
|
|
528138
528930
|
gitRepo: envInfo.isGit,
|
|
528139
528931
|
terminal: env4.terminal,
|
|
528140
|
-
version: "1.3.
|
|
528932
|
+
version: "1.3.327",
|
|
528141
528933
|
transcript: normalizeMessagesForAPI(messages),
|
|
528142
528934
|
errors: sanitizedErrors,
|
|
528143
528935
|
lastApiRequest: getLastAPIRequest(),
|
|
@@ -528329,7 +529121,7 @@ function Feedback({
|
|
|
528329
529121
|
", ",
|
|
528330
529122
|
env4.terminal,
|
|
528331
529123
|
", v",
|
|
528332
|
-
"1.3.
|
|
529124
|
+
"1.3.327"
|
|
528333
529125
|
]
|
|
528334
529126
|
}, undefined, true, undefined, this)
|
|
528335
529127
|
]
|
|
@@ -528435,7 +529227,7 @@ ${sanitizedDescription}
|
|
|
528435
529227
|
` + `**Environment Info**
|
|
528436
529228
|
` + `- Platform: ${env4.platform}
|
|
528437
529229
|
` + `- Terminal: ${env4.terminal}
|
|
528438
|
-
` + `- Version: ${"1.3.
|
|
529230
|
+
` + `- Version: ${"1.3.327"}
|
|
528439
529231
|
` + `- Feedback ID: ${feedbackId}
|
|
528440
529232
|
` + `
|
|
528441
529233
|
**Errors**
|
|
@@ -531274,9 +532066,9 @@ async function assertMinVersion() {
|
|
|
531274
532066
|
if (false) {}
|
|
531275
532067
|
try {
|
|
531276
532068
|
const versionConfig = await getDynamicConfig_BLOCKS_ON_INIT("tengu_version_config", { minVersion: "0.0.0" });
|
|
531277
|
-
if (versionConfig.minVersion && lt("1.3.
|
|
532069
|
+
if (versionConfig.minVersion && lt("1.3.327", versionConfig.minVersion)) {
|
|
531278
532070
|
console.error(`
|
|
531279
|
-
It looks like your version of RAYU (${"1.3.
|
|
532071
|
+
It looks like your version of RAYU (${"1.3.327"}) needs an update.
|
|
531280
532072
|
A newer version (${versionConfig.minVersion} or higher) is required to continue.
|
|
531281
532073
|
|
|
531282
532074
|
To update, please run:
|
|
@@ -531502,7 +532294,7 @@ async function installGlobalPackage(specificVersion) {
|
|
|
531502
532294
|
logError2(new AutoUpdaterError("Another process is currently installing an update"));
|
|
531503
532295
|
logEvent("tengu_auto_updater_lock_contention", {
|
|
531504
532296
|
pid: process.pid,
|
|
531505
|
-
currentVersion: "1.3.
|
|
532297
|
+
currentVersion: "1.3.327"
|
|
531506
532298
|
});
|
|
531507
532299
|
return "in_progress";
|
|
531508
532300
|
}
|
|
@@ -531511,7 +532303,7 @@ async function installGlobalPackage(specificVersion) {
|
|
|
531511
532303
|
if (!env4.isRunningWithBun() && env4.isNpmFromWindowsPath()) {
|
|
531512
532304
|
logError2(new Error("Windows NPM detected in WSL environment"));
|
|
531513
532305
|
logEvent("tengu_auto_updater_windows_npm_in_wsl", {
|
|
531514
|
-
currentVersion: "1.3.
|
|
532306
|
+
currentVersion: "1.3.327"
|
|
531515
532307
|
});
|
|
531516
532308
|
console.error(`
|
|
531517
532309
|
Error: Windows NPM detected in WSL
|
|
@@ -532047,7 +532839,7 @@ function detectLinuxGlobPatternWarnings() {
|
|
|
532047
532839
|
}
|
|
532048
532840
|
async function getDoctorDiagnostic() {
|
|
532049
532841
|
const installationType = await getCurrentInstallationType();
|
|
532050
|
-
const version2 = typeof MACRO !== "undefined" ? "1.3.
|
|
532842
|
+
const version2 = typeof MACRO !== "undefined" ? "1.3.327" : "unknown";
|
|
532051
532843
|
const installationPath = await getInstallationPath();
|
|
532052
532844
|
const invokedBinary = getInvokedBinary();
|
|
532053
532845
|
const multipleInstallations = await detectMultipleInstallations();
|
|
@@ -532842,8 +533634,8 @@ async function updateLatest(channelOrVersion, forceReinstall = false) {
|
|
|
532842
533634
|
const maxVersion = await getMaxVersion();
|
|
532843
533635
|
if (maxVersion && gt(version2, maxVersion)) {
|
|
532844
533636
|
logForDebugging(`Native installer: maxVersion ${maxVersion} is set, capping update from ${version2} to ${maxVersion}`);
|
|
532845
|
-
if (gte("1.3.
|
|
532846
|
-
logForDebugging(`Native installer: current version ${"1.3.
|
|
533637
|
+
if (gte("1.3.327", maxVersion)) {
|
|
533638
|
+
logForDebugging(`Native installer: current version ${"1.3.327"} is already at or above maxVersion ${maxVersion}, skipping update`);
|
|
532847
533639
|
logEvent("tengu_native_update_skipped_max_version", {
|
|
532848
533640
|
latency_ms: Date.now() - startTime,
|
|
532849
533641
|
max_version: maxVersion,
|
|
@@ -532854,7 +533646,7 @@ async function updateLatest(channelOrVersion, forceReinstall = false) {
|
|
|
532854
533646
|
version2 = maxVersion;
|
|
532855
533647
|
}
|
|
532856
533648
|
}
|
|
532857
|
-
if (!forceReinstall && version2 === "1.3.
|
|
533649
|
+
if (!forceReinstall && version2 === "1.3.327" && await versionIsAvailable(version2) && await isPossibleClaudeBinary(executablePath)) {
|
|
532858
533650
|
logForDebugging(`Found ${version2} at ${executablePath}, skipping install`);
|
|
532859
533651
|
logEvent("tengu_native_update_complete", {
|
|
532860
533652
|
latency_ms: Date.now() - startTime,
|
|
@@ -534050,7 +534842,7 @@ function buildPrimarySection() {
|
|
|
534050
534842
|
}, undefined, false, undefined, this);
|
|
534051
534843
|
return [{
|
|
534052
534844
|
label: "Version",
|
|
534053
|
-
value: "1.3.
|
|
534845
|
+
value: "1.3.327"
|
|
534054
534846
|
}, {
|
|
534055
534847
|
label: "Session name",
|
|
534056
534848
|
value: nameValue
|
|
@@ -537741,7 +538533,7 @@ function Config({
|
|
|
537741
538533
|
}
|
|
537742
538534
|
}, undefined, false, undefined, this)
|
|
537743
538535
|
}, undefined, false, undefined, this) : showSubmenu === "ChannelDowngrade" ? /* @__PURE__ */ jsx_dev_runtime170.jsxDEV(ChannelDowngradeDialog, {
|
|
537744
|
-
currentVersion: "1.3.
|
|
538536
|
+
currentVersion: "1.3.327",
|
|
537745
538537
|
onChoice: (choice) => {
|
|
537746
538538
|
setShowSubmenu(null);
|
|
537747
538539
|
setTabsHidden(false);
|
|
@@ -537753,7 +538545,7 @@ function Config({
|
|
|
537753
538545
|
autoUpdatesChannel: "stable"
|
|
537754
538546
|
};
|
|
537755
538547
|
if (choice === "stay") {
|
|
537756
|
-
newSettings.minimumVersion = "1.3.
|
|
538548
|
+
newSettings.minimumVersion = "1.3.327";
|
|
537757
538549
|
}
|
|
537758
538550
|
updateSettingsForSource("userSettings", newSettings);
|
|
537759
538551
|
setSettingsData((prev_27) => ({
|
|
@@ -545815,7 +546607,7 @@ function HelpV2(t0) {
|
|
|
545815
546607
|
let t6;
|
|
545816
546608
|
if ($3[31] !== tabs) {
|
|
545817
546609
|
t6 = /* @__PURE__ */ jsx_dev_runtime197.jsxDEV(Tabs, {
|
|
545818
|
-
title: `Rayu-CLI v${"1.3.
|
|
546610
|
+
title: `Rayu-CLI v${"1.3.327"}`,
|
|
545819
546611
|
color: "professionalBlue",
|
|
545820
546612
|
defaultTab: "general",
|
|
545821
546613
|
children: tabs
|
|
@@ -547218,8 +548010,12 @@ Keep going until the task is fully resolved; state assumptions and continue —
|
|
|
547218
548010
|
## DEFAULT TO PARALLEL (the single most important rule)
|
|
547219
548011
|
Parallel execution is ~3–5x faster than sequential. Unless one call genuinely needs another's output, dispatch independent agents/tools TOGETHER in ONE assistant message (multiple Agent calls), not one-per-message. Plan all the calls you'll need upfront, then fire them together. Cap each batch at ~3–5 calls to avoid timeouts. Sequential is the exception, allowed ONLY on a true dependency. One-per-message dispatch is the #1 cause of slow swarm runs — avoid it.
|
|
547220
548012
|
|
|
548013
|
+
## Foreground subagents · background collaborators (important)
|
|
548014
|
+
- Run ALL **Subagents in the FOREGROUND** — do NOT set \`run_in_background\` on a subagent. Their work and \`thinking…\` then stream INLINE so the user can watch them. This applies whether YOU (the orchestrator) dispatch the subagent OR a collaborator does (a collaborator's subagents appear inside that collaborator's view).
|
|
548015
|
+
- Spawn **Collaborators in the BACKGROUND** (\`run_in_background:true\`, stable lowercase name). Background is the ONLY mode that is resumable via \`SendMessage\`, so semi-persistent collaborators MUST be background. The user watches a collaborator's detailed work by entering its view (↓ then Enter); the task panel shows each collaborator's high-level status (including \`thinking…\`).
|
|
548016
|
+
|
|
547221
548017
|
## How to run the swarm
|
|
547222
|
-
1. **Plan & research
|
|
548018
|
+
1. **Plan & research FIRST — visibly, in the foreground.** Before delegating anything, dispatch \`PA\` and/or several \`Explore\`/\`general-purpose\` subagents in the FOREGROUND (in a SINGLE message, multiple Agent calls, 3–5 max; do NOT set run_in_background) so the user watches the planning/research happen. State your analysis. For UI work, produce a \`design\` PRD. For a new project, run \`global-setup\` to scaffold. Then write the shared brief to \`.rayu/swarm/shared.json\` (goal/stack/flow/constraints/needs) — it is injected into every collaborator, so keep it tight (< ~500 tokens). Set "needs" to ONLY the domains this task requires.
|
|
547223
548019
|
- **Overlap where safe:** kick off work that doesn't depend on the final plan (e.g. \`global-setup\` scaffold, \`asset-generation\`) IN PARALLEL with planning rather than strictly after it.
|
|
547224
548020
|
2. **Delegate in PARALLEL WAVES.** Decide which collaborators each wave needs, then dispatch all collaborators with no unmet dependency TOGETHER — in ONE assistant message containing MULTIPLE Agent tool calls. NEVER send them one-per-message. Typical waves:
|
|
547225
548021
|
- Wave 1: \`backend\` (API + data layer) + \`security\` (auth/RBAC design) — together.
|
|
@@ -565786,7 +566582,7 @@ function getRecentReleaseNotes(currentVersion, previousVersion, changelogContent
|
|
|
565786
566582
|
}
|
|
565787
566583
|
return [];
|
|
565788
566584
|
}
|
|
565789
|
-
async function checkForReleaseNotes(lastSeenVersion, currentVersion = "1.3.
|
|
566585
|
+
async function checkForReleaseNotes(lastSeenVersion, currentVersion = "1.3.327") {
|
|
565790
566586
|
if (false) {}
|
|
565791
566587
|
const cachedChangelog = await getStoredChangelog();
|
|
565792
566588
|
if (lastSeenVersion !== currentVersion || !cachedChangelog) {
|
|
@@ -565799,7 +566595,7 @@ async function checkForReleaseNotes(lastSeenVersion, currentVersion = "1.3.227")
|
|
|
565799
566595
|
releaseNotes
|
|
565800
566596
|
};
|
|
565801
566597
|
}
|
|
565802
|
-
function checkForReleaseNotesSync(lastSeenVersion, currentVersion = "1.3.
|
|
566598
|
+
function checkForReleaseNotesSync(lastSeenVersion, currentVersion = "1.3.327") {
|
|
565803
566599
|
if (false) {}
|
|
565804
566600
|
const releaseNotes = getRecentReleaseNotes(currentVersion, lastSeenVersion);
|
|
565805
566601
|
return {
|
|
@@ -565927,7 +566723,7 @@ function getRecentActivitySync() {
|
|
|
565927
566723
|
return cachedActivity;
|
|
565928
566724
|
}
|
|
565929
566725
|
function getLogoDisplayData() {
|
|
565930
|
-
const version2 = process.env.DEMO_VERSION ?? "1.3.
|
|
566726
|
+
const version2 = process.env.DEMO_VERSION ?? "1.3.327";
|
|
565931
566727
|
const serverUrl = getDirectConnectServerUrl();
|
|
565932
566728
|
const displayPath = process.env.DEMO_VERSION ? "/code/claude" : getDisplayPath(getCwd());
|
|
565933
566729
|
const cwd2 = serverUrl ? `${displayPath} in ${serverUrl.replace(/^https?:\/\//, "")}` : displayPath;
|
|
@@ -567219,7 +568015,7 @@ function LogoV2() {
|
|
|
567219
568015
|
if ($3[2] === Symbol.for("react.memo_cache_sentinel")) {
|
|
567220
568016
|
t2 = () => {
|
|
567221
568017
|
const currentConfig = getGlobalConfig();
|
|
567222
|
-
if (currentConfig.lastReleaseNotesSeen === "1.3.
|
|
568018
|
+
if (currentConfig.lastReleaseNotesSeen === "1.3.327") {
|
|
567223
568019
|
return;
|
|
567224
568020
|
}
|
|
567225
568021
|
saveGlobalConfig(_temp327);
|
|
@@ -567697,7 +568493,7 @@ function LogoV2() {
|
|
|
567697
568493
|
t24 = $3[61];
|
|
567698
568494
|
}
|
|
567699
568495
|
const _latestNpm = getCachedLatestNpmVersionSync();
|
|
567700
|
-
const _updateFeeds = _latestNpm && gt(_latestNpm, "1.3.
|
|
568496
|
+
const _updateFeeds = _latestNpm && gt(_latestNpm, "1.3.327") ? [createUpdateAvailableFeed("1.3.327", _latestNpm)] : [];
|
|
567701
568497
|
const t25 = layoutMode === "horizontal" && /* @__PURE__ */ jsx_dev_runtime239.jsxDEV(FeedColumn, {
|
|
567702
568498
|
feeds: showOnboarding ? [createProjectOnboardingFeed(getSteps()), createRecentActivityFeed(activities)] : showGuestPassesUpsell ? [createRecentActivityFeed(activities), createGuestPassesFeed()] : showOverageCreditUpsell ? [createRecentActivityFeed(activities), createOverageCreditFeed()] : [createRecentActivityFeed(activities), ..._updateFeeds, createWhatsNewFeed(changelog)],
|
|
567703
568499
|
maxWidth: rightWidth
|
|
@@ -567897,12 +568693,12 @@ function LogoV2() {
|
|
|
567897
568693
|
return t41;
|
|
567898
568694
|
}
|
|
567899
568695
|
function _temp327(current) {
|
|
567900
|
-
if (current.lastReleaseNotesSeen === "1.3.
|
|
568696
|
+
if (current.lastReleaseNotesSeen === "1.3.327") {
|
|
567901
568697
|
return current;
|
|
567902
568698
|
}
|
|
567903
568699
|
return {
|
|
567904
568700
|
...current,
|
|
567905
|
-
lastReleaseNotesSeen: "1.3.
|
|
568701
|
+
lastReleaseNotesSeen: "1.3.327"
|
|
567906
568702
|
};
|
|
567907
568703
|
}
|
|
567908
568704
|
function _temp241(s_0) {
|
|
@@ -590343,7 +591139,7 @@ function GenerateStep() {
|
|
|
590343
591139
|
});
|
|
590344
591140
|
goToStep(6);
|
|
590345
591141
|
} catch (err2) {
|
|
590346
|
-
if (err2 instanceof
|
|
591142
|
+
if (err2 instanceof import_sdk15.APIUserAbortError) {} else if (err2 instanceof Error && !err2.message.includes("No assistant message found")) {
|
|
590347
591143
|
setError(err2.message || "Failed to generate agent");
|
|
590348
591144
|
}
|
|
590349
591145
|
updateWizardData({
|
|
@@ -590426,7 +591222,7 @@ function GenerateStep() {
|
|
|
590426
591222
|
}, undefined, true, undefined, this)
|
|
590427
591223
|
}, undefined, false, undefined, this);
|
|
590428
591224
|
}
|
|
590429
|
-
var
|
|
591225
|
+
var import_sdk15, import_react173, jsx_dev_runtime302;
|
|
590430
591226
|
var init_GenerateStep = __esm(() => {
|
|
590431
591227
|
init_useMainLoopModel();
|
|
590432
591228
|
init_ink2();
|
|
@@ -590440,7 +591236,7 @@ var init_GenerateStep = __esm(() => {
|
|
|
590440
591236
|
init_wizard();
|
|
590441
591237
|
init_WizardDialogLayout();
|
|
590442
591238
|
init_generateAgent();
|
|
590443
|
-
|
|
591239
|
+
import_sdk15 = __toESM(require_sdk(), 1);
|
|
590444
591240
|
import_react173 = __toESM(require_react(), 1);
|
|
590445
591241
|
jsx_dev_runtime302 = __toESM(require_jsx_dev_runtime(), 1);
|
|
590446
591242
|
});
|
|
@@ -592693,7 +593489,7 @@ async function captureMemoryDiagnostics(trigger, dumpNumber = 0) {
|
|
|
592693
593489
|
smapsRollup,
|
|
592694
593490
|
platform: process.platform,
|
|
592695
593491
|
nodeVersion: process.version,
|
|
592696
|
-
ccVersion: "1.3.
|
|
593492
|
+
ccVersion: "1.3.327"
|
|
592697
593493
|
};
|
|
592698
593494
|
}
|
|
592699
593495
|
async function performHeapDump(trigger = "manual", dumpNumber = 0) {
|
|
@@ -593215,7 +594011,7 @@ var init_bridge_kick = __esm(() => {
|
|
|
593215
594011
|
var call47 = async () => {
|
|
593216
594012
|
return {
|
|
593217
594013
|
type: "text",
|
|
593218
|
-
value: "1.3.
|
|
594014
|
+
value: "1.3.327"
|
|
593219
594015
|
};
|
|
593220
594016
|
}, version2, version_default;
|
|
593221
594017
|
var init_version = __esm(() => {
|
|
@@ -595645,14 +596441,15 @@ function RayuProviderSetup({
|
|
|
595645
596441
|
}
|
|
595646
596442
|
function finishBedrock(chosenModel, models) {
|
|
595647
596443
|
const trimmed = chosenModel.trim();
|
|
595648
|
-
const
|
|
596444
|
+
const api2 = preset?.bedrockApi ?? "converse";
|
|
596445
|
+
const usesAwsSdk = api2 === "anthropic" || api2 === "converse";
|
|
595649
596446
|
const provider = {
|
|
595650
596447
|
id: preset?.id ?? "bedrock",
|
|
595651
596448
|
kind: "bedrock",
|
|
595652
|
-
bedrockApi:
|
|
596449
|
+
bedrockApi: api2,
|
|
595653
596450
|
apiKey: apiKey.trim() || undefined,
|
|
595654
596451
|
awsRegion: region,
|
|
595655
|
-
...
|
|
596452
|
+
...usesAwsSdk ? {} : { baseURL: bedrockBaseURL(region) },
|
|
595656
596453
|
...trimmed ? { defaultModel: trimmed } : {},
|
|
595657
596454
|
...models.length ? { fetchedModels: models } : {}
|
|
595658
596455
|
};
|
|
@@ -595660,6 +596457,21 @@ function RayuProviderSetup({
|
|
|
595660
596457
|
onDone();
|
|
595661
596458
|
}
|
|
595662
596459
|
function pickBedrockDefault(models) {
|
|
596460
|
+
if (preset?.bedrockApi === "converse") {
|
|
596461
|
+
const prefs = [
|
|
596462
|
+
/kimi-k2-thinking/i,
|
|
596463
|
+
/claude-sonnet-4-6/i,
|
|
596464
|
+
/claude-sonnet/i,
|
|
596465
|
+
/deepseek/i,
|
|
596466
|
+
/kimi/i
|
|
596467
|
+
];
|
|
596468
|
+
for (const re of prefs) {
|
|
596469
|
+
const hit = models.find((m3) => re.test(m3));
|
|
596470
|
+
if (hit)
|
|
596471
|
+
return hit;
|
|
596472
|
+
}
|
|
596473
|
+
return models[0] ?? "";
|
|
596474
|
+
}
|
|
595663
596475
|
if (preset?.bedrockApi === "anthropic") {
|
|
595664
596476
|
const prefs = [
|
|
595665
596477
|
/claude-sonnet-4-6/i,
|
|
@@ -595800,13 +596612,14 @@ function RayuProviderSetup({
|
|
|
595800
596612
|
return;
|
|
595801
596613
|
let cancelled = false;
|
|
595802
596614
|
(async () => {
|
|
596615
|
+
const baseApi = preset?.bedrockApi ?? "converse";
|
|
595803
596616
|
const models = await fetchProviderModels({
|
|
595804
596617
|
id: preset?.id ?? "bedrock",
|
|
595805
596618
|
kind: "bedrock",
|
|
595806
|
-
bedrockApi:
|
|
596619
|
+
bedrockApi: baseApi,
|
|
595807
596620
|
apiKey: apiKey.trim(),
|
|
595808
596621
|
awsRegion: region,
|
|
595809
|
-
baseURL: bedrockBaseURL(region)
|
|
596622
|
+
...baseApi === "openai" ? { baseURL: bedrockBaseURL(region) } : {}
|
|
595810
596623
|
}).catch(() => []);
|
|
595811
596624
|
if (cancelled)
|
|
595812
596625
|
return;
|
|
@@ -602095,7 +602908,7 @@ function generateHtmlReport(data, insights) {
|
|
|
602095
602908
|
</html>`;
|
|
602096
602909
|
}
|
|
602097
602910
|
function buildExportData(data, insights, facets, remoteStats) {
|
|
602098
|
-
const version3 = typeof MACRO !== "undefined" ? "1.3.
|
|
602911
|
+
const version3 = typeof MACRO !== "undefined" ? "1.3.327" : "unknown";
|
|
602099
602912
|
const remote_hosts_collected = remoteStats?.hosts.filter((h3) => h3.sessionCount > 0).map((h3) => h3.name);
|
|
602100
602913
|
const facets_summary = {
|
|
602101
602914
|
total: facets.size,
|
|
@@ -605995,7 +606808,7 @@ var init_sessionStorage = __esm(() => {
|
|
|
605995
606808
|
init_settings2();
|
|
605996
606809
|
init_slowOperations();
|
|
605997
606810
|
init_uuid();
|
|
605998
|
-
VERSION6 = typeof MACRO !== "undefined" ? "1.3.
|
|
606811
|
+
VERSION6 = typeof MACRO !== "undefined" ? "1.3.327" : "unknown";
|
|
605999
606812
|
MAX_TOMBSTONE_REWRITE_BYTES = 50 * 1024 * 1024;
|
|
606000
606813
|
SKIP_FIRST_PROMPT_PATTERN = /^(?:\s*<[a-z][\w-]*[\s>]|\[Request interrupted by user[^\]]*\])/;
|
|
606001
606814
|
EPHEMERAL_PROGRESS_TYPES = new Set([
|
|
@@ -607216,7 +608029,7 @@ var init_filesystem = __esm(() => {
|
|
|
607216
608029
|
});
|
|
607217
608030
|
getBundledSkillsRoot = memoize_default(function getBundledSkillsRoot2() {
|
|
607218
608031
|
const nonce = randomBytes18(16).toString("hex");
|
|
607219
|
-
return join150(getClaudeTempDir(), "bundled-skills", "1.3.
|
|
608032
|
+
return join150(getClaudeTempDir(), "bundled-skills", "1.3.327", nonce);
|
|
607220
608033
|
});
|
|
607221
608034
|
getResolvedWorkingDirPaths = memoize_default(getPathsForPermissionCheck);
|
|
607222
608035
|
});
|
|
@@ -612331,7 +613144,7 @@ __export(exports_update, {
|
|
|
612331
613144
|
import { execFileSync as execFileSync3 } from "node:child_process";
|
|
612332
613145
|
import { homedir as homedir33 } from "os";
|
|
612333
613146
|
async function update() {
|
|
612334
|
-
writeToStdout(`Current version: ${"1.3.
|
|
613147
|
+
writeToStdout(`Current version: ${"1.3.327"}
|
|
612335
613148
|
`);
|
|
612336
613149
|
const isBundled = isInBundledMode();
|
|
612337
613150
|
if (isBundled) {
|
|
@@ -612357,13 +613170,13 @@ Manual check: npm view ${"@rayu-dev/rayu-cli"} version
|
|
|
612357
613170
|
process.exit(1);
|
|
612358
613171
|
return;
|
|
612359
613172
|
}
|
|
612360
|
-
if (latestVersion === "1.3.
|
|
613173
|
+
if (latestVersion === "1.3.327") {
|
|
612361
613174
|
writeToStdout(source_default.green(`
|
|
612362
|
-
Rayu CLI is up to date (${"1.3.
|
|
613175
|
+
Rayu CLI is up to date (${"1.3.327"})
|
|
612363
613176
|
`));
|
|
612364
613177
|
process.exit(0);
|
|
612365
613178
|
}
|
|
612366
|
-
writeToStdout(`New version available: ${latestVersion} (current: ${"1.3.
|
|
613179
|
+
writeToStdout(`New version available: ${latestVersion} (current: ${"1.3.327"})
|
|
612367
613180
|
`);
|
|
612368
613181
|
writeToStdout(`Installing update...
|
|
612369
613182
|
|
|
@@ -612387,7 +613200,7 @@ Try manually:
|
|
|
612387
613200
|
return;
|
|
612388
613201
|
}
|
|
612389
613202
|
writeToStdout(source_default.green(`
|
|
612390
|
-
Successfully updated from ${"1.3.
|
|
613203
|
+
Successfully updated from ${"1.3.327"} to ${latestVersion}
|
|
612391
613204
|
`));
|
|
612392
613205
|
process.exit(0);
|
|
612393
613206
|
}
|
|
@@ -612401,14 +613214,14 @@ async function updateNativeBinary() {
|
|
|
612401
613214
|
} catch {
|
|
612402
613215
|
latestVersion = "";
|
|
612403
613216
|
}
|
|
612404
|
-
if (latestVersion && latestVersion === "1.3.
|
|
613217
|
+
if (latestVersion && latestVersion === "1.3.327") {
|
|
612405
613218
|
writeToStdout(source_default.green(`
|
|
612406
|
-
Rayu CLI is up to date (1.3.
|
|
613219
|
+
Rayu CLI is up to date (1.3.327)
|
|
612407
613220
|
`));
|
|
612408
613221
|
process.exit(0);
|
|
612409
613222
|
}
|
|
612410
613223
|
if (latestVersion) {
|
|
612411
|
-
writeToStdout(`New version available: ${latestVersion} (current: 1.3.
|
|
613224
|
+
writeToStdout(`New version available: ${latestVersion} (current: 1.3.327)
|
|
612412
613225
|
`);
|
|
612413
613226
|
}
|
|
612414
613227
|
writeToStdout(`Downloading and installing update...
|
|
@@ -612423,13 +613236,13 @@ Rayu CLI is up to date (1.3.227)
|
|
|
612423
613236
|
return;
|
|
612424
613237
|
}
|
|
612425
613238
|
writeToStdout(source_default.green(`
|
|
612426
|
-
Rayu CLI is up to date (1.3.
|
|
613239
|
+
Rayu CLI is up to date (1.3.327)
|
|
612427
613240
|
`));
|
|
612428
613241
|
process.exit(0);
|
|
612429
613242
|
}
|
|
612430
613243
|
const updatedTo = result.latestVersion ?? latestVersion ?? "latest";
|
|
612431
613244
|
writeToStdout(source_default.green(`
|
|
612432
|
-
Successfully updated from 1.3.
|
|
613245
|
+
Successfully updated from 1.3.327 to ${updatedTo}
|
|
612433
613246
|
`));
|
|
612434
613247
|
writeToStdout(`Restart your terminal to use the new version.
|
|
612435
613248
|
`);
|
|
@@ -612460,7 +613273,7 @@ __export(exports_uninstall, {
|
|
|
612460
613273
|
import { execFileSync as execFileSync4 } from "node:child_process";
|
|
612461
613274
|
import { homedir as homedir34 } from "os";
|
|
612462
613275
|
async function uninstall() {
|
|
612463
|
-
writeToStdout(`Uninstalling Rayu CLI (${"1.3.
|
|
613276
|
+
writeToStdout(`Uninstalling Rayu CLI (${"1.3.327"})...
|
|
612464
613277
|
`);
|
|
612465
613278
|
writeToStdout(`Running: npm uninstall -g ${"@rayu-dev/rayu-cli"}
|
|
612466
613279
|
|
|
@@ -612483,7 +613296,7 @@ Try running manually:
|
|
|
612483
613296
|
process.exit(1);
|
|
612484
613297
|
}
|
|
612485
613298
|
writeToStdout(source_default.green(`
|
|
612486
|
-
Successfully uninstalled ${"@rayu-dev/rayu-cli"} ${"1.3.
|
|
613299
|
+
Successfully uninstalled ${"@rayu-dev/rayu-cli"} ${"1.3.327"}
|
|
612487
613300
|
`));
|
|
612488
613301
|
writeToStdout(`Thanks for using Rayu CLI!
|
|
612489
613302
|
`);
|
|
@@ -612535,7 +613348,7 @@ function showFirstRunWelcome() {
|
|
|
612535
613348
|
`);
|
|
612536
613349
|
try {
|
|
612537
613350
|
mkdirSync13(getRayuConfigHomeDir(), { recursive: true });
|
|
612538
|
-
writeFileSync15(markerPath(), "1.3.
|
|
613351
|
+
writeFileSync15(markerPath(), "1.3.327", "utf8");
|
|
612539
613352
|
} catch {}
|
|
612540
613353
|
}
|
|
612541
613354
|
var init_firstRun = __esm(() => {
|
|
@@ -624378,7 +625191,7 @@ async function initializeBetaTracing(resource) {
|
|
|
624378
625191
|
});
|
|
624379
625192
|
import_api_logs.logs.setGlobalLoggerProvider(loggerProvider);
|
|
624380
625193
|
setLoggerProvider(loggerProvider);
|
|
624381
|
-
const eventLogger = import_api_logs.logs.getLogger("com.anthropic.claude_code.events", "1.3.
|
|
625194
|
+
const eventLogger = import_api_logs.logs.getLogger("com.anthropic.claude_code.events", "1.3.327");
|
|
624382
625195
|
setEventLogger(eventLogger);
|
|
624383
625196
|
process.on("beforeExit", async () => {
|
|
624384
625197
|
await loggerProvider?.forceFlush();
|
|
@@ -624418,7 +625231,7 @@ async function initializeTelemetry() {
|
|
|
624418
625231
|
const platform4 = getPlatform();
|
|
624419
625232
|
const baseAttributes = {
|
|
624420
625233
|
[import_semantic_conventions2.ATTR_SERVICE_NAME]: "claude-code",
|
|
624421
|
-
[import_semantic_conventions2.ATTR_SERVICE_VERSION]: "1.3.
|
|
625234
|
+
[import_semantic_conventions2.ATTR_SERVICE_VERSION]: "1.3.327"
|
|
624422
625235
|
};
|
|
624423
625236
|
if (platform4 === "wsl") {
|
|
624424
625237
|
const wslVersion = getWslVersion();
|
|
@@ -624463,7 +625276,7 @@ async function initializeTelemetry() {
|
|
|
624463
625276
|
} catch {}
|
|
624464
625277
|
};
|
|
624465
625278
|
registerCleanup(shutdownTelemetry2);
|
|
624466
|
-
return meterProvider2.getMeter("com.anthropic.claude_code", "1.3.
|
|
625279
|
+
return meterProvider2.getMeter("com.anthropic.claude_code", "1.3.327");
|
|
624467
625280
|
}
|
|
624468
625281
|
const meterProvider = new import_sdk_metrics2.MeterProvider({
|
|
624469
625282
|
resource,
|
|
@@ -624483,7 +625296,7 @@ async function initializeTelemetry() {
|
|
|
624483
625296
|
});
|
|
624484
625297
|
import_api_logs.logs.setGlobalLoggerProvider(loggerProvider);
|
|
624485
625298
|
setLoggerProvider(loggerProvider);
|
|
624486
|
-
const eventLogger = import_api_logs.logs.getLogger("com.anthropic.claude_code.events", "1.3.
|
|
625299
|
+
const eventLogger = import_api_logs.logs.getLogger("com.anthropic.claude_code.events", "1.3.327");
|
|
624487
625300
|
setEventLogger(eventLogger);
|
|
624488
625301
|
logForDebugging("[3P telemetry] Event logger set successfully");
|
|
624489
625302
|
process.on("beforeExit", async () => {
|
|
@@ -624545,7 +625358,7 @@ Current timeout: ${timeoutMs}ms
|
|
|
624545
625358
|
}
|
|
624546
625359
|
};
|
|
624547
625360
|
registerCleanup(shutdownTelemetry);
|
|
624548
|
-
return meterProvider.getMeter("com.anthropic.claude_code", "1.3.
|
|
625361
|
+
return meterProvider.getMeter("com.anthropic.claude_code", "1.3.327");
|
|
624549
625362
|
}
|
|
624550
625363
|
async function flushTelemetry() {
|
|
624551
625364
|
const meterProvider = getMeterProvider();
|
|
@@ -626058,7 +626871,7 @@ function buildSystemInitMessage(inputs) {
|
|
|
626058
626871
|
slash_commands: inputs.commands.filter((c4) => c4.userInvocable !== false).map((c4) => c4.name),
|
|
626059
626872
|
apiKeySource: getAnthropicApiKeyWithSource().source,
|
|
626060
626873
|
betas: getSdkBetas(),
|
|
626061
|
-
claude_code_version: "1.3.
|
|
626874
|
+
claude_code_version: "1.3.327",
|
|
626062
626875
|
output_style: outputStyle2,
|
|
626063
626876
|
agents: inputs.agents.map((agent) => agent.agentType),
|
|
626064
626877
|
skills: inputs.skills.filter((s2) => s2.userInvocable !== false).map((skill) => skill.name),
|
|
@@ -642267,7 +643080,7 @@ var init_useVoiceEnabled = __esm(() => {
|
|
|
642267
643080
|
function getSemverPart(version3) {
|
|
642268
643081
|
return `${import_semver12.major(version3, { loose: true })}.${import_semver12.minor(version3, { loose: true })}.${import_semver12.patch(version3, { loose: true })}`;
|
|
642269
643082
|
}
|
|
642270
|
-
function useUpdateNotification(updatedVersion, initialVersion = "1.3.
|
|
643083
|
+
function useUpdateNotification(updatedVersion, initialVersion = "1.3.327") {
|
|
642271
643084
|
const [lastNotifiedSemver, setLastNotifiedSemver] = import_react218.useState(() => getSemverPart(initialVersion));
|
|
642272
643085
|
if (!updatedVersion) {
|
|
642273
643086
|
return null;
|
|
@@ -642307,7 +643120,7 @@ function AutoUpdater({
|
|
|
642307
643120
|
return;
|
|
642308
643121
|
}
|
|
642309
643122
|
if (false) {}
|
|
642310
|
-
const currentVersion = "1.3.
|
|
643123
|
+
const currentVersion = "1.3.327";
|
|
642311
643124
|
const channel = getInitialSettings()?.autoUpdatesChannel ?? "latest";
|
|
642312
643125
|
let latestVersion = await getLatestVersion(channel);
|
|
642313
643126
|
const isDisabled = isAutoUpdaterDisabled();
|
|
@@ -642520,12 +643333,12 @@ function NativeAutoUpdater({
|
|
|
642520
643333
|
logEvent("tengu_native_auto_updater_start", {});
|
|
642521
643334
|
try {
|
|
642522
643335
|
const maxVersion = await getMaxVersion();
|
|
642523
|
-
if (maxVersion && gt("1.3.
|
|
643336
|
+
if (maxVersion && gt("1.3.327", maxVersion)) {
|
|
642524
643337
|
const msg = await getMaxVersionMessage();
|
|
642525
643338
|
setMaxVersionIssue(msg ?? "affects your version");
|
|
642526
643339
|
}
|
|
642527
643340
|
const result = await installLatest(channel);
|
|
642528
|
-
const currentVersion = "1.3.
|
|
643341
|
+
const currentVersion = "1.3.327";
|
|
642529
643342
|
const latencyMs = Date.now() - startTime;
|
|
642530
643343
|
if (result.lockFailed) {
|
|
642531
643344
|
logEvent("tengu_native_auto_updater_lock_contention", {
|
|
@@ -642662,17 +643475,17 @@ function PackageManagerAutoUpdater(t0) {
|
|
|
642662
643475
|
const maxVersion = await getMaxVersion();
|
|
642663
643476
|
if (maxVersion && latest && gt(latest, maxVersion)) {
|
|
642664
643477
|
logForDebugging(`PackageManagerAutoUpdater: maxVersion ${maxVersion} is set, capping update from ${latest} to ${maxVersion}`);
|
|
642665
|
-
if (gte("1.3.
|
|
642666
|
-
logForDebugging(`PackageManagerAutoUpdater: current version ${"1.3.
|
|
643478
|
+
if (gte("1.3.327", maxVersion)) {
|
|
643479
|
+
logForDebugging(`PackageManagerAutoUpdater: current version ${"1.3.327"} is already at or above maxVersion ${maxVersion}, skipping update`);
|
|
642667
643480
|
setUpdateAvailable(false);
|
|
642668
643481
|
return;
|
|
642669
643482
|
}
|
|
642670
643483
|
latest = maxVersion;
|
|
642671
643484
|
}
|
|
642672
|
-
const hasUpdate = latest && !gte("1.3.
|
|
643485
|
+
const hasUpdate = latest && !gte("1.3.327", latest) && !shouldSkipVersion(latest);
|
|
642673
643486
|
setUpdateAvailable(!!hasUpdate);
|
|
642674
643487
|
if (hasUpdate) {
|
|
642675
|
-
logForDebugging(`PackageManagerAutoUpdater: Update available ${"1.3.
|
|
643488
|
+
logForDebugging(`PackageManagerAutoUpdater: Update available ${"1.3.327"} -> ${latest}`);
|
|
642676
643489
|
}
|
|
642677
643490
|
};
|
|
642678
643491
|
$3[0] = t1;
|
|
@@ -642706,7 +643519,7 @@ function PackageManagerAutoUpdater(t0) {
|
|
|
642706
643519
|
wrap: "truncate",
|
|
642707
643520
|
children: [
|
|
642708
643521
|
"currentVersion: ",
|
|
642709
|
-
"1.3.
|
|
643522
|
+
"1.3.327"
|
|
642710
643523
|
]
|
|
642711
643524
|
}, undefined, true, undefined, this);
|
|
642712
643525
|
$3[3] = verbose;
|
|
@@ -648465,15 +649278,15 @@ function getVisibleAgentTasks(tasks2) {
|
|
|
648465
649278
|
return Object.values(tasks2).filter((t2) => isPanelAgentTask(t2) && t2.evictAfter !== 0).sort((a2, b3) => a2.startTime - b3.startTime);
|
|
648466
649279
|
}
|
|
648467
649280
|
function useCoordinatorTaskCount() {
|
|
648468
|
-
const tasks2 = useAppState(
|
|
648469
|
-
|
|
648470
|
-
|
|
648471
|
-
|
|
648472
|
-
|
|
648473
|
-
|
|
648474
|
-
|
|
649281
|
+
const tasks2 = useAppState((s2) => s2.tasks);
|
|
649282
|
+
return React129.useMemo(() => {
|
|
649283
|
+
if (true)
|
|
649284
|
+
return 0;
|
|
649285
|
+
const count4 = getVisibleAgentTasks(tasks2).length;
|
|
649286
|
+
return count4 > 0 ? count4 + 1 : 0;
|
|
649287
|
+
}, [tasks2]);
|
|
648475
649288
|
}
|
|
648476
|
-
var
|
|
649289
|
+
var React129, jsx_dev_runtime401;
|
|
648477
649290
|
var init_CoordinatorAgentStatus = __esm(() => {
|
|
648478
649291
|
init_figures2();
|
|
648479
649292
|
init_useTerminalSize();
|
|
@@ -648485,7 +649298,6 @@ var init_CoordinatorAgentStatus = __esm(() => {
|
|
|
648485
649298
|
init_format();
|
|
648486
649299
|
init_framework();
|
|
648487
649300
|
init_taskStatusUtils();
|
|
648488
|
-
import_compiler_runtime300 = __toESM(require_compiler_runtime(), 1);
|
|
648489
649301
|
React129 = __toESM(require_react(), 1);
|
|
648490
649302
|
jsx_dev_runtime401 = __toESM(require_jsx_dev_runtime(), 1);
|
|
648491
649303
|
});
|
|
@@ -648498,7 +649310,7 @@ var init_highlightMatch = __esm(() => {
|
|
|
648498
649310
|
});
|
|
648499
649311
|
|
|
648500
649312
|
// src/components/design-system/FuzzyPicker.tsx
|
|
648501
|
-
var
|
|
649313
|
+
var import_compiler_runtime300, import_react234, jsx_dev_runtime403;
|
|
648502
649314
|
var init_FuzzyPicker = __esm(() => {
|
|
648503
649315
|
init_useSearchInput();
|
|
648504
649316
|
init_useTerminalSize();
|
|
@@ -648509,13 +649321,13 @@ var init_FuzzyPicker = __esm(() => {
|
|
|
648509
649321
|
init_KeyboardShortcutHint();
|
|
648510
649322
|
init_ListItem();
|
|
648511
649323
|
init_Pane();
|
|
648512
|
-
|
|
649324
|
+
import_compiler_runtime300 = __toESM(require_compiler_runtime(), 1);
|
|
648513
649325
|
import_react234 = __toESM(require_react(), 1);
|
|
648514
649326
|
jsx_dev_runtime403 = __toESM(require_jsx_dev_runtime(), 1);
|
|
648515
649327
|
});
|
|
648516
649328
|
|
|
648517
649329
|
// src/components/GlobalSearchDialog.tsx
|
|
648518
|
-
var
|
|
649330
|
+
var import_compiler_runtime301, import_react235, jsx_dev_runtime404;
|
|
648519
649331
|
var init_GlobalSearchDialog = __esm(() => {
|
|
648520
649332
|
init_overlayContext();
|
|
648521
649333
|
init_useTerminalSize();
|
|
@@ -648530,7 +649342,7 @@ var init_GlobalSearchDialog = __esm(() => {
|
|
|
648530
649342
|
init_ripgrep();
|
|
648531
649343
|
init_FuzzyPicker();
|
|
648532
649344
|
init_LoadingState();
|
|
648533
|
-
|
|
649345
|
+
import_compiler_runtime301 = __toESM(require_compiler_runtime(), 1);
|
|
648534
649346
|
import_react235 = __toESM(require_react(), 1);
|
|
648535
649347
|
jsx_dev_runtime404 = __toESM(require_jsx_dev_runtime(), 1);
|
|
648536
649348
|
});
|
|
@@ -648552,7 +649364,7 @@ var init_HistorySearchDialog = __esm(() => {
|
|
|
648552
649364
|
});
|
|
648553
649365
|
|
|
648554
649366
|
// src/components/QuickOpenDialog.tsx
|
|
648555
|
-
var
|
|
649367
|
+
var import_compiler_runtime302, import_react237, jsx_dev_runtime406;
|
|
648556
649368
|
var init_QuickOpenDialog = __esm(() => {
|
|
648557
649369
|
init_overlayContext();
|
|
648558
649370
|
init_fileSuggestions();
|
|
@@ -648566,14 +649378,14 @@ var init_QuickOpenDialog = __esm(() => {
|
|
|
648566
649378
|
init_readFileInRange();
|
|
648567
649379
|
init_FuzzyPicker();
|
|
648568
649380
|
init_LoadingState();
|
|
648569
|
-
|
|
649381
|
+
import_compiler_runtime302 = __toESM(require_compiler_runtime(), 1);
|
|
648570
649382
|
import_react237 = __toESM(require_react(), 1);
|
|
648571
649383
|
jsx_dev_runtime406 = __toESM(require_jsx_dev_runtime(), 1);
|
|
648572
649384
|
});
|
|
648573
649385
|
|
|
648574
649386
|
// src/components/ThinkingToggle.tsx
|
|
648575
649387
|
function ThinkingToggle(t0) {
|
|
648576
|
-
const $3 =
|
|
649388
|
+
const $3 = import_compiler_runtime303.c(27);
|
|
648577
649389
|
const {
|
|
648578
649390
|
currentValue,
|
|
648579
649391
|
onSelect,
|
|
@@ -648716,7 +649528,7 @@ function ThinkingToggle(t0) {
|
|
|
648716
649528
|
defaultFocusValue: currentValue ? "true" : "false",
|
|
648717
649529
|
options,
|
|
648718
649530
|
onChange: handleSelectChange,
|
|
648719
|
-
onCancel: onCancel ??
|
|
649531
|
+
onCancel: onCancel ?? _temp183,
|
|
648720
649532
|
visibleOptionCount: 2
|
|
648721
649533
|
}, undefined, false, undefined, this)
|
|
648722
649534
|
}, undefined, false, undefined, this)
|
|
@@ -648793,8 +649605,8 @@ function ThinkingToggle(t0) {
|
|
|
648793
649605
|
}
|
|
648794
649606
|
return t11;
|
|
648795
649607
|
}
|
|
648796
|
-
function
|
|
648797
|
-
var
|
|
649608
|
+
function _temp183() {}
|
|
649609
|
+
var import_compiler_runtime303, import_react238, jsx_dev_runtime407;
|
|
648798
649610
|
var init_ThinkingToggle = __esm(() => {
|
|
648799
649611
|
init_useExitOnCtrlCDWithKeybindings();
|
|
648800
649612
|
init_ink2();
|
|
@@ -648804,7 +649616,7 @@ var init_ThinkingToggle = __esm(() => {
|
|
|
648804
649616
|
init_Byline();
|
|
648805
649617
|
init_KeyboardShortcutHint();
|
|
648806
649618
|
init_Pane();
|
|
648807
|
-
|
|
649619
|
+
import_compiler_runtime303 = __toESM(require_compiler_runtime(), 1);
|
|
648808
649620
|
import_react238 = __toESM(require_react(), 1);
|
|
648809
649621
|
jsx_dev_runtime407 = __toESM(require_jsx_dev_runtime(), 1);
|
|
648810
649622
|
});
|
|
@@ -649002,7 +649814,7 @@ function TeamsDialog({
|
|
|
649002
649814
|
return null;
|
|
649003
649815
|
}
|
|
649004
649816
|
function TeamDetailView(t0) {
|
|
649005
|
-
const $3 =
|
|
649817
|
+
const $3 = import_compiler_runtime304.c(13);
|
|
649006
649818
|
const {
|
|
649007
649819
|
teamName,
|
|
649008
649820
|
teammates,
|
|
@@ -649089,7 +649901,7 @@ function TeamDetailView(t0) {
|
|
|
649089
649901
|
return t5;
|
|
649090
649902
|
}
|
|
649091
649903
|
function TeammateListItem(t0) {
|
|
649092
|
-
const $3 =
|
|
649904
|
+
const $3 = import_compiler_runtime304.c(21);
|
|
649093
649905
|
const {
|
|
649094
649906
|
teammate,
|
|
649095
649907
|
isSelected
|
|
@@ -649194,7 +650006,7 @@ function TeammateListItem(t0) {
|
|
|
649194
650006
|
return t8;
|
|
649195
650007
|
}
|
|
649196
650008
|
function TeammateDetailView(t0) {
|
|
649197
|
-
const $3 =
|
|
650009
|
+
const $3 = import_compiler_runtime304.c(39);
|
|
649198
650010
|
const {
|
|
649199
650011
|
teammate,
|
|
649200
650012
|
teamName,
|
|
@@ -649241,7 +650053,7 @@ function TeammateDetailView(t0) {
|
|
|
649241
650053
|
if ($3[6] === Symbol.for("react.memo_cache_sentinel")) {
|
|
649242
650054
|
t4 = (input) => {
|
|
649243
650055
|
if (input === "p") {
|
|
649244
|
-
setPromptExpanded(
|
|
650056
|
+
setPromptExpanded(_temp185);
|
|
649245
650057
|
}
|
|
649246
650058
|
};
|
|
649247
650059
|
$3[6] = t4;
|
|
@@ -649435,7 +650247,7 @@ function _temp276(task_0) {
|
|
|
649435
650247
|
]
|
|
649436
650248
|
}, task_0.id, true, undefined, this);
|
|
649437
650249
|
}
|
|
649438
|
-
function
|
|
650250
|
+
function _temp185(prev) {
|
|
649439
650251
|
return !prev;
|
|
649440
650252
|
}
|
|
649441
650253
|
async function killTeammate(paneId, backendType, teamName, teammateId, teammateName, setAppState) {
|
|
@@ -649552,7 +650364,7 @@ function cycleAllTeammateModes(teammates, teamName, isBypassAvailable) {
|
|
|
649552
650364
|
}
|
|
649553
650365
|
logForDebugging(`[TeamsDialog] Sent mode change to all ${teammates.length} teammates: ${targetMode}`);
|
|
649554
650366
|
}
|
|
649555
|
-
var
|
|
650367
|
+
var import_compiler_runtime304, import_react239, jsx_dev_runtime408;
|
|
649556
650368
|
var init_TeamsDialog = __esm(() => {
|
|
649557
650369
|
init_figures();
|
|
649558
650370
|
init_dist6();
|
|
@@ -649578,7 +650390,7 @@ var init_TeamsDialog = __esm(() => {
|
|
|
649578
650390
|
init_teammateMailbox();
|
|
649579
650391
|
init_Dialog();
|
|
649580
650392
|
init_ThemedText();
|
|
649581
|
-
|
|
650393
|
+
import_compiler_runtime304 = __toESM(require_compiler_runtime(), 1);
|
|
649582
650394
|
import_react239 = __toESM(require_react(), 1);
|
|
649583
650395
|
jsx_dev_runtime408 = __toESM(require_jsx_dev_runtime(), 1);
|
|
649584
650396
|
});
|
|
@@ -650677,7 +651489,7 @@ var init_useVimInput = __esm(() => {
|
|
|
650677
651489
|
|
|
650678
651490
|
// src/components/VimTextInput.tsx
|
|
650679
651491
|
function VimTextInput(props) {
|
|
650680
|
-
const $3 =
|
|
651492
|
+
const $3 = import_compiler_runtime305.c(38);
|
|
650681
651493
|
const [theme2] = useTheme();
|
|
650682
651494
|
const isTerminalFocused = useTerminalFocus();
|
|
650683
651495
|
useClipboardImageHint(isTerminalFocused, !!props.onImagePaste);
|
|
@@ -650695,7 +651507,7 @@ function VimTextInput(props) {
|
|
|
650695
651507
|
const t11 = props.multiline;
|
|
650696
651508
|
const t12 = props.showCursor ? " " : "";
|
|
650697
651509
|
const t13 = props.highlightPastedText;
|
|
650698
|
-
const t14 = isTerminalFocused ? source_default.inverse :
|
|
651510
|
+
const t14 = isTerminalFocused ? source_default.inverse : _temp186;
|
|
650699
651511
|
let t15;
|
|
650700
651512
|
if ($3[0] !== theme2) {
|
|
650701
651513
|
t15 = color("text", theme2);
|
|
@@ -650808,17 +651620,17 @@ function VimTextInput(props) {
|
|
|
650808
651620
|
}
|
|
650809
651621
|
return t19;
|
|
650810
651622
|
}
|
|
650811
|
-
function
|
|
651623
|
+
function _temp186(text2) {
|
|
650812
651624
|
return text2;
|
|
650813
651625
|
}
|
|
650814
|
-
var
|
|
651626
|
+
var import_compiler_runtime305, import_react241, jsx_dev_runtime409;
|
|
650815
651627
|
var init_VimTextInput = __esm(() => {
|
|
650816
651628
|
init_source();
|
|
650817
651629
|
init_useClipboardImageHint();
|
|
650818
651630
|
init_useVimInput();
|
|
650819
651631
|
init_ink2();
|
|
650820
651632
|
init_BaseTextInput();
|
|
650821
|
-
|
|
651633
|
+
import_compiler_runtime305 = __toESM(require_compiler_runtime(), 1);
|
|
650822
651634
|
import_react241 = __toESM(require_react(), 1);
|
|
650823
651635
|
jsx_dev_runtime409 = __toESM(require_jsx_dev_runtime(), 1);
|
|
650824
651636
|
});
|
|
@@ -650872,7 +651684,7 @@ function buildStatusLineCommandInput(permissionMode, exceeds200kTokens, settings
|
|
|
650872
651684
|
project_dir: getOriginalCwd(),
|
|
650873
651685
|
added_dirs: addedDirs
|
|
650874
651686
|
},
|
|
650875
|
-
version: "1.3.
|
|
651687
|
+
version: "1.3.327",
|
|
650876
651688
|
output_style: {
|
|
650877
651689
|
name: outputStyleName
|
|
650878
651690
|
},
|
|
@@ -651168,7 +651980,7 @@ function calculateHorizontalScrollWindow(itemWidths, availableWidth, arrowWidth,
|
|
|
651168
651980
|
|
|
651169
651981
|
// src/components/tasks/BackgroundTaskStatus.tsx
|
|
651170
651982
|
function BackgroundTaskStatus(t0) {
|
|
651171
|
-
const $3 =
|
|
651983
|
+
const $3 = import_compiler_runtime306.c(48);
|
|
651172
651984
|
const {
|
|
651173
651985
|
tasksSelected,
|
|
651174
651986
|
isViewingTeammate,
|
|
@@ -651182,7 +651994,7 @@ function BackgroundTaskStatus(t0) {
|
|
|
651182
651994
|
const {
|
|
651183
651995
|
columns
|
|
651184
651996
|
} = useTerminalSize();
|
|
651185
|
-
const tasks2 = useAppState(
|
|
651997
|
+
const tasks2 = useAppState(_temp187);
|
|
651186
651998
|
const viewingAgentTaskId = useAppState(_temp277);
|
|
651187
651999
|
let t3;
|
|
651188
652000
|
if ($3[0] !== tasks2) {
|
|
@@ -651477,11 +652289,11 @@ function _temp350(t2) {
|
|
|
651477
652289
|
function _temp277(s_0) {
|
|
651478
652290
|
return s_0.viewingAgentTaskId;
|
|
651479
652291
|
}
|
|
651480
|
-
function
|
|
652292
|
+
function _temp187(s2) {
|
|
651481
652293
|
return s2.tasks;
|
|
651482
652294
|
}
|
|
651483
652295
|
function AgentPill(t0) {
|
|
651484
|
-
const $3 =
|
|
652296
|
+
const $3 = import_compiler_runtime306.c(19);
|
|
651485
652297
|
const {
|
|
651486
652298
|
name,
|
|
651487
652299
|
color: color3,
|
|
@@ -651613,7 +652425,7 @@ function AgentPill(t0) {
|
|
|
651613
652425
|
return t3;
|
|
651614
652426
|
}
|
|
651615
652427
|
function SummaryPill(t0) {
|
|
651616
|
-
const $3 =
|
|
652428
|
+
const $3 = import_compiler_runtime306.c(8);
|
|
651617
652429
|
const {
|
|
651618
652430
|
selected,
|
|
651619
652431
|
onClick,
|
|
@@ -651673,7 +652485,7 @@ function getAgentThemeColor(colorName) {
|
|
|
651673
652485
|
}
|
|
651674
652486
|
return;
|
|
651675
652487
|
}
|
|
651676
|
-
var
|
|
652488
|
+
var import_compiler_runtime306, React132, import_react243, jsx_dev_runtime411;
|
|
651677
652489
|
var init_BackgroundTaskStatus = __esm(() => {
|
|
651678
652490
|
init_figures();
|
|
651679
652491
|
init_useTerminalSize();
|
|
@@ -651686,7 +652498,7 @@ var init_BackgroundTaskStatus = __esm(() => {
|
|
|
651686
652498
|
init_agentColorManager();
|
|
651687
652499
|
init_KeyboardShortcutHint();
|
|
651688
652500
|
init_taskStatusUtils();
|
|
651689
|
-
|
|
652501
|
+
import_compiler_runtime306 = __toESM(require_compiler_runtime(), 1);
|
|
651690
652502
|
React132 = __toESM(require_react(), 1);
|
|
651691
652503
|
import_react243 = __toESM(require_react(), 1);
|
|
651692
652504
|
jsx_dev_runtime411 = __toESM(require_jsx_dev_runtime(), 1);
|
|
@@ -651694,12 +652506,12 @@ var init_BackgroundTaskStatus = __esm(() => {
|
|
|
651694
652506
|
|
|
651695
652507
|
// src/components/teams/TeamStatus.tsx
|
|
651696
652508
|
function TeamStatus(t0) {
|
|
651697
|
-
const $3 =
|
|
652509
|
+
const $3 = import_compiler_runtime307.c(14);
|
|
651698
652510
|
const {
|
|
651699
652511
|
teamsSelected,
|
|
651700
652512
|
showHint
|
|
651701
652513
|
} = t0;
|
|
651702
|
-
const teamContext = useAppState(
|
|
652514
|
+
const teamContext = useAppState(_temp188);
|
|
651703
652515
|
let t1;
|
|
651704
652516
|
if ($3[0] !== teamContext) {
|
|
651705
652517
|
t1 = teamContext ? Object.values(teamContext.teammates).filter(_temp278).length : 0;
|
|
@@ -651781,20 +652593,20 @@ function TeamStatus(t0) {
|
|
|
651781
652593
|
function _temp278(t2) {
|
|
651782
652594
|
return t2.name !== "team-lead";
|
|
651783
652595
|
}
|
|
651784
|
-
function
|
|
652596
|
+
function _temp188(s2) {
|
|
651785
652597
|
return s2.teamContext;
|
|
651786
652598
|
}
|
|
651787
|
-
var
|
|
652599
|
+
var import_compiler_runtime307, jsx_dev_runtime412;
|
|
651788
652600
|
var init_TeamStatus = __esm(() => {
|
|
651789
652601
|
init_ink2();
|
|
651790
652602
|
init_AppState();
|
|
651791
|
-
|
|
652603
|
+
import_compiler_runtime307 = __toESM(require_compiler_runtime(), 1);
|
|
651792
652604
|
jsx_dev_runtime412 = __toESM(require_jsx_dev_runtime(), 1);
|
|
651793
652605
|
});
|
|
651794
652606
|
|
|
651795
652607
|
// src/components/PromptInput/HistorySearchInput.tsx
|
|
651796
652608
|
function HistorySearchInput(t0) {
|
|
651797
|
-
const $3 =
|
|
652609
|
+
const $3 = import_compiler_runtime308.c(9);
|
|
651798
652610
|
const {
|
|
651799
652611
|
value,
|
|
651800
652612
|
onChange,
|
|
@@ -651819,7 +652631,7 @@ function HistorySearchInput(t0) {
|
|
|
651819
652631
|
value,
|
|
651820
652632
|
onChange,
|
|
651821
652633
|
cursorOffset: value.length,
|
|
651822
|
-
onChangeCursorOffset:
|
|
652634
|
+
onChangeCursorOffset: _temp189,
|
|
651823
652635
|
columns: t3,
|
|
651824
652636
|
focus: true,
|
|
651825
652637
|
showCursor: true,
|
|
@@ -651850,13 +652662,13 @@ function HistorySearchInput(t0) {
|
|
|
651850
652662
|
}
|
|
651851
652663
|
return t5;
|
|
651852
652664
|
}
|
|
651853
|
-
function
|
|
651854
|
-
var
|
|
652665
|
+
function _temp189() {}
|
|
652666
|
+
var import_compiler_runtime308, jsx_dev_runtime413, HistorySearchInput_default;
|
|
651855
652667
|
var init_HistorySearchInput = __esm(() => {
|
|
651856
652668
|
init_stringWidth();
|
|
651857
652669
|
init_ink2();
|
|
651858
652670
|
init_TextInput();
|
|
651859
|
-
|
|
652671
|
+
import_compiler_runtime308 = __toESM(require_compiler_runtime(), 1);
|
|
651860
652672
|
jsx_dev_runtime413 = __toESM(require_jsx_dev_runtime(), 1);
|
|
651861
652673
|
HistorySearchInput_default = HistorySearchInput;
|
|
651862
652674
|
});
|
|
@@ -651997,18 +652809,18 @@ var init_usePrStatus = __esm(() => {
|
|
|
651997
652809
|
});
|
|
651998
652810
|
|
|
651999
652811
|
// src/components/PromptInput/VoiceIndicator.tsx
|
|
652000
|
-
var
|
|
652812
|
+
var import_compiler_runtime309, jsx_dev_runtime414;
|
|
652001
652813
|
var init_VoiceIndicator = __esm(() => {
|
|
652002
652814
|
init_useSettings();
|
|
652003
652815
|
init_ink2();
|
|
652004
652816
|
init_utils12();
|
|
652005
|
-
|
|
652817
|
+
import_compiler_runtime309 = __toESM(require_compiler_runtime(), 1);
|
|
652006
652818
|
jsx_dev_runtime414 = __toESM(require_jsx_dev_runtime(), 1);
|
|
652007
652819
|
});
|
|
652008
652820
|
|
|
652009
652821
|
// src/components/PromptInput/PromptInputFooterLeftSide.tsx
|
|
652010
652822
|
function PromptInputFooterLeftSide(t0) {
|
|
652011
|
-
const $3 =
|
|
652823
|
+
const $3 = import_compiler_runtime310.c(27);
|
|
652012
652824
|
const {
|
|
652013
652825
|
exitMessage,
|
|
652014
652826
|
vimMode,
|
|
@@ -652411,7 +653223,7 @@ function getSpinnerHintParts(isLoading, escShortcut, todosShortcut, killAgentsSh
|
|
|
652411
653223
|
function isPrStatusEnabled() {
|
|
652412
653224
|
return getGlobalConfig().prStatusFooterEnabled ?? true;
|
|
652413
653225
|
}
|
|
652414
|
-
var
|
|
653226
|
+
var import_compiler_runtime310, import_react245, jsx_dev_runtime415, proactiveModule3 = null, NO_OP_SUBSCRIBE = (_cb) => () => {}, NULL2 = () => null;
|
|
652415
653227
|
var init_PromptInputFooterLeftSide = __esm(() => {
|
|
652416
653228
|
init_ink2();
|
|
652417
653229
|
init_figures();
|
|
@@ -652443,7 +653255,7 @@ var init_PromptInputFooterLeftSide = __esm(() => {
|
|
|
652443
653255
|
init_config2();
|
|
652444
653256
|
init_platform2();
|
|
652445
653257
|
init_PrBadge();
|
|
652446
|
-
|
|
653258
|
+
import_compiler_runtime310 = __toESM(require_compiler_runtime(), 1);
|
|
652447
653259
|
import_react245 = __toESM(require_react(), 1);
|
|
652448
653260
|
jsx_dev_runtime415 = __toESM(require_jsx_dev_runtime(), 1);
|
|
652449
653261
|
});
|
|
@@ -652660,7 +653472,7 @@ function getTeammateThemeColor() {
|
|
|
652660
653472
|
return;
|
|
652661
653473
|
}
|
|
652662
653474
|
function PromptChar(t0) {
|
|
652663
|
-
const $3 =
|
|
653475
|
+
const $3 = import_compiler_runtime311.c(3);
|
|
652664
653476
|
const {
|
|
652665
653477
|
isLoading,
|
|
652666
653478
|
themeColor
|
|
@@ -652686,7 +653498,7 @@ function PromptChar(t0) {
|
|
|
652686
653498
|
return t1;
|
|
652687
653499
|
}
|
|
652688
653500
|
function PromptInputModeIndicator(t0) {
|
|
652689
|
-
const $3 =
|
|
653501
|
+
const $3 = import_compiler_runtime311.c(6);
|
|
652690
653502
|
const {
|
|
652691
653503
|
mode,
|
|
652692
653504
|
isLoading,
|
|
@@ -652731,14 +653543,14 @@ function PromptInputModeIndicator(t0) {
|
|
|
652731
653543
|
}
|
|
652732
653544
|
return t2;
|
|
652733
653545
|
}
|
|
652734
|
-
var
|
|
653546
|
+
var import_compiler_runtime311, jsx_dev_runtime417;
|
|
652735
653547
|
var init_PromptInputModeIndicator = __esm(() => {
|
|
652736
653548
|
init_figures();
|
|
652737
653549
|
init_ink2();
|
|
652738
653550
|
init_agentColorManager();
|
|
652739
653551
|
init_teammate();
|
|
652740
653552
|
init_agentSwarmsEnabled();
|
|
652741
|
-
|
|
653553
|
+
import_compiler_runtime311 = __toESM(require_compiler_runtime(), 1);
|
|
652742
653554
|
jsx_dev_runtime417 = __toESM(require_jsx_dev_runtime(), 1);
|
|
652743
653555
|
});
|
|
652744
653556
|
|
|
@@ -652839,7 +653651,7 @@ var init_PromptInputQueuedCommands = __esm(() => {
|
|
|
652839
653651
|
|
|
652840
653652
|
// src/components/PromptInput/PromptInputStashNotice.tsx
|
|
652841
653653
|
function PromptInputStashNotice(t0) {
|
|
652842
|
-
const $3 =
|
|
653654
|
+
const $3 = import_compiler_runtime312.c(1);
|
|
652843
653655
|
const {
|
|
652844
653656
|
hasStash
|
|
652845
653657
|
} = t0;
|
|
@@ -652864,11 +653676,11 @@ function PromptInputStashNotice(t0) {
|
|
|
652864
653676
|
}
|
|
652865
653677
|
return t1;
|
|
652866
653678
|
}
|
|
652867
|
-
var
|
|
653679
|
+
var import_compiler_runtime312, jsx_dev_runtime419;
|
|
652868
653680
|
var init_PromptInputStashNotice = __esm(() => {
|
|
652869
653681
|
init_figures();
|
|
652870
653682
|
init_ink2();
|
|
652871
|
-
|
|
653683
|
+
import_compiler_runtime312 = __toESM(require_compiler_runtime(), 1);
|
|
652872
653684
|
jsx_dev_runtime419 = __toESM(require_jsx_dev_runtime(), 1);
|
|
652873
653685
|
});
|
|
652874
653686
|
|
|
@@ -656772,7 +657584,7 @@ var init_useDebouncedDigitInput = __esm(() => {
|
|
|
656772
657584
|
|
|
656773
657585
|
// src/components/FeedbackSurvey/FeedbackSurveyView.tsx
|
|
656774
657586
|
function FeedbackSurveyView(t0) {
|
|
656775
|
-
const $3 =
|
|
657587
|
+
const $3 = import_compiler_runtime313.c(15);
|
|
656776
657588
|
const {
|
|
656777
657589
|
onSelect,
|
|
656778
657590
|
inputValue,
|
|
@@ -656926,11 +657738,11 @@ function FeedbackSurveyView(t0) {
|
|
|
656926
657738
|
}
|
|
656927
657739
|
return t10;
|
|
656928
657740
|
}
|
|
656929
|
-
var
|
|
657741
|
+
var import_compiler_runtime313, jsx_dev_runtime421, RESPONSE_INPUTS, inputToResponse, isValidResponseInput = (input) => RESPONSE_INPUTS.includes(input), DEFAULT_MESSAGE = "How is Claude doing this session? (optional)";
|
|
656930
657742
|
var init_FeedbackSurveyView = __esm(() => {
|
|
656931
657743
|
init_ink2();
|
|
656932
657744
|
init_useDebouncedDigitInput();
|
|
656933
|
-
|
|
657745
|
+
import_compiler_runtime313 = __toESM(require_compiler_runtime(), 1);
|
|
656934
657746
|
jsx_dev_runtime421 = __toESM(require_jsx_dev_runtime(), 1);
|
|
656935
657747
|
RESPONSE_INPUTS = ["0", "1", "2", "3"];
|
|
656936
657748
|
inputToResponse = {
|
|
@@ -656942,13 +657754,13 @@ var init_FeedbackSurveyView = __esm(() => {
|
|
|
656942
657754
|
});
|
|
656943
657755
|
|
|
656944
657756
|
// src/components/SkillImprovementSurvey.tsx
|
|
656945
|
-
var
|
|
657757
|
+
var import_compiler_runtime314, import_react257, jsx_dev_runtime422;
|
|
656946
657758
|
var init_SkillImprovementSurvey = __esm(() => {
|
|
656947
657759
|
init_figures2();
|
|
656948
657760
|
init_ink2();
|
|
656949
657761
|
init_stringUtils();
|
|
656950
657762
|
init_FeedbackSurveyView();
|
|
656951
|
-
|
|
657763
|
+
import_compiler_runtime314 = __toESM(require_compiler_runtime(), 1);
|
|
656952
657764
|
import_react257 = __toESM(require_react(), 1);
|
|
656953
657765
|
jsx_dev_runtime422 = __toESM(require_jsx_dev_runtime(), 1);
|
|
656954
657766
|
});
|
|
@@ -657766,7 +658578,7 @@ var init_useGlobalKeybindings = __esm(() => {
|
|
|
657766
658578
|
|
|
657767
658579
|
// src/hooks/useCommandKeybindings.tsx
|
|
657768
658580
|
function CommandKeybindingHandlers(t0) {
|
|
657769
|
-
const $3 =
|
|
658581
|
+
const $3 = import_compiler_runtime315.c(8);
|
|
657770
658582
|
const {
|
|
657771
658583
|
onSubmit,
|
|
657772
658584
|
isActive: t1
|
|
@@ -657836,12 +658648,12 @@ function CommandKeybindingHandlers(t0) {
|
|
|
657836
658648
|
useKeybindings(handlers, t4);
|
|
657837
658649
|
return null;
|
|
657838
658650
|
}
|
|
657839
|
-
var
|
|
658651
|
+
var import_compiler_runtime315, NOOP_HELPERS;
|
|
657840
658652
|
var init_useCommandKeybindings = __esm(() => {
|
|
657841
658653
|
init_overlayContext();
|
|
657842
658654
|
init_KeybindingContext();
|
|
657843
658655
|
init_useKeybinding();
|
|
657844
|
-
|
|
658656
|
+
import_compiler_runtime315 = __toESM(require_compiler_runtime(), 1);
|
|
657845
658657
|
NOOP_HELPERS = {
|
|
657846
658658
|
setCursorOffset: () => {},
|
|
657847
658659
|
clearBuffer: () => {},
|
|
@@ -658828,7 +659640,7 @@ var init_swarmWorkerHandler = __esm(() => {
|
|
|
658828
659640
|
|
|
658829
659641
|
// src/hooks/useCanUseTool.tsx
|
|
658830
659642
|
function useCanUseTool(setToolUseConfirmQueue, setToolPermissionContext) {
|
|
658831
|
-
const $3 =
|
|
659643
|
+
const $3 = import_compiler_runtime316.c(3);
|
|
658832
659644
|
let t0;
|
|
658833
659645
|
if ($3[0] !== setToolPermissionContext || $3[1] !== setToolUseConfirmQueue) {
|
|
658834
659646
|
t0 = async (tool, input, toolUseContext, assistantMessage, toolUseID, forceDecision) => new Promise((resolve49) => {
|
|
@@ -658918,7 +659730,7 @@ function useCanUseTool(setToolUseConfirmQueue, setToolPermissionContext) {
|
|
|
658918
659730
|
}
|
|
658919
659731
|
}
|
|
658920
659732
|
}).catch((error54) => {
|
|
658921
|
-
if (error54 instanceof AbortError || error54 instanceof
|
|
659733
|
+
if (error54 instanceof AbortError || error54 instanceof import_sdk16.APIUserAbortError) {
|
|
658922
659734
|
logForDebugging(`Permission check threw ${error54.constructor.name} for tool=${tool.name}: ${error54.message}`);
|
|
658923
659735
|
ctx.logCancelled();
|
|
658924
659736
|
resolve49(ctx.cancelAndAbort(undefined, true));
|
|
@@ -658938,7 +659750,7 @@ function useCanUseTool(setToolUseConfirmQueue, setToolPermissionContext) {
|
|
|
658938
659750
|
}
|
|
658939
659751
|
return t0;
|
|
658940
659752
|
}
|
|
658941
|
-
var
|
|
659753
|
+
var import_compiler_runtime316, import_sdk16, jsx_dev_runtime423, useCanUseTool_default;
|
|
658942
659754
|
var init_useCanUseTool = __esm(() => {
|
|
658943
659755
|
init_ink2();
|
|
658944
659756
|
init_bashPermissions();
|
|
@@ -658953,8 +659765,8 @@ var init_useCanUseTool = __esm(() => {
|
|
|
658953
659765
|
init_swarmWorkerHandler();
|
|
658954
659766
|
init_PermissionContext();
|
|
658955
659767
|
init_permissionLogging();
|
|
658956
|
-
|
|
658957
|
-
|
|
659768
|
+
import_compiler_runtime316 = __toESM(require_compiler_runtime(), 1);
|
|
659769
|
+
import_sdk16 = __toESM(require_sdk(), 1);
|
|
658958
659770
|
jsx_dev_runtime423 = __toESM(require_jsx_dev_runtime(), 1);
|
|
658959
659771
|
useCanUseTool_default = useCanUseTool;
|
|
658960
659772
|
});
|
|
@@ -659030,7 +659842,7 @@ var init_processTextPrompt = __esm(() => {
|
|
|
659030
659842
|
|
|
659031
659843
|
// src/components/BashModeProgress.tsx
|
|
659032
659844
|
function BashModeProgress(t0) {
|
|
659033
|
-
const $3 =
|
|
659845
|
+
const $3 = import_compiler_runtime317.c(8);
|
|
659034
659846
|
const {
|
|
659035
659847
|
input,
|
|
659036
659848
|
progress,
|
|
@@ -659088,13 +659900,13 @@ function BashModeProgress(t0) {
|
|
|
659088
659900
|
}
|
|
659089
659901
|
return t4;
|
|
659090
659902
|
}
|
|
659091
|
-
var
|
|
659903
|
+
var import_compiler_runtime317, jsx_dev_runtime424;
|
|
659092
659904
|
var init_BashModeProgress = __esm(() => {
|
|
659093
659905
|
init_ink2();
|
|
659094
659906
|
init_BashTool();
|
|
659095
659907
|
init_UserBashInputMessage();
|
|
659096
659908
|
init_ShellProgressMessage();
|
|
659097
|
-
|
|
659909
|
+
import_compiler_runtime317 = __toESM(require_compiler_runtime(), 1);
|
|
659098
659910
|
jsx_dev_runtime424 = __toESM(require_jsx_dev_runtime(), 1);
|
|
659099
659911
|
});
|
|
659100
659912
|
|
|
@@ -660388,8 +661200,8 @@ var init_useManagePlugins = __esm(() => {
|
|
|
660388
661200
|
|
|
660389
661201
|
// src/components/TeammateViewHeader.tsx
|
|
660390
661202
|
function TeammateViewHeader() {
|
|
660391
|
-
const $3 =
|
|
660392
|
-
const viewedTeammate = useAppState(
|
|
661203
|
+
const $3 = import_compiler_runtime318.c(14);
|
|
661204
|
+
const viewedTeammate = useAppState(_temp190);
|
|
660393
661205
|
if (!viewedTeammate) {
|
|
660394
661206
|
return null;
|
|
660395
661207
|
}
|
|
@@ -660488,10 +661300,10 @@ function TeammateViewHeader() {
|
|
|
660488
661300
|
}
|
|
660489
661301
|
return t6;
|
|
660490
661302
|
}
|
|
660491
|
-
function
|
|
661303
|
+
function _temp190(s2) {
|
|
660492
661304
|
return getViewedTeammateTask(s2);
|
|
660493
661305
|
}
|
|
660494
|
-
var
|
|
661306
|
+
var import_compiler_runtime318, jsx_dev_runtime426;
|
|
660495
661307
|
var init_TeammateViewHeader = __esm(() => {
|
|
660496
661308
|
init_ink2();
|
|
660497
661309
|
init_AppState();
|
|
@@ -660499,7 +661311,7 @@ var init_TeammateViewHeader = __esm(() => {
|
|
|
660499
661311
|
init_ink3();
|
|
660500
661312
|
init_KeyboardShortcutHint();
|
|
660501
661313
|
init_OffscreenFreeze();
|
|
660502
|
-
|
|
661314
|
+
import_compiler_runtime318 = __toESM(require_compiler_runtime(), 1);
|
|
660503
661315
|
jsx_dev_runtime426 = __toESM(require_jsx_dev_runtime(), 1);
|
|
660504
661316
|
});
|
|
660505
661317
|
|
|
@@ -661528,7 +662340,7 @@ var init_useTaskListWatcher = __esm(() => {
|
|
|
661528
662340
|
|
|
661529
662341
|
// src/hooks/useIDEIntegration.tsx
|
|
661530
662342
|
function useIDEIntegration(t0) {
|
|
661531
|
-
const $3 =
|
|
662343
|
+
const $3 = import_compiler_runtime319.c(7);
|
|
661532
662344
|
const {
|
|
661533
662345
|
autoConnectIdeFlag,
|
|
661534
662346
|
ideToInstallExtension,
|
|
@@ -661582,18 +662394,18 @@ function useIDEIntegration(t0) {
|
|
|
661582
662394
|
}
|
|
661583
662395
|
import_react277.useEffect(t1, t2);
|
|
661584
662396
|
}
|
|
661585
|
-
var
|
|
662397
|
+
var import_compiler_runtime319, import_react277;
|
|
661586
662398
|
var init_useIDEIntegration = __esm(() => {
|
|
661587
662399
|
init_config2();
|
|
661588
662400
|
init_envUtils();
|
|
661589
662401
|
init_ide();
|
|
661590
|
-
|
|
662402
|
+
import_compiler_runtime319 = __toESM(require_compiler_runtime(), 1);
|
|
661591
662403
|
import_react277 = __toESM(require_react(), 1);
|
|
661592
662404
|
});
|
|
661593
662405
|
|
|
661594
662406
|
// src/components/SessionBackgroundHint.tsx
|
|
661595
662407
|
function SessionBackgroundHint(t0) {
|
|
661596
|
-
const $3 =
|
|
662408
|
+
const $3 = import_compiler_runtime320.c(10);
|
|
661597
662409
|
const {
|
|
661598
662410
|
onBackgroundSession,
|
|
661599
662411
|
isLoading
|
|
@@ -661601,7 +662413,7 @@ function SessionBackgroundHint(t0) {
|
|
|
661601
662413
|
const setAppState = useSetAppState();
|
|
661602
662414
|
const appStateStore = useAppStateStore();
|
|
661603
662415
|
const [showSessionHint, setShowSessionHint] = import_react278.useState(false);
|
|
661604
|
-
const handleDoublePress = useDoublePress(setShowSessionHint, onBackgroundSession,
|
|
662416
|
+
const handleDoublePress = useDoublePress(setShowSessionHint, onBackgroundSession, _temp191);
|
|
661605
662417
|
let t1;
|
|
661606
662418
|
if ($3[0] !== appStateStore || $3[1] !== handleDoublePress || $3[2] !== isLoading || $3[3] !== setAppState) {
|
|
661607
662419
|
t1 = () => {
|
|
@@ -661681,8 +662493,8 @@ function _temp279(c4) {
|
|
|
661681
662493
|
hasUsedBackgroundTask: true
|
|
661682
662494
|
};
|
|
661683
662495
|
}
|
|
661684
|
-
function
|
|
661685
|
-
var
|
|
662496
|
+
function _temp191() {}
|
|
662497
|
+
var import_compiler_runtime320, import_react278, jsx_dev_runtime427;
|
|
661686
662498
|
var init_SessionBackgroundHint = __esm(() => {
|
|
661687
662499
|
init_useDoublePress();
|
|
661688
662500
|
init_ink2();
|
|
@@ -661694,7 +662506,7 @@ var init_SessionBackgroundHint = __esm(() => {
|
|
|
661694
662506
|
init_env();
|
|
661695
662507
|
init_envUtils();
|
|
661696
662508
|
init_KeyboardShortcutHint();
|
|
661697
|
-
|
|
662509
|
+
import_compiler_runtime320 = __toESM(require_compiler_runtime(), 1);
|
|
661698
662510
|
import_react278 = __toESM(require_react(), 1);
|
|
661699
662511
|
jsx_dev_runtime427 = __toESM(require_jsx_dev_runtime(), 1);
|
|
661700
662512
|
});
|
|
@@ -661826,7 +662638,7 @@ var init_useSessionBackgrounding = __esm(() => {
|
|
|
661826
662638
|
|
|
661827
662639
|
// src/components/EffortCallout.tsx
|
|
661828
662640
|
function EffortCallout(t0) {
|
|
661829
|
-
const $3 =
|
|
662641
|
+
const $3 = import_compiler_runtime321.c(18);
|
|
661830
662642
|
const {
|
|
661831
662643
|
model,
|
|
661832
662644
|
onDone
|
|
@@ -661868,7 +662680,7 @@ function EffortCallout(t0) {
|
|
|
661868
662680
|
} else {
|
|
661869
662681
|
t4 = $3[4];
|
|
661870
662682
|
}
|
|
661871
|
-
import_react280.useEffect(
|
|
662683
|
+
import_react280.useEffect(_temp192, t4);
|
|
661872
662684
|
let t5;
|
|
661873
662685
|
let t6;
|
|
661874
662686
|
if ($3[5] === Symbol.for("react.memo_cache_sentinel")) {
|
|
@@ -662018,11 +662830,11 @@ function EffortCallout(t0) {
|
|
|
662018
662830
|
}
|
|
662019
662831
|
return t14;
|
|
662020
662832
|
}
|
|
662021
|
-
function
|
|
662833
|
+
function _temp192() {
|
|
662022
662834
|
markV2Dismissed();
|
|
662023
662835
|
}
|
|
662024
662836
|
function EffortIndicatorSymbol(t0) {
|
|
662025
|
-
const $3 =
|
|
662837
|
+
const $3 = import_compiler_runtime321.c(4);
|
|
662026
662838
|
const {
|
|
662027
662839
|
level
|
|
662028
662840
|
} = t0;
|
|
@@ -662048,7 +662860,7 @@ function EffortIndicatorSymbol(t0) {
|
|
|
662048
662860
|
return t2;
|
|
662049
662861
|
}
|
|
662050
662862
|
function EffortOptionLabel(t0) {
|
|
662051
|
-
const $3 =
|
|
662863
|
+
const $3 = import_compiler_runtime321.c(5);
|
|
662052
662864
|
const {
|
|
662053
662865
|
level,
|
|
662054
662866
|
text: text2
|
|
@@ -662115,7 +662927,7 @@ function markV2Dismissed() {
|
|
|
662115
662927
|
};
|
|
662116
662928
|
});
|
|
662117
662929
|
}
|
|
662118
|
-
var
|
|
662930
|
+
var import_compiler_runtime321, import_react280, jsx_dev_runtime428, AUTO_DISMISS_MS = 30000;
|
|
662119
662931
|
var init_EffortCallout = __esm(() => {
|
|
662120
662932
|
init_ink2();
|
|
662121
662933
|
init_auth();
|
|
@@ -662126,7 +662938,7 @@ var init_EffortCallout = __esm(() => {
|
|
|
662126
662938
|
init_select();
|
|
662127
662939
|
init_EffortIndicator();
|
|
662128
662940
|
init_PermissionDialog();
|
|
662129
|
-
|
|
662941
|
+
import_compiler_runtime321 = __toESM(require_compiler_runtime(), 1);
|
|
662130
662942
|
import_react280 = __toESM(require_react(), 1);
|
|
662131
662943
|
jsx_dev_runtime428 = __toESM(require_jsx_dev_runtime(), 1);
|
|
662132
662944
|
});
|
|
@@ -662242,7 +663054,7 @@ async function submitTranscriptShare(messages, trigger, appearanceId) {
|
|
|
662242
663054
|
} catch {}
|
|
662243
663055
|
const data = {
|
|
662244
663056
|
trigger,
|
|
662245
|
-
version: "1.3.
|
|
663057
|
+
version: "1.3.327",
|
|
662246
663058
|
platform: process.platform,
|
|
662247
663059
|
transcript,
|
|
662248
663060
|
subagentTranscripts: Object.keys(subagentTranscripts).length > 0 ? subagentTranscripts : undefined,
|
|
@@ -662827,7 +663639,7 @@ function hasMessageAfterBoundary(messages, boundaryUuid) {
|
|
|
662827
663639
|
return false;
|
|
662828
663640
|
}
|
|
662829
663641
|
function usePostCompactSurvey(messages, isLoading, t0, t1) {
|
|
662830
|
-
const $3 =
|
|
663642
|
+
const $3 = import_compiler_runtime322.c(23);
|
|
662831
663643
|
const hasActivePrompt = t0 === undefined ? false : t0;
|
|
662832
663644
|
let t2;
|
|
662833
663645
|
if ($3[0] !== t1) {
|
|
@@ -662851,7 +663663,7 @@ function usePostCompactSurvey(messages, isLoading, t0, t1) {
|
|
|
662851
663663
|
}
|
|
662852
663664
|
const seenCompactBoundaries = import_react286.useRef(t4);
|
|
662853
663665
|
const pendingCompactBoundaryUuid = import_react286.useRef(null);
|
|
662854
|
-
const onOpen =
|
|
663666
|
+
const onOpen = _temp193;
|
|
662855
663667
|
const onSelect = _temp280;
|
|
662856
663668
|
let t5;
|
|
662857
663669
|
if ($3[3] === Symbol.for("react.memo_cache_sentinel")) {
|
|
@@ -662987,7 +663799,7 @@ function _temp280(appearanceId_0, selected) {
|
|
|
662987
663799
|
survey_type: "post_compact"
|
|
662988
663800
|
});
|
|
662989
663801
|
}
|
|
662990
|
-
function
|
|
663802
|
+
function _temp193(appearanceId) {
|
|
662991
663803
|
const smCompactionEnabled = shouldUseSessionMemoryCompaction();
|
|
662992
663804
|
logEvent("tengu_post_compact_survey_event", {
|
|
662993
663805
|
event_type: "appeared",
|
|
@@ -663000,7 +663812,7 @@ function _temp194(appearanceId) {
|
|
|
663000
663812
|
survey_type: "post_compact"
|
|
663001
663813
|
});
|
|
663002
663814
|
}
|
|
663003
|
-
var
|
|
663815
|
+
var import_compiler_runtime322, import_react286, HIDE_THANKS_AFTER_MS2 = 3000, POST_COMPACT_SURVEY_GATE = "tengu_post_compact_survey", SURVEY_PROBABILITY2 = 0.2;
|
|
663004
663816
|
var init_usePostCompactSurvey = __esm(() => {
|
|
663005
663817
|
init_config();
|
|
663006
663818
|
init_growthbook();
|
|
@@ -663010,13 +663822,13 @@ var init_usePostCompactSurvey = __esm(() => {
|
|
|
663010
663822
|
init_messages5();
|
|
663011
663823
|
init_events3();
|
|
663012
663824
|
init_useSurveyState();
|
|
663013
|
-
|
|
663825
|
+
import_compiler_runtime322 = __toESM(require_compiler_runtime(), 1);
|
|
663014
663826
|
import_react286 = __toESM(require_react(), 1);
|
|
663015
663827
|
});
|
|
663016
663828
|
|
|
663017
663829
|
// src/components/FeedbackSurvey/TranscriptSharePrompt.tsx
|
|
663018
663830
|
function TranscriptSharePrompt(t0) {
|
|
663019
|
-
const $3 =
|
|
663831
|
+
const $3 = import_compiler_runtime323.c(11);
|
|
663020
663832
|
const {
|
|
663021
663833
|
onSelect,
|
|
663022
663834
|
inputValue,
|
|
@@ -663150,12 +663962,12 @@ function TranscriptSharePrompt(t0) {
|
|
|
663150
663962
|
}
|
|
663151
663963
|
return t7;
|
|
663152
663964
|
}
|
|
663153
|
-
var
|
|
663965
|
+
var import_compiler_runtime323, jsx_dev_runtime430, RESPONSE_INPUTS2, inputToResponse2, isValidResponseInput2 = (input) => RESPONSE_INPUTS2.includes(input);
|
|
663154
663966
|
var init_TranscriptSharePrompt = __esm(() => {
|
|
663155
663967
|
init_figures2();
|
|
663156
663968
|
init_ink2();
|
|
663157
663969
|
init_useDebouncedDigitInput();
|
|
663158
|
-
|
|
663970
|
+
import_compiler_runtime323 = __toESM(require_compiler_runtime(), 1);
|
|
663159
663971
|
jsx_dev_runtime430 = __toESM(require_jsx_dev_runtime(), 1);
|
|
663160
663972
|
RESPONSE_INPUTS2 = ["1", "2", "3"];
|
|
663161
663973
|
inputToResponse2 = {
|
|
@@ -663167,7 +663979,7 @@ var init_TranscriptSharePrompt = __esm(() => {
|
|
|
663167
663979
|
|
|
663168
663980
|
// src/components/FeedbackSurvey/FeedbackSurvey.tsx
|
|
663169
663981
|
function FeedbackSurvey(t0) {
|
|
663170
|
-
const $3 =
|
|
663982
|
+
const $3 = import_compiler_runtime324.c(16);
|
|
663171
663983
|
const {
|
|
663172
663984
|
state: state2,
|
|
663173
663985
|
lastResponse,
|
|
@@ -663283,7 +664095,7 @@ function FeedbackSurvey(t0) {
|
|
|
663283
664095
|
return t1;
|
|
663284
664096
|
}
|
|
663285
664097
|
function FeedbackSurveyThanks(t0) {
|
|
663286
|
-
const $3 =
|
|
664098
|
+
const $3 = import_compiler_runtime324.c(12);
|
|
663287
664099
|
const {
|
|
663288
664100
|
lastResponse,
|
|
663289
664101
|
inputValue,
|
|
@@ -663377,14 +664189,14 @@ function FeedbackSurveyThanks(t0) {
|
|
|
663377
664189
|
}
|
|
663378
664190
|
return t5;
|
|
663379
664191
|
}
|
|
663380
|
-
var
|
|
664192
|
+
var import_compiler_runtime324, jsx_dev_runtime431, isFollowUpDigit = (char) => char === "1";
|
|
663381
664193
|
var init_FeedbackSurvey = __esm(() => {
|
|
663382
664194
|
init_analytics();
|
|
663383
664195
|
init_ink2();
|
|
663384
664196
|
init_FeedbackSurveyView();
|
|
663385
664197
|
init_TranscriptSharePrompt();
|
|
663386
664198
|
init_useDebouncedDigitInput();
|
|
663387
|
-
|
|
664199
|
+
import_compiler_runtime324 = __toESM(require_compiler_runtime(), 1);
|
|
663388
664200
|
jsx_dev_runtime431 = __toESM(require_jsx_dev_runtime(), 1);
|
|
663389
664201
|
});
|
|
663390
664202
|
|
|
@@ -663421,9 +664233,9 @@ function useInstallMessages() {
|
|
|
663421
664233
|
}
|
|
663422
664234
|
async function _temp281() {
|
|
663423
664235
|
const messages = await checkInstall();
|
|
663424
|
-
return messages.map(
|
|
664236
|
+
return messages.map(_temp194);
|
|
663425
664237
|
}
|
|
663426
|
-
function
|
|
664238
|
+
function _temp194(message, index) {
|
|
663427
664239
|
let priority = "low";
|
|
663428
664240
|
if (message.type === "error" || message.userActionRequired) {
|
|
663429
664241
|
priority = "high";
|
|
@@ -663445,7 +664257,7 @@ var init_useInstallMessages = __esm(() => {
|
|
|
663445
664257
|
});
|
|
663446
664258
|
|
|
663447
664259
|
// src/services/awaySummary.ts
|
|
663448
|
-
var
|
|
664260
|
+
var import_sdk17;
|
|
663449
664261
|
var init_awaySummary = __esm(() => {
|
|
663450
664262
|
init_Tool();
|
|
663451
664263
|
init_debug();
|
|
@@ -663453,7 +664265,7 @@ var init_awaySummary = __esm(() => {
|
|
|
663453
664265
|
init_model();
|
|
663454
664266
|
init_claude();
|
|
663455
664267
|
init_sessionMemoryUtils();
|
|
663456
|
-
|
|
664268
|
+
import_sdk17 = __toESM(require_sdk(), 1);
|
|
663457
664269
|
});
|
|
663458
664270
|
|
|
663459
664271
|
// src/hooks/useAwaySummary.ts
|
|
@@ -663733,9 +664545,9 @@ var init_officialMarketplaceStartupCheck = __esm(() => {
|
|
|
663733
664545
|
|
|
663734
664546
|
// src/hooks/useOfficialMarketplaceNotification.tsx
|
|
663735
664547
|
function useOfficialMarketplaceNotification() {
|
|
663736
|
-
useStartupNotification(
|
|
664548
|
+
useStartupNotification(_temp195);
|
|
663737
664549
|
}
|
|
663738
|
-
async function
|
|
664550
|
+
async function _temp195() {
|
|
663739
664551
|
const result = await checkAndInstallOfficialMarketplace();
|
|
663740
664552
|
const notifs = [];
|
|
663741
664553
|
if (result.configSaveFailed) {
|
|
@@ -663974,7 +664786,7 @@ function getDownloadUrl() {
|
|
|
663974
664786
|
}
|
|
663975
664787
|
}
|
|
663976
664788
|
function DesktopHandoff(t0) {
|
|
663977
|
-
const $3 =
|
|
664789
|
+
const $3 = import_compiler_runtime325.c(20);
|
|
663978
664790
|
const {
|
|
663979
664791
|
onDone
|
|
663980
664792
|
} = t0;
|
|
@@ -663992,7 +664804,7 @@ function DesktopHandoff(t0) {
|
|
|
663992
664804
|
}
|
|
663993
664805
|
if (state2 === "prompt-download") {
|
|
663994
664806
|
if (input === "y" || input === "Y") {
|
|
663995
|
-
openBrowser(getDownloadUrl()).catch(
|
|
664807
|
+
openBrowser(getDownloadUrl()).catch(_temp196);
|
|
663996
664808
|
onDone(`Starting download. Re-run /desktop once you’ve installed the app.
|
|
663997
664809
|
Learn more at ${DESKTOP_DOCS_URL}`, {
|
|
663998
664810
|
display: "system"
|
|
@@ -664168,8 +664980,8 @@ async function _temp282(onDone_0) {
|
|
|
664168
664980
|
});
|
|
664169
664981
|
await gracefulShutdown(0, "other");
|
|
664170
664982
|
}
|
|
664171
|
-
function
|
|
664172
|
-
var
|
|
664983
|
+
function _temp196() {}
|
|
664984
|
+
var import_compiler_runtime325, import_react289, jsx_dev_runtime433, DESKTOP_DOCS_URL = "https://clau.de/desktop";
|
|
664173
664985
|
var init_DesktopHandoff = __esm(() => {
|
|
664174
664986
|
init_ink2();
|
|
664175
664987
|
init_browser();
|
|
@@ -664178,7 +664990,7 @@ var init_DesktopHandoff = __esm(() => {
|
|
|
664178
664990
|
init_gracefulShutdown();
|
|
664179
664991
|
init_sessionStorage();
|
|
664180
664992
|
init_LoadingState();
|
|
664181
|
-
|
|
664993
|
+
import_compiler_runtime325 = __toESM(require_compiler_runtime(), 1);
|
|
664182
664994
|
import_react289 = __toESM(require_react(), 1);
|
|
664183
664995
|
jsx_dev_runtime433 = __toESM(require_jsx_dev_runtime(), 1);
|
|
664184
664996
|
});
|
|
@@ -664203,7 +665015,7 @@ function shouldShowDesktopUpsellStartup() {
|
|
|
664203
665015
|
return true;
|
|
664204
665016
|
}
|
|
664205
665017
|
function DesktopUpsellStartup(t0) {
|
|
664206
|
-
const $3 =
|
|
665018
|
+
const $3 = import_compiler_runtime326.c(14);
|
|
664207
665019
|
const {
|
|
664208
665020
|
onDone
|
|
664209
665021
|
} = t0;
|
|
@@ -664215,7 +665027,7 @@ function DesktopUpsellStartup(t0) {
|
|
|
664215
665027
|
} else {
|
|
664216
665028
|
t1 = $3[0];
|
|
664217
665029
|
}
|
|
664218
|
-
import_react290.useEffect(
|
|
665030
|
+
import_react290.useEffect(_temp197, t1);
|
|
664219
665031
|
if (showHandoff) {
|
|
664220
665032
|
let t22;
|
|
664221
665033
|
if ($3[1] !== onDone) {
|
|
@@ -664340,7 +665152,7 @@ function _temp283(prev_0) {
|
|
|
664340
665152
|
desktopUpsellDismissed: true
|
|
664341
665153
|
};
|
|
664342
665154
|
}
|
|
664343
|
-
function
|
|
665155
|
+
function _temp197() {
|
|
664344
665156
|
const newCount = (getGlobalConfig().desktopUpsellSeenCount ?? 0) + 1;
|
|
664345
665157
|
saveGlobalConfig((prev) => {
|
|
664346
665158
|
if ((prev.desktopUpsellSeenCount ?? 0) >= newCount) {
|
|
@@ -664355,7 +665167,7 @@ function _temp198() {
|
|
|
664355
665167
|
seen_count: newCount
|
|
664356
665168
|
});
|
|
664357
665169
|
}
|
|
664358
|
-
var
|
|
665170
|
+
var import_compiler_runtime326, import_react290, jsx_dev_runtime434, DESKTOP_UPSELL_DEFAULT;
|
|
664359
665171
|
var init_DesktopUpsellStartup = __esm(() => {
|
|
664360
665172
|
init_ink2();
|
|
664361
665173
|
init_growthbook();
|
|
@@ -664364,7 +665176,7 @@ var init_DesktopUpsellStartup = __esm(() => {
|
|
|
664364
665176
|
init_select();
|
|
664365
665177
|
init_DesktopHandoff();
|
|
664366
665178
|
init_PermissionDialog();
|
|
664367
|
-
|
|
665179
|
+
import_compiler_runtime326 = __toESM(require_compiler_runtime(), 1);
|
|
664368
665180
|
import_react290 = __toESM(require_react(), 1);
|
|
664369
665181
|
jsx_dev_runtime434 = __toESM(require_jsx_dev_runtime(), 1);
|
|
664370
665182
|
DESKTOP_UPSELL_DEFAULT = {
|
|
@@ -665923,7 +666735,7 @@ var init_useFileHistorySnapshotInit = __esm(() => {
|
|
|
665923
666735
|
|
|
665924
666736
|
// src/components/permissions/SandboxPermissionRequest.tsx
|
|
665925
666737
|
function SandboxPermissionRequest(t0) {
|
|
665926
|
-
const $3 =
|
|
666738
|
+
const $3 = import_compiler_runtime327.c(22);
|
|
665927
666739
|
const {
|
|
665928
666740
|
hostPattern: t1,
|
|
665929
666741
|
onUserResponse
|
|
@@ -666120,13 +666932,13 @@ function SandboxPermissionRequest(t0) {
|
|
|
666120
666932
|
}
|
|
666121
666933
|
return t13;
|
|
666122
666934
|
}
|
|
666123
|
-
var
|
|
666935
|
+
var import_compiler_runtime327, jsx_dev_runtime435;
|
|
666124
666936
|
var init_SandboxPermissionRequest = __esm(() => {
|
|
666125
666937
|
init_ink2();
|
|
666126
666938
|
init_sandbox_adapter();
|
|
666127
666939
|
init_select();
|
|
666128
666940
|
init_PermissionDialog();
|
|
666129
|
-
|
|
666941
|
+
import_compiler_runtime327 = __toESM(require_compiler_runtime(), 1);
|
|
666130
666942
|
jsx_dev_runtime435 = __toESM(require_jsx_dev_runtime(), 1);
|
|
666131
666943
|
});
|
|
666132
666944
|
|
|
@@ -666139,7 +666951,7 @@ function formatTime(date6) {
|
|
|
666139
666951
|
return `${h3}:${m3}:${s2}${ampm}`;
|
|
666140
666952
|
}
|
|
666141
666953
|
function SandboxViolationExpandedView() {
|
|
666142
|
-
const $3 =
|
|
666954
|
+
const $3 = import_compiler_runtime328.c(15);
|
|
666143
666955
|
let t0;
|
|
666144
666956
|
if ($3[0] === Symbol.for("react.memo_cache_sentinel")) {
|
|
666145
666957
|
t0 = [];
|
|
@@ -666198,7 +667010,7 @@ function SandboxViolationExpandedView() {
|
|
|
666198
667010
|
}
|
|
666199
667011
|
let t5;
|
|
666200
667012
|
if ($3[6] !== violations) {
|
|
666201
|
-
t5 = violations.map(
|
|
667013
|
+
t5 = violations.map(_temp198);
|
|
666202
667014
|
$3[6] = violations;
|
|
666203
667015
|
$3[7] = t5;
|
|
666204
667016
|
} else {
|
|
@@ -666245,7 +667057,7 @@ function SandboxViolationExpandedView() {
|
|
|
666245
667057
|
}
|
|
666246
667058
|
return t8;
|
|
666247
667059
|
}
|
|
666248
|
-
function
|
|
667060
|
+
function _temp198(v2, i4) {
|
|
666249
667061
|
return /* @__PURE__ */ jsx_dev_runtime436.jsxDEV(ThemedBox_default, {
|
|
666250
667062
|
paddingLeft: 2,
|
|
666251
667063
|
children: /* @__PURE__ */ jsx_dev_runtime436.jsxDEV(ThemedText, {
|
|
@@ -666259,19 +667071,19 @@ function _temp199(v2, i4) {
|
|
|
666259
667071
|
}, undefined, true, undefined, this)
|
|
666260
667072
|
}, `${v2.timestamp.getTime()}-${i4}`, false, undefined, this);
|
|
666261
667073
|
}
|
|
666262
|
-
var
|
|
667074
|
+
var import_compiler_runtime328, import_react293, jsx_dev_runtime436;
|
|
666263
667075
|
var init_SandboxViolationExpandedView = __esm(() => {
|
|
666264
667076
|
init_ink2();
|
|
666265
667077
|
init_sandbox_adapter();
|
|
666266
667078
|
init_platform2();
|
|
666267
|
-
|
|
667079
|
+
import_compiler_runtime328 = __toESM(require_compiler_runtime(), 1);
|
|
666268
667080
|
import_react293 = __toESM(require_react(), 1);
|
|
666269
667081
|
jsx_dev_runtime436 = __toESM(require_jsx_dev_runtime(), 1);
|
|
666270
667082
|
});
|
|
666271
667083
|
|
|
666272
667084
|
// src/hooks/notifs/useMcpConnectivityStatus.tsx
|
|
666273
667085
|
function useMcpConnectivityStatus(t0) {
|
|
666274
|
-
const $3 =
|
|
667086
|
+
const $3 = import_compiler_runtime329.c(4);
|
|
666275
667087
|
const {
|
|
666276
667088
|
mcpClients: t1
|
|
666277
667089
|
} = t0;
|
|
@@ -666286,7 +667098,7 @@ function useMcpConnectivityStatus(t0) {
|
|
|
666286
667098
|
if (getIsRemoteMode()) {
|
|
666287
667099
|
return;
|
|
666288
667100
|
}
|
|
666289
|
-
const failedLocalClients = mcpClients.filter(
|
|
667101
|
+
const failedLocalClients = mcpClients.filter(_temp199);
|
|
666290
667102
|
const needsAuthLocalServers = mcpClients.filter(_temp352);
|
|
666291
667103
|
if (failedLocalClients.length === 0 && needsAuthLocalServers.length === 0) {
|
|
666292
667104
|
return;
|
|
@@ -666355,15 +667167,15 @@ function useMcpConnectivityStatus(t0) {
|
|
|
666355
667167
|
function _temp352(client_1) {
|
|
666356
667168
|
return client_1.type === "needs-auth";
|
|
666357
667169
|
}
|
|
666358
|
-
function
|
|
667170
|
+
function _temp199(client4) {
|
|
666359
667171
|
return client4.type === "failed" && client4.config.type !== "sse-ide" && client4.config.type !== "ws-ide";
|
|
666360
667172
|
}
|
|
666361
|
-
var
|
|
667173
|
+
var import_compiler_runtime329, import_react294, jsx_dev_runtime437, EMPTY_MCP_CLIENTS;
|
|
666362
667174
|
var init_useMcpConnectivityStatus = __esm(() => {
|
|
666363
667175
|
init_notifications();
|
|
666364
667176
|
init_state();
|
|
666365
667177
|
init_ink2();
|
|
666366
|
-
|
|
667178
|
+
import_compiler_runtime329 = __toESM(require_compiler_runtime(), 1);
|
|
666367
667179
|
import_react294 = __toESM(require_react(), 1);
|
|
666368
667180
|
jsx_dev_runtime437 = __toESM(require_jsx_dev_runtime(), 1);
|
|
666369
667181
|
EMPTY_MCP_CLIENTS = [];
|
|
@@ -666412,12 +667224,12 @@ var init_useAutoModeUnavailableNotification = __esm(() => {
|
|
|
666412
667224
|
|
|
666413
667225
|
// src/hooks/notifs/useLspInitializationNotification.tsx
|
|
666414
667226
|
function useLspInitializationNotification() {
|
|
666415
|
-
const $3 =
|
|
667227
|
+
const $3 = import_compiler_runtime330.c(10);
|
|
666416
667228
|
const {
|
|
666417
667229
|
addNotification
|
|
666418
667230
|
} = useNotifications();
|
|
666419
667231
|
const setAppState = useSetAppState();
|
|
666420
|
-
const [shouldPoll, setShouldPoll] = React141.useState(
|
|
667232
|
+
const [shouldPoll, setShouldPoll] = React141.useState(_temp200);
|
|
666421
667233
|
let t0;
|
|
666422
667234
|
if ($3[0] === Symbol.for("react.memo_cache_sentinel")) {
|
|
666423
667235
|
t0 = new Set;
|
|
@@ -666544,10 +667356,10 @@ function _temp284(e2) {
|
|
|
666544
667356
|
}
|
|
666545
667357
|
return `${e2.type}:${e2.source}`;
|
|
666546
667358
|
}
|
|
666547
|
-
function
|
|
667359
|
+
function _temp200() {
|
|
666548
667360
|
return isEnvTruthy("true");
|
|
666549
667361
|
}
|
|
666550
|
-
var
|
|
667362
|
+
var import_compiler_runtime330, React141, jsx_dev_runtime438, LSP_POLL_INTERVAL_MS = 5000;
|
|
666551
667363
|
var init_useLspInitializationNotification = __esm(() => {
|
|
666552
667364
|
init_dist6();
|
|
666553
667365
|
init_state();
|
|
@@ -666557,7 +667369,7 @@ var init_useLspInitializationNotification = __esm(() => {
|
|
|
666557
667369
|
init_AppState();
|
|
666558
667370
|
init_debug();
|
|
666559
667371
|
init_envUtils();
|
|
666560
|
-
|
|
667372
|
+
import_compiler_runtime330 = __toESM(require_compiler_runtime(), 1);
|
|
666561
667373
|
React141 = __toESM(require_react(), 1);
|
|
666562
667374
|
jsx_dev_runtime438 = __toESM(require_jsx_dev_runtime(), 1);
|
|
666563
667375
|
});
|
|
@@ -666770,7 +667582,7 @@ var init_lspRecommendation = __esm(() => {
|
|
|
666770
667582
|
|
|
666771
667583
|
// src/hooks/usePluginRecommendationBase.tsx
|
|
666772
667584
|
function usePluginRecommendationBase() {
|
|
666773
|
-
const $3 =
|
|
667585
|
+
const $3 = import_compiler_runtime331.c(6);
|
|
666774
667586
|
const [recommendation, setRecommendation] = React142.useState(null);
|
|
666775
667587
|
const isCheckingRef = React142.useRef(false);
|
|
666776
667588
|
let t0;
|
|
@@ -666860,14 +667672,14 @@ async function installPluginAndNotify(pluginId, pluginName, keyPrefix, addNotifi
|
|
|
666860
667672
|
});
|
|
666861
667673
|
}
|
|
666862
667674
|
}
|
|
666863
|
-
var
|
|
667675
|
+
var import_compiler_runtime331, React142, jsx_dev_runtime439;
|
|
666864
667676
|
var init_usePluginRecommendationBase = __esm(() => {
|
|
666865
667677
|
init_figures();
|
|
666866
667678
|
init_state();
|
|
666867
667679
|
init_ink2();
|
|
666868
667680
|
init_log2();
|
|
666869
667681
|
init_marketplaceManager();
|
|
666870
|
-
|
|
667682
|
+
import_compiler_runtime331 = __toESM(require_compiler_runtime(), 1);
|
|
666871
667683
|
React142 = __toESM(require_react(), 1);
|
|
666872
667684
|
jsx_dev_runtime439 = __toESM(require_jsx_dev_runtime(), 1);
|
|
666873
667685
|
});
|
|
@@ -666875,8 +667687,8 @@ var init_usePluginRecommendationBase = __esm(() => {
|
|
|
666875
667687
|
// src/hooks/useLspPluginRecommendation.tsx
|
|
666876
667688
|
import { extname as extname15, join as join162 } from "path";
|
|
666877
667689
|
function useLspPluginRecommendation() {
|
|
666878
|
-
const $3 =
|
|
666879
|
-
const trackedFiles = useAppState(
|
|
667690
|
+
const $3 = import_compiler_runtime332.c(12);
|
|
667691
|
+
const trackedFiles = useAppState(_temp201);
|
|
666880
667692
|
const {
|
|
666881
667693
|
addNotification
|
|
666882
667694
|
} = useNotifications();
|
|
@@ -667020,10 +667832,10 @@ function _temp285(current) {
|
|
|
667020
667832
|
lspRecommendationDisabled: true
|
|
667021
667833
|
};
|
|
667022
667834
|
}
|
|
667023
|
-
function
|
|
667835
|
+
function _temp201(s2) {
|
|
667024
667836
|
return s2.fileHistory.trackedFiles;
|
|
667025
667837
|
}
|
|
667026
|
-
var
|
|
667838
|
+
var import_compiler_runtime332, React143, TIMEOUT_THRESHOLD_MS = 28000;
|
|
667027
667839
|
var init_useLspPluginRecommendation = __esm(() => {
|
|
667028
667840
|
init_state();
|
|
667029
667841
|
init_notifications();
|
|
@@ -667035,7 +667847,7 @@ var init_useLspPluginRecommendation = __esm(() => {
|
|
|
667035
667847
|
init_pluginInstallationHelpers();
|
|
667036
667848
|
init_settings2();
|
|
667037
667849
|
init_usePluginRecommendationBase();
|
|
667038
|
-
|
|
667850
|
+
import_compiler_runtime332 = __toESM(require_compiler_runtime(), 1);
|
|
667039
667851
|
React143 = __toESM(require_react(), 1);
|
|
667040
667852
|
});
|
|
667041
667853
|
|
|
@@ -667174,7 +667986,7 @@ var init_LspRecommendationMenu = __esm(() => {
|
|
|
667174
667986
|
|
|
667175
667987
|
// src/hooks/useClaudeCodeHintRecommendation.tsx
|
|
667176
667988
|
function useClaudeCodeHintRecommendation() {
|
|
667177
|
-
const $3 =
|
|
667989
|
+
const $3 = import_compiler_runtime333.c(11);
|
|
667178
667990
|
const pendingHint2 = React145.useSyncExternalStore(subscribeToPendingHint, getPendingHintSnapshot);
|
|
667179
667991
|
const {
|
|
667180
667992
|
addNotification
|
|
@@ -667277,7 +668089,7 @@ function useClaudeCodeHintRecommendation() {
|
|
|
667277
668089
|
}
|
|
667278
668090
|
return t3;
|
|
667279
668091
|
}
|
|
667280
|
-
var
|
|
668092
|
+
var import_compiler_runtime333, React145;
|
|
667281
668093
|
var init_useClaudeCodeHintRecommendation = __esm(() => {
|
|
667282
668094
|
init_notifications();
|
|
667283
668095
|
init_analytics();
|
|
@@ -667286,7 +668098,7 @@ var init_useClaudeCodeHintRecommendation = __esm(() => {
|
|
|
667286
668098
|
init_hintRecommendation();
|
|
667287
668099
|
init_pluginInstallationHelpers();
|
|
667288
668100
|
init_usePluginRecommendationBase();
|
|
667289
|
-
|
|
668101
|
+
import_compiler_runtime333 = __toESM(require_compiler_runtime(), 1);
|
|
667290
668102
|
React145 = __toESM(require_react(), 1);
|
|
667291
668103
|
});
|
|
667292
668104
|
|
|
@@ -667417,11 +668229,11 @@ var init_PluginHintMenu = __esm(() => {
|
|
|
667417
668229
|
|
|
667418
668230
|
// src/hooks/notifs/usePluginInstallationStatus.tsx
|
|
667419
668231
|
function usePluginInstallationStatus() {
|
|
667420
|
-
const $3 =
|
|
668232
|
+
const $3 = import_compiler_runtime334.c(20);
|
|
667421
668233
|
const {
|
|
667422
668234
|
addNotification
|
|
667423
668235
|
} = useNotifications();
|
|
667424
|
-
const installationStatus = useAppState(
|
|
668236
|
+
const installationStatus = useAppState(_temp202);
|
|
667425
668237
|
let t0;
|
|
667426
668238
|
bb0: {
|
|
667427
668239
|
if (!installationStatus) {
|
|
@@ -667547,10 +668359,10 @@ function _temp353(p) {
|
|
|
667547
668359
|
function _temp286(m3) {
|
|
667548
668360
|
return m3.status === "failed";
|
|
667549
668361
|
}
|
|
667550
|
-
function
|
|
668362
|
+
function _temp202(s2) {
|
|
667551
668363
|
return s2.plugins.installationStatus;
|
|
667552
668364
|
}
|
|
667553
|
-
var
|
|
668365
|
+
var import_compiler_runtime334, import_react296, jsx_dev_runtime442;
|
|
667554
668366
|
var init_usePluginInstallationStatus = __esm(() => {
|
|
667555
668367
|
init_state();
|
|
667556
668368
|
init_notifications();
|
|
@@ -667558,14 +668370,14 @@ var init_usePluginInstallationStatus = __esm(() => {
|
|
|
667558
668370
|
init_AppState();
|
|
667559
668371
|
init_debug();
|
|
667560
668372
|
init_stringUtils();
|
|
667561
|
-
|
|
668373
|
+
import_compiler_runtime334 = __toESM(require_compiler_runtime(), 1);
|
|
667562
668374
|
import_react296 = __toESM(require_react(), 1);
|
|
667563
668375
|
jsx_dev_runtime442 = __toESM(require_jsx_dev_runtime(), 1);
|
|
667564
668376
|
});
|
|
667565
668377
|
|
|
667566
668378
|
// src/hooks/notifs/usePluginAutoupdateNotification.tsx
|
|
667567
668379
|
function usePluginAutoupdateNotification() {
|
|
667568
|
-
const $3 =
|
|
668380
|
+
const $3 = import_compiler_runtime335.c(7);
|
|
667569
668381
|
const {
|
|
667570
668382
|
addNotification
|
|
667571
668383
|
} = useNotifications();
|
|
@@ -667608,7 +668420,7 @@ function usePluginAutoupdateNotification() {
|
|
|
667608
668420
|
if (updatedPlugins.length === 0) {
|
|
667609
668421
|
return;
|
|
667610
668422
|
}
|
|
667611
|
-
const pluginNames = updatedPlugins.map(
|
|
668423
|
+
const pluginNames = updatedPlugins.map(_temp203);
|
|
667612
668424
|
const displayNames = pluginNames.length <= 2 ? pluginNames.join(" and ") : `${pluginNames.length} plugins`;
|
|
667613
668425
|
addNotification({
|
|
667614
668426
|
key: "plugin-autoupdate-restart",
|
|
@@ -667645,18 +668457,18 @@ function usePluginAutoupdateNotification() {
|
|
|
667645
668457
|
}
|
|
667646
668458
|
import_react297.useEffect(t3, t4);
|
|
667647
668459
|
}
|
|
667648
|
-
function
|
|
668460
|
+
function _temp203(id) {
|
|
667649
668461
|
const atIndex = id.indexOf("@");
|
|
667650
668462
|
return atIndex > 0 ? id.substring(0, atIndex) : id;
|
|
667651
668463
|
}
|
|
667652
|
-
var
|
|
668464
|
+
var import_compiler_runtime335, import_react297, jsx_dev_runtime443;
|
|
667653
668465
|
var init_usePluginAutoupdateNotification = __esm(() => {
|
|
667654
668466
|
init_state();
|
|
667655
668467
|
init_notifications();
|
|
667656
668468
|
init_ink2();
|
|
667657
668469
|
init_debug();
|
|
667658
668470
|
init_pluginAutoupdate();
|
|
667659
|
-
|
|
668471
|
+
import_compiler_runtime335 = __toESM(require_compiler_runtime(), 1);
|
|
667660
668472
|
import_react297 = __toESM(require_react(), 1);
|
|
667661
668473
|
jsx_dev_runtime443 = __toESM(require_jsx_dev_runtime(), 1);
|
|
667662
668474
|
});
|
|
@@ -667940,7 +668752,7 @@ var init_performStartupChecks = __esm(() => {
|
|
|
667940
668752
|
|
|
667941
668753
|
// src/components/AwsAuthStatusBox.tsx
|
|
667942
668754
|
function AwsAuthStatusBox() {
|
|
667943
|
-
const $3 =
|
|
668755
|
+
const $3 = import_compiler_runtime336.c(11);
|
|
667944
668756
|
let t0;
|
|
667945
668757
|
if ($3[0] === Symbol.for("react.memo_cache_sentinel")) {
|
|
667946
668758
|
t0 = AwsAuthStatusManager.getInstance().getStatus();
|
|
@@ -667986,7 +668798,7 @@ function AwsAuthStatusBox() {
|
|
|
667986
668798
|
t4 = status2.output.length > 0 && /* @__PURE__ */ jsx_dev_runtime444.jsxDEV(ThemedBox_default, {
|
|
667987
668799
|
flexDirection: "column",
|
|
667988
668800
|
marginTop: 1,
|
|
667989
|
-
children: status2.output.slice(-5).map(
|
|
668801
|
+
children: status2.output.slice(-5).map(_temp204)
|
|
667990
668802
|
}, undefined, false, undefined, this);
|
|
667991
668803
|
$3[4] = status2.output;
|
|
667992
668804
|
$3[5] = t4;
|
|
@@ -668029,7 +668841,7 @@ function AwsAuthStatusBox() {
|
|
|
668029
668841
|
}
|
|
668030
668842
|
return t6;
|
|
668031
668843
|
}
|
|
668032
|
-
function
|
|
668844
|
+
function _temp204(line, index) {
|
|
668033
668845
|
const m3 = line.match(URL_RE);
|
|
668034
668846
|
if (!m3) {
|
|
668035
668847
|
return /* @__PURE__ */ jsx_dev_runtime444.jsxDEV(ThemedText, {
|
|
@@ -668053,11 +668865,11 @@ function _temp205(line, index) {
|
|
|
668053
668865
|
]
|
|
668054
668866
|
}, index, true, undefined, this);
|
|
668055
668867
|
}
|
|
668056
|
-
var
|
|
668868
|
+
var import_compiler_runtime336, import_react298, jsx_dev_runtime444, URL_RE;
|
|
668057
668869
|
var init_AwsAuthStatusBox = __esm(() => {
|
|
668058
668870
|
init_ink2();
|
|
668059
668871
|
init_awsAuthStatusManager();
|
|
668060
|
-
|
|
668872
|
+
import_compiler_runtime336 = __toESM(require_compiler_runtime(), 1);
|
|
668061
668873
|
import_react298 = __toESM(require_react(), 1);
|
|
668062
668874
|
jsx_dev_runtime444 = __toESM(require_jsx_dev_runtime(), 1);
|
|
668063
668875
|
URL_RE = /https?:\/\/\S+/;
|
|
@@ -668065,7 +668877,7 @@ var init_AwsAuthStatusBox = __esm(() => {
|
|
|
668065
668877
|
|
|
668066
668878
|
// src/hooks/notifs/useRateLimitWarningNotification.tsx
|
|
668067
668879
|
function useRateLimitWarningNotification(model) {
|
|
668068
|
-
const $3 =
|
|
668880
|
+
const $3 = import_compiler_runtime337.c(17);
|
|
668069
668881
|
const {
|
|
668070
668882
|
addNotification
|
|
668071
668883
|
} = useNotifications();
|
|
@@ -668172,7 +668984,7 @@ function useRateLimitWarningNotification(model) {
|
|
|
668172
668984
|
}
|
|
668173
668985
|
import_react299.useEffect(t6, t7);
|
|
668174
668986
|
}
|
|
668175
|
-
var
|
|
668987
|
+
var import_compiler_runtime337, import_react299, jsx_dev_runtime445;
|
|
668176
668988
|
var init_useRateLimitWarningNotification = __esm(() => {
|
|
668177
668989
|
init_notifications();
|
|
668178
668990
|
init_ink2();
|
|
@@ -668181,7 +668993,7 @@ var init_useRateLimitWarningNotification = __esm(() => {
|
|
|
668181
668993
|
init_auth();
|
|
668182
668994
|
init_billing();
|
|
668183
668995
|
init_state();
|
|
668184
|
-
|
|
668996
|
+
import_compiler_runtime337 = __toESM(require_compiler_runtime(), 1);
|
|
668185
668997
|
import_react299 = __toESM(require_react(), 1);
|
|
668186
668998
|
jsx_dev_runtime445 = __toESM(require_jsx_dev_runtime(), 1);
|
|
668187
668999
|
});
|
|
@@ -668249,7 +669061,7 @@ var init_deprecation = __esm(() => {
|
|
|
668249
669061
|
|
|
668250
669062
|
// src/hooks/notifs/useDeprecationWarningNotification.tsx
|
|
668251
669063
|
function useDeprecationWarningNotification(model) {
|
|
668252
|
-
const $3 =
|
|
669064
|
+
const $3 = import_compiler_runtime338.c(4);
|
|
668253
669065
|
const {
|
|
668254
669066
|
addNotification
|
|
668255
669067
|
} = useNotifications();
|
|
@@ -668286,20 +669098,20 @@ function useDeprecationWarningNotification(model) {
|
|
|
668286
669098
|
}
|
|
668287
669099
|
import_react300.useEffect(t0, t1);
|
|
668288
669100
|
}
|
|
668289
|
-
var
|
|
669101
|
+
var import_compiler_runtime338, import_react300;
|
|
668290
669102
|
var init_useDeprecationWarningNotification = __esm(() => {
|
|
668291
669103
|
init_notifications();
|
|
668292
669104
|
init_deprecation();
|
|
668293
669105
|
init_state();
|
|
668294
|
-
|
|
669106
|
+
import_compiler_runtime338 = __toESM(require_compiler_runtime(), 1);
|
|
668295
669107
|
import_react300 = __toESM(require_react(), 1);
|
|
668296
669108
|
});
|
|
668297
669109
|
|
|
668298
669110
|
// src/hooks/notifs/useNpmDeprecationNotification.tsx
|
|
668299
669111
|
function useNpmDeprecationNotification() {
|
|
668300
|
-
useStartupNotification(
|
|
669112
|
+
useStartupNotification(_temp205);
|
|
668301
669113
|
}
|
|
668302
|
-
async function
|
|
669114
|
+
async function _temp205() {
|
|
668303
669115
|
return null;
|
|
668304
669116
|
}
|
|
668305
669117
|
var init_useNpmDeprecationNotification = __esm(() => {
|
|
@@ -668308,7 +669120,7 @@ var init_useNpmDeprecationNotification = __esm(() => {
|
|
|
668308
669120
|
|
|
668309
669121
|
// src/hooks/notifs/useIDEStatusIndicator.tsx
|
|
668310
669122
|
function useIDEStatusIndicator(t0) {
|
|
668311
|
-
const $3 =
|
|
669123
|
+
const $3 = import_compiler_runtime339.c(26);
|
|
668312
669124
|
const {
|
|
668313
669125
|
ideSelection,
|
|
668314
669126
|
mcpClients,
|
|
@@ -668461,7 +669273,7 @@ function _temp287(hasShownHintRef_0, addNotification_0) {
|
|
|
668461
669273
|
const ideName_0 = infos[0]?.name;
|
|
668462
669274
|
if (ideName_0 && !hasShownHintRef_0.current) {
|
|
668463
669275
|
hasShownHintRef_0.current = true;
|
|
668464
|
-
saveGlobalConfig(
|
|
669276
|
+
saveGlobalConfig(_temp206);
|
|
668465
669277
|
addNotification_0({
|
|
668466
669278
|
key: "ide-status-hint",
|
|
668467
669279
|
jsx: /* @__PURE__ */ jsx_dev_runtime446.jsxDEV(ThemedText, {
|
|
@@ -668479,13 +669291,13 @@ function _temp287(hasShownHintRef_0, addNotification_0) {
|
|
|
668479
669291
|
}
|
|
668480
669292
|
});
|
|
668481
669293
|
}
|
|
668482
|
-
function
|
|
669294
|
+
function _temp206(current) {
|
|
668483
669295
|
return {
|
|
668484
669296
|
...current,
|
|
668485
669297
|
ideHintShownCount: (current.ideHintShownCount ?? 0) + 1
|
|
668486
669298
|
};
|
|
668487
669299
|
}
|
|
668488
|
-
var
|
|
669300
|
+
var import_compiler_runtime339, import_react301, jsx_dev_runtime446, MAX_IDE_HINT_SHOW_COUNT = 5;
|
|
668489
669301
|
var init_useIDEStatusIndicator = __esm(() => {
|
|
668490
669302
|
init_notifications();
|
|
668491
669303
|
init_ink2();
|
|
@@ -668493,16 +669305,16 @@ var init_useIDEStatusIndicator = __esm(() => {
|
|
|
668493
669305
|
init_ide();
|
|
668494
669306
|
init_state();
|
|
668495
669307
|
init_useIdeConnectionStatus();
|
|
668496
|
-
|
|
669308
|
+
import_compiler_runtime339 = __toESM(require_compiler_runtime(), 1);
|
|
668497
669309
|
import_react301 = __toESM(require_react(), 1);
|
|
668498
669310
|
jsx_dev_runtime446 = __toESM(require_jsx_dev_runtime(), 1);
|
|
668499
669311
|
});
|
|
668500
669312
|
|
|
668501
669313
|
// src/hooks/notifs/useModelMigrationNotifications.tsx
|
|
668502
669314
|
function useModelMigrationNotifications() {
|
|
668503
|
-
useStartupNotification(
|
|
669315
|
+
useStartupNotification(_temp207);
|
|
668504
669316
|
}
|
|
668505
|
-
function
|
|
669317
|
+
function _temp207() {
|
|
668506
669318
|
const config5 = getGlobalConfig();
|
|
668507
669319
|
const notifs = [];
|
|
668508
669320
|
for (const migration of MIGRATIONS) {
|
|
@@ -668621,11 +669433,11 @@ var init_useTeammateShutdownNotification = __esm(() => {
|
|
|
668621
669433
|
|
|
668622
669434
|
// src/hooks/notifs/useFastModeNotification.tsx
|
|
668623
669435
|
function useFastModeNotification() {
|
|
668624
|
-
const $3 =
|
|
669436
|
+
const $3 = import_compiler_runtime340.c(13);
|
|
668625
669437
|
const {
|
|
668626
669438
|
addNotification
|
|
668627
669439
|
} = useNotifications();
|
|
668628
|
-
const isFastMode = useAppState(
|
|
669440
|
+
const isFastMode = useAppState(_temp208);
|
|
668629
669441
|
const setAppState = useSetAppState();
|
|
668630
669442
|
let t0;
|
|
668631
669443
|
let t1;
|
|
@@ -668759,7 +669571,7 @@ function _temp288(prev) {
|
|
|
668759
669571
|
fastMode: false
|
|
668760
669572
|
};
|
|
668761
669573
|
}
|
|
668762
|
-
function
|
|
669574
|
+
function _temp208(s2) {
|
|
668763
669575
|
return s2.fastMode;
|
|
668764
669576
|
}
|
|
668765
669577
|
function getCooldownMessage(reason, resetIn) {
|
|
@@ -668770,20 +669582,20 @@ function getCooldownMessage(reason, resetIn) {
|
|
|
668770
669582
|
return `Fast limit reached and temporarily disabled · resets in ${resetIn}`;
|
|
668771
669583
|
}
|
|
668772
669584
|
}
|
|
668773
|
-
var
|
|
669585
|
+
var import_compiler_runtime340, import_react303, COOLDOWN_STARTED_KEY = "fast-mode-cooldown-started", COOLDOWN_EXPIRED_KEY = "fast-mode-cooldown-expired", ORG_CHANGED_KEY = "fast-mode-org-changed", OVERAGE_REJECTED_KEY = "fast-mode-overage-rejected";
|
|
668774
669586
|
var init_useFastModeNotification = __esm(() => {
|
|
668775
669587
|
init_notifications();
|
|
668776
669588
|
init_AppState();
|
|
668777
669589
|
init_fastMode();
|
|
668778
669590
|
init_format();
|
|
668779
669591
|
init_state();
|
|
668780
|
-
|
|
669592
|
+
import_compiler_runtime340 = __toESM(require_compiler_runtime(), 1);
|
|
668781
669593
|
import_react303 = __toESM(require_react(), 1);
|
|
668782
669594
|
});
|
|
668783
669595
|
|
|
668784
669596
|
// src/utils/autoRunIssue.tsx
|
|
668785
669597
|
function AutoRunIssueNotification(t0) {
|
|
668786
|
-
const $3 =
|
|
669598
|
+
const $3 = import_compiler_runtime341.c(8);
|
|
668787
669599
|
const {
|
|
668788
669600
|
onRun,
|
|
668789
669601
|
onCancel,
|
|
@@ -668902,12 +669714,12 @@ function getAutoRunIssueReasonText(reason) {
|
|
|
668902
669714
|
return "Unknown reason";
|
|
668903
669715
|
}
|
|
668904
669716
|
}
|
|
668905
|
-
var
|
|
669717
|
+
var import_compiler_runtime341, import_react304, jsx_dev_runtime447;
|
|
668906
669718
|
var init_autoRunIssue = __esm(() => {
|
|
668907
669719
|
init_KeyboardShortcutHint();
|
|
668908
669720
|
init_ink2();
|
|
668909
669721
|
init_useKeybinding();
|
|
668910
|
-
|
|
669722
|
+
import_compiler_runtime341 = __toESM(require_compiler_runtime(), 1);
|
|
668911
669723
|
import_react304 = __toESM(require_react(), 1);
|
|
668912
669724
|
jsx_dev_runtime447 = __toESM(require_jsx_dev_runtime(), 1);
|
|
668913
669725
|
});
|
|
@@ -669021,18 +669833,18 @@ var init_useIssueFlagBanner = __esm(() => {
|
|
|
669021
669833
|
});
|
|
669022
669834
|
|
|
669023
669835
|
// src/components/DevBar.tsx
|
|
669024
|
-
var
|
|
669836
|
+
var import_compiler_runtime342, import_react306, jsx_dev_runtime448;
|
|
669025
669837
|
var init_DevBar = __esm(() => {
|
|
669026
669838
|
init_state();
|
|
669027
669839
|
init_ink2();
|
|
669028
|
-
|
|
669840
|
+
import_compiler_runtime342 = __toESM(require_compiler_runtime(), 1);
|
|
669029
669841
|
import_react306 = __toESM(require_react(), 1);
|
|
669030
669842
|
jsx_dev_runtime448 = __toESM(require_jsx_dev_runtime(), 1);
|
|
669031
669843
|
});
|
|
669032
669844
|
|
|
669033
669845
|
// src/ink/components/AlternateScreen.tsx
|
|
669034
669846
|
function AlternateScreen(t0) {
|
|
669035
|
-
const $3 =
|
|
669847
|
+
const $3 = import_compiler_runtime343.c(7);
|
|
669036
669848
|
const {
|
|
669037
669849
|
children,
|
|
669038
669850
|
mouseTracking: t1
|
|
@@ -669084,14 +669896,14 @@ function AlternateScreen(t0) {
|
|
|
669084
669896
|
}
|
|
669085
669897
|
return t5;
|
|
669086
669898
|
}
|
|
669087
|
-
var
|
|
669899
|
+
var import_compiler_runtime343, import_react307, jsx_dev_runtime449;
|
|
669088
669900
|
var init_AlternateScreen = __esm(() => {
|
|
669089
669901
|
init_instances();
|
|
669090
669902
|
init_dec();
|
|
669091
669903
|
init_useTerminalNotification();
|
|
669092
669904
|
init_Box();
|
|
669093
669905
|
init_TerminalSizeContext();
|
|
669094
|
-
|
|
669906
|
+
import_compiler_runtime343 = __toESM(require_compiler_runtime(), 1);
|
|
669095
669907
|
import_react307 = __toESM(require_react(), 1);
|
|
669096
669908
|
jsx_dev_runtime449 = __toESM(require_jsx_dev_runtime(), 1);
|
|
669097
669909
|
});
|
|
@@ -669731,7 +670543,7 @@ import { tmpdir as tmpdir16 } from "os";
|
|
|
669731
670543
|
import { writeFile as writeFile47 } from "fs/promises";
|
|
669732
670544
|
import { randomUUID as randomUUID52 } from "crypto";
|
|
669733
670545
|
function TranscriptModeFooter(t0) {
|
|
669734
|
-
const $3 =
|
|
670546
|
+
const $3 = import_compiler_runtime344.c(9);
|
|
669735
670547
|
const {
|
|
669736
670548
|
showAllInTranscript,
|
|
669737
670549
|
virtualScroll,
|
|
@@ -669928,7 +670740,7 @@ function TranscriptSearchBar({
|
|
|
669928
670740
|
}, undefined, true, undefined, this);
|
|
669929
670741
|
}
|
|
669930
670742
|
function AnimatedTerminalTitle(t0) {
|
|
669931
|
-
const $3 =
|
|
670743
|
+
const $3 = import_compiler_runtime344.c(6);
|
|
669932
670744
|
const {
|
|
669933
670745
|
isAnimating,
|
|
669934
670746
|
title,
|
|
@@ -669964,9 +670776,9 @@ function AnimatedTerminalTitle(t0) {
|
|
|
669964
670776
|
return null;
|
|
669965
670777
|
}
|
|
669966
670778
|
function _temp289(setFrame_0) {
|
|
669967
|
-
return setFrame_0(
|
|
670779
|
+
return setFrame_0(_temp209);
|
|
669968
670780
|
}
|
|
669969
|
-
function
|
|
670781
|
+
function _temp209(f3) {
|
|
669970
670782
|
return (f3 + 1) % TITLE_ANIMATION_FRAMES.length;
|
|
669971
670783
|
}
|
|
669972
670784
|
function REPL({
|
|
@@ -673100,7 +673912,7 @@ Note: ctrl + z now suspends RAYU, ctrl + _ undoes input.
|
|
|
673100
673912
|
}
|
|
673101
673913
|
return mainReturn;
|
|
673102
673914
|
}
|
|
673103
|
-
var
|
|
673915
|
+
var import_compiler_runtime344, React151, import_react310, jsx_dev_runtime450, useFrustrationDetection = () => ({
|
|
673104
673916
|
state: "closed",
|
|
673105
673917
|
handleTranscriptSelect: () => {}
|
|
673106
673918
|
}), useAntOrgWarningNotification = () => {}, getCoordinatorUserContext = () => ({}), proactiveModule5 = null, PROACTIVE_NO_OP_SUBSCRIBE = (_cb) => () => {}, PROACTIVE_FALSE = () => false, SUGGEST_BG_PR_NOOP = (_p, _n) => false, EMPTY_MCP_CLIENTS2, HISTORY_STUB, RECENT_SCROLL_REPIN_WINDOW_MS = 3000, TITLE_ANIMATION_FRAMES, TITLE_STATIC_PREFIX = "✳", TITLE_ANIMATION_INTERVAL_MS = 960;
|
|
@@ -673306,7 +674118,7 @@ var init_REPL = __esm(() => {
|
|
|
673306
674118
|
init_osc();
|
|
673307
674119
|
init_attachments2();
|
|
673308
674120
|
init_pendingFileChanges();
|
|
673309
|
-
|
|
674121
|
+
import_compiler_runtime344 = __toESM(require_compiler_runtime(), 1);
|
|
673310
674122
|
React151 = __toESM(require_react(), 1);
|
|
673311
674123
|
import_react310 = __toESM(require_react(), 1);
|
|
673312
674124
|
jsx_dev_runtime450 = __toESM(require_jsx_dev_runtime(), 1);
|
|
@@ -673757,7 +674569,7 @@ var init_grove = __esm(() => {
|
|
|
673757
674569
|
|
|
673758
674570
|
// src/components/MCPServerDialogCopy.tsx
|
|
673759
674571
|
function MCPServerDialogCopy() {
|
|
673760
|
-
const $3 =
|
|
674572
|
+
const $3 = import_compiler_runtime345.c(1);
|
|
673761
674573
|
let t0;
|
|
673762
674574
|
if ($3[0] === Symbol.for("react.memo_cache_sentinel")) {
|
|
673763
674575
|
t0 = /* @__PURE__ */ jsx_dev_runtime452.jsxDEV(ThemedText, {
|
|
@@ -673777,16 +674589,16 @@ function MCPServerDialogCopy() {
|
|
|
673777
674589
|
}
|
|
673778
674590
|
return t0;
|
|
673779
674591
|
}
|
|
673780
|
-
var
|
|
674592
|
+
var import_compiler_runtime345, jsx_dev_runtime452;
|
|
673781
674593
|
var init_MCPServerDialogCopy = __esm(() => {
|
|
673782
674594
|
init_ink2();
|
|
673783
|
-
|
|
674595
|
+
import_compiler_runtime345 = __toESM(require_compiler_runtime(), 1);
|
|
673784
674596
|
jsx_dev_runtime452 = __toESM(require_jsx_dev_runtime(), 1);
|
|
673785
674597
|
});
|
|
673786
674598
|
|
|
673787
674599
|
// src/components/MCPServerApprovalDialog.tsx
|
|
673788
674600
|
function MCPServerApprovalDialog(t0) {
|
|
673789
|
-
const $3 =
|
|
674601
|
+
const $3 = import_compiler_runtime346.c(13);
|
|
673790
674602
|
const {
|
|
673791
674603
|
serverName,
|
|
673792
674604
|
onDone
|
|
@@ -673899,20 +674711,20 @@ function MCPServerApprovalDialog(t0) {
|
|
|
673899
674711
|
}
|
|
673900
674712
|
return t7;
|
|
673901
674713
|
}
|
|
673902
|
-
var
|
|
674714
|
+
var import_compiler_runtime346, jsx_dev_runtime453;
|
|
673903
674715
|
var init_MCPServerApprovalDialog = __esm(() => {
|
|
673904
674716
|
init_analytics();
|
|
673905
674717
|
init_settings2();
|
|
673906
674718
|
init_CustomSelect();
|
|
673907
674719
|
init_Dialog();
|
|
673908
674720
|
init_MCPServerDialogCopy();
|
|
673909
|
-
|
|
674721
|
+
import_compiler_runtime346 = __toESM(require_compiler_runtime(), 1);
|
|
673910
674722
|
jsx_dev_runtime453 = __toESM(require_jsx_dev_runtime(), 1);
|
|
673911
674723
|
});
|
|
673912
674724
|
|
|
673913
674725
|
// src/components/MCPServerMultiselectDialog.tsx
|
|
673914
674726
|
function MCPServerMultiselectDialog(t0) {
|
|
673915
|
-
const $3 =
|
|
674727
|
+
const $3 = import_compiler_runtime347.c(21);
|
|
673916
674728
|
const {
|
|
673917
674729
|
serverNames,
|
|
673918
674730
|
onDone
|
|
@@ -673977,7 +674789,7 @@ function MCPServerMultiselectDialog(t0) {
|
|
|
673977
674789
|
}
|
|
673978
674790
|
let t5;
|
|
673979
674791
|
if ($3[7] !== serverNames) {
|
|
673980
|
-
t5 = serverNames.map(
|
|
674792
|
+
t5 = serverNames.map(_temp221);
|
|
673981
674793
|
$3[7] = serverNames;
|
|
673982
674794
|
$3[8] = t5;
|
|
673983
674795
|
} else {
|
|
@@ -674066,13 +674878,13 @@ function MCPServerMultiselectDialog(t0) {
|
|
|
674066
674878
|
}
|
|
674067
674879
|
return t9;
|
|
674068
674880
|
}
|
|
674069
|
-
function
|
|
674881
|
+
function _temp221(server_0) {
|
|
674070
674882
|
return {
|
|
674071
674883
|
label: server_0,
|
|
674072
674884
|
value: server_0
|
|
674073
674885
|
};
|
|
674074
674886
|
}
|
|
674075
|
-
var
|
|
674887
|
+
var import_compiler_runtime347, jsx_dev_runtime454;
|
|
674076
674888
|
var init_MCPServerMultiselectDialog = __esm(() => {
|
|
674077
674889
|
init_partition();
|
|
674078
674890
|
init_analytics();
|
|
@@ -674084,7 +674896,7 @@ var init_MCPServerMultiselectDialog = __esm(() => {
|
|
|
674084
674896
|
init_Dialog();
|
|
674085
674897
|
init_KeyboardShortcutHint();
|
|
674086
674898
|
init_MCPServerDialogCopy();
|
|
674087
|
-
|
|
674899
|
+
import_compiler_runtime347 = __toESM(require_compiler_runtime(), 1);
|
|
674088
674900
|
jsx_dev_runtime454 = __toESM(require_jsx_dev_runtime(), 1);
|
|
674089
674901
|
});
|
|
674090
674902
|
|
|
@@ -674291,7 +675103,7 @@ function WelcomeV2() {
|
|
|
674291
675103
|
dimColor: true,
|
|
674292
675104
|
children: [
|
|
674293
675105
|
"v",
|
|
674294
|
-
"1.3.
|
|
675106
|
+
"1.3.327"
|
|
674295
675107
|
]
|
|
674296
675108
|
}, undefined, true, undefined, this)
|
|
674297
675109
|
]
|
|
@@ -674315,7 +675127,7 @@ var init_WelcomeV2 = __esm(() => {
|
|
|
674315
675127
|
|
|
674316
675128
|
// src/components/ui/OrderedListItem.tsx
|
|
674317
675129
|
function OrderedListItem(t0) {
|
|
674318
|
-
const $3 =
|
|
675130
|
+
const $3 = import_compiler_runtime348.c(7);
|
|
674319
675131
|
const {
|
|
674320
675132
|
children
|
|
674321
675133
|
} = t0;
|
|
@@ -674361,10 +675173,10 @@ function OrderedListItem(t0) {
|
|
|
674361
675173
|
}
|
|
674362
675174
|
return t3;
|
|
674363
675175
|
}
|
|
674364
|
-
var
|
|
675176
|
+
var import_compiler_runtime348, import_react311, jsx_dev_runtime457, OrderedListItemContext;
|
|
674365
675177
|
var init_OrderedListItem = __esm(() => {
|
|
674366
675178
|
init_ink2();
|
|
674367
|
-
|
|
675179
|
+
import_compiler_runtime348 = __toESM(require_compiler_runtime(), 1);
|
|
674368
675180
|
import_react311 = __toESM(require_react(), 1);
|
|
674369
675181
|
jsx_dev_runtime457 = __toESM(require_jsx_dev_runtime(), 1);
|
|
674370
675182
|
OrderedListItemContext = import_react311.createContext({
|
|
@@ -674374,7 +675186,7 @@ var init_OrderedListItem = __esm(() => {
|
|
|
674374
675186
|
|
|
674375
675187
|
// src/components/ui/OrderedList.tsx
|
|
674376
675188
|
function OrderedListComponent(t0) {
|
|
674377
|
-
const $3 =
|
|
675189
|
+
const $3 = import_compiler_runtime349.c(9);
|
|
674378
675190
|
const {
|
|
674379
675191
|
children
|
|
674380
675192
|
} = t0;
|
|
@@ -674438,11 +675250,11 @@ function OrderedListComponent(t0) {
|
|
|
674438
675250
|
}
|
|
674439
675251
|
return t2;
|
|
674440
675252
|
}
|
|
674441
|
-
var
|
|
675253
|
+
var import_compiler_runtime349, import_react312, jsx_dev_runtime458, OrderedListContext, OrderedList;
|
|
674442
675254
|
var init_OrderedList = __esm(() => {
|
|
674443
675255
|
init_ink2();
|
|
674444
675256
|
init_OrderedListItem();
|
|
674445
|
-
|
|
675257
|
+
import_compiler_runtime349 = __toESM(require_compiler_runtime(), 1);
|
|
674446
675258
|
import_react312 = __toESM(require_react(), 1);
|
|
674447
675259
|
jsx_dev_runtime458 = __toESM(require_jsx_dev_runtime(), 1);
|
|
674448
675260
|
OrderedListContext = import_react312.createContext({
|
|
@@ -674822,7 +675634,7 @@ __export(exports_TrustDialog, {
|
|
|
674822
675634
|
});
|
|
674823
675635
|
import { homedir as homedir37 } from "os";
|
|
674824
675636
|
function TrustDialog(t0) {
|
|
674825
|
-
const $3 =
|
|
675637
|
+
const $3 = import_compiler_runtime350.c(33);
|
|
674826
675638
|
const {
|
|
674827
675639
|
onDone,
|
|
674828
675640
|
commands
|
|
@@ -675136,12 +675948,12 @@ function _temp355(tool_0) {
|
|
|
675136
675948
|
return tool_0 === BASH_TOOL_NAME || tool_0.startsWith(BASH_TOOL_NAME + "(");
|
|
675137
675949
|
}
|
|
675138
675950
|
function _temp290(command10) {
|
|
675139
|
-
return command10.type === "prompt" && command10.loadedFrom === "commands_DEPRECATED" && (command10.source === "projectSettings" || command10.source === "localSettings") && command10.allowedTools?.some(
|
|
675951
|
+
return command10.type === "prompt" && command10.loadedFrom === "commands_DEPRECATED" && (command10.source === "projectSettings" || command10.source === "localSettings") && command10.allowedTools?.some(_temp224);
|
|
675140
675952
|
}
|
|
675141
|
-
function
|
|
675953
|
+
function _temp224(tool) {
|
|
675142
675954
|
return tool === BASH_TOOL_NAME || tool.startsWith(BASH_TOOL_NAME + "(");
|
|
675143
675955
|
}
|
|
675144
|
-
var
|
|
675956
|
+
var import_compiler_runtime350, import_react314, jsx_dev_runtime460;
|
|
675145
675957
|
var init_TrustDialog = __esm(() => {
|
|
675146
675958
|
init_analytics();
|
|
675147
675959
|
init_state();
|
|
@@ -675156,7 +675968,7 @@ var init_TrustDialog = __esm(() => {
|
|
|
675156
675968
|
init_CustomSelect();
|
|
675157
675969
|
init_PermissionDialog();
|
|
675158
675970
|
init_utils18();
|
|
675159
|
-
|
|
675971
|
+
import_compiler_runtime350 = __toESM(require_compiler_runtime(), 1);
|
|
675160
675972
|
import_react314 = __toESM(require_react(), 1);
|
|
675161
675973
|
jsx_dev_runtime460 = __toESM(require_jsx_dev_runtime(), 1);
|
|
675162
675974
|
});
|
|
@@ -675168,7 +675980,7 @@ __export(exports_Grove, {
|
|
|
675168
675980
|
GroveDialog: () => GroveDialog
|
|
675169
675981
|
});
|
|
675170
675982
|
function GracePeriodContentBody() {
|
|
675171
|
-
const $3 =
|
|
675983
|
+
const $3 = import_compiler_runtime351.c(9);
|
|
675172
675984
|
let t0;
|
|
675173
675985
|
if ($3[0] === Symbol.for("react.memo_cache_sentinel")) {
|
|
675174
675986
|
t0 = /* @__PURE__ */ jsx_dev_runtime461.jsxDEV(ThemedText, {
|
|
@@ -675311,7 +676123,7 @@ function GracePeriodContentBody() {
|
|
|
675311
676123
|
return t8;
|
|
675312
676124
|
}
|
|
675313
676125
|
function PostGracePeriodContentBody() {
|
|
675314
|
-
const $3 =
|
|
676126
|
+
const $3 = import_compiler_runtime351.c(7);
|
|
675315
676127
|
let t0;
|
|
675316
676128
|
if ($3[0] === Symbol.for("react.memo_cache_sentinel")) {
|
|
675317
676129
|
t0 = /* @__PURE__ */ jsx_dev_runtime461.jsxDEV(ThemedText, {
|
|
@@ -675423,7 +676235,7 @@ function PostGracePeriodContentBody() {
|
|
|
675423
676235
|
return t6;
|
|
675424
676236
|
}
|
|
675425
676237
|
function GroveDialog(t0) {
|
|
675426
|
-
const $3 =
|
|
676238
|
+
const $3 = import_compiler_runtime351.c(34);
|
|
675427
676239
|
const {
|
|
675428
676240
|
showIfAlreadyViewed,
|
|
675429
676241
|
location,
|
|
@@ -675657,7 +676469,7 @@ function GroveDialog(t0) {
|
|
|
675657
676469
|
title: "Updates to Consumer Terms and Policies",
|
|
675658
676470
|
color: "professionalBlue",
|
|
675659
676471
|
onCancel: handleCancel,
|
|
675660
|
-
inputGuide:
|
|
676472
|
+
inputGuide: _temp234,
|
|
675661
676473
|
children: [
|
|
675662
676474
|
t8,
|
|
675663
676475
|
t13
|
|
@@ -675672,7 +676484,7 @@ function GroveDialog(t0) {
|
|
|
675672
676484
|
}
|
|
675673
676485
|
return t14;
|
|
675674
676486
|
}
|
|
675675
|
-
function
|
|
676487
|
+
function _temp234(exitState) {
|
|
675676
676488
|
return exitState.pending ? /* @__PURE__ */ jsx_dev_runtime461.jsxDEV(ThemedText, {
|
|
675677
676489
|
children: [
|
|
675678
676490
|
"Press ",
|
|
@@ -675693,7 +676505,7 @@ function _temp244(exitState) {
|
|
|
675693
676505
|
}, undefined, true, undefined, this);
|
|
675694
676506
|
}
|
|
675695
676507
|
function PrivacySettingsDialog(t0) {
|
|
675696
|
-
const $3 =
|
|
676508
|
+
const $3 = import_compiler_runtime351.c(17);
|
|
675697
676509
|
const {
|
|
675698
676510
|
settings,
|
|
675699
676511
|
domainExcluded,
|
|
@@ -675857,7 +676669,7 @@ function PrivacySettingsDialog(t0) {
|
|
|
675857
676669
|
function _temp291() {
|
|
675858
676670
|
logEvent("tengu_grove_privacy_settings_viewed", {});
|
|
675859
676671
|
}
|
|
675860
|
-
var
|
|
676672
|
+
var import_compiler_runtime351, import_react315, jsx_dev_runtime461, NEW_TERMS_ASCII = ` _____________
|
|
675861
676673
|
| \\ \\
|
|
675862
676674
|
| NEW TERMS \\__\\
|
|
675863
676675
|
| |
|
|
@@ -675876,7 +676688,7 @@ var init_Grove = __esm(() => {
|
|
|
675876
676688
|
init_Byline();
|
|
675877
676689
|
init_Dialog();
|
|
675878
676690
|
init_KeyboardShortcutHint();
|
|
675879
|
-
|
|
676691
|
+
import_compiler_runtime351 = __toESM(require_compiler_runtime(), 1);
|
|
675880
676692
|
import_react315 = __toESM(require_react(), 1);
|
|
675881
676693
|
jsx_dev_runtime461 = __toESM(require_jsx_dev_runtime(), 1);
|
|
675882
676694
|
});
|
|
@@ -675887,7 +676699,7 @@ __export(exports_BypassPermissionsModeDialog, {
|
|
|
675887
676699
|
BypassPermissionsModeDialog: () => BypassPermissionsModeDialog
|
|
675888
676700
|
});
|
|
675889
676701
|
function BypassPermissionsModeDialog(t0) {
|
|
675890
|
-
const $3 =
|
|
676702
|
+
const $3 = import_compiler_runtime352.c(7);
|
|
675891
676703
|
const {
|
|
675892
676704
|
onAccept
|
|
675893
676705
|
} = t0;
|
|
@@ -675898,7 +676710,7 @@ function BypassPermissionsModeDialog(t0) {
|
|
|
675898
676710
|
} else {
|
|
675899
676711
|
t1 = $3[0];
|
|
675900
676712
|
}
|
|
675901
|
-
import_react316.default.useEffect(
|
|
676713
|
+
import_react316.default.useEffect(_temp244, t1);
|
|
675902
676714
|
let t2;
|
|
675903
676715
|
if ($3[1] !== onAccept) {
|
|
675904
676716
|
t2 = function onChange2(value) {
|
|
@@ -675986,10 +676798,10 @@ function BypassPermissionsModeDialog(t0) {
|
|
|
675986
676798
|
function _temp292() {
|
|
675987
676799
|
gracefulShutdownSync(0);
|
|
675988
676800
|
}
|
|
675989
|
-
function
|
|
676801
|
+
function _temp244() {
|
|
675990
676802
|
logEvent("tengu_bypass_permissions_mode_dialog_shown", {});
|
|
675991
676803
|
}
|
|
675992
|
-
var
|
|
676804
|
+
var import_compiler_runtime352, import_react316, jsx_dev_runtime462;
|
|
675993
676805
|
var init_BypassPermissionsModeDialog = __esm(() => {
|
|
675994
676806
|
init_analytics();
|
|
675995
676807
|
init_ink2();
|
|
@@ -675997,7 +676809,7 @@ var init_BypassPermissionsModeDialog = __esm(() => {
|
|
|
675997
676809
|
init_settings2();
|
|
675998
676810
|
init_CustomSelect();
|
|
675999
676811
|
init_Dialog();
|
|
676000
|
-
|
|
676812
|
+
import_compiler_runtime352 = __toESM(require_compiler_runtime(), 1);
|
|
676001
676813
|
import_react316 = __toESM(require_react(), 1);
|
|
676002
676814
|
jsx_dev_runtime462 = __toESM(require_jsx_dev_runtime(), 1);
|
|
676003
676815
|
});
|
|
@@ -676008,7 +676820,7 @@ function completeOnboarding() {
|
|
|
676008
676820
|
saveGlobalConfig((current) => ({
|
|
676009
676821
|
...current,
|
|
676010
676822
|
hasCompletedOnboarding: true,
|
|
676011
|
-
lastOnboardingVersion: "1.3.
|
|
676823
|
+
lastOnboardingVersion: "1.3.327"
|
|
676012
676824
|
}));
|
|
676013
676825
|
}
|
|
676014
676826
|
function showDialog(root2, renderer) {
|
|
@@ -676219,7 +677031,7 @@ __export(exports_InvalidSettingsDialog, {
|
|
|
676219
677031
|
InvalidSettingsDialog: () => InvalidSettingsDialog
|
|
676220
677032
|
});
|
|
676221
677033
|
function InvalidSettingsDialog(t0) {
|
|
676222
|
-
const $3 =
|
|
677034
|
+
const $3 = import_compiler_runtime353.c(13);
|
|
676223
677035
|
const {
|
|
676224
677036
|
settingsErrors,
|
|
676225
677037
|
onContinue,
|
|
@@ -676306,19 +677118,19 @@ function InvalidSettingsDialog(t0) {
|
|
|
676306
677118
|
}
|
|
676307
677119
|
return t6;
|
|
676308
677120
|
}
|
|
676309
|
-
var
|
|
677121
|
+
var import_compiler_runtime353, jsx_dev_runtime464;
|
|
676310
677122
|
var init_InvalidSettingsDialog = __esm(() => {
|
|
676311
677123
|
init_ink2();
|
|
676312
677124
|
init_CustomSelect();
|
|
676313
677125
|
init_Dialog();
|
|
676314
677126
|
init_ValidationErrorsList();
|
|
676315
|
-
|
|
677127
|
+
import_compiler_runtime353 = __toESM(require_compiler_runtime(), 1);
|
|
676316
677128
|
jsx_dev_runtime464 = __toESM(require_jsx_dev_runtime(), 1);
|
|
676317
677129
|
});
|
|
676318
677130
|
|
|
676319
677131
|
// src/hooks/useTeleportResume.tsx
|
|
676320
677132
|
function useTeleportResume(source) {
|
|
676321
|
-
const $3 =
|
|
677133
|
+
const $3 = import_compiler_runtime354.c(8);
|
|
676322
677134
|
const [isResuming, setIsResuming] = import_react317.useState(false);
|
|
676323
677135
|
const [error54, setError] = import_react317.useState(null);
|
|
676324
677136
|
const [selectedSession, setSelectedSession] = import_react317.useState(null);
|
|
@@ -676386,13 +677198,13 @@ function useTeleportResume(source) {
|
|
|
676386
677198
|
}
|
|
676387
677199
|
return t2;
|
|
676388
677200
|
}
|
|
676389
|
-
var
|
|
677201
|
+
var import_compiler_runtime354, import_react317;
|
|
676390
677202
|
var init_useTeleportResume = __esm(() => {
|
|
676391
677203
|
init_state();
|
|
676392
677204
|
init_analytics();
|
|
676393
677205
|
init_errors();
|
|
676394
677206
|
init_teleport();
|
|
676395
|
-
|
|
677207
|
+
import_compiler_runtime354 = __toESM(require_compiler_runtime(), 1);
|
|
676396
677208
|
import_react317 = __toESM(require_react(), 1);
|
|
676397
677209
|
});
|
|
676398
677210
|
|
|
@@ -676767,7 +677579,7 @@ __export(exports_TeleportResumeWrapper, {
|
|
|
676767
677579
|
TeleportResumeWrapper: () => TeleportResumeWrapper
|
|
676768
677580
|
});
|
|
676769
677581
|
function TeleportResumeWrapper(t0) {
|
|
676770
|
-
const $3 =
|
|
677582
|
+
const $3 = import_compiler_runtime355.c(25);
|
|
676771
677583
|
const {
|
|
676772
677584
|
onComplete,
|
|
676773
677585
|
onCancel,
|
|
@@ -676965,7 +677777,7 @@ function TeleportResumeWrapper(t0) {
|
|
|
676965
677777
|
}
|
|
676966
677778
|
return t8;
|
|
676967
677779
|
}
|
|
676968
|
-
var
|
|
677780
|
+
var import_compiler_runtime355, import_react319, jsx_dev_runtime466;
|
|
676969
677781
|
var init_TeleportResumeWrapper = __esm(() => {
|
|
676970
677782
|
init_analytics();
|
|
676971
677783
|
init_useTeleportResume();
|
|
@@ -676973,7 +677785,7 @@ var init_TeleportResumeWrapper = __esm(() => {
|
|
|
676973
677785
|
init_useKeybinding();
|
|
676974
677786
|
init_ResumeTask();
|
|
676975
677787
|
init_Spinner2();
|
|
676976
|
-
|
|
677788
|
+
import_compiler_runtime355 = __toESM(require_compiler_runtime(), 1);
|
|
676977
677789
|
import_react319 = __toESM(require_react(), 1);
|
|
676978
677790
|
jsx_dev_runtime466 = __toESM(require_jsx_dev_runtime(), 1);
|
|
676979
677791
|
});
|
|
@@ -676984,7 +677796,7 @@ __export(exports_TeleportRepoMismatchDialog, {
|
|
|
676984
677796
|
TeleportRepoMismatchDialog: () => TeleportRepoMismatchDialog
|
|
676985
677797
|
});
|
|
676986
677798
|
function TeleportRepoMismatchDialog(t0) {
|
|
676987
|
-
const $3 =
|
|
677799
|
+
const $3 = import_compiler_runtime356.c(18);
|
|
676988
677800
|
const {
|
|
676989
677801
|
targetRepo,
|
|
676990
677802
|
initialPaths,
|
|
@@ -677035,7 +677847,7 @@ function TeleportRepoMismatchDialog(t0) {
|
|
|
677035
677847
|
} else {
|
|
677036
677848
|
t32 = $3[7];
|
|
677037
677849
|
}
|
|
677038
|
-
t2 = [...availablePaths.map(
|
|
677850
|
+
t2 = [...availablePaths.map(_temp254), t32];
|
|
677039
677851
|
$3[5] = availablePaths;
|
|
677040
677852
|
$3[6] = t2;
|
|
677041
677853
|
} else {
|
|
@@ -677121,7 +677933,7 @@ function TeleportRepoMismatchDialog(t0) {
|
|
|
677121
677933
|
}
|
|
677122
677934
|
return t4;
|
|
677123
677935
|
}
|
|
677124
|
-
function
|
|
677936
|
+
function _temp254(path30) {
|
|
677125
677937
|
return {
|
|
677126
677938
|
label: /* @__PURE__ */ jsx_dev_runtime467.jsxDEV(ThemedText, {
|
|
677127
677939
|
children: [
|
|
@@ -677135,7 +677947,7 @@ function _temp293(path30) {
|
|
|
677135
677947
|
value: path30
|
|
677136
677948
|
};
|
|
677137
677949
|
}
|
|
677138
|
-
var
|
|
677950
|
+
var import_compiler_runtime356, import_react320, jsx_dev_runtime467;
|
|
677139
677951
|
var init_TeleportRepoMismatchDialog = __esm(() => {
|
|
677140
677952
|
init_ink2();
|
|
677141
677953
|
init_file2();
|
|
@@ -677143,7 +677955,7 @@ var init_TeleportRepoMismatchDialog = __esm(() => {
|
|
|
677143
677955
|
init_CustomSelect();
|
|
677144
677956
|
init_Dialog();
|
|
677145
677957
|
init_Spinner2();
|
|
677146
|
-
|
|
677958
|
+
import_compiler_runtime356 = __toESM(require_compiler_runtime(), 1);
|
|
677147
677959
|
import_react320 = __toESM(require_react(), 1);
|
|
677148
677960
|
jsx_dev_runtime467 = __toESM(require_jsx_dev_runtime(), 1);
|
|
677149
677961
|
});
|
|
@@ -677407,7 +678219,7 @@ function ResumeConversation({
|
|
|
677407
678219
|
}, undefined, false, undefined, this);
|
|
677408
678220
|
}
|
|
677409
678221
|
function NoConversationsMessage() {
|
|
677410
|
-
const $3 =
|
|
678222
|
+
const $3 = import_compiler_runtime357.c(2);
|
|
677411
678223
|
let t0;
|
|
677412
678224
|
if ($3[0] === Symbol.for("react.memo_cache_sentinel")) {
|
|
677413
678225
|
t0 = {
|
|
@@ -677417,7 +678229,7 @@ function NoConversationsMessage() {
|
|
|
677417
678229
|
} else {
|
|
677418
678230
|
t0 = $3[0];
|
|
677419
678231
|
}
|
|
677420
|
-
useKeybinding("app:interrupt",
|
|
678232
|
+
useKeybinding("app:interrupt", _temp293, t0);
|
|
677421
678233
|
let t1;
|
|
677422
678234
|
if ($3[1] === Symbol.for("react.memo_cache_sentinel")) {
|
|
677423
678235
|
t1 = /* @__PURE__ */ jsx_dev_runtime468.jsxDEV(ThemedBox_default, {
|
|
@@ -677438,11 +678250,11 @@ function NoConversationsMessage() {
|
|
|
677438
678250
|
}
|
|
677439
678251
|
return t1;
|
|
677440
678252
|
}
|
|
677441
|
-
function
|
|
678253
|
+
function _temp293() {
|
|
677442
678254
|
process.exit(1);
|
|
677443
678255
|
}
|
|
677444
678256
|
function CrossProjectMessage(t0) {
|
|
677445
|
-
const $3 =
|
|
678257
|
+
const $3 = import_compiler_runtime357.c(8);
|
|
677446
678258
|
const {
|
|
677447
678259
|
command: command10
|
|
677448
678260
|
} = t0;
|
|
@@ -677526,7 +678338,7 @@ function _temp356() {
|
|
|
677526
678338
|
function _temp294() {
|
|
677527
678339
|
process.exit(0);
|
|
677528
678340
|
}
|
|
677529
|
-
var
|
|
678341
|
+
var import_compiler_runtime357, import_react321, jsx_dev_runtime468;
|
|
677530
678342
|
var init_ResumeConversation = __esm(() => {
|
|
677531
678343
|
init_useTerminalSize();
|
|
677532
678344
|
init_state();
|
|
@@ -677549,7 +678361,7 @@ var init_ResumeConversation = __esm(() => {
|
|
|
677549
678361
|
init_sessionRestore();
|
|
677550
678362
|
init_sessionStorage();
|
|
677551
678363
|
init_REPL();
|
|
677552
|
-
|
|
678364
|
+
import_compiler_runtime357 = __toESM(require_compiler_runtime(), 1);
|
|
677553
678365
|
import_react321 = __toESM(require_react(), 1);
|
|
677554
678366
|
jsx_dev_runtime468 = __toESM(require_jsx_dev_runtime(), 1);
|
|
677555
678367
|
});
|
|
@@ -680308,7 +681120,7 @@ function appendToLog(path30, message) {
|
|
|
680308
681120
|
cwd: getFsImplementation().cwd(),
|
|
680309
681121
|
userType: "external",
|
|
680310
681122
|
sessionId: getSessionId(),
|
|
680311
|
-
version: "1.3.
|
|
681123
|
+
version: "1.3.327"
|
|
680312
681124
|
};
|
|
680313
681125
|
getLogWriter(path30).write(messageWithTimestamp);
|
|
680314
681126
|
}
|
|
@@ -684416,8 +685228,8 @@ async function getEnvLessBridgeConfig() {
|
|
|
684416
685228
|
}
|
|
684417
685229
|
async function checkEnvLessBridgeMinVersion() {
|
|
684418
685230
|
const cfg = await getEnvLessBridgeConfig();
|
|
684419
|
-
if (cfg.min_version && lt("1.3.
|
|
684420
|
-
return `Your version of RAYU (${"1.3.
|
|
685231
|
+
if (cfg.min_version && lt("1.3.327", cfg.min_version)) {
|
|
685232
|
+
return `Your version of RAYU (${"1.3.327"}) is too old for Remote Control.
|
|
684421
685233
|
Version ${cfg.min_version} or higher is required. Run \`claude update\` to update.`;
|
|
684422
685234
|
}
|
|
684423
685235
|
return null;
|
|
@@ -684891,7 +685703,7 @@ async function initBridgeCore(params) {
|
|
|
684891
685703
|
const rawApi = createBridgeApiClient({
|
|
684892
685704
|
baseUrl,
|
|
684893
685705
|
getAccessToken,
|
|
684894
|
-
runnerVersion: "1.3.
|
|
685706
|
+
runnerVersion: "1.3.327",
|
|
684895
685707
|
onDebug: logForDebugging,
|
|
684896
685708
|
onAuth401,
|
|
684897
685709
|
getTrustedDeviceToken
|
|
@@ -689579,7 +690391,7 @@ __export(exports_TeleportProgress, {
|
|
|
689579
690391
|
TeleportProgress: () => TeleportProgress
|
|
689580
690392
|
});
|
|
689581
690393
|
function TeleportProgress(t0) {
|
|
689582
|
-
const $3 =
|
|
690394
|
+
const $3 = import_compiler_runtime358.c(16);
|
|
689583
690395
|
const {
|
|
689584
690396
|
currentStep,
|
|
689585
690397
|
sessionId
|
|
@@ -689732,13 +690544,13 @@ async function teleportWithProgress(root2, sessionId) {
|
|
|
689732
690544
|
branchName
|
|
689733
690545
|
};
|
|
689734
690546
|
}
|
|
689735
|
-
var
|
|
690547
|
+
var import_compiler_runtime358, import_react322, jsx_dev_runtime470, SPINNER_FRAMES3, STEPS;
|
|
689736
690548
|
var init_TeleportProgress = __esm(() => {
|
|
689737
690549
|
init_figures();
|
|
689738
690550
|
init_ink2();
|
|
689739
690551
|
init_AppState();
|
|
689740
690552
|
init_teleport();
|
|
689741
|
-
|
|
690553
|
+
import_compiler_runtime358 = __toESM(require_compiler_runtime(), 1);
|
|
689742
690554
|
import_react322 = __toESM(require_react(), 1);
|
|
689743
690555
|
jsx_dev_runtime470 = __toESM(require_jsx_dev_runtime(), 1);
|
|
689744
690556
|
SPINNER_FRAMES3 = ["◐", "◓", "◑", "◒"];
|
|
@@ -690253,7 +691065,7 @@ async function startMCPServer(cwd3, debug4, verbose) {
|
|
|
690253
691065
|
setCwd(cwd3);
|
|
690254
691066
|
const server = new Server({
|
|
690255
691067
|
name: "claude/tengu",
|
|
690256
|
-
version: "1.3.
|
|
691068
|
+
version: "1.3.327"
|
|
690257
691069
|
}, {
|
|
690258
691070
|
capabilities: {
|
|
690259
691071
|
tools: {}
|
|
@@ -691246,7 +692058,7 @@ function getInstallationPath2() {
|
|
|
691246
692058
|
return "~/.local/bin/claude";
|
|
691247
692059
|
}
|
|
691248
692060
|
function SetupNotes(t0) {
|
|
691249
|
-
const $3 =
|
|
692061
|
+
const $3 = import_compiler_runtime359.c(5);
|
|
691250
692062
|
const {
|
|
691251
692063
|
messages
|
|
691252
692064
|
} = t0;
|
|
@@ -691273,7 +692085,7 @@ function SetupNotes(t0) {
|
|
|
691273
692085
|
}
|
|
691274
692086
|
let t2;
|
|
691275
692087
|
if ($3[1] !== messages) {
|
|
691276
|
-
t2 = messages.map(
|
|
692088
|
+
t2 = messages.map(_temp295);
|
|
691277
692089
|
$3[1] = messages;
|
|
691278
692090
|
$3[2] = t2;
|
|
691279
692091
|
} else {
|
|
@@ -691297,7 +692109,7 @@ function SetupNotes(t0) {
|
|
|
691297
692109
|
}
|
|
691298
692110
|
return t3;
|
|
691299
692111
|
}
|
|
691300
|
-
function
|
|
692112
|
+
function _temp295(message, index) {
|
|
691301
692113
|
return /* @__PURE__ */ jsx_dev_runtime471.jsxDEV(ThemedBox_default, {
|
|
691302
692114
|
marginLeft: 2,
|
|
691303
692115
|
children: /* @__PURE__ */ jsx_dev_runtime471.jsxDEV(ThemedText, {
|
|
@@ -691551,7 +692363,7 @@ function Install({
|
|
|
691551
692363
|
]
|
|
691552
692364
|
}, undefined, true, undefined, this);
|
|
691553
692365
|
}
|
|
691554
|
-
var
|
|
692366
|
+
var import_compiler_runtime359, import_react323, jsx_dev_runtime471, install;
|
|
691555
692367
|
var init_install = __esm(() => {
|
|
691556
692368
|
init_analytics();
|
|
691557
692369
|
init_StatusIcon();
|
|
@@ -691561,7 +692373,7 @@ var init_install = __esm(() => {
|
|
|
691561
692373
|
init_errors();
|
|
691562
692374
|
init_nativeInstaller();
|
|
691563
692375
|
init_settings2();
|
|
691564
|
-
|
|
692376
|
+
import_compiler_runtime359 = __toESM(require_compiler_runtime(), 1);
|
|
691565
692377
|
import_react323 = __toESM(require_react(), 1);
|
|
691566
692378
|
jsx_dev_runtime471 = __toESM(require_jsx_dev_runtime(), 1);
|
|
691567
692379
|
install = {
|
|
@@ -691595,7 +692407,7 @@ __export(exports_util2, {
|
|
|
691595
692407
|
});
|
|
691596
692408
|
import { cwd as cwd4 } from "process";
|
|
691597
692409
|
function DoctorWithPlugins(t0) {
|
|
691598
|
-
const $3 =
|
|
692410
|
+
const $3 = import_compiler_runtime360.c(2);
|
|
691599
692411
|
const {
|
|
691600
692412
|
onDone
|
|
691601
692413
|
} = t0;
|
|
@@ -691655,14 +692467,14 @@ async function installHandler(target, options) {
|
|
|
691655
692467
|
}, {}, args);
|
|
691656
692468
|
});
|
|
691657
692469
|
}
|
|
691658
|
-
var
|
|
692470
|
+
var import_compiler_runtime360, import_react324, jsx_dev_runtime472, DoctorLazy;
|
|
691659
692471
|
var init_util5 = __esm(() => {
|
|
691660
692472
|
init_useManagePlugins();
|
|
691661
692473
|
init_KeybindingProviderSetup();
|
|
691662
692474
|
init_analytics();
|
|
691663
692475
|
init_MCPConnectionManager();
|
|
691664
692476
|
init_AppState();
|
|
691665
|
-
|
|
692477
|
+
import_compiler_runtime360 = __toESM(require_compiler_runtime(), 1);
|
|
691666
692478
|
import_react324 = __toESM(require_react(), 1);
|
|
691667
692479
|
jsx_dev_runtime472 = __toESM(require_jsx_dev_runtime(), 1);
|
|
691668
692480
|
DoctorLazy = import_react324.default.lazy(() => Promise.resolve().then(() => (init_Doctor(), exports_Doctor)).then((m3) => ({
|
|
@@ -692779,7 +693591,7 @@ ${customInstructions}` : customInstructions;
|
|
|
692779
693591
|
}
|
|
692780
693592
|
}
|
|
692781
693593
|
logForDiagnosticsNoPII("info", "started", {
|
|
692782
|
-
version: "1.3.
|
|
693594
|
+
version: "1.3.327",
|
|
692783
693595
|
is_native_binary: isInBundledMode()
|
|
692784
693596
|
});
|
|
692785
693597
|
registerCleanup(async () => {
|
|
@@ -693497,7 +694309,7 @@ Usage: rayu --remote "your task description"`, () => gracefulShutdown(1));
|
|
|
693497
694309
|
pendingHookMessages
|
|
693498
694310
|
}, renderAndRun);
|
|
693499
694311
|
}
|
|
693500
|
-
}).version("1.3.
|
|
694312
|
+
}).version("1.3.327 (Rayu-CLI)", "-v, --version", "Output the version number");
|
|
693501
694313
|
program.option("-w, --worktree [name]", "Create a new git worktree for this session (optionally specify a name)");
|
|
693502
694314
|
program.option("--tmux", "Create a tmux session for the worktree (requires --worktree). Uses iTerm2 native panes when available; use --tmux=classic for traditional tmux.");
|
|
693503
694315
|
if (canUserConfigureAdvisor()) {
|
|
@@ -693963,7 +694775,7 @@ if (false) {}
|
|
|
693963
694775
|
async function main2() {
|
|
693964
694776
|
const args = process.argv.slice(2);
|
|
693965
694777
|
if (args.length === 1 && (args[0] === "--version" || args[0] === "-v" || args[0] === "-V")) {
|
|
693966
|
-
console.log(`${"1.3.
|
|
694778
|
+
console.log(`${"1.3.327"} (Rayu-CLI)`);
|
|
693967
694779
|
return;
|
|
693968
694780
|
}
|
|
693969
694781
|
const {
|