Part of the Vector Lab — research instruments for critical vector theory. Website and map · Org profile
Tier: single-object scope. Object: a corpus of theoretical texts.
Sibling instruments: Vectorscope · Manifoldscope · Manifold Atlas · LLMbench
A renormalisation-group workbench for corpora of theoretical texts.
Author: David M. Berry Institution: University of Sussex Version: 0.3.0 Date: 17 April 2026 Licence: MIT
Theoryscope is a web-based research tool that treats a corpus of theoretical texts as a geometry and asks renormalisation-group and eigenvector questions about it. It ingests a corpus, embeds each text with an open-weight model, and provides operations for inspecting the cloud's structure using vocabulary drawn from renormalisation group theory and linear algebra: principal eigendirections of a field, coarse-graining flows, fixed points, relevant and irrelevant operators, and universality classes.
The tool is designed for critical inquiry into the geometry of intellectual fields, not bibliometric measurement. Where existing computational literature tools (citation graph analyses, topic models, bibliometric dashboards) count and cluster surface features, Theoryscope provides an instrument for making visible the gap between what a field says it is about and what its geometry suggests it is about.
Theoryscope emerges from the convergence of three research programmes.
The Vector Lab. The tool is the fourth instrument in a family alongside Manifold Atlas (between-model comparison of output embeddings), Vectorscope (within-model inspection of open-weight internals), and LLMbench (close reading of model outputs). Manifold Atlas and Vectorscope take a model as their object; Theoryscope takes a corpus as its object, extending the Vector Lab's critical posture beyond the machine to the thought that is written about the machine. All four instruments share the editorial design system, an open-weight-only methodology, and a commitment to making every parameter visible on screen rather than hidden behind opaque kernels.
The renormalisation group as critical method. Berry (2026) Renormalising Theory argues that claims critics already perform intuitively, that "Foucault, Deleuze and Guattari really come down to X", or that "Habermas and Rorty converge at depth", are in fact renormalisation-group claims about what survives when a field is coarse-grained. The physics vocabulary of flow on theory space (Fisher 1974), relevant and irrelevant operators, universality classes, and the mapping to deep learning (Mehta and Schwab 2014; Lin, Tegmark and Rolnick 2017) provides a formal language for a critical move that has always happened through the reading. Theoryscope is the instrument that follows from the argument.
Counterfactual media and the theory-space concept. Berry (2026) What Is Theory Space? treats theory space as the inaccessible totality of counterfactual media from which a particular manifold is selected during training. That post is about what cannot be inspected. Theoryscope works on a cognate but distinct object, a corpus of theoretical texts that is empirically given. The kinship is methodological. The difference is that Theoryscope's corpus space is available for inspection, coarse-graining, and re-embedding. It is the empirical companion to the conceptual argument.
Theoryscope uses two kinds of object, and it helps to understand the difference.
A corpus is a finite, explicitly defined set of documents: a Zotero collection, an author's complete works, a time-bounded selection of a field. A corpus is a theoretical claim in its own right. Who is in it and who is out, under what criterion, with what filters, determines what the instrument can see. Theoryscope records the corpus definition as part of every result so that findings can be reproduced and contested.
An embedding model (MiniLM, BGE, Nomic, Qwen3-Embedding) takes text in and produces a vector out: a list of numbers (typically 384 to 1024 floating-point values). No language comes back, just coordinates in a high-dimensional space. Those coordinates are the model's geometric encoding of what the text "means", where meaning is reduced to position. The embedding model is the telescope: it converts text into a location.
This matters for Theoryscope because every operation is sensitive to which embedding model is computing the distances. The same corpus, embedded by two different open-weight models, will not produce the same eigendirections. The Embedding Dependence Probe exists to make this visible. An operation that reports a single eigenbasis without its stability under re-embedding is reporting half a result. Theoryscope uses only open-weight embedding models, whose architectures, training data, and update schedules are available for scholarly inspection.
The difference between a chat model and an embedding model is relevant here too. A chat model (GPT, Claude, Llama) takes text in and produces text out. An embedding model stops earlier: it produces the vector and hands it to you. This is why embedding API calls are cheap (fractions of a penny) while chat API calls are expensive. Theoryscope uses embedding models as its core instrument. Chat models appear only in later phases for the semantic coarse-graining operator, where an LLM is used to produce progressively more abstract paraphrases of a text before re-embedding.
Theoryscope is organised as a tabbed workspace with five groups: three operational groups (Inspect, Flow, Critique) and two cross-cutting features (Annotations, Atlas). Live at v0.3.0: all three Inspect anchors, three Flow operations, three Critique operations.
| Group | Operation | Status | Core question |
|---|---|---|---|
| Inspect | Corpus Map | ✅ live | What does the cloud look like? |
| Inspect | Eigendirections | ✅ live | What are the principal axes of the field? |
| Inspect | Concept Locator | ⏳ planned | Where does this concept sit, and along which axis does it vary? |
| Inspect | Author Constellation | ⏳ planned | How do authors differ and where do they concentrate? |
| Flow | Coarse-Graining Trajectory | ✅ live | How do points move under successive coarse-grainings? |
| Flow | Fixed Point Finder | ✅ live | Where does the flow stop? |
| Flow | Universality Class Finder | ✅ live | Which starting positions converge to the same endpoint? |
| Flow | Relevant / Irrelevant Operator Spectrum | ⏳ planned | Which concepts persist and which wash out? |
| Flow | Temporal RG Flow | ⏳ planned | How do the principal axes shift across decades? |
| Critique | Embedding Dependence Probe | ✅ live | Do these results survive a different embedding? |
| Critique | Perturbation Test | ✅ live | How robust is this result to a small change in the corpus? |
| Critique | Forgetting Curve | ✅ live | How fragile are these eigendirections under bootstrap? |
| Critique | Symmetry Breaking Map | ⏳ planned | Where does the field fragment, and along which axis? |
| Critique | Phase Diagram | ⏳ planned | What does the flow field look like as a whole? |
| Critique | Translated Corpus Probe | ⏳ planned | What survives translation? |
| Critique | Corpus-vs-Model Probe | ⏳ planned | Do the eigendirections of a corpus match those of a model trained on it? |
| Annotations | Critical Annotations Layer | ⏳ planned | Markdown notes attached to any geometric feature, exported with the result. |
| Atlas | Curated pre-run analyses | ⏳ planned | Curated entries on named corpora, with provenance and annotations. |
All live operations carry a provenance record (corpus hash, embedding model, chunking spec, coarse-graining operator, optional stability score) that travels with every export. Results from the three Critique operations are recorded in the same format so that any downstream claim about the corpus can be cross-checked for robustness.
The opening workspace. Load a corpus, watch it appear as geometry, read its principal axes.
- Open-weight embeddings. Following the commitment to make every parameter inspectable, Theoryscope does not use commercial embedding APIs. The default embedder is
sentence-transformers/all-MiniLM-L6-v2; the Embedding Dependence Probe usesall-mpnet-base-v2andBAAI/bge-small-en-v1.5as alternatives. All embedding models run locally viasentence-transformers. - Corpus as a cloud. ✅ Each document is a point in a high-dimensional embedding space. The Corpus Map projects to three dimensions via PCA and renders the cloud as a 3D scatter in Plotly, with documents coloured by year and labelled by author.
- Annotated eigendirections. ✅ Each principal component is annotated with the documents that load most positively and most negatively on it. The critical use is comparison with the field's debated oppositions: computed axes and debated axes rarely match, and the gap is diagnostic.
- Concept locator. ⏳ Enter a short text or concept. The tool embeds it into the same space, returns the nearest documents and authors, and reports the eigenvector most aligned with the query.
- Author constellations. ⏳ Aggregate an author's corpus to a single centroid with intra-author spread. Overlay multiple authors on the same eigenbasis to compare their constellations.
- Provenance record. ✅ Every operation view has a deep-dive panel exposing the full provenance JSON: corpus source, document IDs, embedding model and dimension, chunking spec, ingestion timestamp, and SHA-256 corpus hash. The
ExportButtondownloads the full operation result with its provenance as a timestamped JSON file.
The second tab group. Coarse-grain the corpus, watch it flow, locate its fixed points.
Applies a coarse-graining operator in stepwise passes, animating how points move. The operator is visible on screen with its parameters at every step. v0.3.0 implements the aggregative operator (progressive k-means with a log-spaced schedule from the full corpus down to two clusters); the semantic, lexical, and citation-graph operators are planned. A Play/Pause scrubber and clickable schedule bar let the user step through the flow manually.
Iterates the flow to its terminal step and reports the basins every document falls into. Basins are the fixed points of the flow: positions that do not move under further coarse-graining within the terminal cluster count. The terminal map is rendered with basins colour-coded; clicking a basin card highlights its members on the map. Each basin lists its population, exemplar document (the member closest to the basin centroid), and full member list.
For a user-supplied or auto-extracted list of concepts, ranks each by whether its role in discriminating texts grows or shrinks under coarse-graining. Relevant operators persist at every scale; irrelevant operators wash out. The critical interpretation is the reader's; the tool reports the pattern.
Clusters corpus points by the fixed point they flow to, rather than by surface embedding. Classes are ranked by ascending surface mean cosine: a class whose members were surface-different but converge on the same basin is the universality-class finding worth inspecting. Each class card shows a universality bar (1 − surface cosine) so the relative universality of classes is legible at a glance.
Coarse-grains the corpus by time window rather than by semantic or aggregative operator. Watches how eigendirections shift across decades. Shows how the principal axes of a field change over time, which is distinct from how they respond to semantic abstraction.
The third tab group. Expose the tool's own dependencies. Stability, sensitivity, translation, reflexivity.
Identifies the parameters whose variation splits a unified cloud into distinct clusters. Answers: at what point does this field fragment, and along which axis?
Renders the coarse-graining flow as a 2D projection with basins shaded, fixed points marked, and critical boundaries drawn. Analogous to RG-flow phase diagrams in physics, legible as a single image.
Re-embeds the same corpus under a second open-weight model chosen from a shortlist (MiniLM, MPNet, BGE) and aligns the two bases via document projections. Dimensions may differ between models; the alignment is computed as the absolute Pearson correlation of per-document scores under each basis, which is basis-dim-independent. Reports per-component agreement (with signed cosine so sign flips are visible), side-by-side loadings, and an overall stability score. The methodological keystone of the Critique tab: every Theoryscope finding is a finding about the corpus-as-measured-by-a-particular-embedding-model, and this probe is how you check whether it survives.
Appends one user-supplied out-of-field text to the corpus, re-embeds that one row, recomputes the eigenbasis on the full set, and aligns to baseline directly in the embedding space. Ships with three curated default probes (commercial press release, medieval canon law, nature writing) so the operation can be run immediately. Returns per-component rotation (1 − |cos|) ranked descending so the user sees which axis was most sensitive to the perturbation, plus where the probe itself lands on each component. A component that rotates substantially under one new paper was not a structural feature of the field.
Bootstraps over the corpus: at each iteration (default 20), a random fraction of documents (default 20%) is removed, the eigenbasis is recomputed on the survivors, and aligned to baseline. Reports per-component mean / standard deviation / min / interquartile range of the alignment scores across iterations, plus overall stability. The per-iteration table is visible in the deep dive. A formal stability gate for every other finding the tool produces.
Re-runs the eigendecomposition on a machine-translated version of the corpus. Eigendirections that survive translation arguably track concepts. Directions that do not arguably track language-specific framings. The translation is not neutral, and the delta is what matters.
The reflexive operation. Compares the eigendirections of a theoretical corpus against the eigendirections of an open-weight model trained on (or plausibly exposed to) that corpus. Alignment is computed via Procrustes analysis or Canonical Correlation Analysis. The output distinguishes agreement (axes the model preserved), disagreement (axes the corpus has and the model does not), and delta directions (axes the model added from its broader training).
Markdown notes attachable to any eigendirection, fixed point, universality class, or basin. Notes live with the corpus cache and travel with every export. The affordance that distinguishes Theoryscope from a bibliometric dashboard: the critical reading travels with the geometry.
A curated set of pre-run analyses on named corpora. Each Atlas entry bundles a corpus definition (Zotero query or explicit list), the embedding model, the coarse-graining operator, the results, the stability scores, and David's critical annotations. The Atlas ships with the GitHub release. Three v1 entries are planned: Philosophy of Technology (the Phase 0 corpus), Bias as Universality Class (the AI ethics literature 2015–2025), and a Reflexive Run on the methodology literature that spawned the tool.
Why open-weight embeddings only? Commercial embedding APIs do not give you what you think they give you. The output-layer vectors of a separately-trained embedding model are not the internal representations of a generative model, and the hidden decisions behind a commercial API (tokeniser, architecture, training data, update schedule) are not available for scholarly inspection. An instrument whose results cannot be reproduced or re-run is not a critical instrument. Theoryscope uses only open-weight embedding models for the same reason Vectorscope does.
Why implement coarse-graining in process? A black-box clustering library would produce the same shapes as an in-process implementation, but the black box hides the operator. The critical value of a coarse-graining result depends on the user seeing what has been done to the corpus. Every Theoryscope operator has its source visible, its parameters on screen, and its intermediate states inspectable. Same principle as Vectorscope's Signal Degradation Laboratory, applied to corpora rather than to weights.
Why RG rather than topic models or citation analysis? Topic models identify what clusters co-occur in the surface vocabulary. Citation analysis traces reference networks. Both are useful, but both take the surface as their object. Renormalisation group thinking asks a different question: what survives when the surface is abstracted away? The relevant operators, the fixed points, the universality classes are features of the field's geometry under coarse-graining, not of its surface vocabulary. This is the move critics perform intuitively when they say that two traditions converge at depth, and it is the move the instrument makes available for inspection.
Why provenance with every result? A finding that cannot be cited is not a finding. The provenance record (corpus hash, document IDs, embedding model, chunking spec, operator, timestamp) is what makes a Theoryscope result something that can travel into a paper. Without it, the geometry is suggestive but not defensible. With it, the reading can be re-run and contested.
Why tabbed groups rather than a dashboard? Each operation is a distinct analytical act with its own controls, its own visualisation, and its own deep dive. A dashboard blurs the operations together. A tabbed workspace keeps them honest: one operation, one result, one provenance record. The user chooses which question to ask, and the interface reflects that choice.
Why stability scores? Eigendirections depend on the embedding model. Change the model and the computed axes of the field change with it. Reporting a single eigenbasis without its stability under re-embedding is reporting half a result. The Embedding Dependence Probe is not a bonus feature; it is a precondition for taking any of the other operations' outputs seriously.
- Node.js 18+
- Python 3.11+ (for the FastAPI backend and sentence-transformers)
- npm
git clone https://github.com/dmberry/theoryscope.git
cd theoryscope
npm installSet up the Python backend:
cd backend
./setup.shThis creates a local .venv and installs FastAPI, sentence-transformers, scikit-learn, umap-learn, pyzotero, and their dependencies.
Start the backend:
cd backend
source .venv/bin/activate
uvicorn main:app --reload --port 8000Start the frontend in a separate terminal:
npm run devOpen http://localhost:3000. Click Load Phase 0 Corpus to embed the 20-document philosophy-of-technology corpus and render the Corpus Map. The deep-dive panel at the bottom of the Corpus Map shows the full provenance record.
backend/
main.py # FastAPI app, CORS, route registration
requirements.txt
setup.sh # venv bootstrap
corpus/
loader.py # Phase 0 hard-coded corpus; Zotero ingest in later phases
embed.py # Sentence-transformers embedding pipeline
provenance.py # ProvenanceRecord dataclass + corpus hashing
operations/
corpus_map.py # PCA to 3D with provenance
(eigendirections, rg_flow, fixed_points, ... stubbed for later phases)
geometry/ # stats, reduction helpers (adapted from Vectorscope)
atlas/
entries/ # Pre-computed Atlas entries (later phases)
src/
app/
api/backend/[...path]/route.ts # Next.js proxy to FastAPI on localhost:8000
layout.tsx # Editorial typography and fonts
page.tsx # Tabbed shell: Inspect / Flow / Critique / Annotations / Atlas
providers.tsx # CorpusProvider
components/
layout/ # Header, CorpusLoader, StatusBar
operations/ # CorpusMap live; others stubbed
atlas/ # AtlasBrowser, AtlasEntry (later phases)
annotations/ # AnnotationPanel, AnnotationMarker (later phases)
viz/ # CloudScene, EigenBars, FlowAnimation (later phases)
shared/ # CorpusSelector, OperatorPicker, ProvenanceBadge
context/
CorpusContext.tsx # Loaded corpus state and load action
hooks/
useBackend.ts # Thin fetch wrapper for the proxy route
lib/
geometry/ # Copied from Manifold Atlas: cosine, pca, umap, clusters
provenance.ts # Frontend mirror of the backend ProvenanceRecord
streaming.ts # NDJSON streaming (from LLMbench)
utils.ts
version.ts
types/
corpus.ts
react-plotly.d.ts # Type shim for react-plotly.js
The architecture mirrors Vectorscope's pattern: a Next.js App Router frontend proxies all /api/backend/* requests to a FastAPI backend on localhost:8000. No CORS. The Python side owns the embedding model, the corpus cache, and the provenance record; the TypeScript side owns the visualisation and the annotations.
Heavy visualisations (Plotly 3D scatter, and in later phases the Three.js flow animation and phase-diagram renderer) are code-split via next/dynamic to keep the initial bundle lean.
| Layer | Technology |
|---|---|
| Framework | Next.js 16 (App Router), React 19 |
| Language | TypeScript 5 (strict) |
| Styling | Tailwind CSS 3, editorial design system shared with Vectorscope |
| Visualisation | Plotly.js (GL3D), Three.js (@react-three/fiber), custom SVG |
| Backend | FastAPI, uvicorn, Python 3.11+ |
| Embeddings | sentence-transformers (open-weight, local) |
| Dimensionality Reduction | scikit-learn (PCA), umap-learn |
| Corpus ingestion | pyzotero, networkx (citation graphs) |
| Caching | Local disk (embedded corpora JSON + provenance) |
- Phase 0 scaffold: Next.js frontend, FastAPI backend, editorial design system, hard-coded Philosophy of Technology corpus
- Phase 1: Eigendirections operation with annotated axis cards
- Phase 1.5: Zotero ingestion via pyzotero (user/group libraries, collection picker, credentials in localStorage)
- Phase 1.5: Export pipeline — provenance-stamped JSON downloads from every live operation
- Phase 1.5: On-disk cache for embedded corpora (keyed by document IDs + chunking + embedding model)
- Phase 2: Flow core + three operations (Coarse-Graining Trajectory, Fixed Point Finder, Universality Class Finder) via aggregative k-means coarse-graining
- Phase 3A: Critique tab open — Embedding Dependence Probe, Perturbation Test, Forgetting Curve, all built on a shared eigenbasis-alignment primitive
- Inspect completions: Concept Locator, Author Constellation, Debated-vs-computed comparison UI
- Flow continuation: Relevant / Irrelevant Operator Spectrum, Temporal RG Flow, semantic and lexical coarse-graining operators
- Critique continuation: Symmetry Breaking Map, Phase Diagram rendering, Translated Corpus Probe
- Phase 4: Corpus-vs-Model Probe with worked example (AICT corpus vs small open-weight model); Atlas feature with first three entries; Critical Annotations Layer
- Phase 5: Release blog post on Stunlaw (companion to Renormalising Theory)
- Berry, D. M. (2026) 'Renormalising Theory', Stunlaw.
- Berry, D. M. (2026) 'What Is Theory Space?', Stunlaw.
- Berry, D. M. (2026) 'Vector Theory', Stunlaw. Available at: https://stunlaw.blogspot.com/2026/02/vector-theory.html
- Berry, D. M. (2026) Artificial Intelligence and Critical Theory. MUP.
- Fisher, M. E. (1974) 'The renormalization group in the theory of critical behavior', Reviews of Modern Physics, 46(4), pp. 597-616.
- Mehta, P. and Schwab, D. J. (2014) 'An exact mapping between the variational renormalization group and deep learning'. Available at: https://arxiv.org/abs/1410.3831.
Concept and Design by David M. Berry, implemented with Claude Code 4.6. Design system adapted from the CCS Workbench. Theoryscope shares its editorial design system, geometry library, NDJSON streaming, and FastAPI proxy pattern with its sibling instruments Vectorscope, Manifold Atlas, and LLMbench.
Many thanks to John Hessler for the renormalisation group and deep-learning genealogy reading list that inspired the Theoryscope.
MIT