Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .agents/core/agents-core.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
routes, its subsystem map, and its setup/verification/CI commands.
-->

> **Who this is for.** Every AI agent working in a repo governed by the
> **Who this is for.** Every AI agent working in a repo governed by
> KITT — Codex, Claude Code, Replit, and whatever comes next. It tells
> you **how to behave and what is non-negotiable**, independent of which
> product you are working on. The repo's own `AGENTS.md` carries the product
Expand All @@ -31,7 +31,7 @@

> **One source of truth for all agents.** These rules are shared. Claude
> Code's `CLAUDE.md` holds only Claude-specific ceremony and defers here for
> every cross-agent principle. When a shared rule changes, it changes in the
> every cross-agent principle. When a shared rule changes, it changes in
> KITT — never as a forked copy in one agent's own file or private
> memory.

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ PR is open on it.
`remote.origin.fetch = +refs/heads/main:refs/remotes/origin/main` — so no
`refs/remotes/origin/claude/<branch>` ref is ever created or updated, and
every tool that compares the branch to its remote-tracking ref sees nothing
there. Measured twice on 2026-10-11 (kitt, then DojoOS), both clones
there. Measured twice on 2026-10-11 (ai-handbook, then DojoOS), both clones
set up by the session harness.

**Fix.** Widen the refspec and fetch the branch once; never re-push to
Expand Down
2 changes: 1 addition & 1 deletion .agents/reviews/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
# the same hole remains for the plan loop.)
#
# WHY THERE ARE TWO COPIES. Git does not follow a symlinked .gitignore, so a
# pointer is impossible and a real file at each root is the only option. The
# pointer is impossible and a real file at each root is the only option.
# KITT mirrors this one at .agents/reviews/.gitignore, and
# scripts/check-root-wiring.mjs compares the pattern lines so the duplication
# is enforced rather than merely intended. Edit THIS copy; the root follows.
Expand Down
41 changes: 29 additions & 12 deletions docs/ai-context/token-pricing.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ published!"*).

## Anthropic — Claude API list prices

Read 2026-10-12 from
Read 2026-11-01 from
<https://platform.claude.com/docs/en/about-claude/pricing> (the `.md` form of
the page). Standard tier; USD per million tokens. Rows quoted as the page
printed them, whitespace collapsed and the cache-read column's footnote
Expand Down Expand Up @@ -43,20 +43,37 @@ write, cache read, output.

## OpenAI — the Codex reviewer (Astra)

Read 2026-10-12 from <https://developers.openai.com/api/docs/pricing>
(`openai.com/api/pricing` answered 403 to this container's fetch). Standard
tier, prompts up to 272K tokens; USD per million tokens. Row quoted as the
page printed it: input, cached input, cache write, output, then the four
long-context columns:
Read 2026-11-01 from <https://developers.openai.com/api/docs/pricing>, the
rendered HTML fetched directly (`openai.com/api/pricing` answered 403 to this
container's fetch on 2026-10-12). Standard tab; USD per million tokens.
Header and row as the page's text-token table prints them:

```
| gpt-6-astra | $10.00 | $1.00 | $12.50 | $50.00 | $20.00 | $2.00 | $25.00 | $75.00 |
| Model | Input | Output | Cached input | 30m write | 12h write |
| gpt-6-astra | $10.00 | $50.00 | $1.00 | $12.50 | $25.00 |
```

| Model | Input | Cached input | Cache write | Output |
|---|---|---|---|---|
| `gpt-6-astra` (the `strongestCodex` pin), prompt ≤ 272K | $10 | $1 | $12.50 | $50 |
| `gpt-6-astra`, prompt > 272K (the long-context columns) | $20 | $2 | $25 | $75 |
The page no longer prints long-context figures for this model. The long-context
row below is **derived, not quoted**, from the rule the `gpt-6-astra` model
page (<https://developers.openai.com/api/docs/models/gpt-6-astra>) prints,
read the same day: "Prompts with more than 272K input tokens are priced at 2x
input and cache rates and 1.5x output for the full request." The derived
figures for input, cached input, the 30-minute write and output match the
long-context columns the pricing page printed on 2026-10-12.

| Model | Input | Cached input | Cache write 30m | Cache write 12h | Output |
|---|---|---|---|---|---|
| `gpt-6-astra` (the `strongestCodex` pin), prompt ≤ 272K | $10 | $1 | $12.50 | $25 | $50 |
| `gpt-6-astra`, prompt > 272K (derived: 2x input and cache, 1.5x output) | $20 | $2 | $25 | $50 | $75 |

Until 2026-11-01 the page printed one cache-write column, at the figure it
now prints as the 30-minute write, and the model page still prints that
single figure; the 12-hour write is new, and every other short-context
figure is unchanged from the 2026-10-12 read. **The CLI's cache-write bucket
does not say which retention it bought, so it is priced at the 12-hour rate**
— the higher of the two, which overstates and never understates, the side
the long-context and Haiku rules below take for the same reason. Every probe
so far has read that bucket as 0, so the choice has not yet moved a figure.

### Pricing an Astra run — per bucket, never by the proxy

Expand Down Expand Up @@ -87,7 +104,7 @@ Three readings behind that formula, each settled rather than assumed:
- **The usage is the turn's cumulative total, but the 272K threshold is per
request** — "Prompts with more than 272K input tokens are priced at 2x input
and cache rates and 1.5x output for the full request" (the `gpt-6-astra`
model page, read 2026-10-12), and the CLI's `turn.completed` is built from
model page, read 2026-10-12 and again, unchanged, 2026-11-01), and the CLI's `turn.completed` is built from
the turn's running `total`. A turn of several tool-using requests can sum
past 272K with every request short. So: **`input_tokens` at or under
272,000 is priced exactly from the short row** — no single request can
Expand Down
2 changes: 1 addition & 1 deletion scripts/__tests__/map.unit.test.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
//
// The map tool's pure functions, on bare Node: no compiler, no sync, no
// fixture repository. This file ships with the payload, so it must run
// wherever it lands; the compiler-backed behaviour is proven by the
// wherever it lands; the compiler-backed behaviour is proven by
// KITT's own integration suite, which never ships.
import test from "node:test";
import assert from "node:assert/strict";
Expand Down
2 changes: 1 addition & 1 deletion scripts/machinery.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -249,7 +249,7 @@ export const PAID_RUN_LEDGER_REPO = "TheAnswerManIsHere/KITT";
* equal to the pin; `review-proxy.mjs` reads the declared effort to say, in an
* assessment's header, what the role actually runs at. Those are the two ends
* of one fact, and a second copy of the reader is a second thing to drift --
* the failure this whole area is about. KITT-only checker can import
* the failure this whole area is about. The KITT-only checker can import
* payload code; payload code cannot import the checker, so the shared copy
* lives here. (Both assessors, #131 round 1.)
*
Expand Down
2 changes: 1 addition & 1 deletion scripts/sweep-scope.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -347,7 +347,7 @@ export function plan({ root, spec, workers = DEFAULT_WORKERS, include = [] }) {
const fullSet = new Set();
for (const g of spec.readInFull ?? []) {
// A glob is payload-relative like `home`, but an `--include`d file is
// repo-relative and outside the payload; match both spellings so the
// repo-relative and outside the payload; match both spellings so
// KITT can name a non-payload document for a full read.
const asPayload = globToRegExp(toRepoPath(prefix, g));
const asRepo = globToRegExp(g.replace(/^\.\//, ""));
Expand Down
Loading