replicas-engine 0.1.1671 → 0.1.1673

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.
@@ -8,12 +8,12 @@ import {
8
8
  listCodexModelsForDetails,
9
9
  restartCodexAspHost,
10
10
  restartCodexAspHostIfRunning
11
- } from "./chunk-HDCQF7AQ.js";
12
- import "./chunk-55OD2MGN.js";
13
- import "./chunk-KJ6QPUJ6.js";
14
- import "./chunk-3EYNKOGU.js";
11
+ } from "./chunk-KJWBQJ7O.js";
12
+ import "./chunk-KLQBH5ER.js";
13
+ import "./chunk-7FIJ3NDE.js";
14
+ import "./chunk-A2AR7HTE.js";
15
15
  import "./chunk-UZSNFLDQ.js";
16
- import "./chunk-D5SSZI5B.js";
16
+ import "./chunk-LLL64U6P.js";
17
17
  import "./chunk-VEQXQN22.js";
18
18
  export {
19
19
  CODEX_ULTRAFAST_SERVICE_TIER,
@@ -3,10 +3,10 @@ import { createRequire as __createRequire } from 'node:module';
3
3
  const require = __createRequire(import.meta.url);
4
4
  import {
5
5
  execFileAsync
6
- } from "./chunk-3EYNKOGU.js";
6
+ } from "./chunk-A2AR7HTE.js";
7
7
  import {
8
8
  isVersionBelow
9
- } from "./chunk-D5SSZI5B.js";
9
+ } from "./chunk-LLL64U6P.js";
10
10
 
11
11
  // src/utils/codex-agent-env.ts
12
12
  function buildCodexAgentEnv(source = process.env) {
@@ -242,7 +242,7 @@ function getCodexModelProvider(method) {
242
242
  if (method === "foundry") return "azure";
243
243
  return method === "ollama" || method === "openai-compatible" ? "replicas_openai_compatible" : "openai";
244
244
  }
245
- var ENGINE_PACKAGE_VERSION = "0.1.1671";
245
+ var ENGINE_PACKAGE_VERSION = "0.1.1673";
246
246
  var INITIALIZE_METHOD = "initialize";
247
247
  var INITIALIZED_NOTIFICATION = "initialized";
248
248
  var ACCOUNT_LOGIN_START_METHOD = "account/login/start";
@@ -3,7 +3,7 @@ import { createRequire as __createRequire } from 'node:module';
3
3
  const require = __createRequire(import.meta.url);
4
4
  import {
5
5
  HOOK_EXEC_MAX_BUFFER_BYTES
6
- } from "./chunk-D5SSZI5B.js";
6
+ } from "./chunk-LLL64U6P.js";
7
7
 
8
8
  // src/utils/exec.ts
9
9
  import { exec, execFile } from "child_process";
@@ -5,7 +5,7 @@ import {
5
5
  ENGINE_ENV,
6
6
  monolithRequest,
7
7
  runGitCommand
8
- } from "./chunk-55OD2MGN.js";
8
+ } from "./chunk-KLQBH5ER.js";
9
9
  import {
10
10
  COMMAND_PROTECTION_MAX_MESSAGE_FILE_BYTES,
11
11
  COMMAND_PROTECTION_REPO_GIT_ARGS,
@@ -18,7 +18,7 @@ import {
18
18
  parseCommandProtectionRequest,
19
19
  toCommandProtectionRepoState,
20
20
  withRetry
21
- } from "./chunk-D5SSZI5B.js";
21
+ } from "./chunk-LLL64U6P.js";
22
22
 
23
23
  // src/services/command-protection-service.ts
24
24
  import { readFile, stat } from "fs/promises";
@@ -12,15 +12,15 @@ import {
12
12
  resolveDiffBase,
13
13
  runGitCommand,
14
14
  setAgentCredentialSnapshot
15
- } from "./chunk-55OD2MGN.js";
15
+ } from "./chunk-KLQBH5ER.js";
16
16
  import {
17
17
  AppServerProcess,
18
18
  buildCodexAgentEnv
19
- } from "./chunk-KJ6QPUJ6.js";
19
+ } from "./chunk-7FIJ3NDE.js";
20
20
  import {
21
21
  SUBPROCESS_MAX_BUFFER,
22
22
  execFileAsync
23
- } from "./chunk-3EYNKOGU.js";
23
+ } from "./chunk-A2AR7HTE.js";
24
24
  import {
25
25
  isRecord
26
26
  } from "./chunk-UZSNFLDQ.js";
