Skip to content

Commit 1f0bbe4

Browse files
committed
docs: re-measure the example CRM size and state the commit it was measured at
The four pages quoting the bundled example CRM's size (31 files, 1,929 lines, ~18,500 tokens) drifted again: the pages' own count command prints 30 files and 1,844 lines at 7a6ba03. Re-measure with that command and the bytes / 4 token method the figure was first made with, and state the measuring commit beside each figure, so the next edit to the example leaves the pages dated rather than wrong. The context-window post's Todo and showcase sizes, in the paragraph after the CRM table, had drifted the same way (90 showcase files, not 91) and are re-measured at the same commit under the same pin. Claude-Session: https://claude.ai/code/session_016PVjjuVPte5XEJvaQx1E4t Co-authored-by: Claude <noreply@anthropic.com>
1 parent 7a6ba03 commit 1f0bbe4

4 files changed

Lines changed: 26 additions & 14 deletions

File tree

‎content/blog/context-window-is-the-constraint.mdx‎

Lines changed: 12 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -38,19 +38,25 @@ a dashboard, a lead-conversion flow, permission sets, an action, translations.
3838

3939
| | |
4040
| :--- | :--- |
41-
| Files | 31 |
42-
| Lines | 1,929 |
43-
| Approximate tokens | ~18,500 |
41+
| Files | 30 |
42+
| Lines | 1,844 |
43+
| Approximate tokens | ~17,500 |
4444

4545
That's the **whole example app**. Not a module of it — the data model, the
4646
UI, the automation, the access rules, all of it. It fits in about 9% of a
4747
200k-token context window.
4848

49-
The Todo example is ~24.5k tokens. The kitchen-sink showcase app — which
50-
deliberately exercises every metadata type in the protocol, 91 files of it — is
51-
~174k. Even that one, the maximalist case, still fits in a 200k-token window —
49+
The Todo example is ~25k tokens. The kitchen-sink showcase app — which
50+
deliberately exercises every metadata type in the protocol, 90 files of it — is
51+
~175k. Even that one, the maximalist case, still fits in a 200k-token window —
5252
about 87% of it, leaving about 13% free for the actual work.
5353

54+
These figures were measured at commit
55+
[`7a6ba0310`](https://github.com/objectstack-ai/objectstack/tree/7a6ba03109dbb7e91359eb0f7f3e64dd1263bca8/examples)
56+
over the non-test `.ts` files in each example's `src/`, with tokens estimated
57+
at four bytes each. The examples keep changing, so today's counts will differ a
58+
little.
59+
5460
Measure your own:
5561

5662
```bash

‎content/blog/the-ontology-is-the-software.mdx‎

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -116,8 +116,9 @@ pages that is parsed into a UI tree and never executed as code.
116116
**The whole system becomes small enough to be held.** The bundled example CRM in
117117
this repository — accounts, contacts, leads, opportunities, activities, views, a
118118
dashboard, a lead-conversion flow, permission sets, actions, translations — is
119-
31 files and roughly 18,500 tokens. That is the whole application, not
120-
a module of it. An agent can load it end to end, answer *what breaks if I change
119+
30 files and roughly 17,500 tokens, measured at commit
120+
[`7a6ba0310`](https://github.com/objectstack-ai/objectstack/tree/7a6ba03109dbb7e91359eb0f7f3e64dd1263bca8/examples/app-crm).
121+
That is the whole application, not a module of it. An agent can load it end to end, answer *what breaks if I change
121122
this*, and refactor across data, API, UI, and permissions in a single change.
122123
We wrote about why that number is the one that matters in
123124
[The Constraint Isn't Typing Speed. It's the Context Window.](/blog/context-window-is-the-constraint)

‎content/docs/concepts/metadata-driven.mdx‎

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -228,12 +228,15 @@ actions, translations):
228228

229229
| | |
230230
| :--- | :--- |
231-
| Files | 31 |
232-
| Lines | 1,929 |
233-
| Approximate tokens | ~18,500 |
231+
| Files | 30 |
232+
| Lines | 1,844 |
233+
| Approximate tokens | ~17,500 |
234234

235235
That's the **whole example app** — about 9% of a 200k-token context window.
236-
Count it yourself:
236+
These figures were measured at commit
237+
[`7a6ba0310`](https://github.com/objectstack-ai/objectstack/tree/7a6ba03109dbb7e91359eb0f7f3e64dd1263bca8/examples/app-crm),
238+
with tokens estimated at four bytes each. The example keeps changing, so count
239+
it yourself for today's numbers:
237240

238241
```bash
239242
find examples/app-crm/src -name '*.ts' -not -name '*.test.ts' | xargs cat | wc -l

‎content/docs/getting-started/how-ai-development-works.mdx‎

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,8 +34,10 @@ build the thing I actually meant?*
3434
A typical enterprise app spreads CRUD, forms, queries, permissions, and API glue
3535
across dozens of files. ObjectStack keeps only the part that's yours: the bundled
3636
example CRM — six objects, views, a dashboard, a lead-conversion flow,
37-
permission sets, actions, translations — is **1,929 lines across 31 files, about
38-
18.5k tokens**. That's the whole example app, not a module of it.
37+
permission sets, actions, translations — is **1,844 lines across 30 files, about
38+
17.5k tokens** (measured at commit
39+
[`7a6ba0310`](https://github.com/objectstack-ai/objectstack/tree/7a6ba03109dbb7e91359eb0f7f3e64dd1263bca8/examples/app-crm)).
40+
That's the whole example app, not a module of it.
3941

4042
The point isn't lines of code; it's **fit in an agent's context window.** When the
4143
entire business system is small, typed, and declarative, an agent can load it

0 commit comments

Comments
 (0)