replicas-cli 0.3.347 → 0.3.349

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.
Files changed (2) hide show
  1. package/dist/index.cjs +24 -9
  2. package/package.json +1 -1
package/dist/index.cjs CHANGED
@@ -21700,7 +21700,7 @@ function classifyCanvasFilename(filename) {
21700
21700
  const ext = idx === -1 ? "" : filename.slice(idx).toLowerCase();
21701
21701
  return CANVAS_KIND_BY_EXTENSION[ext] ?? (detectLanguageByPath(filename) ? { kind: "text", mimeType: "text/plain; charset=utf-8" } : { kind: "other", mimeType: "application/octet-stream" });
21702
21702
  }
21703
- var CLAUDE_OPUS_1M_MODEL, LEGACY_CLAUDE_OPUS_1M_MODEL, CLAUDE_FABLE_5_2_MODEL, CLAUDE_FABLE_5_1_MODEL, CLAUDE_FABLE_5_MODEL, CLAUDE_OPUS_5_5_MODEL, CLAUDE_OPUS_5_MODEL, CLAUDE_OPUS_4_8_MODEL, CLAUDE_SONNET_5_5_MODEL, CLAUDE_SONNET_5_MODEL, CLAUDE_HAIKU_5_5_MODEL, CLAUDE_HAIKU_4_5_MODEL, CLAUDE_FABLE_5_2_BEDROCK_MODEL, CLAUDE_FABLE_5_1_BEDROCK_MODEL, CLAUDE_FABLE_5_BEDROCK_MODEL, CLAUDE_OPUS_5_5_BEDROCK_MODEL, CLAUDE_OPUS_5_BEDROCK_MODEL, CLAUDE_OPUS_4_8_BEDROCK_MODEL, CLAUDE_SONNET_5_5_BEDROCK_MODEL, CLAUDE_SONNET_5_BEDROCK_MODEL, CLAUDE_HAIKU_5_5_BEDROCK_MODEL, CLAUDE_HAIKU_4_5_BEDROCK_MODEL, DEFAULT_CLAUDE_MODEL, GPT_6_ASTRA_MODEL, GPT_6_1_SOL_MODEL, GPT_6_SOL_MODEL, GPT_6_LUNA_MODEL, GPT_5_6_SOL_MODEL, GPT_5_6_TERRA_MODEL, GPT_5_6_LUNA_MODEL, DEFAULT_CODEX_MODEL, DEFAULT_OPENCODE_MODEL, GLM_5_3_FLASH_MODEL, DEEPSEEK_V4_PRO_MODEL, DEEPSEEK_V4_FLASH_MODEL, MUSE_WONDER_1_0_MODEL, MUSE_SPARK_1_3_MODEL, DEFAULT_MUSE_MODEL, DEFAULT_OPENROUTER_MODELS, OPENROUTER_MODELS, CLAUDE_MODEL_CONTEXT_WINDOWS, CLAUDE_MODEL_MIN_SANDBOX_IMAGE, CODEX_MODEL_MIN_SANDBOX_IMAGE, AGENT_MODELS, HIDDEN_BY_DEFAULT_MODELS, withoutHiddenByDefault, DEFAULT_STATIC_AGENT_MODELS, DEFAULT_CURSOR_MODELS, SANDBOX_IMAGE_MODEL_FALLBACKS, MODEL_LABELS, IMAGE_MEDIA_TYPES, resourcePressure, sandboxResourceMinuteSchema, MAX_PENDING_RESOURCE_MINUTES, sandboxResourceMinutesSchema, sandboxMemorySampleSchema, MAX_CANVAS_FILE_BYTES, MAX_CANVAS_PREVIEW_BYTES, CANVAS_KIND_BY_EXTENSION;
21703
+ var CLAUDE_OPUS_1M_MODEL, LEGACY_CLAUDE_OPUS_1M_MODEL, CLAUDE_FABLE_5_2_MODEL, CLAUDE_FABLE_5_1_MODEL, CLAUDE_FABLE_5_MODEL, CLAUDE_OPUS_5_5_MODEL, CLAUDE_OPUS_5_MODEL, CLAUDE_OPUS_4_8_MODEL, CLAUDE_SONNET_5_5_MODEL, CLAUDE_SONNET_5_MODEL, CLAUDE_HAIKU_5_5_MODEL, CLAUDE_HAIKU_4_5_MODEL, CLAUDE_FABLE_5_2_BEDROCK_MODEL, CLAUDE_FABLE_5_1_BEDROCK_MODEL, CLAUDE_FABLE_5_BEDROCK_MODEL, CLAUDE_OPUS_5_5_BEDROCK_MODEL, CLAUDE_OPUS_5_BEDROCK_MODEL, CLAUDE_OPUS_4_8_BEDROCK_MODEL, CLAUDE_SONNET_5_5_BEDROCK_MODEL, CLAUDE_SONNET_5_BEDROCK_MODEL, CLAUDE_HAIKU_5_5_BEDROCK_MODEL, CLAUDE_HAIKU_4_5_BEDROCK_MODEL, DEFAULT_CLAUDE_MODEL, GPT_6_ASTRA_MODEL, GPT_6_1_SOL_MODEL, GPT_6_SOL_MODEL, GPT_6_LUNA_MODEL, GPT_5_6_SOL_MODEL, GPT_5_6_TERRA_MODEL, GPT_5_6_LUNA_MODEL, DEFAULT_CODEX_MODEL, DEFAULT_OPENCODE_MODEL, GLM_5_3_FLASH_MODEL, DEEPSEEK_V4_PRO_MODEL, DEEPSEEK_V4_FLASH_MODEL, MUSE_WONDER_1_0_MODEL, MUSE_SPARK_1_3_MODEL, DEFAULT_MUSE_MODEL, DEFAULT_OPENROUTER_MODELS, OPENROUTER_MODELS, CLAUDE_MODEL_CONTEXT_WINDOWS, CLAUDE_MODEL_MIN_SANDBOX_IMAGE, CODEX_MODEL_MIN_SANDBOX_IMAGE, AGENT_MODELS, HIDDEN_BY_DEFAULT_MODELS, withoutHiddenByDefault, DEFAULT_STATIC_AGENT_MODELS, DEFAULT_CURSOR_MODELS, SANDBOX_IMAGE_MODEL_FALLBACKS, MODEL_LABELS, IMAGE_MEDIA_TYPES, resourcePressure, sandboxResourceMinuteSchema, MAX_PENDING_RESOURCE_MINUTES, sandboxResourceMinutesSchema, sandboxMemorySampleSchema, engineUpdateProgressSchema, MAX_CANVAS_FILE_BYTES, MAX_CANVAS_PREVIEW_BYTES, CANVAS_KIND_BY_EXTENSION;
21704
21704
  var init_types4 = __esm({
21705
21705
  "../shared/src/engine/types.ts"() {
21706
21706
  "use strict";
@@ -21988,6 +21988,10 @@ var init_types4 = __esm({
21988
21988
  memoryUsedMb: external_exports.number().min(0),
21989
21989
  memoryPressureSome: resourcePressure
21990
21990
  });
21991
+ engineUpdateProgressSchema = external_exports.discriminatedUnion("state", [
21992
+ external_exports.object({ state: external_exports.enum(["updating", "updated"]), from: external_exports.string(), to: external_exports.string() }),
21993
+ external_exports.object({ state: external_exports.literal("failed"), from: external_exports.string(), to: external_exports.string(), reason: external_exports.string() })
21994
+ ]);
21991
21995
  MAX_CANVAS_FILE_BYTES = 100 * 1024 * 1024;
21992
21996
  MAX_CANVAS_PREVIEW_BYTES = 5 * 1024 * 1024;
21993
21997
  CANVAS_KIND_BY_EXTENSION = {
@@ -22998,6 +23002,7 @@ var init_replicas_mcp = __esm({
22998
23002
  waitForSubagents: "wait_for_subagents",
22999
23003
  getBoard: "get_board",
23000
23004
  updateBoard: "update_board",
23005
+ sendToChat: "send_to_chat",
23001
23006
  getLinearRouting: "get_linear_routing",
23002
23007
  setLinearRouting: "set_linear_routing",
23003
23008
  clearLinearRouting: "clear_linear_routing",
@@ -26181,7 +26186,7 @@ function removeTag(text4, tag) {
26181
26186
  function stripReplicasInstructionBlock(text4) {
26182
26187
  return removeTag(text4, REPLICAS_INSTRUCTIONS_TAG);
26183
26188
  }
26184
- var REPLICAS_INSTRUCTIONS_TAG, MOTHERSHIP_INSTRUCTIONS_TAG, BOARD_ANSWER_NOTE, BOARD_RULES, MOTHERSHIP_INSTRUCTIONS_BLOCK, T, SCOUT_LINEAR_RULES, SCOUT_MUTED_RULES, SCOUT_PRIOR_UNTAGGED_RULES, SCOUT_JOINED_RULES, SCOUT_REACTION_RULES;
26189
+ var REPLICAS_INSTRUCTIONS_TAG, MOTHERSHIP_INSTRUCTIONS_TAG, MOTHERSHIP_EVENT_CHAT_NOTE, BOARD_ANSWER_NOTE, BOARD_RULES, MOTHERSHIP_INSTRUCTIONS_BLOCK, T, SCOUT_LINEAR_RULES, SCOUT_MUTED_RULES, SCOUT_PRIOR_UNTAGGED_RULES, SCOUT_JOINED_RULES, SCOUT_REACTION_RULES;
26185
26190
  var init_prompts = __esm({
26186
26191
  "../shared/src/prompts.ts"() {
26187
26192
  "use strict";
@@ -26198,6 +26203,7 @@ var init_prompts = __esm({
26198
26203
  init_slack_response_style();
26199
26204
  REPLICAS_INSTRUCTIONS_TAG = "replicas_instructions";
26200
26205
  MOTHERSHIP_INSTRUCTIONS_TAG = "multitask_instructions";
26206
+ MOTHERSHIP_EVENT_CHAT_NOTE = `The user doesn't see text you write in this turn. If it brings something they asked for, or a blocker that needs them, send it with ${REPLICAS_MCP_TOOLS.sendToChat}; otherwise update the board and end with a one-line note.`;
26201
26207
  BOARD_ANSWER_NOTE = "The user answered on the board.";
26202
26208
  BOARD_RULES = `- The board, a live status page you keep with \`${REPLICAS_MCP_TOOLS.updateBoard}\` in the Ships pane beside this chat, is the user's one view of the work: keep it covering every ship, pull request, deploy and blocker. Show ships, pull requests and Linear tickets as ship, pr and linear blocks, which stay current on their own, instead of describing their status. Keep exactly these sections, always in this order, leaving out any that are empty; when you add one, give it the position that keeps this order:
26203
26209
  - Questions (needs_you): only decisions you truly can't make, and blocked ships. Give each your recommendation and a choice. Make routine calls yourself, such as retries, small scope choices or test cleanup, and note them on the ship's row instead of asking.
@@ -26207,8 +26213,8 @@ var init_prompts = __esm({
26207
26213
  - On every \`finished\` and \`archived\` event, move that ship's rows out of Working, or remove them, so Working only lists ships that are working.
26208
26214
  - A ship with open pull requests is not done when it sends \`finished\`: Replicas fixes their CI failures and review comments automatically, then sends \`ready\` or \`needs_attention\`. On \`needs_attention\`, direct the ship, or add it to Questions only if you can't decide.
26209
26215
  - When a pull request should merge once it's approved and CI passes, call \`${REPLICAS_MCP_TOOLS.mergeWhenReady}\`: Replicas merges it and sends \`merged\`, or \`needs_attention\` saying why it can't. Never watch CI or pull requests with \`gh\`, sleep loops or wait scripts, and merge one yourself only when the user wants it merged right away.
26210
- - On every ship event and every answer the user gives on the board (marked "${BOARD_ANSWER_NOTE}"), act with tools on the answer or on any work the event unblocks, such as starting the next task once a pull request merges, and update the board. Then write in chat only if the turn delivers something the user asked for, such as the answer, result, media or links, or needs their attention; otherwise end your turn with no text at all. Saying what you put on the board, or that you archived or messaged a ship, delivers nothing. Never write an acknowledgement such as "Noted.", even if earlier turns did.
26211
- - The chat is like texting an assistant: the user sees only your final reply of each turn, never your tool calls or earlier text, so put everything they should see in it. Write in a line or two with links, and include any media inline. Anything that needs the user later goes on the board. Never restate the board in chat: no status tables, per-ship lists or summaries of what ships did.
26216
+ - On every ship event and every answer the user gives on the board (marked "${BOARD_ANSWER_NOTE}"), act with tools on the answer or on any work the event unblocks, such as starting the next task once a pull request merges, and update the board. The user sees nothing you write in these turns: the only way to reach them is \`${REPLICAS_MCP_TOOLS.sendToChat}\`. Call it only for what they would want right now: a deliverable they asked for, with its media, links or answer (the finished video, the requested numbers); a failure or blocker that needs them, also on the board; or a request of theirs being done. Never for status, such as "PR #12 merged", "deploying", "it's on the board" or "I asked the ship to\u2026": the board and the chat's own rows show those. End the turn with a one-line note of what you did; only the activity log shows it.
26217
+ - The chat is like texting an assistant: the user sees only your final reply to each message they type, plus what you send with \`${REPLICAS_MCP_TOOLS.sendToChat}\`, never your tool calls or earlier text. Write in a line or two with links, and include any media inline. Anything that needs the user later goes on the board. Never restate the board in chat: no status tables, per-ship lists or summaries of what ships did.
26212
26218
  - When the user picks a choice or clicks a button that messages or merges, Replicas removes that item from the board for you. Add it back, or a new item, only if the user is still needed.
26213
26219
  `;
26214
26220
  MOTHERSHIP_INSTRUCTIONS_BLOCK = new RegExp(`\\s*<${MOTHERSHIP_INSTRUCTIONS_TAG}>\\n([\\s\\S]*?)\\n</${MOTHERSHIP_INSTRUCTIONS_TAG}>`);
@@ -34627,6 +34633,7 @@ var init_steps = __esm({
34627
34633
  [REPLICAS_MCP_TOOLS.clearLinearRouting]: { icon: "trash", live: "Clearing Linear routing", done: "Cleared Linear routing" },
34628
34634
  [REPLICAS_MCP_TOOLS.getBoard]: { icon: "book", live: "Reading board", done: "Read board" },
34629
34635
  [REPLICAS_MCP_TOOLS.updateBoard]: { icon: "file-pen", live: "Updating board", done: "Updated board" },
34636
+ [REPLICAS_MCP_TOOLS.sendToChat]: { icon: "message", live: "Sending to chat", done: "Sent to chat" },
34630
34637
  [REPLICAS_MCP_TOOLS.mergeWhenReady]: { icon: "target", live: "Setting merge when ready", done: "Set merge when ready" }
34631
34638
  };
34632
34639
  }
@@ -37522,7 +37529,7 @@ var CLI_VERSION;
37522
37529
  var init_cli_version = __esm({
37523
37530
  "../shared/src/cli-version.ts"() {
37524
37531
  "use strict";
37525
- CLI_VERSION = "0.3.347";
37532
+ CLI_VERSION = "0.3.349";
37526
37533
  }
37527
37534
  });
37528
37535
 
@@ -50744,7 +50751,7 @@ async function resolveEnvironmentId(input2) {
50744
50751
  }
50745
50752
  return resolved.id;
50746
50753
  }
50747
- function printEnvironment(env) {
50754
+ function printEnvironment(env, repoSkillCount) {
50748
50755
  console.log(import_chalk20.default.white(` ${env.name}${env.user_id ? import_chalk20.default.gray(" (personal)") : ""}`));
50749
50756
  console.log(import_chalk20.default.gray(` ID: ${env.id}`));
50750
50757
  if (env.description) {
@@ -50755,7 +50762,10 @@ function printEnvironment(env) {
50755
50762
  console.log(import_chalk20.default.gray(` Repositories: ${repositoryIds.join(", ")}`));
50756
50763
  }
50757
50764
  if (env.variable_count !== void 0) {
50758
- console.log(import_chalk20.default.gray(` Variables: ${env.variable_count}, Files: ${env.file_count ?? 0}, Skills: ${env.skill_count ?? 0}, MCPs: ${env.mcp_count ?? 0}`));
50765
+ console.log(import_chalk20.default.gray(` Variables: ${env.variable_count}, Files: ${env.file_count ?? 0}, Added skills: ${env.skill_count ?? 0}, MCPs: ${env.mcp_count ?? 0}`));
50766
+ }
50767
+ if (repoSkillCount !== void 0) {
50768
+ console.log(import_chalk20.default.gray(` Repository skills: ${repoSkillCount}`));
50759
50769
  }
50760
50770
  console.log(import_chalk20.default.gray(` Updated: ${formatDate(env.updated_at)}`));
50761
50771
  console.log();
@@ -50778,11 +50788,16 @@ async function environmentGetCommand(idOrName) {
50778
50788
  ensureOrgApiAuthenticated();
50779
50789
  const id = await resolveEnvironmentId(idOrName);
50780
50790
  const response = await orgAuthenticatedFetch(`/v1/environments/${id}`);
50781
- output2(response, ({ environment: environment2 }) => {
50791
+ const repoSkills = await orgAuthenticatedFetch(`/v1/environments/${response.environment.id}/repo-skills`);
50792
+ output2({ ...response, ...repoSkills }, ({ environment: environment2 }) => {
50782
50793
  console.log(import_chalk20.default.green(`
50783
50794
  Environment: ${environment2.name}
50784
50795
  `));
50785
- printEnvironment(environment2);
50796
+ const linkedSkills = repoSkills.repo_skills.filter((skill) => skill.path.startsWith(`.${skill.framework}/skills/`));
50797
+ printEnvironment(environment2, new Set(linkedSkills.map((skill) => `${skill.repository_id}:${skill.path.split("/")[2]}`)).size);
50798
+ for (const message2 of [repoSkills.error, ...repoSkills.repo_errors.map((repo) => `${repo.repository_full_name}: ${repo.error}`)]) {
50799
+ if (message2) console.log(import_chalk20.default.yellow(` Could not read repository skills: ${message2}`));
50800
+ }
50786
50801
  });
50787
50802
  }
50788
50803
  async function environmentCreateCommand(name, options) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "replicas-cli",
3
- "version": "0.3.347",
3
+ "version": "0.3.349",
4
4
  "description": "CLI for managing Replicas workspaces - SSH into cloud dev environments with automatic port forwarding",
5
5
  "main": "dist/index.cjs",
6
6
  "bin": {