@@ -61,7 +61,7 @@ import {
61
61
  shrunkImageSize,
62
62
  splitManagerInstructions,
63
63
  withTimeout
64
- } from "./chunk-D5SSZI5B.js";
64
+ } from "./chunk-LLL64U6P.js";
65
65
 
66
66
  // src/managers/codex-token-manager.ts
67
67
  import { promises as fs } from "fs";
@@ -461,7 +461,7 @@ var CodexTokenManager = class extends BaseRefreshManager {
461
461
  await this.applyCredentialUpdate(++this.credentialGeneration, async () => {
462
462
  await this.applyCredentialsResponse(data);
463
463
  setAgentCredentialSnapshot("codex", data);
464
- const { restartCodexAspHostIfRunning: restartCodexAspHostIfRunning2 } = await import("./asp-host-PKDNKKHF.js");
464
+ const { restartCodexAspHostIfRunning: restartCodexAspHostIfRunning2 } = await import("./asp-host-ZIJHBKY2.js");
465
465
  await restartCodexAspHostIfRunning2();
466
466
  });
467
467
  await this.start(true);
@@ -483,7 +483,7 @@ var CodexTokenManager = class extends BaseRefreshManager {
483
483
  const accountChanged = ENGINE_ENV.REPLICAS_AGENT_CREDENTIALS.codex?.credentialId !== data.credentialId;
484
484
  await this.applyCredentialsResponse(data);
485
485
  if (restartOnChange && (accountChanged || CODEX_AUTH_ENV_KEYS.some((key, index) => process.env[key] !== previousEnv[index]))) {
486
- const { restartCodexAspHostIfRunning: restartCodexAspHostIfRunning2 } = await import("./asp-host-PKDNKKHF.js");
486
+ const { restartCodexAspHostIfRunning: restartCodexAspHostIfRunning2 } = await import("./asp-host-ZIJHBKY2.js");
487
487
  await restartCodexAspHostIfRunning2();
488
488
  }
489
489
  setAgentCredentialSnapshot("codex", data);
@@ -4,7 +4,7 @@ const require = __createRequire(import.meta.url);
4
4
  import {
5
5
  SUBPROCESS_MAX_BUFFER,
6
6
  execFileAsync
7
- } from "./chunk-3EYNKOGU.js";
7
+ } from "./chunk-A2AR7HTE.js";
8
8
  import {
9
9
  isRecord as isRecord2
10
10
  } from "./chunk-UZSNFLDQ.js";
@@ -21,7 +21,7 @@ import {
21
21
  provisionedDeviceSchema,
22
22
  readReplicasRuntimeEnv,
23
23
  serializePosixEnvFile
24
- } from "./chunk-D5SSZI5B.js";
24
+ } from "./chunk-LLL64U6P.js";
25
25
 
26
26
  // src/runtime-env-loader.ts
27
27
  import { readFileSync } from "fs";
@@ -12621,6 +12621,7 @@ import { z as z22 } from "zod";
12621
12621
  // ../shared/src/workspace-attention.ts
12622
12622
  var WORKSPACE_ATTENTION_REASONS = ["question", "plan", "variables", "blocked", "setup", "deploy_failed"];
12623
12623
  var CHAT_ATTENTION_REASONS = ["question", "blocked"];
12624
+ var INPUT_REQUEST_REASONS = ["question", "plan"];
12624
12625
 
12625
12626
  // ../shared/src/routes/push.ts
