panoptiblog #
An index of English-language standard.site publications. Authors are shown for attribution; they are not scored.
scripts/panoptiblog/index.mjs reads the network and writes one JSON dataset.
It is a snapshot: every run re-reads the current records, so edits and deletions
need no event log, cursor, or replay.
Running #
npm run panoptiblog:index -- --out scripts/panoptiblog/out/panoptiblog.json
The output and the DID cache are gitignored. Useful flags:
--top Nkeeps the top N publications, for a smaller file.--limit-repos Nreads only N repositories, for a smoke run.--concurrency Nchanges how many repositories are read at once.--now ISOmakes the recency windows reproducible.--compacttrims the fields the public site does not render.--from FILEtrims an existing dataset instead of walking the network.--all-out FILE/--all-uploadwrite and upload the full dataset.--labeler-out FILE/--labeler-uploadare reserved for the author-stats labeler that will follow the dashboard. They are not part of this release.--excluded-out FILEwrites every excluded publication with its exclusion label and spam reasons. It is an audit export, not part of the published run.--baseline FILEcompares the ecosystem metrics to another corpus; repeat it for several baselines. Accepts{name, periodDays, documents:[{text,title?,publishedAt?}]}or{name, metrics}.--prettyindents the output.
What it reads #
Four standard.site collections, found through the relay's
com.atproto.sync.listReposByCollection, then read from each author's PDS with
com.atproto.repo.listRecords:
site.standard.publication— the blogs.site.standard.document— the posts.site.standard.graph.subscription— who follows a publication.site.standard.graph.recommend— who endorsed a document.
No credential is used. The relay and each PDS are public.
What it computes #
Per publication: documents, words, median words, first and last post, posts in
the last thirty and ninety days, distinct subscribers, distinct recommenders,
top tags, out-links, readability, lexical diversity, word rarity from a bundled
English Zipf lists (FrequencyWords, MIT), cadence, reading time,
theme colors, icon, author attribution, and percentiles. The score is a
two-level tree: six composites (Audience, Volume, Consistency, Style, Pulse,
and Network) each average the percentiles of their factors; the overall score
averages the composites, one sixth each. Audience counts subscribers and
recommenders. A zero count scores zero; positive counts are ranked only
against publications with a positive count. Consistency combines Presence, an
exponentially weighted share of the weeks with a post, and cadence. Style includes structural variety across headings,
lists, quotes, code, and images. Pulse combines smoothed recency and new
audience; recent citations are a diagnostic. Network counts inbound citations
from other ranked publications,
source range, and at:// or Bluesky embeds; self-links and same-author links are
excluded, and reciprocal links count.
Each composite and factor carries a name, an icon in the page, a one-line
description of its character, and the exact metric its info button shows. The
composite and factor weights are in method.tree; each row’s factor and
composite percentiles are in factors and composites. Missing factors and
zero weights are renormalized away. theme is the publication’s
standard.site basicTheme converted from RGB to CSS colors.
Each row also carries diagnostics outside the score: new subscribers and recommenders in the last ninety days, median subscriber tenure, endorsement breadth, subscriber–recommender overlap, outbound and ecosystem link density, source mix, citation impact (PageRank), citation evenness, reciprocal share, recent citing sources, citation months, citation persistence, and posting acceleration. These are reported and are not canonical factors. The debug button on a row shows the raw counts, diagnostics, and factor percentiles. Bluesky engagement is not collected in this release.
Author profiles — display name, handle, and avatar — are fetched for attribution on each publication row. No author-level score, rank, or label is computed. A separate author-stats labeler will follow; it is not part of this score.
The scored cohort is English-only for now because the readability formulas, syllable heuristic, tokenizer, and Zipf list are English-specific. Publications in other languages are indexed and shown in the filter counts, not scored. This is a tooling limit, not a judgment. The rule is stated on the page and in the filter dialog.
Spam signals look for repetition, not for a topic. A publication is kept out of the rankings when at least half its documents share an opening, at least half its titles reduce to one pattern, or it publishes at least twenty documents a day with a median under a hundred words. A publication network is excluded when one owner has at least twenty publications, or two thousand documents across several, or five million words across ten. "Mostly empty" and "bulk volume" only lower a score. These are filters, not author scores.
A publication needs at least one thousand words to rank: a linkblog or an
empty shell is counted but not listed. Consistency is discounted until five
dated posts establish a history, so two posts cannot read as a sustained
cadence. A publication that sets
preferences.showInDiscover=false opts out of scoring: it is indexed and
shown in the filter counts, but it receives no score, rank, or percentile
label. --include-undiscoverable is a diagnostic override, not part of the
published run.
Documents carry prose in textContent or, for tools that predate it, in a
platform content union. The indexer reads the plaintext, text and content
keys of that union, so a Leaflet or pckt post counts its body rather than zero.
Out-links come from raw URLs, markdown links, HTML anchors, content link
facets, the document’s links field, and structured embeds or at:// references
inside the body. An image embed is not an out-link unless a link wraps it.
Links to another ranked publication or an atproto resource count as ecosystem
links; embedded posts are counted separately.
Self subscriptions and self recommends are not counted. The check is exact-DID; a second account is invisible.
Scoring core and ports #
The durable rules are in panoptiblog-invariants.md.
scripts/panoptiblog/scoring.mjs is the pure scoring core. It has no imports:
text metrics, analyzeDocument, factorValues, SCORE_TREE,
percentileRanks, and treeScore. The indexer imports it directly;
metrics.mjs keeps the cohort and publication-level model and re-exports the
core.
node scripts/panoptiblog/emit-score-tree.mjs writes
scripts/panoptiblog/score-tree.json from SCORE_TREE. The scoring test fails
if the file and tree differ. The JSON lists composite and factor ids, weights, scales, display caps, and the
bound used by the single-entity entry point.
scoreEntity(recordOrRecords, options) scores one document or a thread with no
cohort. It returns raw factor values, bounded 0–1 values, tree weights, and
cohort: { percentiles: null, score: null }. Subscribers and recommenders are 0
because no subscription graph is supplied; their bounded values are null.
Recency is absolute against now. Audience inflow has no single-entity
value without the graph. Factors without an absolute upper bound
(subscribers, recommenders, words, vocabulary, sources) have null bounded values.
Corpus-wide uniqueness and per-article contribution breakdowns are diagnostics,
not canonical composites.
The parity fixture is scripts/panoptiblog/fixtures/document-parity.json;
scoring.test.mjs checks every checked-in value.
Reading time and the ecosystem #
Reading time is words divided by 200. Each post and publication carries minutes and hours; the leaderboard shows the publication total.
totals.ecosystem is the corpus view, separate from a publication score:
hours published in the last 24 hours, 7-day and 30-day averages per day, total
hours, posts per day, active publications, new publications, the median
readability and lexical metrics, and link density.
By default the whole corpus is compared to its top 100 ranked publications.
--baseline replaces that with another corpus: {name, periodDays, documents:[{text,title?,publishedAt?}]} computes the same text metrics, and
{name, metrics} takes precomputed values. The dataset carries a comparison
and a 0-100 health index. No Substack corpus is shipped; supply one with
--baseline.
Reading the page #
Publications render as leaderboard rows: rank, publication identity, author attribution, six composite percentile cards, and one larger overall percentile. Links in this view do not use the site-wide red underline.
The weight editor is a two-level slider set built from method.tree. The
overall percentile sits above six composite cards; each card shows its icon,
name, weight, and a one-line description, with its factors nested below. Hover
or focus any info button for the exact metric. Moving a weight recomputes the
percentiles in this browser against the full ranked cohort, re-ranks the top
100 shown, and stores the experiment in localStorage; reset restores the
published weights. The payload carries a compact cohort array of factor
vectors and warning counts for every ranked publication, so these experiments
are not renormalised against the visible top 100.
The “what’s included?” dialog shows the disjoint publication universe:
included, no posts, below minimum words, undiscoverable, not English, spam
(with reasons), and other. It also shows skipped and failed repositories and
loose or orphan documents. A publication that sets
preferences.showInDiscover=false opts out; it is not scored. Zero subscribers
is not an exclusion; it scores zero on the subscriber factor. Positive counts
are ranked against other positive publications.
Quality models #
No pretrained “blog quality” model exists. The closest pretrained options:
- Automated essay scoring:
KevSun/IELTS_essay_scoringandJacobLinCool/IELTS_essay_scoring_safetensors(RoBERTa, MIT). Trained on IELTS essays, so out of distribution for blogs. - Readability:
agentlans/deberta-v3-base-readability-v2(DeBERTa-v3, Apache-2.0) andkiddom/modernbert-readability-grade-predictor(ModernBERT, MIT). Useful as a cross-check on the deterministic formulas. - Generated text:
desklib/ai-text-detector-v1.01(DeBERTa-v3-large, MIT, RAID) andonnx-community/tmr-ai-text-detector-ONNX. Treat as a spam signal, not a quality verdict; false positives are common on edited prose. - Writing-quality reward model:
ConicCat/Lamp-P-Writing-Quality-RM(Llama-3.2-3B, Llama licence). Research-grade and heavy.
The indexer calls no model. There is no placeholder model composite: a model scorer must be evaluated against human ratings and then added to an existing composite, with an audit entry and a version bump. The DeBERTa readability and detector models fit on a laptop GPU; CPU works for a sample but is slower. This environment reports no GPU, so the model pass is not part of the scheduled job.
Scheduled job #
scripts/panoptiblog/deploy.sh builds the image from
scripts/panoptiblog/Dockerfile, pushes it to ECR, and applies the ECS and
EventBridge resources in infra/main.tf. The rule runs once a day at 04:17
UTC.
The task runs the indexer with --top 100 --compact --upload --all-out /tmp/all.json --all-upload. The task definition supplies PANOPTIBLOG_BUCKET
and PANOPTIBLOG_KEY for the site data and PANOPTIBLOG_ALL_KEY for the full
corpus; the job writes s3://substandard.blog/panoptiblog/data.json for the
site and extension and all.json for full-data consumers. The labeler flags
remain in the indexer for the author-stats labeler that will follow; they are
not part of this job.
CloudFront serves them from the bucket root, not from a release tree, so a
refresh does not need a site deploy.
scripts/panoptiblog/deploy.sh --run starts one task immediately. The first
run requires scripts/deploy-site.sh to have been applied, because the site
infra owns the bucket and the release_sha variable.
The job uses the account's default VPC and needs outbound internet access. The
task role can write only the panoptiblog/ prefix.
Hosting #
The page is at the root of panoptiblog.substandard.blog. The subdomain is an
alias on the same distribution; infra/viewer-request.js rewrites its root to
the built page, and every asset and the dataset keep their normal paths. The
old /panoptiblog path on substandard.blog redirects to the subdomain, and the
page's canonical URL is the subdomain root.
Deploying this release #
Deploy the indexer image first so the daily task cannot write the old schema:
scripts/panoptiblog/deploy.sh. Then run scripts/deploy-site.sh.
The site deploy upgrades panoptiblog/data.json at the bucket root when its
method version is older than the committed snapshot. If the root already has
the same version, it leaves the scheduled job's fresher copy alone. Running
scripts/panoptiblog/deploy.sh --run after both refreshes the root
immediately.
Limits #
- A document with no readable prose in
textContentor a known content union counts as a post with zero words. - Words are prose tokens. Fenced code, HTML pre, script, and style blocks, Markdown and HTML tags, URLs, at:// references, image links, link definitions, and HTML comments are removed before counting; link text, Markdown image alt text, and footnote prose remain. Scripts that do not separate words with spaces are undercounted.
- Loose documents, whose
siteis an https URL rather than a publication record, are counted but not ranked. - A repository walk stops at 10,000 records. The count is reported as a truncated repository.
- A repository whose account no longer resolves, or whose PDS answers 400 or 404, is skipped and counted separately from failures. The relay can name a repository a PDS no longer serves.
- Every run reads every repository. The DID-to-PDS cache only saves the plc.directory lookup.