A lit/dark standard for CI lights
Abstract. Continuous integration produces a conclusion for each completed run, but everyday language around that conclusion is inconsistent (and often borrowed from color metaphors). This note defines a single bit of CI truth called a light, with vocabulary limited to lit and dark, encoded active-low (lit = 0, dark = 1). It specifies how to read one light from GitHub Actions, how to pack eight lights into a byte, and how a “light computer” can consume that byte. Both states are demonstrated with reproducible proof runs in a public repository.
1. Problem
Programs that react to upstream CI need a stable name for “the latest relevant build is in the good state” versus “it is not.” Color words and pass/fail jargon vary by UI and by speaker. Fetch errors (API rate limits, missing runs, network failure) are sometimes conflated with a dark CI light. Without a short standard, readers disagree about what a dashboard row or a registry rewrite means.
2. Definitions
A light is one bit of CI truth for a GitHub repository (or a local override used only for demos).
The vocabulary is only lit and dark. Map once from GitHub Actions:
conclusion === "success" → lit; any other conclusion → dark. After that mapping,
speak only in lit and dark.
- lit — logical
0— lamp ● - dark — logical
1— lamp ○
Encoding is active-low, like a hardware signal line: lit = 0, dark = 1.
Dark means the upstream project’s latest relevant CI run mapped to dark. Dark does not mean “download failed”, “registry 404”, “npm install broke”, or “we could not fetch the API.” Those are fetch or transport errors; report them separately and do not invent a dark light from them.
“Relevant” means the newest completed GitHub Actions run with event=push.
If no such run exists, that is an error, not a dark light.
3. How a light is read from CI
Request the newest completed push-triggered run:
GET /repos/{owner}/{repo}/actions/runs?per_page=1&status=completed&event=push
Accept: application/vnd.github+json
Take workflow_runs[0]. Apply the one-time map above to obtain lit or dark.
Optional authentication via GITHUB_TOKEN raises the API rate limit; it is not required
for public repositories under ordinary use.
A no-dependency Node reader ships in the companion repository:
node read-light.mjs [owner/repo].
4. Active-low encoding into bytes
Eight lights pack into one active-low byte. Repo index i (0…7) occupies bit
(7 − i). The bit is 1 when the light is dark and 0 when lit.
Example lamps ●●●●○○●● → bits 00001100 → byte 12.
// lit → 0, dark → 1
function lightsToByte(lights) {
return lights.slice(0, 8).reduce(
(b, l, i) => (l.lit ? b : b | (1 << (7 - i))),
0,
);
}
5. The light computer as a consumer
A light computer loads the byte onto an 8-bit CPU IN port and runs small programs (for example a popcount of dark bits, XOR against the previous read, a running tally). Higher-level programs read the last lights and emit suggested actions in plain words — on demand, offline relative to further fetching, and suggest-only (no automatic posts, publishes, or registry changes).
The public landing for the standard and proof is fitzyracing1/lit-dark. The implementation repository fitzyracing1/light-computer is private for now; companion suggest-only programs and an opt-in registry remain private until opened.
6. Reproducibility method and proof runs
Repository fitzyracing1/lit-dark contains a file LIGHT whose sole contents are the
word lit or dark. A GitHub Actions workflow reads that file and exits 0 for lit
or 1 for dark, forcing the Actions conclusion. Anyone may fork the repository, flip the file,
push, wait for the run to complete, and read the light with read-light.mjs.
Proof runs recorded on this repository (Oct 11, 2026 ~11:58–11:59 PM ET):
- lit (bit 0) —
actions/runs/38201903463
— reader:
● lit bit=0 fitzyracing1/lit-dark - dark (bit 1) —
actions/runs/38201942095
— reader:
○ dark bit=1 fitzyracing1/lit-dark
7. Uses
Verified directions already explored in companion private tools (not adoption metrics):
- Opt-in registries. While a mapped package’s light is dark, an opt-in registry may serve a packaged fork under the same name; while lit, it serves or proxies the ordinary upstream.
- Dashboards and programs. A status board or suggest-only program can list which tracked lights are dark and propose human-reviewed next steps.
- Local demos. A local override file can force lit or dark for a demo package without waiting on a public upstream — without claiming that override is the upstream’s light.
8. Limitations
- The “latest push run” filter is a convention; monorepos with many workflows may surface a run that is not the check a human cares about most.
- A dark light does not by itself imply a safe or desirable rewrite of dependencies.
- API failures must not be encoded as dark; the reader should error instead.
- Private implementation repositories are not yet publicly auditable.
9. Future work
- Opening the light computer and companion tools when ready, with the same lit/dark vocabulary.
- Optional workflow selectors (by name or path) where “latest push run” is too coarse.
- History that distinguishes flake (dark→lit→dark in a short window) from a sustained dark streak.
Copyright
Copyright (c) 2026 Joshua Almeida