replicas-cli 0.2.727 → 0.2.728
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/README.md +1 -1
- package/dist/index.cjs +1 -204
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -45,7 +45,7 @@ Connect to a workspace via SSH.
|
|
|
45
45
|
Open a workspace in VS Code via Remote SSH. Omit the argument to pick a workspace with the arrow keys and Enter, or pass a name or ID. Names with spaces work with or without quotes.
|
|
46
46
|
|
|
47
47
|
### Coding agents
|
|
48
|
-
Use `replicas claude-auth` or `replicas codex-auth` to connect subscription credentials.
|
|
48
|
+
Use `replicas claude-auth` or `replicas codex-auth` to connect subscription credentials. Cursor uses API keys configured in Coding Agents settings.
|
|
49
49
|
|
|
50
50
|
## Configuration
|
|
51
51
|
|
package/dist/index.cjs
CHANGED
|
@@ -7701,9 +7701,7 @@ var AGENT = {
|
|
|
7701
7701
|
CLAUDE: "claude",
|
|
7702
7702
|
CODEX: "codex",
|
|
7703
7703
|
CURSOR: "cursor",
|
|
7704
|
-
DEEPSEEK: "deepseek",
|
|
7705
7704
|
FX: "fx",
|
|
7706
|
-
GEMINI: "gemini",
|
|
7707
7705
|
KIMI: "kimi",
|
|
7708
7706
|
MUSE: "muse",
|
|
7709
7707
|
OPENCODE: "opencode",
|
|
@@ -7715,7 +7713,6 @@ var VALID_RELAY_SUBAGENT_PROVIDERS = VALID_AGENT_PROVIDERS;
|
|
|
7715
7713
|
var VALID_RELAY_BASE_PROVIDERS = [
|
|
7716
7714
|
AGENT.CLAUDE,
|
|
7717
7715
|
AGENT.CODEX,
|
|
7718
|
-
AGENT.DEEPSEEK,
|
|
7719
7716
|
AGENT.OPENCODE,
|
|
7720
7717
|
AGENT.PI
|
|
7721
7718
|
];
|
|
@@ -7748,21 +7745,11 @@ var AGENT_PROVIDER_OPTIONS = [
|
|
|
7748
7745
|
label: "Cursor",
|
|
7749
7746
|
description: "Use Cursor for tasks"
|
|
7750
7747
|
},
|
|
7751
|
-
{
|
|
7752
|
-
value: "deepseek",
|
|
7753
|
-
label: "DeepSeek Harness",
|
|
7754
|
-
description: "Use DeepSeek Harness for tasks"
|
|
7755
|
-
},
|
|
7756
7748
|
{
|
|
7757
7749
|
value: "fx",
|
|
7758
7750
|
label: "fx",
|
|
7759
7751
|
description: "Use fx for tasks"
|
|
7760
7752
|
},
|
|
7761
|
-
{
|
|
7762
|
-
value: "gemini",
|
|
7763
|
-
label: "Gemini CLI",
|
|
7764
|
-
description: "Use Gemini CLI for tasks"
|
|
7765
|
-
},
|
|
7766
7753
|
{
|
|
7767
7754
|
value: "kimi",
|
|
7768
7755
|
label: "Kimi Code",
|
|
@@ -7795,9 +7782,7 @@ var THINKING_LEVELS_BY_AGENT = {
|
|
|
7795
7782
|
claude: [...STANDARD_THINKING_LEVELS, "ultracode"],
|
|
7796
7783
|
codex: [...STANDARD_THINKING_LEVELS, "ultra"],
|
|
7797
7784
|
cursor: STANDARD_THINKING_LEVELS,
|
|
7798
|
-
deepseek: STANDARD_THINKING_LEVELS,
|
|
7799
7785
|
fx: STANDARD_THINKING_LEVELS,
|
|
7800
|
-
gemini: STANDARD_THINKING_LEVELS,
|
|
7801
7786
|
kimi: STANDARD_THINKING_LEVELS,
|
|
7802
7787
|
muse: VALID_THINKING_LEVELS.filter((level) => level !== "max" && level !== "ultracode"),
|
|
7803
7788
|
opencode: STANDARD_THINKING_LEVELS,
|
|
@@ -7819,12 +7804,8 @@ function getProviderDisplayName(provider, variant = "short") {
|
|
|
7819
7804
|
return "Codex";
|
|
7820
7805
|
case "cursor":
|
|
7821
7806
|
return "Cursor";
|
|
7822
|
-
case "deepseek":
|
|
7823
|
-
return variant === "long" ? "DeepSeek Harness" : "DeepSeek";
|
|
7824
7807
|
case "fx":
|
|
7825
7808
|
return "fx";
|
|
7826
|
-
case "gemini":
|
|
7827
|
-
return "Gemini";
|
|
7828
7809
|
case "kimi":
|
|
7829
7810
|
return variant === "long" ? "Kimi Code" : "Kimi";
|
|
7830
7811
|
case "muse":
|
|
@@ -7880,7 +7861,6 @@ var CREDENTIAL_TYPE = {
|
|
|
7880
7861
|
ASTER_API_KEY: "aster_api_key",
|
|
7881
7862
|
OPENROUTER_API_KEY: "openrouter_api_key",
|
|
7882
7863
|
AI_GATEWAY_API_KEY: "ai_gateway_api_key",
|
|
7883
|
-
GEMINI_API_KEY: "gemini_api_key",
|
|
7884
7864
|
MUSE_OAUTH: "muse_oauth",
|
|
7885
7865
|
MUSE_API_KEY: "muse_api_key"
|
|
7886
7866
|
};
|
|
@@ -7908,16 +7888,9 @@ var AGENT_CREDENTIAL_METHODS_IN_ORDER = {
|
|
|
7908
7888
|
[AGENT.CURSOR]: [
|
|
7909
7889
|
{ method: CREDENTIAL_METHOD.API_KEY, credentialType: CREDENTIAL_TYPE.CURSOR_API_KEY }
|
|
7910
7890
|
],
|
|
7911
|
-
[AGENT.DEEPSEEK]: [
|
|
7912
|
-
{ method: CREDENTIAL_METHOD.OPENROUTER, credentialType: CREDENTIAL_TYPE.OPENROUTER_API_KEY },
|
|
7913
|
-
{ method: CREDENTIAL_METHOD.OLLAMA, credentialType: CREDENTIAL_TYPE.OLLAMA }
|
|
7914
|
-
],
|
|
7915
7891
|
[AGENT.FX]: [
|
|
7916
7892
|
{ method: CREDENTIAL_METHOD.AI_GATEWAY, credentialType: CREDENTIAL_TYPE.AI_GATEWAY_API_KEY }
|
|
7917
7893
|
],
|
|
7918
|
-
[AGENT.GEMINI]: [
|
|
7919
|
-
{ method: CREDENTIAL_METHOD.API_KEY, credentialType: CREDENTIAL_TYPE.GEMINI_API_KEY }
|
|
7920
|
-
],
|
|
7921
7894
|
[AGENT.KIMI]: [
|
|
7922
7895
|
{ method: CREDENTIAL_METHOD.AI_GATEWAY, credentialType: CREDENTIAL_TYPE.AI_GATEWAY_API_KEY },
|
|
7923
7896
|
{ method: CREDENTIAL_METHOD.OLLAMA, credentialType: CREDENTIAL_TYPE.OLLAMA }
|
|
@@ -22645,7 +22618,6 @@ var OX_ALPHA_MODEL = "stealth/ox-alpha";
|
|
|
22645
22618
|
var DEEPSEEK_V4_PRO_MODEL = "deepseek/deepseek-v4-pro-0813";
|
|
22646
22619
|
var DEEPSEEK_V4_FLASH_MODEL = "deepseek/deepseek-v4-flash-0731";
|
|
22647
22620
|
var DEFAULT_FX_MODEL = "zai/glm-5.2";
|
|
22648
|
-
var DEFAULT_GEMINI_MODEL = "gemini-3.8-flash";
|
|
22649
22621
|
var DEFAULT_KIMI_MODEL = "moonshotai/kimi-k2.6";
|
|
22650
22622
|
var MUSE_SPARK_1_3_MODEL = "muse-spark-1.3";
|
|
22651
22623
|
var DEFAULT_MUSE_MODEL = "muse-spark-1.2";
|
|
@@ -22666,12 +22638,6 @@ var OPENROUTER_MODELS = [
|
|
|
22666
22638
|
"xiaomi/mimo-v2.5-pro",
|
|
22667
22639
|
"meta/muse-spark-1.3"
|
|
22668
22640
|
];
|
|
22669
|
-
function prioritizeDeepseekModels(models) {
|
|
22670
|
-
return [
|
|
22671
|
-
...models.filter((model) => model.startsWith("deepseek/")),
|
|
22672
|
-
...models.filter((model) => !model.startsWith("deepseek/"))
|
|
22673
|
-
];
|
|
22674
|
-
}
|
|
22675
22641
|
function normalizeClaudeModel(model) {
|
|
22676
22642
|
if (model === "opus" || model === CLAUDE_OPUS_1M_MODEL || model === LEGACY_CLAUDE_OPUS_1M_MODEL) {
|
|
22677
22643
|
return DEFAULT_CLAUDE_MODEL;
|
|
@@ -22751,9 +22717,7 @@ var AGENT_MODELS = {
|
|
|
22751
22717
|
CLAUDE_HAIKU_4_5_MODEL,
|
|
22752
22718
|
"kimi-k2.5"
|
|
22753
22719
|
],
|
|
22754
|
-
deepseek: prioritizeDeepseekModels(DEFAULT_OPENROUTER_MODELS),
|
|
22755
22720
|
fx: [DEFAULT_FX_MODEL],
|
|
22756
|
-
gemini: [DEFAULT_GEMINI_MODEL, "gemini-3.1-pro-preview"],
|
|
22757
22721
|
kimi: [DEFAULT_KIMI_MODEL],
|
|
22758
22722
|
muse: [MUSE_SPARK_1_3_MODEL, DEFAULT_MUSE_MODEL],
|
|
22759
22723
|
opencode: [...DEFAULT_OPENROUTER_MODELS, ...ASTER_MODELS],
|
|
@@ -22811,8 +22775,6 @@ var MODEL_LABELS = {
|
|
|
22811
22775
|
"xiaomi/mimo-v2.5-pro": "MiMo V2.5 Pro via OpenRouter",
|
|
22812
22776
|
"moonshotai/kimi-k2.6": "Kimi K2.6 via OpenRouter",
|
|
22813
22777
|
"moonshotai/kimi-k3": "Kimi K3 via OpenRouter",
|
|
22814
|
-
"gemini-3-flash-preview": "Gemini 3 Flash Preview",
|
|
22815
|
-
"gemini-3.1-pro-preview": "Gemini 3.1 Pro Preview",
|
|
22816
22778
|
[MUSE_SPARK_1_3_MODEL]: "Muse Spark 1.3",
|
|
22817
22779
|
[DEFAULT_MUSE_MODEL]: "Muse Spark 1.2",
|
|
22818
22780
|
"meta/muse-spark-1.3": "Muse Spark 1.3 via OpenRouter",
|
|
@@ -25819,165 +25781,6 @@ function parseCursorEvents(events) {
|
|
|
25819
25781
|
return messages;
|
|
25820
25782
|
}
|
|
25821
25783
|
|
|
25822
|
-
// ../shared/src/display-message/parsers/deepseek-parser.ts
|
|
25823
|
-
function parseArguments(value) {
|
|
25824
|
-
if (typeof value !== "string") return void 0;
|
|
25825
|
-
const parsed = safeJsonParse(value, value);
|
|
25826
|
-
return isRecord(parsed) ? parsed : stringifyDisplayValue(parsed);
|
|
25827
|
-
}
|
|
25828
|
-
function getDeepseekAssistantMessageText(event, blockType) {
|
|
25829
|
-
if (!isRecord(event) || event.type !== "assistant/message" || !isRecord(event.data) || !isRecord(event.data.message) || !Array.isArray(event.data.message.content)) return "";
|
|
25830
|
-
return event.data.message.content.flatMap((block) => isRecord(block) && block.type === blockType && typeof block.text === "string" ? [block.text] : []).join("");
|
|
25831
|
-
}
|
|
25832
|
-
function parseDeepseekEvents(events) {
|
|
25833
|
-
const messages = [];
|
|
25834
|
-
for (const source of events) {
|
|
25835
|
-
if (source.type === "event_msg" && source.payload.type === "user_message") {
|
|
25836
|
-
if (typeof source.payload.message === "string" && source.payload.message.trim()) {
|
|
25837
|
-
const messageId = source.payload[USER_MESSAGE_ID_PAYLOAD_KEY];
|
|
25838
|
-
messages.push({
|
|
25839
|
-
id: typeof messageId === "string" ? messageId : `deepseek-user-${source.timestamp}`,
|
|
25840
|
-
type: "user",
|
|
25841
|
-
content: source.payload.message,
|
|
25842
|
-
timestamp: source.timestamp
|
|
25843
|
-
});
|
|
25844
|
-
}
|
|
25845
|
-
continue;
|
|
25846
|
-
}
|
|
25847
|
-
if (source.type === "deepseek-error") {
|
|
25848
|
-
messages.push({
|
|
25849
|
-
id: `deepseek-error-${source.timestamp}`,
|
|
25850
|
-
type: "error",
|
|
25851
|
-
message: typeof source.payload.message === "string" ? source.payload.message : "DeepSeek Harness failed",
|
|
25852
|
-
timestamp: source.timestamp
|
|
25853
|
-
});
|
|
25854
|
-
continue;
|
|
25855
|
-
}
|
|
25856
|
-
if (source.type === "deepseek-input-request") {
|
|
25857
|
-
const requestId = typeof source.payload.requestId === "string" ? source.payload.requestId : `deepseek-input-${source.timestamp}`;
|
|
25858
|
-
if (source.payload.kind === "approval") {
|
|
25859
|
-
upsertDisplayMessage(messages, createCallDisplayMessage({
|
|
25860
|
-
id: requestId,
|
|
25861
|
-
server: "deepseek",
|
|
25862
|
-
tool: typeof source.payload.toolName === "string" ? source.payload.toolName : "approval",
|
|
25863
|
-
input: typeof source.payload.reason === "string" ? source.payload.reason : void 0,
|
|
25864
|
-
status: "in_progress",
|
|
25865
|
-
timestamp: source.timestamp,
|
|
25866
|
-
inputRequest: {
|
|
25867
|
-
requestId,
|
|
25868
|
-
status: "pending",
|
|
25869
|
-
options: [
|
|
25870
|
-
{ id: "deny", label: "Deny", variant: "secondary" },
|
|
25871
|
-
{ id: "allow", label: "Allow once", variant: "primary" }
|
|
25872
|
-
]
|
|
25873
|
-
}
|
|
25874
|
-
}));
|
|
25875
|
-
} else {
|
|
25876
|
-
const questions = Array.isArray(source.payload.questions) ? source.payload.questions : [];
|
|
25877
|
-
upsertDisplayMessage(messages, createCallDisplayMessage({
|
|
25878
|
-
id: requestId,
|
|
25879
|
-
server: "deepseek",
|
|
25880
|
-
tool: "ask_user",
|
|
25881
|
-
status: "in_progress",
|
|
25882
|
-
timestamp: source.timestamp,
|
|
25883
|
-
inputRequest: {
|
|
25884
|
-
requestId,
|
|
25885
|
-
status: "pending",
|
|
25886
|
-
questions: questions.flatMap((question) => {
|
|
25887
|
-
if (!isRecord(question) || typeof question.id !== "string" || typeof question.question !== "string") return [];
|
|
25888
|
-
const options = Array.isArray(question.options) ? question.options : [];
|
|
25889
|
-
return [{
|
|
25890
|
-
id: question.id,
|
|
25891
|
-
prompt: question.question,
|
|
25892
|
-
multiSelect: question.multiSelect === true,
|
|
25893
|
-
options: options.flatMap((option) => isRecord(option) && typeof option.label === "string" ? [{ id: `${question.id}:${option.label}`, label: option.label, ...typeof option.description === "string" ? { description: option.description } : {} }] : [])
|
|
25894
|
-
}];
|
|
25895
|
-
})
|
|
25896
|
-
}
|
|
25897
|
-
}));
|
|
25898
|
-
}
|
|
25899
|
-
continue;
|
|
25900
|
-
}
|
|
25901
|
-
if (source.type === "deepseek-input-resolved") {
|
|
25902
|
-
const requestId = typeof source.payload.requestId === "string" ? source.payload.requestId : "";
|
|
25903
|
-
const existing = messages.find((message) => message.type === "tool_call" && message.inputRequest?.requestId === requestId);
|
|
25904
|
-
if (existing?.type === "tool_call" && existing.inputRequest) {
|
|
25905
|
-
existing.inputRequest.status = source.payload.status === "aborted" ? "aborted" : "resolved";
|
|
25906
|
-
existing.status = source.payload.status === "aborted" ? "failed" : "completed";
|
|
25907
|
-
}
|
|
25908
|
-
continue;
|
|
25909
|
-
}
|
|
25910
|
-
if (source.type === "deepseek-jobs" && Array.isArray(source.payload.jobs)) {
|
|
25911
|
-
for (const job of source.payload.jobs) {
|
|
25912
|
-
if (!isRecord(job) || typeof job.id !== "string") continue;
|
|
25913
|
-
const existing = messages.find((message) => message.type === "background_task" && message.taskId === job.id);
|
|
25914
|
-
const status = normalizeBackgroundTaskStatus(job.status);
|
|
25915
|
-
const next = {
|
|
25916
|
-
id: existing?.id ?? `deepseek-job-${job.id}`,
|
|
25917
|
-
type: "background_task",
|
|
25918
|
-
taskId: job.id,
|
|
25919
|
-
status,
|
|
25920
|
-
description: typeof job.label === "string" ? job.label : void 0,
|
|
25921
|
-
taskType: typeof job.kind === "string" ? job.kind : void 0,
|
|
25922
|
-
error: status === "failed" && typeof job.detail === "string" ? job.detail : void 0,
|
|
25923
|
-
timestamp: existing?.timestamp ?? source.timestamp
|
|
25924
|
-
};
|
|
25925
|
-
if (existing?.type === "background_task") Object.assign(existing, next);
|
|
25926
|
-
else messages.push(next);
|
|
25927
|
-
}
|
|
25928
|
-
continue;
|
|
25929
|
-
}
|
|
25930
|
-
if (source.type !== "deepseek-session-event" || !isRecord(source.payload.event)) continue;
|
|
25931
|
-
const event = source.payload.event;
|
|
25932
|
-
const data = isRecord(event.data) ? event.data : {};
|
|
25933
|
-
const seq = typeof event.seq === "number" ? event.seq : source.timestamp;
|
|
25934
|
-
if (event.type === "assistant/message") {
|
|
25935
|
-
const content = getDeepseekAssistantMessageText(event, "text");
|
|
25936
|
-
const reasoning = getDeepseekAssistantMessageText(event, "reasoning");
|
|
25937
|
-
if (reasoning.trim()) messages.push({ id: `deepseek-reasoning-${seq}`, type: "reasoning", content: reasoning, status: "completed", timestamp: source.timestamp });
|
|
25938
|
-
if (content.trim()) messages.push({ id: `deepseek-assistant-${seq}`, type: "agent", content, timestamp: source.timestamp });
|
|
25939
|
-
continue;
|
|
25940
|
-
}
|
|
25941
|
-
if (event.type === "tool/call") {
|
|
25942
|
-
const callId = typeof data.callId === "string" ? data.callId : String(seq);
|
|
25943
|
-
upsertDisplayMessage(messages, createCallDisplayMessage({
|
|
25944
|
-
id: `deepseek-tool-${callId}`,
|
|
25945
|
-
server: "deepseek",
|
|
25946
|
-
tool: typeof data.name === "string" ? data.name : "tool",
|
|
25947
|
-
input: parseArguments(data.arguments),
|
|
25948
|
-
status: "in_progress",
|
|
25949
|
-
timestamp: source.timestamp
|
|
25950
|
-
}));
|
|
25951
|
-
continue;
|
|
25952
|
-
}
|
|
25953
|
-
if (event.type === "tool/result") {
|
|
25954
|
-
const message = isRecord(data.message) ? data.message : {};
|
|
25955
|
-
const messageSource = isRecord(message.source) ? message.source : {};
|
|
25956
|
-
const result = Array.isArray(message.content) && isRecord(message.content[0]) ? message.content[0] : {};
|
|
25957
|
-
const callId = typeof messageSource.callId === "string" ? messageSource.callId : typeof data.callId === "string" ? data.callId : String(seq);
|
|
25958
|
-
const existing = messages.find((message2) => message2.id === `deepseek-tool-${callId}` && message2.type === "tool_call");
|
|
25959
|
-
if (existing?.type === "tool_call") {
|
|
25960
|
-
existing.output = stringifyDisplayValue(result.content ?? data.result);
|
|
25961
|
-
existing.status = result.isError === true || data.isError === true ? "failed" : "completed";
|
|
25962
|
-
}
|
|
25963
|
-
continue;
|
|
25964
|
-
}
|
|
25965
|
-
if (event.type === "todo/write" && Array.isArray(data.items)) {
|
|
25966
|
-
messages.push({
|
|
25967
|
-
id: `deepseek-todo-${seq}`,
|
|
25968
|
-
type: "todo_list",
|
|
25969
|
-
items: data.items.flatMap((item) => {
|
|
25970
|
-
if (!isRecord(item) || typeof item.content !== "string") return [];
|
|
25971
|
-
const itemStatus = item.status === "in_progress" || item.status === "completed" ? item.status : "pending";
|
|
25972
|
-
return [{ text: item.content, completed: itemStatus === "completed", itemStatus }];
|
|
25973
|
-
}),
|
|
25974
|
-
timestamp: source.timestamp
|
|
25975
|
-
});
|
|
25976
|
-
}
|
|
25977
|
-
}
|
|
25978
|
-
return messages;
|
|
25979
|
-
}
|
|
25980
|
-
|
|
25981
25784
|
// ../shared/src/display-message/parsers/acp-parser.ts
|
|
25982
25785
|
var FX_CONTEXT_DIAGNOSTIC = /^\[context\] skill catalog omitted .*?(?:\r?\n|$)/;
|
|
25983
25786
|
function getAcpTextChunk(update, kind) {
|
|
@@ -27172,18 +26975,12 @@ function parseAgentEvents(events, agentType) {
|
|
|
27172
26975
|
if (agentType === "cursor") {
|
|
27173
26976
|
return parseCursorEvents(events);
|
|
27174
26977
|
}
|
|
27175
|
-
if (agentType === "deepseek") {
|
|
27176
|
-
return parseDeepseekEvents(events);
|
|
27177
|
-
}
|
|
27178
26978
|
if (agentType === "fx") {
|
|
27179
26979
|
return parseFxEvents(events);
|
|
27180
26980
|
}
|
|
27181
26981
|
if (agentType === "kimi") {
|
|
27182
26982
|
return parseAcpEvents(events, "kimi");
|
|
27183
26983
|
}
|
|
27184
|
-
if (agentType === "gemini") {
|
|
27185
|
-
return parseAcpEvents(events, "gemini");
|
|
27186
|
-
}
|
|
27187
26984
|
if (agentType === "muse") {
|
|
27188
26985
|
return parseMuseEvents(events);
|
|
27189
26986
|
}
|
|
@@ -27457,7 +27254,7 @@ var headlessFilesystemAgentResultSchema = external_exports.object({
|
|
|
27457
27254
|
});
|
|
27458
27255
|
|
|
27459
27256
|
// ../shared/src/cli-version.ts
|
|
27460
|
-
var CLI_VERSION = "0.2.
|
|
27257
|
+
var CLI_VERSION = "0.2.728";
|
|
27461
27258
|
|
|
27462
27259
|
// ../shared/src/version.ts
|
|
27463
27260
|
function compareVersions(v1, v2) {
|