@tryarcanist/cli 0.1.249 → 0.1.251
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 +2 -3
- package/dist/index.js +76 -16
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -191,7 +191,6 @@ printf "add tests" | arcanist sessions create your-org/your-repo --prompt-stdin
|
|
|
191
191
|
arcanist sessions create your-org/your-repo - --model gpt-5.5
|
|
192
192
|
arcanist sessions create your-org/your-repo "port to claude" --backend claude_code --model claude-opus-4-8
|
|
193
193
|
arcanist sessions create your-org/your-repo "refactor auth" --reasoning-effort xhigh
|
|
194
|
-
arcanist sessions create your-org/your-repo "verify this automatically" --auto-verify
|
|
195
194
|
arcanist sessions create your-org/your-repo "use the saved login" --browser-identity identity-id
|
|
196
195
|
arcanist sessions create your-org/your-repo "start signed out" --browser-identity none
|
|
197
196
|
arcanist sessions create your-org/your-repo "fix release branch" --base-branch release/2026-06
|
|
@@ -203,7 +202,7 @@ arcanist sessions create your-org/your-repo "retry-safe create" --idempotency-ke
|
|
|
203
202
|
|
|
204
203
|
`--wait` blocks until the created prompt finishes, prints the resulting PR/branch line in human-readable mode when it is already available, and exits non-zero if the prompt finishes with `status: failed`, making it suitable for cron or other schedulers that alert on command failure. JSON mode waits quietly and prints the create payload after the prompt completes successfully. `--poll-interval <ms>` tunes the completion check frequency.
|
|
205
204
|
|
|
206
|
-
|
|
205
|
+
`--auto-verify` is a deprecated no-op. The verifier child is no longer spawned at publish — QA runs only on an explicit request (GitHub `/qa`, Slack `/qa`, API, or the UI "Verify"/"QA Test PR" button). The flag is accepted for backward compatibility and no longer starts a verifier.
|
|
207
206
|
|
|
208
207
|
Use `--browser-identity <id|none>` to attach a business browser identity to the session, or pass `none` to explicitly start without one. Access is authorized by the control plane when the session is created.
|
|
209
208
|
|
|
@@ -225,7 +224,7 @@ Sessions always start from a fresh sandbox (the warm sandbox pool was removed).
|
|
|
225
224
|
`--idempotency-key <uuid>` is for manually retrying a create request that may have reached the server.
|
|
226
225
|
The CLI derives separate session and prompt idempotency keys from the provided value.
|
|
227
226
|
|
|
228
|
-
`--onboarding` creates an onboarding session: the agent authors the repo's `.arcanist.json` (`appRuntime` runtime contract plus optional `verify`
|
|
227
|
+
`--onboarding` creates an onboarding session: the agent authors the repo's `.arcanist.json` (`appRuntime` runtime contract plus optional legacy `verify` metadata), a root `REVIEW.md` with repo-specific review checks (skipped only when the repo yields none), `.arcanist/` runtime files as needed, and `ARCANIST.md` only when the repo has no usable project doc, proves what it can inside its sandbox, and opens the setup PR ready for review. Zeus discovers and observes review commands itself; the live server-side `repo_review_config.verify_config_json` surface supplies test-coverage lens overrides. The onboarding behavior is driven by the bridge's canonical onboarding playbook, not the prompt, so `--onboarding` needs no prompt: `arcanist sessions create <repo> --onboarding --wait`. Any prompt supplied alongside `--onboarding` is ignored. Team use; not part of the external API surface.
|
|
229
228
|
|
|
230
229
|
JSON mode returns `{sessionId, sessionUrl?, repoUrl, model?, agentRuntimeBackend?, reasoningEffort?, autoVerify?, baseBranch?, startBranch?, continuePrUrl?, continueMode?, onboarding?, promptId?}`. `sessionUrl` is emitted only when the server returns it; `agentRuntimeBackend` only when `--backend` is passed. With `--wait`, JSON mode also includes best-effort result fields when available: `prUrl?`, `publishedBranch?`, and `lastBranch?`.
|
|
231
230
|
|
package/dist/index.js
CHANGED
|
@@ -1,4 +1,6 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
+
import { createRequire as __arcanistCreateRequire } from "node:module";
|
|
3
|
+
const require = __arcanistCreateRequire(import.meta.url);
|
|
2
4
|
var __create = Object.create;
|
|
3
5
|
var __defProp = Object.defineProperty;
|
|
4
6
|
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
@@ -7993,6 +7995,7 @@ function assertSameAttempt(triggeredSessionId, settledSessionId, label) {
|
|
|
7993
7995
|
var PHASES = [
|
|
7994
7996
|
"idle",
|
|
7995
7997
|
"running",
|
|
7998
|
+
"review_starting",
|
|
7996
7999
|
"waiting_for_input",
|
|
7997
8000
|
"finalizing",
|
|
7998
8001
|
"review_listening",
|
|
@@ -8312,6 +8315,9 @@ var MODEL_REGISTRY = [
|
|
|
8312
8315
|
// Default codex model after the gpt-5.5 downgrade; carries gpt-5.5's prior
|
|
8313
8316
|
// "medium" default so default sessions keep the same reasoning effort.
|
|
8314
8317
|
reasoning: { efforts: ["none", "low", "medium", "high", "xhigh"], default: "medium" },
|
|
8318
|
+
// No cacheWritePerMillion: the pricing page shows a dash in the cache-writes
|
|
8319
|
+
// column for gpt-5.4 and gpt-5.5, so the absence is deliberate, not an
|
|
8320
|
+
// oversight (checked 2026-07-30). The 5.6 family does publish that rate.
|
|
8315
8321
|
pricing: {
|
|
8316
8322
|
inputPerMillion: 2.5,
|
|
8317
8323
|
outputPerMillion: 15,
|
|
@@ -8334,17 +8340,21 @@ var MODEL_REGISTRY = [
|
|
|
8334
8340
|
contextWindow: 105e4,
|
|
8335
8341
|
// Verified 2026-07-09 against OpenAI's GPT-5.6 migration guide and model
|
|
8336
8342
|
// catalog: the alias routes to gpt-5.6-sol and supports max effort. Pricing
|
|
8337
|
-
// mirrors gpt-5.6-sol since the alias resolves to it.
|
|
8343
|
+
// mirrors gpt-5.6-sol since the alias resolves to it. Cache-write rates
|
|
8344
|
+
// verified 2026-07-30 against the Standard tier at
|
|
8345
|
+
// developers.openai.com/api/docs/pricing.
|
|
8338
8346
|
reasoning: { efforts: ["none", "low", "medium", "high", "xhigh", "max"], default: "medium" },
|
|
8339
8347
|
pricing: {
|
|
8340
8348
|
inputPerMillion: 5,
|
|
8341
8349
|
outputPerMillion: 30,
|
|
8342
8350
|
cacheReadPerMillion: 0.5,
|
|
8351
|
+
cacheWritePerMillion: 6.25,
|
|
8343
8352
|
longContext: {
|
|
8344
8353
|
thresholdTokens: 272e3,
|
|
8345
8354
|
inputPerMillion: 10,
|
|
8346
8355
|
outputPerMillion: 45,
|
|
8347
|
-
cacheReadPerMillion: 1
|
|
8356
|
+
cacheReadPerMillion: 1,
|
|
8357
|
+
cacheWritePerMillion: 12.5
|
|
8348
8358
|
}
|
|
8349
8359
|
},
|
|
8350
8360
|
sessionStart: { eligible: true }
|
|
@@ -8357,15 +8367,19 @@ var MODEL_REGISTRY = [
|
|
|
8357
8367
|
capabilities: { codexToolSearch: true },
|
|
8358
8368
|
contextWindow: 105e4,
|
|
8359
8369
|
reasoning: { efforts: ["none", "low", "medium", "high", "xhigh", "max"], default: "medium" },
|
|
8370
|
+
// Cache-write rates verified 2026-07-30 against the Standard tier at
|
|
8371
|
+
// developers.openai.com/api/docs/pricing.
|
|
8360
8372
|
pricing: {
|
|
8361
8373
|
inputPerMillion: 5,
|
|
8362
8374
|
outputPerMillion: 30,
|
|
8363
8375
|
cacheReadPerMillion: 0.5,
|
|
8376
|
+
cacheWritePerMillion: 6.25,
|
|
8364
8377
|
longContext: {
|
|
8365
8378
|
thresholdTokens: 272e3,
|
|
8366
8379
|
inputPerMillion: 10,
|
|
8367
8380
|
outputPerMillion: 45,
|
|
8368
|
-
cacheReadPerMillion: 1
|
|
8381
|
+
cacheReadPerMillion: 1,
|
|
8382
|
+
cacheWritePerMillion: 12.5
|
|
8369
8383
|
}
|
|
8370
8384
|
},
|
|
8371
8385
|
sessionStart: { eligible: true }
|
|
@@ -8378,15 +8392,20 @@ var MODEL_REGISTRY = [
|
|
|
8378
8392
|
capabilities: { codexToolSearch: true },
|
|
8379
8393
|
contextWindow: 105e4,
|
|
8380
8394
|
reasoning: { efforts: ["none", "low", "medium", "high", "xhigh", "max"], default: "medium" },
|
|
8395
|
+
// Verified 2026-07-30 against the Standard tier at
|
|
8396
|
+
// developers.openai.com/api/docs/pricing: short and long context input,
|
|
8397
|
+
// cached input, cache writes, and output.
|
|
8381
8398
|
pricing: {
|
|
8382
|
-
inputPerMillion: 2
|
|
8383
|
-
outputPerMillion:
|
|
8384
|
-
cacheReadPerMillion: 0.
|
|
8399
|
+
inputPerMillion: 2,
|
|
8400
|
+
outputPerMillion: 12,
|
|
8401
|
+
cacheReadPerMillion: 0.2,
|
|
8402
|
+
cacheWritePerMillion: 2.5,
|
|
8385
8403
|
longContext: {
|
|
8386
8404
|
thresholdTokens: 272e3,
|
|
8387
|
-
inputPerMillion:
|
|
8388
|
-
outputPerMillion:
|
|
8389
|
-
cacheReadPerMillion: 0.
|
|
8405
|
+
inputPerMillion: 4,
|
|
8406
|
+
outputPerMillion: 18,
|
|
8407
|
+
cacheReadPerMillion: 0.4,
|
|
8408
|
+
cacheWritePerMillion: 5
|
|
8390
8409
|
}
|
|
8391
8410
|
},
|
|
8392
8411
|
sessionStart: { eligible: true }
|
|
@@ -8395,19 +8414,25 @@ var MODEL_REGISTRY = [
|
|
|
8395
8414
|
id: OpenAIModel.GPT56Luna,
|
|
8396
8415
|
name: "GPT-5.6 Luna",
|
|
8397
8416
|
provider: "openai",
|
|
8417
|
+
overloadFallback: OpenAIModel.GPT56Terra,
|
|
8398
8418
|
backends: [CODEX_AGENT_RUNTIME_BACKEND],
|
|
8399
8419
|
capabilities: { codexToolSearch: true },
|
|
8400
8420
|
contextWindow: 105e4,
|
|
8401
8421
|
reasoning: { efforts: ["none", "low", "medium", "high", "xhigh", "max"], default: "medium" },
|
|
8422
|
+
// Verified 2026-07-30 against the Standard tier at
|
|
8423
|
+
// developers.openai.com/api/docs/pricing: short and long context input,
|
|
8424
|
+
// cached input, cache writes, and output.
|
|
8402
8425
|
pricing: {
|
|
8403
|
-
inputPerMillion:
|
|
8404
|
-
outputPerMillion:
|
|
8405
|
-
cacheReadPerMillion: 0.
|
|
8426
|
+
inputPerMillion: 0.2,
|
|
8427
|
+
outputPerMillion: 1.2,
|
|
8428
|
+
cacheReadPerMillion: 0.02,
|
|
8429
|
+
cacheWritePerMillion: 0.25,
|
|
8406
8430
|
longContext: {
|
|
8407
8431
|
thresholdTokens: 272e3,
|
|
8408
|
-
inputPerMillion:
|
|
8409
|
-
outputPerMillion:
|
|
8410
|
-
cacheReadPerMillion: 0.
|
|
8432
|
+
inputPerMillion: 0.4,
|
|
8433
|
+
outputPerMillion: 1.8,
|
|
8434
|
+
cacheReadPerMillion: 0.04,
|
|
8435
|
+
cacheWritePerMillion: 0.5
|
|
8411
8436
|
}
|
|
8412
8437
|
},
|
|
8413
8438
|
sessionStart: { eligible: true }
|
|
@@ -9636,7 +9661,8 @@ function projectRetryStatus(data, index) {
|
|
|
9636
9661
|
...typeof data?.scope === "string" ? { scope: data.scope } : {},
|
|
9637
9662
|
...typeof data?.maxAttempts === "number" ? { maxAttempts: data.maxAttempts } : {},
|
|
9638
9663
|
...typeof data?.reason === "string" ? { reason: data.reason } : {},
|
|
9639
|
-
...typeof data?.retryAfterMs === "number" ? { retryAfterMs: data.retryAfterMs } : {}
|
|
9664
|
+
...typeof data?.retryAfterMs === "number" ? { retryAfterMs: data.retryAfterMs } : {},
|
|
9665
|
+
...typeof data?.fallbackModel === "string" ? { fallbackModel: data.fallbackModel } : {}
|
|
9640
9666
|
};
|
|
9641
9667
|
}
|
|
9642
9668
|
function projectPromptRetrying(data, index) {
|
|
@@ -10105,6 +10131,16 @@ function resolveAuthoritativePromptEventsWithDiagnostics(raw) {
|
|
|
10105
10131
|
};
|
|
10106
10132
|
}
|
|
10107
10133
|
|
|
10134
|
+
// ../../shared/transcript/review-prompt-sections.ts
|
|
10135
|
+
var REVIEW_CALIBRATION_SECTION_HEADING = "## Previously declined findings on this repository (calibration)";
|
|
10136
|
+
var REVIEW_EXISTING_BOT_FINDINGS_SECTION_HEADING = "## Findings already reported by other reviewers";
|
|
10137
|
+
var REVIEW_STACK_NEIGHBOURS_SECTION_HEADING = "## Graphite stack neighbours";
|
|
10138
|
+
var REVIEW_PROMPT_ENRICHMENT_SECTION_HEADINGS = [
|
|
10139
|
+
REVIEW_CALIBRATION_SECTION_HEADING,
|
|
10140
|
+
REVIEW_EXISTING_BOT_FINDINGS_SECTION_HEADING,
|
|
10141
|
+
REVIEW_STACK_NEIGHBOURS_SECTION_HEADING
|
|
10142
|
+
];
|
|
10143
|
+
|
|
10108
10144
|
// ../../shared/transcript/prompt-display.ts
|
|
10109
10145
|
var WRAPPED_CONTENT_BLOCK_RE = /<(user_content|instruction_content)\b[^>]*>[\s\S]*?<\/\1>/gi;
|
|
10110
10146
|
var SCAFFOLDING_LINE_PATTERNS = [
|
|
@@ -10132,6 +10168,25 @@ var SCAFFOLDING_MARKERS = [
|
|
|
10132
10168
|
/^Repository:\s+\S+$/im,
|
|
10133
10169
|
/^\[arcanist:review-loop\b/im
|
|
10134
10170
|
];
|
|
10171
|
+
var REVIEW_PROMPT_FIRST_LINE_RE = /^Review pull request \S+ at its current head\./;
|
|
10172
|
+
function stripReviewPromptEnrichment(text) {
|
|
10173
|
+
const lines = text.split(/\r?\n/);
|
|
10174
|
+
const headingIndexes = [];
|
|
10175
|
+
const cutLineIndexes = [];
|
|
10176
|
+
lines.forEach((line, lineIndex) => {
|
|
10177
|
+
const headingIndex = REVIEW_PROMPT_ENRICHMENT_SECTION_HEADINGS.findIndex((heading) => line.trim() === heading);
|
|
10178
|
+
if (headingIndex === -1) return;
|
|
10179
|
+
headingIndexes.push(headingIndex);
|
|
10180
|
+
cutLineIndexes.push(lineIndex);
|
|
10181
|
+
});
|
|
10182
|
+
if (cutLineIndexes.length === 0) return text.trim();
|
|
10183
|
+
const isCanonicalRun = headingIndexes.every(
|
|
10184
|
+
(headingIndex, position) => position === 0 || headingIndex > (headingIndexes[position - 1] ?? -1)
|
|
10185
|
+
);
|
|
10186
|
+
if (!isCanonicalRun) return text.trim();
|
|
10187
|
+
const cutAt = cutLineIndexes[0] ?? 0;
|
|
10188
|
+
return lines.slice(0, cutAt).join("\n").trim();
|
|
10189
|
+
}
|
|
10135
10190
|
function promptContainsScaffolding(text) {
|
|
10136
10191
|
return SCAFFOLDING_MARKERS.some((pattern) => pattern.test(text));
|
|
10137
10192
|
}
|
|
@@ -10148,6 +10203,9 @@ function derivePromptDisplayText(prompt) {
|
|
|
10148
10203
|
}
|
|
10149
10204
|
const reply = prompt.replyToText?.trim();
|
|
10150
10205
|
if (reply && !promptContainsScaffolding(reply)) return reply;
|
|
10206
|
+
if (REVIEW_PROMPT_FIRST_LINE_RE.test(prompt.prompt.trimStart())) {
|
|
10207
|
+
return stripReviewPromptEnrichment(prompt.prompt.trim());
|
|
10208
|
+
}
|
|
10151
10209
|
if (promptContainsScaffolding(prompt.prompt)) {
|
|
10152
10210
|
const recovered = stripPromptScaffolding(prompt.prompt);
|
|
10153
10211
|
if (recovered) return recovered;
|
|
@@ -10166,6 +10224,7 @@ var ERROR_CODES = [
|
|
|
10166
10224
|
"aborted",
|
|
10167
10225
|
"rate_limit",
|
|
10168
10226
|
"api_error",
|
|
10227
|
+
"model_overloaded",
|
|
10169
10228
|
"config_error",
|
|
10170
10229
|
"failed_edits",
|
|
10171
10230
|
"memory_enforcement_failed",
|
|
@@ -10208,6 +10267,7 @@ var ERROR_CODE_LABELS = {
|
|
|
10208
10267
|
aborted: "Stopped by user",
|
|
10209
10268
|
rate_limit: "Rate limited - please retry shortly",
|
|
10210
10269
|
api_error: "Model service error",
|
|
10270
|
+
model_overloaded: "Model at capacity",
|
|
10211
10271
|
config_error: "Configuration error",
|
|
10212
10272
|
failed_edits: "Edit failure",
|
|
10213
10273
|
memory_enforcement_failed: "Memory enforcement failed",
|