From 60d26908d63544c5b814b5457c74ec9d3d65000c Mon Sep 17 00:00:00 2001 From: Tyler Hallada Date: Tue, 17 Nov 2026 18:03:49 -0500 Subject: [PATCH] Name: Explicata, and EX_ for the environment variables Infinispand becomes Explicata (Latin, "things unfolded") wherever the name shows: the page title, README, package, prompts, seed title, Wikipedia User-Agent and startup line. Every IE_* variable becomes EX_*. The browser's IndexedDB name and the ie: storage keys stay, so settings and replicas already stored are found; the migration fixtures keep the old seed title. Co-Authored-By: Claude Opus 5.5 Claude-Session: https://claude.ai/code/session_014yB6q6Kn9JiRmGKzPQMh7o --- README.md | 83 +++++++++++++++++----------------- docs/wikipedia.md | 24 +++++----- e2e/colours.spec.ts | 4 +- e2e/forks.spec.ts | 38 ++++++++-------- e2e/keyboard.spec.ts | 4 +- e2e/libraries.spec.ts | 2 +- e2e/links.spec.ts | 6 +-- e2e/more.spec.ts | 10 ++-- e2e/nodes.spec.ts | 14 +++--- e2e/panes.spec.ts | 44 +++++++++--------- e2e/panes3.spec.ts | 30 ++++++------ e2e/panes4.spec.ts | 4 +- e2e/research.spec.ts | 2 +- e2e/review.spec.ts | 2 +- e2e/reviewer.spec.ts | 4 +- index.html | 2 +- package-lock.json | 4 +- package.json | 4 +- playwright.config.ts | 10 ++-- scripts/fixtures.ts | 2 +- scripts/linkEval.ts | 32 ++++++------- server/bundle.ts | 2 +- server/embed.ts | 20 ++++---- server/index.ts | 48 ++++++++++---------- server/links/jobs.ts | 4 +- server/links/pending.ts | 2 +- server/links/review.ts | 2 +- server/links/routes.ts | 2 +- server/links/scan.ts | 2 +- server/migrateLibraries.ts | 4 +- server/subscription.ts | 2 +- server/util.ts | 4 +- server/web.ts | 18 ++++---- server/wiki.ts | 12 ++--- server/wikiMock.ts | 2 +- server/wikiRoutes.ts | 6 +-- src/core/seed.ts | 2 +- src/llm/prompts.ts | 4 +- src/llm/web.ts | 2 +- src/seed/tree.ts | 2 +- src/ui/idb.ts | 2 +- src/ui/store.ts | 10 ++-- src/ui/wiki.ts | 2 +- tests/actions.test.ts | 2 +- tests/converge.test.ts | 2 +- tests/libraries.test.ts | 4 +- tests/linker.test.ts | 2 +- tests/migrateLibraries.test.ts | 1 + tests/research.test.ts | 12 ++--- tests/wiki.test.ts | 4 +- tests/wikiRoutes.test.ts | 2 +- 51 files changed, 256 insertions(+), 252 deletions(-) diff --git a/README.md b/README.md index 097197a..bf47cf9 100644 --- a/README.md +++ b/README.md @@ -1,9 +1,10 @@ -# Infinispand +# Explicata A tree of writing you can expand without limit. It opens as an outline of titles; every node, sentence, phrase and word can be opened further. The first levels are written ahead of time and open instantly; past them, a model writes the expansion on request. Everything is editable, by you or -by a model, and the tree is versioned like git. +by a model, and the tree is versioned like git. The name is Latin for "things unfolded" (*explicare*, +to unfold). Everything is a node of a library: a single versioned tree whose root is the library itself. Any node, with everything under it, can be moved under any other, copied, saved to a file, or @@ -33,27 +34,27 @@ use on their own machine. |---|---|---| | `ANTHROPIC_API_KEY` | unset | Enables generation. The key stays in the server process. | | `CLAUDE_CODE_OAUTH_TOKEN` | unset | A subscription token, used when no API key is set. A token put in `ANTHROPIC_API_KEY` by mistake is moved here. | -| `IE_MODEL` | `claude-opus-5-5` | Model for every call. | -| `IE_LLM` | `claude` with a key, `subscription` with a token, else `off` | `mock`: a deterministic stand-in (the tests). | -| `IE_DATA` | `.data` | Where the libraries and their caches are kept. Delete it to start again from the seed and the starter trees. | -| `IE_LIBRARY` | `library` | Starter trees (`.md` files in the text format), written into the first library when `IE_DATA` is empty. | -| `IE_USER` | your login name | The name on commits the server makes for you (the page lets you change yours with `/user`). | -| `IE_WIKI` | `live` | `mock`: built-in test articles, no network (the browser tests); `off`: every `/api/wiki/*` route answers 503. | -| `IE_HOSTS` | (none) | Extra host names the dev server answers to, comma-separated. `localhost` and `*.ts.net` (Tailscale) are always allowed. | -| `IE_WIKI_LANG` | `en` | Which Wikipedia. | -| `IE_WIKI_CONTACT` | unset | An email address, an `https://` URL or `User:Name` for the User-Agent of Wikipedia requests. Without it requests are spaced 6.5 s apart (the page says so once, the first time it is slow); with it, 1 s. Nothing else about you is sent. | -| `IE_WEB` | `on` when a model is configured | `off` takes web search and fetch away from the editor agent, whatever the page asks. | -| `IE_WEB_SEARCHES`, `IE_WEB_FETCHES` | `5`, `5` | Searches and page reads one request to the editor may make. | -| `IE_REVIEW_CALLS` | `50` | Model calls the link reviewer may make in one `/linkhere` or `/linkall` (each call judges up to 60 links). What is left past the cap waits for you. | -| `IE_EMBED` | on | Local embeddings for link discovery (bge-small, loaded on first use in a worker thread, about 560 MB of memory). `off`: links are found by text alone. `fake`: hashed words, no download (the tests). | -| `IE_EMBED_MODEL` | `Xenova/bge-small-en-v1.5` | Downloaded once into `IE_DATA/models/`. `Snowflake/snowflake-arctic-embed-xs` is a drop-in alternative. | -| `IE_EMBED_THREADS` | `4` | ONNX threads for the embedding model. | -| `IE_EMBED_OFFLINE` | unset | `1`: never download, use cached model files only. | +| `EX_MODEL` | `claude-opus-5-5` | Model for every call. | +| `EX_LLM` | `claude` with a key, `subscription` with a token, else `off` | `mock`: a deterministic stand-in (the tests). | +| `EX_DATA` | `.data` | Where the libraries and their caches are kept. Delete it to start again from the seed and the starter trees. | +| `EX_LIBRARY` | `library` | Starter trees (`.md` files in the text format), written into the first library when `EX_DATA` is empty. | +| `EX_USER` | your login name | The name on commits the server makes for you (the page lets you change yours with `/user`). | +| `EX_WIKI` | `live` | `mock`: built-in test articles, no network (the browser tests); `off`: every `/api/wiki/*` route answers 503. | +| `EX_HOSTS` | (none) | Extra host names the dev server answers to, comma-separated. `localhost` and `*.ts.net` (Tailscale) are always allowed. | +| `EX_WIKI_LANG` | `en` | Which Wikipedia. | +| `EX_WIKI_CONTACT` | unset | An email address, an `https://` URL or `User:Name` for the User-Agent of Wikipedia requests. Without it requests are spaced 6.5 s apart (the page says so once, the first time it is slow); with it, 1 s. Nothing else about you is sent. | +| `EX_WEB` | `on` when a model is configured | `off` takes web search and fetch away from the editor agent, whatever the page asks. | +| `EX_WEB_SEARCHES`, `EX_WEB_FETCHES` | `5`, `5` | Searches and page reads one request to the editor may make. | +| `EX_REVIEW_CALLS` | `50` | Model calls the link reviewer may make in one `/linkhere` or `/linkall` (each call judges up to 60 links). What is left past the cap waits for you. | +| `EX_EMBED` | on | Local embeddings for link discovery (bge-small, loaded on first use in a worker thread, about 560 MB of memory). `off`: links are found by text alone. `fake`: hashed words, no download (the tests). | +| `EX_EMBED_MODEL` | `Xenova/bge-small-en-v1.5` | Downloaded once into `EX_DATA/models/`. `Snowflake/snowflake-arctic-embed-xs` is a drop-in alternative. | +| `EX_EMBED_THREADS` | `4` | ONNX threads for the embedding model. | +| `EX_EMBED_OFFLINE` | unset | `1`: never download, use cached model files only. | | `PORT` | `4747` | | -For the tests: `IE_MOCK_DELAY` (ms per mock token), `IE_WIKI_MOCK_BULK_MS` (delay on background -Wikipedia requests), `IE_PROD=1` and `IE_DIST` (serve a build, and which one), `IE_E2E_PORT` and -`IE_E2E_DATA` (playwright.config.ts). +For the tests: `EX_MOCK_DELAY` (ms per mock token), `EX_WIKI_MOCK_BULK_MS` (delay on background +Wikipedia requests), `EX_PROD=1` and `EX_DIST` (serve a build, and which one), `EX_E2E_PORT` and +`EX_E2E_DATA` (playwright.config.ts). ## Using it @@ -271,8 +272,8 @@ Press `?` for every key. The short version: it rejects is kept, with its one-line reason, and not looked for again. The model gets no tools, only the candidates: each phrase's sentence, its section's title and path, and the target's title and description (or first sentence); many candidates go in one call, and nothing judged is sent - twice. Without a model (`IE_LLM=off`), or when a call fails or a job reaches its cap - (`IE_REVIEW_CALLS`), nothing unreviewed is linked: the candidates are suggested instead, and the + twice. Without a model (`EX_LLM=off`), or when a call fails or a job reaches its cap + (`EX_REVIEW_CALLS`), nothing unreviewed is linked: the candidates are suggested instead, and the status line says why. - A **suggestion** has a faint dashed underline. `Tab` reaches suggestions; `y` links one, `n` declines it (remembered in the node, on every replica). `/autolink suggest` leaves every @@ -314,7 +315,7 @@ sources linked. `Esc` stops a run and keeps nothing of it (its edits were on its Every claim taken from the web is linked (↗) to the page it came from, and only pages retrieved in that run may be cited; any other address is refused. Each request may make at most -`IE_WEB_SEARCHES` searches and `IE_WEB_FETCHES` reads. Page text is treated as data, never +`EX_WEB_SEARCHES` searches and `EX_WEB_FETCHES` reads. Page text is treated as data, never instructions. What is sent where: @@ -327,7 +328,7 @@ What is sent where: page **from this machine** and a small model summarises it. A guard in the server refuses every other tool, any non-public address, any page the run's searches did not return and the request did not name, and anything past the caps. -- **With `IE_LLM=mock`** nothing leaves the machine. +- **With `EX_LLM=mock`** nothing leaves the machine. ## How it works @@ -378,14 +379,14 @@ What is sent where: On disk: ``` -IE_DATA/libraries/index.json the libraries, in order: id, title, when made, whether deleted -IE_DATA/libraries//.loro a library, one Loro snapshot per branch -IE_DATA/libraries//links/pending.json its link suggestions, the reviewer's verdicts and your decisions (derived) -IE_DATA/libraries//vectors/nodes.* its sections as vectors (derived) -IE_DATA/libraries/.deleted/-