humanish 0.73.0 → 0.75.0
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/chrome-cdp-probe.d.ts +63 -0
- package/dist/chrome-cdp-probe.js +288 -0
- package/dist/chrome-cdp-probe.js.map +1 -0
- package/dist/cua-actor-lab.d.ts +16 -10
- package/dist/cua-actor-lab.js +123 -148
- package/dist/cua-actor-lab.js.map +1 -1
- package/dist/pricing.js +15 -6
- package/dist/pricing.js.map +1 -1
- package/dist/program.js +23 -0
- package/dist/program.js.map +1 -1
- package/docs/contracts/schemas.md +1 -1
- package/docs/goals/current.md +13 -1
- package/docs/ramp/README.md +1 -1
- package/package.json +1 -1
package/dist/pricing.js
CHANGED
|
@@ -23,17 +23,21 @@ const GPT56_SOURCE = "developers.openai.com/api/docs/pricing (gpt-5.6 family, st
|
|
|
23
23
|
// One 5.6-family entry: rates in USD-per-1M for legibility, converted once. Cache writes bill at
|
|
24
24
|
// 1.25x the uncached input rate on this family (`cache_write_tokens`, prompt-caching guide); the
|
|
25
25
|
// built-in `computer` tool has no per-call fee on the live sheet.
|
|
26
|
-
function gpt56Rate(inPer1M, cachedPer1M, writePer1M, outPer1M) {
|
|
26
|
+
function gpt56Rate(inPer1M, cachedPer1M, writePer1M, outPer1M, asOf = "2026-08-18") {
|
|
27
27
|
return {
|
|
28
28
|
inputUsdPerToken: inPer1M * 1e-6,
|
|
29
29
|
cachedInputUsdPerToken: cachedPer1M * 1e-6,
|
|
30
30
|
cacheWriteUsdPerToken: writePer1M * 1e-6,
|
|
31
31
|
outputUsdPerToken: outPer1M * 1e-6,
|
|
32
32
|
longContext: { ...GPT56_LONG_CONTEXT },
|
|
33
|
-
asOf
|
|
33
|
+
asOf,
|
|
34
34
|
source: GPT56_SOURCE
|
|
35
35
|
};
|
|
36
36
|
}
|
|
37
|
+
// gpt-5.6-sol promotional rates (live sheet 2026-09-03: $4 / $0.40 cached / $5 write / $20 out,
|
|
38
|
+
// "available at least through November 21, 2026"). The 2026-08-18 pin of 5 / 0.5 / 6.25 / 30
|
|
39
|
+
// over-estimated every Sol run by 25-33% for two weeks. Re-verify against the sheet after Nov 21.
|
|
40
|
+
const GPT56_SOL_PROMO_AS_OF = "2026-09-03";
|
|
37
41
|
// Per-model rates, keyed on the model id that lands in trace.ids.model (lookup is
|
|
38
42
|
// case-insensitive on a trimmed id). An id NOT present here is DECLARED ABSENT, never guessed.
|
|
39
43
|
export const MODEL_RATES = {
|
|
@@ -59,18 +63,23 @@ export const MODEL_RATES = {
|
|
|
59
63
|
// the longContext block prices the >272K re-tier when per-request turns are recorded).
|
|
60
64
|
// sol = flagship (the shipped CUA default), terra = cost-balanced, luna = high-volume,
|
|
61
65
|
// cyber = the Daybreak frontier tier.
|
|
62
|
-
"gpt-5.6-sol": gpt56Rate(
|
|
66
|
+
"gpt-5.6-sol": gpt56Rate(4, 0.4, 5, 20, GPT56_SOL_PROMO_AS_OF),
|
|
63
67
|
// "gpt-5.6" is OpenAI's own alias for gpt-5.6-sol (models index); priced identically so a
|
|
64
68
|
// lab configured with the alias never reads as unpriced.
|
|
65
|
-
"gpt-5.6": gpt56Rate(
|
|
69
|
+
"gpt-5.6": gpt56Rate(4, 0.4, 5, 20, GPT56_SOL_PROMO_AS_OF),
|
|
66
70
|
"gpt-5.6-terra": gpt56Rate(2, 0.2, 2.5, 12),
|
|
67
71
|
"gpt-5.6-luna": gpt56Rate(0.2, 0.02, 0.25, 1.2),
|
|
68
72
|
"gpt-5.6-cyber": gpt56Rate(12.5, 1.25, 15.625, 75),
|
|
69
73
|
// Daybreak program aliases (blue -> sol, red -> cyber today). OpenAI repoints these as new
|
|
70
74
|
// frontier models ship, so prefer the explicit tier id in labs; the entries exist so a
|
|
71
75
|
// configured alias still prices at what the alias bills TODAY.
|
|
72
|
-
"daybreak-blue-latest": gpt56Rate(
|
|
73
|
-
"daybreak-red-latest": gpt56Rate(12.5, 1.25, 15.625, 75)
|
|
76
|
+
"daybreak-blue-latest": gpt56Rate(4, 0.4, 5, 20, GPT56_SOL_PROMO_AS_OF),
|
|
77
|
+
"daybreak-red-latest": gpt56Rate(12.5, 1.25, 15.625, 75),
|
|
78
|
+
// gpt-6-astra (shipped 2026-09-03; API access announced as rolling out). Same two mechanics
|
|
79
|
+
// as the 5.6 family on the sheet: writes at 1.25x, >272K re-tiers at 2x input-side / 1.5x
|
|
80
|
+
// output ($20 / $2 / $25 / $75 long-context columns). Priced so a lab that declares it never
|
|
81
|
+
// reads as unpriced; NOT the default and not yet exercised by a live run here.
|
|
82
|
+
"gpt-6-astra": gpt56Rate(10, 1, 12.5, 50, GPT56_SOL_PROMO_AS_OF)
|
|
74
83
|
};
|
|
75
84
|
// E2B desktop sandbox compute, billed per-second by vCPU+RAM. Live sheet: 2 vCPU (default)
|
|
76
85
|
// $0.000028/s + RAM $0.0000045/GiB/s => at an ASSUMED 4 GiB desktop, $0.000046/s ~= $0.00276/min
|
package/dist/pricing.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"pricing.js","sourceRoot":"","sources":["../src/pricing.ts"],"names":[],"mappings":"AAAA,2FAA2F;AAC3F,0FAA0F;AAC1F,6FAA6F;AAC7F,uFAAuF;AACvF,EAAE;AACF,yFAAyF;AACzF,4FAA4F;AAC5F,2FAA2F;AAC3F,+FAA+F;AAC/F,2FAA2F;AAC3F,4FAA4F;AAC5F,uFAAuF;AAMvF,MAAM,CAAC,MAAM,cAAc,GAAG,qBAAqB,CAAC;AACpD,MAAM,CAAC,MAAM,2BAA2B,GAAG,kCAAkC,CAAC;AA2F9E,qFAAqF;AACrF,4FAA4F;AAC5F,MAAM,kBAAkB,GAAG;IACzB,oBAAoB,EAAE,OAAO;IAC7B,eAAe,EAAE,CAAC;IAClB,gBAAgB,EAAE,GAAG;CACb,CAAC;AAEX,MAAM,YAAY,GAAG,wEAAwE,CAAC;AAE9F,iGAAiG;AACjG,iGAAiG;AACjG,kEAAkE;AAClE,SAAS,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AAC;YAChE,GAAG,CAAC,gBAAgB,GAAG,CAAC,CAAC,CAAC,CAAC,EAAE,gBAAgB,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;SACtD;KACF,CAAC;AACJ,CAAC;AAED;;;;GAIG;AACH,MAAM,UAAU,mBAAmB,CACjC,OAA2B,EAC3B,OAAoB,YAAY;IAEhC,IAAI,OAAO,KAAK,SAAS,IAAI,CAAC,CAAC,OAAO,IAAI,CAAC,CAAC,EAAE,CAAC;QAC7C,OAAO,EAAE,gBAAgB,EAAE,IAAI,EAAE,MAAM,EAAE,aAAa,EAAE,SAAS,EAAE,IAAI,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC;IAC3F,CAAC;IACD,OAAO;QACL,gBAAgB,EAAE,MAAM,CAAC,OAAO,GAAG,IAAI,CAAC,YAAY,CAAC;QACrD,SAAS,EAAE,IAAI,CAAC,IAAI;QACpB,MAAM,EAAE,IAAI,CAAC,MAAM;QACnB,OAAO,EAAE,MAAM,CAAC,OAAO,CAAC;QACxB,GAAG,CAAC,IAAI,CAAC,WAAW,CAAC,CAAC,CAAC,EAAE,WAAW,EAAE,IAAI,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;KACnD,CAAC;AACJ,CAAC"}
|
package/dist/program.js
CHANGED
|
@@ -159,6 +159,23 @@ function reportActiveHandles(command, io) {
|
|
|
159
159
|
io.writeErr(`humanish debug: active resources after \`${commandPath(command) || "humanish"}\` settled: ${summary}\n`);
|
|
160
160
|
}).unref?.();
|
|
161
161
|
}
|
|
162
|
+
/**
|
|
163
|
+
* Write observer/index.html for a finished run the way `watch` does, so a bundle is the same
|
|
164
|
+
* bundle whichever command produced it (#597). Never fails the run: a bundle without its Observer
|
|
165
|
+
* is still evidence, and `export` can render one later.
|
|
166
|
+
*/
|
|
167
|
+
async function renderObserverForRun(cwd, result) {
|
|
168
|
+
if (!result.ok || result.runId === undefined)
|
|
169
|
+
return;
|
|
170
|
+
try {
|
|
171
|
+
const rendered = await renderObserver(cwd, result.runId, { open: false });
|
|
172
|
+
if (!rendered.ok)
|
|
173
|
+
result.warnings.push(`observer/index.html was not written: ${rendered.error?.message ?? "render failed"}`);
|
|
174
|
+
}
|
|
175
|
+
catch (error) {
|
|
176
|
+
result.warnings.push(`observer/index.html was not written: ${error instanceof Error ? error.message : String(error)}`);
|
|
177
|
+
}
|
|
178
|
+
}
|
|
162
179
|
/** `lab run`, not `run`, so the two are distinguishable — and nothing else from the invocation. */
|
|
163
180
|
function commandPath(command) {
|
|
164
181
|
const parts = [];
|
|
@@ -875,6 +892,7 @@ function registerRunCommand(parent, io) {
|
|
|
875
892
|
...(simCount === undefined || simCount === null ? {} : { simCount }),
|
|
876
893
|
...(timeoutMs === undefined || timeoutMs === null ? {} : { timeoutMs })
|
|
877
894
|
});
|
|
895
|
+
await renderObserverForRun(options.cwd, result);
|
|
878
896
|
writeResult(command, io, result, formatRunHuman);
|
|
879
897
|
io.setExitCode(result.ok ? 0 : 2);
|
|
880
898
|
});
|
|
@@ -2331,6 +2349,11 @@ async function runSyntheticBackend(args) {
|
|
|
2331
2349
|
}
|
|
2332
2350
|
const runResult = outcome.result;
|
|
2333
2351
|
if (args.mode === "run") {
|
|
2352
|
+
// `run` and `watch` used to disagree about whether a bundle has observer/index.html: watch
|
|
2353
|
+
// rendered it to serve it, run did not, and the first `export` of a run bundle failed (#597,
|
|
2354
|
+
// found by the 0.72.0 dogfood participant). Render it here too, so the two commands write the
|
|
2355
|
+
// same bundle; a render failure is a warning on the result, never a failed run.
|
|
2356
|
+
await renderObserverForRun(args.options.cwd, runResult);
|
|
2334
2357
|
writeResult(args.command, args.io, runResult, formatRunHuman);
|
|
2335
2358
|
args.io.setExitCode(runResult.ok ? 0 : 2);
|
|
2336
2359
|
return;
|