12626
12627
  var registerPushDeviceRequestSchema = z22.discriminatedUnion("platform", [
@@ -13533,7 +13534,7 @@ Track work in Replicas Issues (\`REP-42\`), the shared to-do list of the people
13533
13534
  Use this when:
13534
13535
  - You are told to work on an issue, or a message names one like \`REP-42\`
13535
13536
  - You receive an \`<issue_event>\` block
13536
- - You open a pull request, finish, get blocked, or need a person to decide something on an issue you work on
13537
+ - You open a pull request, hear one merged, finish, get blocked, or need a person to decide something on an issue you work on
13537
13538
  - Someone asks you to file, update, or split up work`;
13538
13539
  var REFERENCE7 = `# Replicas Issues
13539
13540
 
@@ -13555,6 +13556,7 @@ replicas issue assign REP-42 alice@acme.com # a member's email, user ID, or a
13555
13556
  replicas issue unassign REP-42 alice@acme.com # they stay subscribed
13556
13557
  replicas issue subscribe REP-42 | unsubscribe REP-42
13557
13558
  replicas issue link-pr REP-42 https://github.com/acme/app/pull/12
13559
+ replicas issue unlink-pr REP-42 https://github.com/acme/app/pull/12
13558
13560
  replicas issue relate REP-42 blocks REP-43 | duplicate_of REP-40
13559
13561
  \`\`\`
13560
13562
 
@@ -13574,8 +13576,16 @@ Read the event and act only when it asks something of you: a person's question o
13574
13576
 
13575
13577
  **Keep the status true as you go:**
13576
13578
  1. \`in_progress\` when you start.
13577
- 2. \`in_review\` when its pull request is open, and comment with the link: "Ready for review: <url>". A pull request opened from a workspace assigned to the issue, or whose title or body mentions \`REP-42\`, links itself and moves the issue to \`in_review\`; merging it moves the issue to \`done\`. Mention the identifier in the pull request body.
13578
- 3. \`done\` when the work is shipped and nothing is left; \`canceled\` when it won't be done.
13579
+ 2. \`in_review\` when you open its pull request: link it with \`replicas issue link-pr\`, set the status yourself, and comment "Ready for review: <url>". Open one pull request per issue where you can. Nothing links or changes status on its own: \`Fixes REP-42\` in a pull request body is only documentation.
13580
+ 3. \`done\` when its pull request merges and nothing is left: a linked pull request's merge arrives as an \`<issue_event>\`, and you set the status. \`canceled\` when it won't be done.
13581
+
13582
+ **Statuses mean exactly this**, so a person can read only In review and trust the rest:
13583
+ - \`in_progress\`: work is underway, including fixing CI, answering review comments, resolving conflicts, or waiting on another pull request.
13584
+ - \`in_review\`: waiting only on a person. A linked pull request is open with CI green and needs someone's review or approval; assign that person. Nothing else is in flight. When CI fails or someone pushes changes, move it back to \`in_progress\`.
13585
+ - \`done\`: every linked pull request it needs is merged (and deployed when that matters), and nothing is left. Set it yourself after the merge.
13586
+ - \`canceled\`: dropped, with a comment saying why.
13587
+
13588
+ Keep every property true at all times: status, assignee, linked pull requests (link only the pull requests that do this issue's work; unlink wrong ones with \`replicas issue unlink-pr\` or the app), and the description, when the plan changes. Before ending a turn, check that your issues' statuses match reality.
13579
13589
 
13580
13590
  **Keep the description current**, the way a good PM does: when the scope or the plan changes, edit it rather than burying the change in comment 14. Comments are for progress, questions, and decisions.
13581
13591
 
@@ -16149,7 +16159,7 @@ ${MERGE_RULE}
16149
16159
  ${chatRule("the board", "a finding that changes the answer, a ship you started, or a decision you need")}
16150
16160
  `;
16151
16161
  var ISSUE_RULES = `- Your work lives in issues in your slice of the organization's Issues, which the Issues tab beside this chat shows the user. Before delegating, turn a request into issues with \`replicas issue create\`: one per independent task, so five small bugs are five issues, and a parent with sub-issues for a big project. Reuse an issue the request is about; find it with \`replicas issue list\`. A title says what the task is about, never a ship, branch or pull request name.
16152
- - Spawn ships with \`issue\`, and pass \`issue\` to \`${REPLICAS_MCP_TOOLS.messageSubagent}\` to point a ship at another one: it is assigned, subscribed and told. Several ships can share an issue. Replicas moves an issue to In progress when a ship starts it, In review when its pull request opens and Done when they merge, and ships comment their progress, so never restate what an issue shows. Order, reprioritize or cancel issues with \`replicas issue update\`.
16162
+ - Spawn ships with \`issue\`, and pass \`issue\` to \`${REPLICAS_MCP_TOOLS.messageSubagent}\` to point a ship at another one: it is assigned, subscribed and told. Several ships can share an issue. Replicas moves an issue to In progress when a ship starts it. Ships link their pull requests with \`replicas issue link-pr\`, move the issue to In review themselves, and comment their progress, so never restate what an issue shows. Nothing changes an issue's status when a pull request merges: when you hear a ship's pull request merged and the ship is asleep, link it if it isn't and move the issue to Done if that finishes it. Give a ship one issue per pull request where you can. Statuses mean exactly this: In progress, work underway (including fixing CI, review comments, conflicts, or waiting on another pull request); In review, waiting only on a person, with a linked pull request open, CI green, and the person who must review or approve it assigned, and nothing else in flight (move it back to In progress when CI fails or someone pushes changes); Done, every linked pull request it needs merged (and deployed when that matters) and nothing left; Canceled, dropped, with a comment saying why. Keep every property true at all times: status, assignee, linked pull requests (link only the pull requests that do this issue's work; unlink wrong ones with \`replicas issue unlink-pr\` or the app), and the description, when the plan changes. Before ending a turn, check that your issues' statuses match reality, including those of ships that are asleep. Order, reprioritize or cancel issues with \`replicas issue update\`.
16153
16163
  - You are subscribed to every issue in your slice: comments and changes by ships and people arrive as \`<issue_event>\` blocks. Act on them like ship events. Ships assigned to an issue get its comments too, so never relay a comment to them; pass it only to a ship that isn't on the issue.
16154
16164
  - Ask the user only for decisions you truly can't make. Make routine calls yourself, such as retries, small scope choices or test cleanup. For a decision or merge only they can give, assign them to the issue with \`replicas issue assign\` and comment the question with \`replicas issue comment\`; their reply comes back as an \`<issue_event>\`. Once they answer a question you asked, unassign them with \`replicas issue unassign\` so the issue leaves their "Assigned to you"; they stay subscribed. Ships ask and unassign for their own questions, so leave those to them.
16155
16165
  - 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 assign the user only if you can't decide. On \`ready\` for a pull request that needs a person's review, assign the user with a one-line comment.
@@ -21562,7 +21572,7 @@ async function withRetry(label, fn, options) {
21562
21572
  }
21563
21573
 
21564
21574
  // ../shared/src/tensorlake.ts
21565
- var TENSORLAKE_IMAGE_NAME = "replicas-sandbox-2026-11-20-v19";
21575
+ var TENSORLAKE_IMAGE_NAME = "replicas-sandbox-2026-11-20-v21";
21566
21576
  var TENSORLAKE_DISK_MB = 100 * 1024;
21567
21577
 
21568
21578
  // ../shared/src/egress.ts
@@ -23020,6 +23030,7 @@ var workspaceTurnCompletionSchema = z43.object({
23020
23030
  pullRequestFeedback: z43.boolean().optional(),
23021
23031
  attention: z43.object({ reason: z43.enum(CHAT_ATTENTION_REASONS), userId: z43.string() }).optional()
23022
23032
  });
23033
+ var inputRequestRaisedSchema = z43.object({ reason: z43.enum(INPUT_REQUEST_REASONS), userId: z43.string(), chatId: z43.string(), since: z43.string() });
23023
23034
  var workspaceEventSchemaByType = z43.discriminatedUnion("type", [
23024
23035
  z43.object({
23025
23036
  type: z43.literal("workspace.changed"),
@@ -23073,7 +23084,7 @@ var workspaceEventSchemaByType = z43.discriminatedUnion("type", [
23073
23084
  }),
23074
23085
  z43.object({ type: z43.enum(["manager.board.changed", "mothership.board.changed"]), workspaceId: z43.string(), ts: z43.string() }),
23075
23086
  z43.object({ type: z43.literal("issues.synced"), syncId: z43.number(), ts: z43.string() }),
23076
- z43.object({ type: z43.literal("needs-you.changed"), workspaceId: z43.string().nullable(), userId: z43.string().optional(), ts: z43.string() }),
23087
+ z43.object({ type: z43.literal("needs-you.changed"), workspaceId: z43.string().nullable(), userId: z43.string().optional(), request: inputRequestRaisedSchema.optional(), ts: z43.string() }),
23077
23088
  z43.object({
23078
23089
  type: z43.literal("workspace.shared"),
23079
23090
  workspaceId: z43.string(),
@@ -5,7 +5,7 @@ import {
5
5
  extractCommandProtectionCommandText,
6
6
  isRecord,
7
7
  parseCodeHostPrUrl
8
- } from "./chunk-D5SSZI5B.js";
8
+ } from "./chunk-LLL64U6P.js";
9
9
 
10
10
  // src/services/published-pull-request-urls.ts
11
11
  function publishedPullRequestUrls(result) {
@@ -3,7 +3,7 @@ import { createRequire as __createRequire } from 'node:module';
3
3
  const require = __createRequire(import.meta.url);
4
4
  import {
5
5
  AspClient
6
- } from "./chunk-KJ6QPUJ6.js";
6
+ } from "./chunk-7FIJ3NDE.js";
7
7
  import {
8
8
  ASTER_BASE_URL,
9
9
  ASTER_PROVIDER,
@@ -15,7 +15,7 @@ import {
15
15
  isRecord,
16
16
  readOllamaAuthEnv,
17
17
  readOpenAICompatibleAuthEnv
18
- } from "./chunk-D5SSZI5B.js";
18
+ } from "./chunk-LLL64U6P.js";
19
19
 
20
20
  // src/managers/codex-asp/notification-dispatch.ts
21
21
  var TURN_STARTED_METHOD = "turn/started";
@@ -3,13 +3,13 @@ import { createRequire as __createRequire } from 'node:module';
3
3
  const require = __createRequire(import.meta.url);
4
4
  import {
5
5
  evaluateCommandProtection
6
- } from "./chunk-4KUQJQPT.js";
7
- import "./chunk-55OD2MGN.js";
8
- import "./chunk-3EYNKOGU.js";
6
+ } from "./chunk-EGLNDZLJ.js";
7
+ import "./chunk-KLQBH5ER.js";
8
+ import "./chunk-A2AR7HTE.js";
9
9
  import {
10
10
  isRecord
11
11
  } from "./chunk-UZSNFLDQ.js";
12
- import "./chunk-D5SSZI5B.js";
12
+ import "./chunk-LLL64U6P.js";
13
13
  import "./chunk-VEQXQN22.js";
14
14
 
15
15
  // src/command-protection-hook.ts
@@ -14,12 +14,12 @@ import {
14
14
  recoverCompletedTurn,
15
15
  spawnMuseMsp,
16
16
  startMuseSession
17
- } from "./chunk-SLFFVHAI.js";
17
+ } from "./chunk-W4NAJNGD.js";
18
18
  import {
19
19
  AppServerProcess,
20
20
  buildCodexAgentEnv
21
- } from "./chunk-KJ6QPUJ6.js";
22
- import "./chunk-3EYNKOGU.js";
21
+ } from "./chunk-7FIJ3NDE.js";
22
+ import "./chunk-A2AR7HTE.js";
23
23
  import {
24
24
  AGENT,
25
25
  OPENCODE_GO_PROVIDER,
@@ -29,7 +29,7 @@ import {
29
29
  headlessAgentUsagePath,
30
30
  isRecord,
31
31
  withTimeout
32
- } from "./chunk-D5SSZI5B.js";
32
+ } from "./chunk-LLL64U6P.js";
33
33
  import "./chunk-VEQXQN22.js";
34
34
 
35
35
  // src/headless-agent.ts
package/dist/src/index.js CHANGED
@@ -91,7 +91,7 @@ import {
91
91
  evaluateCommandProtection,
92
92
  extractToolCommand,
93
93
  reportCommandProtectionBlock
94
- } from "./chunk-4KUQJQPT.js";
94
+ } from "./chunk-EGLNDZLJ.js";
95
95
  import {
96
96
  ACCOUNT_RATE_LIMITS_UPDATED_METHOD,
97
97
  AGENT_MESSAGE_DELTA_METHOD,
@@ -129,10 +129,10 @@ import {
129
129
  spawnMuseMsp,
130
130
  startMuseSession,
131
131
  uuidV7
132
- } from "./chunk-SLFFVHAI.js";
132
+ } from "./chunk-W4NAJNGD.js";
133
133
  import {
134
134
  publishedPullRequestUrls
135
- } from "./chunk-3RZH5OUF.js";
135
+ } from "./chunk-NN4XDT6W.js";
136
136
  import {
137
137
  ACCOUNT_RATE_LIMITS_READ_METHOD,
138
138
  AsyncLock,
@@ -212,7 +212,7 @@ import {
212
212
  transcriptSecrets,
213
213
  upsertCredentialFileLines,
214
214
  writeSecureCredentialFile
215
- } from "./chunk-HDCQF7AQ.js";
215
+ } from "./chunk-KJWBQJ7O.js";
216
216
  import {
217
217
  ENGINE_ENV,
218
218
  UNQUOTED_PATHS_CONFIG,
@@ -223,17 +223,17 @@ import {
223
223
  resolveDiffBase,
224
224
  setAgentCredentialSnapshot,
225
225
  setLinearSessionId
226
- } from "./chunk-55OD2MGN.js";
226
+ } from "./chunk-KLQBH5ER.js";
227
227
  import {
228
228
  AspRequestTimeoutError,
229
229
  buildCodexAgentEnv,
230
230
  getCodexModelProvider
231
- } from "./chunk-KJ6QPUJ6.js";
231
+ } from "./chunk-7FIJ3NDE.js";
232
232
  import {
233
233
  SUBPROCESS_MAX_BUFFER,
234
234
  execAsync,
235
235
  execFileAsync
236
- } from "./chunk-3EYNKOGU.js";
236
+ } from "./chunk-A2AR7HTE.js";
237
237
  import {
238
238
  isRecord as isRecord2
239
239
  } from "./chunk-UZSNFLDQ.js";
@@ -533,7 +533,7 @@ import {
533
533
  workspaceTokenRequestSchema,
534
534
  workspaceTokenResponseSchema,
535
535
  wrapInTag
536
- } from "./chunk-D5SSZI5B.js";
536
+ } from "./chunk-LLL64U6P.js";
537
537
  import {
538
538
  __commonJS,
539
539
  __export,
@@ -3,13 +3,13 @@ import { createRequire as __createRequire } from 'node:module';
3
3
  const require = __createRequire(import.meta.url);
4
4
  import {
5
5
  publishedPullRequestUrls
6
- } from "./chunk-3RZH5OUF.js";
6
+ } from "./chunk-NN4XDT6W.js";
7
7
  import {
8
8
  isRecord
9
9
  } from "./chunk-UZSNFLDQ.js";
10
10
  import {
11
11
  shouldRefreshPullRequests
12
- } from "./chunk-D5SSZI5B.js";
12
+ } from "./chunk-LLL64U6P.js";
13
13
  import "./chunk-VEQXQN22.js";
14
14
 
15
15
  // src/services/post-tool-pr-notifier.ts
@@ -11,7 +11,7 @@ import {
11
11
  spawnSubagentRequestSchema,
12
12
  subagentResponseSchema,
13
13
  waitSubagentRequestSchema
14
- } from "./chunk-D5SSZI5B.js";
14
+ } from "./chunk-LLL64U6P.js";
15
15
  import "./chunk-VEQXQN22.js";
16
16
 
17
17
  // src/subagent-mcp.ts
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "replicas-engine",
3
- "version": "0.1.1671",
3
+ "version": "0.1.1673",
4
4
  "description": "Lightweight API server for Replicas workspaces",
5
5
  "type": "module",
6
6
  "main": "dist/src/index.js",