replicas-engine 0.1.1599 → 0.1.1601
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/src/{asp-host-I6D3XFCU.js → asp-host-OTRP5WWS.js} +5 -5
- package/dist/src/{chunk-H46T66CK.js → chunk-4XXV6XF7.js} +1 -1
- package/dist/src/{chunk-67JKD6VG.js → chunk-6DGCGNRD.js} +1 -1
- package/dist/src/{chunk-MPK36Q6E.js → chunk-E5U45B5E.js} +3 -3
- package/dist/src/{chunk-DT6WSNCT.js → chunk-LAVIBP35.js} +2 -2
- package/dist/src/{chunk-JIQRYCNB.js → chunk-LM3GPSH5.js} +6 -6
- package/dist/src/{chunk-U6KFB3LG.js → chunk-O76HWQZW.js} +2 -2
- package/dist/src/{chunk-ILBD3KEP.js → chunk-PUN65MPP.js} +2 -2
- package/dist/src/{chunk-OUWKFKBD.js → chunk-Z744SRUU.js} +437 -228
- package/dist/src/command-protection-hook.js +4 -4
- package/dist/src/headless-agent.js +6 -4
- package/dist/src/index.js +18 -12
- package/dist/src/post-tool-pr-hook.js +2 -2
- package/dist/src/subagent-mcp.js +1 -1
- package/package.json +1 -1
|
@@ -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-
|
|
7
|
-
import "./chunk-
|
|
8
|
-
import "./chunk-
|
|
6
|
+
} from "./chunk-O76HWQZW.js";
|
|
7
|
+
import "./chunk-LAVIBP35.js";
|
|
8
|
+
import "./chunk-6DGCGNRD.js";
|
|
9
9
|
import {
|
|
10
10
|
isRecord
|
|
11
11
|
} from "./chunk-UZSNFLDQ.js";
|
|
12
|
-
import "./chunk-
|
|
12
|
+
import "./chunk-Z744SRUU.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-
|
|
17
|
+
} from "./chunk-PUN65MPP.js";
|
|
18
18
|
import {
|
|
19
19
|
AppServerProcess,
|
|
20
20
|
buildCodexAgentEnv
|
|
21
|
-
} from "./chunk-
|
|
22
|
-
import "./chunk-
|
|
21
|
+
} from "./chunk-E5U45B5E.js";
|
|
22
|
+
import "./chunk-6DGCGNRD.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-
|
|
32
|
+
} from "./chunk-Z744SRUU.js";
|
|
33
33
|
import "./chunk-VEQXQN22.js";
|
|
34
34
|
|
|
35
35
|
// src/headless-agent.ts
|
|
@@ -288,6 +288,8 @@ async function main() {
|
|
|
288
288
|
break;
|
|
289
289
|
case AGENT.PI:
|
|
290
290
|
throw new Error("Send Pi credentials as an Opencode request, which reads the same stored secrets");
|
|
291
|
+
case AGENT.REPLICAS:
|
|
292
|
+
throw new Error("Replicas chats run on the harness worker, not the engine");
|
|
291
293
|
default: {
|
|
292
294
|
const unsupported = request.agent;
|
|
293
295
|
throw new Error(`Unsupported headless agent: ${String(unsupported)}`);
|
package/dist/src/index.js
CHANGED
|
@@ -27,7 +27,7 @@ import {
|
|
|
27
27
|
evaluateCommandProtection,
|
|
28
28
|
extractToolCommand,
|
|
29
29
|
reportCommandProtectionBlock
|
|
30
|
-
} from "./chunk-
|
|
30
|
+
} from "./chunk-O76HWQZW.js";
|
|
31
31
|
import {
|
|
32
32
|
ACCOUNT_RATE_LIMITS_UPDATED_METHOD,
|
|
33
33
|
AGENT_MESSAGE_DELTA_METHOD,
|
|
@@ -65,10 +65,10 @@ import {
|
|
|
65
65
|
spawnMuseMsp,
|
|
66
66
|
startMuseSession,
|
|
67
67
|
uuidV7
|
|
68
|
-
} from "./chunk-
|
|
68
|
+
} from "./chunk-PUN65MPP.js";
|
|
69
69
|
import {
|
|
70
70
|
publishedPullRequestUrls
|
|
71
|
-
} from "./chunk-
|
|
71
|
+
} from "./chunk-4XXV6XF7.js";
|
|
72
72
|
import {
|
|
73
73
|
ACCOUNT_RATE_LIMITS_READ_METHOD,
|
|
74
74
|
AsyncLock,
|
|
@@ -147,7 +147,7 @@ import {
|
|
|
147
147
|
transcriptSecrets,
|
|
148
148
|
upsertCredentialFileLines,
|
|
149
149
|
writeSecureCredentialFile
|
|
150
|
-
} from "./chunk-
|
|
150
|
+
} from "./chunk-LM3GPSH5.js";
|
|
151
151
|
import {
|
|
152
152
|
ENGINE_ENV,
|
|
153
153
|
UNQUOTED_PATHS_CONFIG,
|
|
@@ -158,16 +158,16 @@ import {
|
|
|
158
158
|
resolveDiffBase,
|
|
159
159
|
setAgentCredentialSnapshot,
|
|
160
160
|
setLinearSessionId
|
|
161
|
-
} from "./chunk-
|
|
161
|
+
} from "./chunk-LAVIBP35.js";
|
|
162
162
|
import {
|
|
163
163
|
buildCodexAgentEnv,
|
|
164
164
|
getCodexModelProvider
|
|
165
|
-
} from "./chunk-
|
|
165
|
+
} from "./chunk-E5U45B5E.js";
|
|
166
166
|
import {
|
|
167
167
|
SUBPROCESS_MAX_BUFFER,
|
|
168
168
|
execAsync,
|
|
169
169
|
execFileAsync
|
|
170
|
-
} from "./chunk-
|
|
170
|
+
} from "./chunk-6DGCGNRD.js";
|
|
171
171
|
import {
|
|
172
172
|
isRecord as isRecord2
|
|
173
173
|
} from "./chunk-UZSNFLDQ.js";
|
|
@@ -382,6 +382,7 @@ import {
|
|
|
382
382
|
isCodexAuthError,
|
|
383
383
|
isCompactCommand,
|
|
384
384
|
isDefaultChat,
|
|
385
|
+
isEngineAgentProvider,
|
|
385
386
|
isExcludedRepoFilePath,
|
|
386
387
|
isLatestChatHistoryPage,
|
|
387
388
|
isNonEmptyString,
|
|
@@ -393,7 +394,6 @@ import {
|
|
|
393
394
|
isTokenUsageUploadRecord,
|
|
394
395
|
isToolInputQuestion,
|
|
395
396
|
isTransientErrorText,
|
|
396
|
-
isValidAgentProvider,
|
|
397
397
|
isValidEngineLogSessionId,
|
|
398
398
|
isValidThinkingLevel,
|
|
399
399
|
lastPlainStepLabel,
|
|
@@ -463,7 +463,7 @@ import {
|
|
|
463
463
|
workspaceTokenRequestSchema,
|
|
464
464
|
workspaceTokenResponseSchema,
|
|
465
465
|
wrapInTag
|
|
466
|
-
} from "./chunk-
|
|
466
|
+
} from "./chunk-Z744SRUU.js";
|
|
467
467
|
import {
|
|
468
468
|
cloneMcpConfig,
|
|
469
469
|
ensureCompatibilityImports,
|
|
@@ -9955,6 +9955,8 @@ function detectAgentAuthMethod(provider) {
|
|
|
9955
9955
|
case AGENT.PI:
|
|
9956
9956
|
if (readOpenAICompatibleAuthEnv(provider, process.env)) return "openai-compatible";
|
|
9957
9957
|
return existsSync(provider === AGENT.OPENCODE ? OPENCODE_AUTH_PATH : PI_AUTH_PATH) ? "api_key" : "none";
|
|
9958
|
+
case AGENT.REPLICAS:
|
|
9959
|
+
return "none";
|
|
9958
9960
|
}
|
|
9959
9961
|
}
|
|
9960
9962
|
function isAgentAvailable(provider) {
|
|
@@ -11158,7 +11160,7 @@ import { z as z4 } from "zod";
|
|
|
11158
11160
|
|
|
11159
11161
|
// ../shared/src/persisted-query-hashes.ts
|
|
11160
11162
|
var PERSISTED_QUERY_HASHES = {
|
|
11161
|
-
workspaceChats: "
|
|
11163
|
+
workspaceChats: "79951346"
|
|
11162
11164
|
};
|
|
11163
11165
|
|
|
11164
11166
|
// ../shared/src/workspace-chat.ts
|
|
@@ -14439,7 +14441,10 @@ var ClaudeManager = class _ClaudeManager extends CodingAgentManager {
|
|
|
14439
14441
|
env: {
|
|
14440
14442
|
...shared.env,
|
|
14441
14443
|
// A resumed session reports tools from a still-connecting MCP server as removed, so the agent stops using them.
|
|
14442
|
-
|
|
14444
|
+
// A new session waits too: tools that connect after its first request stay out of its tool list, so the next process would send a different list and rewrite the whole prompt cache.
|
|
14445
|
+
MCP_CONNECTION_NONBLOCKING: "false",
|
|
14446
|
+
// That wait ends after 5 seconds. Without this, a chat that passes a server of its own would go on waiting for every server still connecting, up to 30 seconds.
|
|
14447
|
+
CLAUDE_CODE_MCP_STARTUP_WAIT_MS: "0",
|
|
14443
14448
|
...resolveClaudeAuthMethodForMessage() === "ollama" ? {
|
|
14444
14449
|
ANTHROPIC_DEFAULT_SONNET_MODEL: resolvedModel,
|
|
14445
14450
|
ANTHROPIC_DEFAULT_OPUS_MODEL: resolvedModel,
|
|
@@ -61539,7 +61544,7 @@ function isPersistedChat(value) {
|
|
|
61539
61544
|
return false;
|
|
61540
61545
|
}
|
|
61541
61546
|
const candidate = value;
|
|
61542
|
-
return typeof candidate.id === "string" && typeof candidate.provider === "string" &&
|
|
61547
|
+
return typeof candidate.id === "string" && typeof candidate.provider === "string" && isEngineAgentProvider(candidate.provider) && typeof candidate.title === "string" && (candidate.displayName === void 0 || typeof candidate.displayName === "string") && typeof candidate.createdAt === "string" && typeof candidate.updatedAt === "string" && (candidate.providerSessionId === null || typeof candidate.providerSessionId === "string") && (candidate.parentChatId === void 0 || candidate.parentChatId === null || typeof candidate.parentChatId === "string") && (candidate.deletedAt === void 0 || candidate.deletedAt === null || typeof candidate.deletedAt === "string");
|
|
61543
61548
|
}
|
|
61544
61549
|
function normalizePersistedChat(chat) {
|
|
61545
61550
|
return {
|
|
@@ -61990,6 +61995,7 @@ var ChatService = class {
|
|
|
61990
61995
|
return { ...forwarded, chatId: forwarded.chatId ?? continuation.id };
|
|
61991
61996
|
}
|
|
61992
61997
|
const { provider, ...sameHarnessRequest } = request;
|
|
61998
|
+
if (provider && !isEngineAgentProvider(provider)) throw new ChatProviderUnavailableError(provider);
|
|
61993
61999
|
if (provider && provider !== chat.persisted.provider) return this.switchHarness(chat, { ...sameHarnessRequest, provider });
|
|
61994
62000
|
request = sameHarnessRequest;
|
|
61995
62001
|
const nameFromMessage = !chat.persisted.displayName && !chat.persisted.fork && !chat.persisted.parentChatId && getChatKind(chat.persisted) === "standard" && hasGeneratedChatTitle(chat.persisted) && !hasChatStarted(this.toSummary(chat));
|
|
@@ -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-
|
|
6
|
+
} from "./chunk-4XXV6XF7.js";
|
|
7
7
|
import {
|
|
8
8
|
isRecord
|
|
9
9
|
} from "./chunk-UZSNFLDQ.js";
|
|
10
10
|
import {
|
|
11
11
|
shouldRefreshPullRequests
|
|
12
|
-
} from "./chunk-
|
|
12
|
+
} from "./chunk-Z744SRUU.js";
|
|
13
13
|
import "./chunk-VEQXQN22.js";
|
|
14
14
|
|
|
15
15
|
// src/services/post-tool-pr-notifier.ts
|
package/dist/src/subagent-mcp.js
CHANGED