Skip to content
AI.info

Policy archive · Method

How a text is made

The exact steps by which AI.info turns a company’s page into the text it keeps and hashes, with a worked example, so that anyone can make the same text and the same SHA-256 from the same bytes.

Every version in the archive is a text made from the company’s page by code, without a model and without a person’s edit. These are the steps, in the order the code takes them. The same bytes always make the same text and the same SHA-256.

The steps

  1. Read

    Once a day the document’s address is asked for once, with the site’s crawler agent (AIInfoBot/1.0), and conditionally when the last version’s server sent an ETag or a Last-Modified date. Redirects are followed, and once a page that holds only a meta refresh. A page over 4 MB, an HTTP error, a timeout or a bot wall is not a reading: the document’s state says so.

  2. Decode

    The bytes are read as text by the charset the page declares: a byte-order mark first, then the charset of the Content-Type header, then a meta charset in the first 4,096 bytes; UTF-8 when it declares none.

  3. Select the main part

    Comments and CDATA are removed. The longest <main> element, or element with role="main" (read to its own closing tag, nested elements of the same name counted), is kept; else the longest <article>; else the <body>, without its <header>, <footer> and <aside>. A part counts only with 400 characters of text or more.

  4. Remove what is not the document

    Removed with everything inside them: script, style, noscript, template, svg, iframe, head, object, canvas, and the page’s chrome: nav, form, button, select, dialog. Every attribute goes with its tag.

  5. Keep the structure as marks

    A line break in the source is a space. A heading becomes a line that starts with # (one per level), a list item a line that starts with "- ", a table cell ends with " | ", and paragraphs, divisions, tables, rows and the other blocks end a line. Short inline elements marked aria-hidden="true", and labels for screen readers only (sr-only, visually-hidden), are left out. Character references are decoded (&nbsp; becomes a space).

  6. Normalise

    Unicode NFC. Zero-width characters, soft hyphens and byte-order marks removed; no-break and other spaces and tabs made plain spaces; carriage returns made line feeds. A copyright notice’s year (©, (c) or "copyright" before a year or a range of years) and any run of 32 or more hexadecimal digits (a build id, a nonce) removed. Spaces collapsed, each line trimmed, a trailing " |" removed; empty lines, lines that are only a mark (#, -, |) and a line equal to the one before it dropped. Lines joined by a line feed (U+000A), with none at the end. Dates in the text are kept: a changed date is a changed document.

  7. Apply the document’s own cut

    Some documents have a cut, printed on their pages and in /policies.json as "extract": from the first line containing "start" to the line before the first later line containing "end", and lines containing a "drop" word left out wherever they are. If an anchor is gone, the page changed shape: that is a failure, never a version. A text under 400 characters is not a reading.

  8. Hash

    SHA-256 of the text’s UTF-8 bytes, written in lower-case hexadecimal. Each version’s .txt file is those bytes exactly, so its SHA-256 is the one printed.

  9. Keep it only if it changed

    The same hash as the latest version: nothing is written. A new hash: a new version, dated and hashed, with the bytes the server answered (kept with their own SHA-256) and a request to the Wayback Machine to save the page. Once a week, if a version was added, every text is released as one ZIP.

A worked example

A small page as a company’s server might answer it: a menu, a script with a nonce, a cookie button, the document and a footer with a year. The archive keeps only the text below it, and hashes that.

The page as answered

<!doctype html>
<html lang="en"><head><meta charset="utf-8"><title>Usage Policy | Example AI</title>
<script nonce="9f86d081884c7d659a2feaa0c55ad015">window.__BUILD = "a3f1";</script></head>
<body><header><nav><a href="/">Home</a> <a href="/pricing">Pricing</a></nav></header>
<main>
  <h1>Usage Policy</h1>
  <p>Effective: <strong>November&nbsp;20, 2026</strong></p>
  <p>This policy applies to everyone who uses the
     Example AI models, apps and API.</p>
  <h2>1. Do not break the law</h2>
  <ul><li>Do not use the services to plan or commit a crime.</li>
      <li>Do not use them to harass, threaten or defraud anyone.</li></ul>
  <h2>2. Keep people safe</h2>
  <p>Do not use the services to make weapons that can cause mass casualties, or to
     help anyone hurt themselves or others.</p>
  <h2>3. Changes</h2>
  <p>We post every change to this policy on this page and update its date.</p>
  <button>Accept cookies</button>
</main>
<footer>&copy; 2026 Example AI, Inc. All rights reserved.</footer>
<script>track("9f86d081884c7d659a2feaa0c55ad015")</script></body></html>

The text kept (482 characters)

# Usage Policy
Effective: November 20, 2026
This policy applies to everyone who uses the Example AI models, apps and API.
## 1. Do not break the law
- Do not use the services to plan or commit a crime.
- Do not use them to harass, threaten or defraud anyone.
## 2. Keep people safe
Do not use the services to make weapons that can cause mass casualties, or to help anyone hurt themselves or others.
## 3. Changes
We post every change to this policy on this page and update its date.

Its SHA-256

3749f3033debd252cd00a0a6f51db33dec75076e4d82bf55b122797663d09bf5

Hash the text yourself (it has no line feed at the end):

printf '%s' "$TEXT" | sha256sum

Check a version yourself

  1. The text: download a version’s .txt file and hash it. The result is the SHA-256 printed on its page and in /policies.json.
    curl -s https://ai.info/policies/<company>/<document>/<YYYY-MM-DD>.txt | sha256sum
  2. The page: where the archive kept the bytes the company’s server answered (the version’s .raw file), run the archive’s own reader on them, with the document’s cut from /policies.json. It prints the text’s SHA-256.
    curl -sL -o page.raw https://ai.info/policies/<company>/<document>/<YYYY-MM-DD>.raw
    node verify.ts page.raw "text/html; charset=utf-8" '<extract>'
  3. Independently of the archive: open the copy the Internet Archive saved when the version was read, linked from the version’s page, and compare the text.

The reader

The code the daily job runs, published as it is: the reader, the charset step and a script that reads a saved page and prints its text and SHA-256 (Node 22.18 or later).

Changes to this method

A change to the reader that would change a kept text is said here, with the documents it touches, so that no new version is ever made by a change of method alone.

Licence

Dates, hashes, change lists and summaries: CC BY 4.0, credit “AI.info Policy archive”. The texts are the companies’ own and remain theirs. CC BY 4.0

Every document and version (JSON) · The policy archive