Skip to content

About

Onboarding material for ikigai: books, worked examples, and the code they teach. Each book is its own rustdoc — the examples are doctests, so the tutorial cannot silently rot.

Topics

Resources

Security policy

Accessibility

Stars

1 star

Watchers

0 watching

Forks

Repository files navigation

ikigai-tutorial

Onboarding material for ikigai — a resource-oriented computing kernel in Rust. Books, worked examples, and the code they teach.

The library, https://ikigai-rs.github.io/ikigai-tutorial/library/, lists every book with who it is for, what to read first and where to start. It is generated by crates/book-library from books/library/library.toml and each book's own book.toml, and a book under books/ with no entry there fails cargo test and the deploy.

The book

The ikigai Book — one book, in parts.

part covers
The front door Twenty minutes with the CLI, nothing compiled — catalog, manifold, pipe, as=, cache hit, cut thread, trace — then the REPL grammar with a Run button wherever the in-page kernel can answer
Getting started The resolution model, running a kernel, your first endpoint (camel-case), what resolution buys you (a cache hit, a golden thread cut, a trace, a catalog — each one run), self-description, binding, configuration (a config file the host reads, layered), the file workspace
Building endpoints A transreptor of your own and the kernel selecting it, a three-verb endpoint whose declared capability is enforced per verb, SPARQL over the catalog, and a clock-reading endpoint tested under a fixed clock
Loadable modules Modules vs. linked-in spaces, the host callback, the wire session, dual-mode crates, and an honest account of what is actually finished
Beyond one host A kernel behind a socket, the authority a certificate mints, a query's authority as its dataset (two tenants in one store, one SPARQL text, three answers, and a join refused rather than narrowed), the three things a mount can mean, an editor and a machine as clients — and three exercises against all of it
Polyglot tracks Part I mirrored from Python and TypeScript over the wire protocol — decorator, signature-as-contract, mount-as-binding, cache and trace from outside, a scoped connect refused — plus a notebook querying the catalog with rdflib and SPARQL; and what an L0 peer cannot do
end matter A glossary, a map of every repository in the organization (derived from the org's list, not from memory), and how to contribute a module

Read it:

https://ikigai-rs.github.io/ikigai-tutorial/ — published from main on every merge, by the same run that tests it (below), so what is at that URL is a book that passed.

The published book runs its own kernel in the page: crates/book-wasm is a wasm-bindgen face over book_wasm::page_kernel() (Part I's space and the applied chapter's tic-tac-toe game) and the CLI's engine, built by pages.yml into wasm/ beside the book, and books/ikigai/js/run.js turns a <div class="ikigai-run" data-cmd='…'> in a chapter into a cell: an editable command, Run (or Enter), Reset, and a history of every run with its cache verdict and elapsed time. Nothing runs until the reader does, and nothing is answered in advance: the result is empty until Run, and the listing's output waits behind an "Expected output" disclosure. The four runs in "What resolution buys you" resolve in your browser, against the same space the chapter's tests run against; with the wasm absent a cell cannot run — Run is disabled and says why — and still answers nothing (a11y/no-kernel.mjs pins that in CI). The URN gate checks the chapter's original command; what the reader types is theirs. A picture that a chapter's steps change, shown as numbered tabs of its stages, is books/ikigai/js/stages.js, one copy any book can load; its markup contract is docs/stages.md.

Or clone it and serve it locally:

cargo install mdbook
mdbook serve books/ikigai --open        # the prose; Run is disabled (no kernel)
./scripts/serve-with-drafts.sh          # prose + drafts + the in-page kernel, on 127.0.0.1:3000

mdbook serve never builds crates/book-wasm, so its cells cannot run. The drafts script builds the book with the unpublished chapters linked in, builds the kernel the way pages.yml does, and serves the result statically (no live reload — run it again after an edit). It needs the wasm32-unknown-unknown target and wasm-bindgen-cli at the version crates/book-wasm pins, and prints the install commands if either is missing; --no-kernel skips it. The target is checked in the rustc the build will actually use ($RUSTC, else the first on PATH), not by asking rustup: with Homebrew's Rust ahead of ~/.cargo/bin on PATH, rustup can have the target while cargo builds with a compiler that does not (E0463, "can't find crate for core"). The script says so when it finds that, and the fix is PATH order, not rustup target add. It builds into target/drafts-book/, which ./scripts/test-books.sh does not wipe.

Each part ends in exercises, and each exercise names the file to open, the command to run, what "right" looks like, and the section to re-read — with a worked hint behind a disclosure triangle. Hints rather than solutions, deliberately: a full answer becomes the thing people read instead of the exercise, and an exercise whose hint cannot be written without giving the answer away is an exercise that needed rewriting.

The file every exercise opens is in crates/your-endpoints — the reader's crate. Nothing in the book includes a listing from it (a test enforces that), so it can be broken freely; the crates the chapters quote stay as the book describes them.

Parts rather than separate books, deliberately: one navigation tree, one search index, and cross-references between them that actually resolve. Two mdbook projects cannot link to each other without hand-built relative paths into each other's output directories — which is exactly as brittle as it sounds, and was already broken here before this was merged.

Run the worked example:

cargo run -p hello-camel -- "resource oriented computing"
cargo run -p hello-camel -- --catalog
in  resource oriented computing
out resourceOrientedComputing

@prefix ik: <https://ikigai-rs.dev/ns#> .
…
<urn:ikigai:endpoint:camel-case> a ik:Endpoint ;
    ik:id "camel-case" ;
…

The tutorial host is built with ikigai-vocab's TurtleRenderer, which is what lets it print that catalog — and answer Meta — rather than no Meta renderer configured. The four things Part I promises (a cache hit, a golden thread cut, a traced sub-resolution, a description that is a graph) are tests in crates/hello-camel/tests/payoff.rs, included into the chapter that makes the promise.

Part II's module answers by asking its host a question in the middle of its own invocation:

cargo run -p loadable-module
host    resolves urn:iki:tutorial:module:greeting name=urn:host:name
module  asks the host for urn:host:name
out     Hello, Peter!

The second book: The gonk Book

The gonk Book — gonk, the work-ledger and repository-browser host, one part per way it is used on its own: a ledger of your own, an agent's ledger, the repository browser, review without a reviewer, a spec in the repository (OpenSpec), bridges, several machines, scripts and sentences, several teams, ways of working, and embedding. Published at https://ikigai-rs.github.io/ikigai-tutorial/gonk/, by the same run as the first book and through the same gates. Its design, outline and the check each kind of example is under are in books/gonk/DESIGN.md; the first chapter, A ledger of your own, is written, and the rest are listed as drafts.

Its examples come in three kinds, and the third is new here: cells that run in the page (crates/gonk-book-wasm, the ledger over an in-memory store), Rust that mdbook test runs (crates/ledger-host), and shell transcripts of the gonk binary, which ./scripts/test-transcripts.sh replays against a scratch gonk built from the revision the book pins (books/gonk/gonk.rev; gonk is not on crates.io yet), in a scratch home, comparing what each command prints with what the page says (crates/book-transcripts). Checking what you have runs that gonk over the real RDF Toolbox, so the script also builds the toolbox at its pin (scripts/build-toolbox.sh, books/ikigai/toolbox.rev), which needs rustup and node. The Dashboard's screenshots are regenerated by ./scripts/capture-dashboard.sh, over a scratch gonk and the chapter's seed; The ikigai Book's Checking a resource has its own, ./scripts/capture-toolbox.sh, over scratch hosts of the chapter's crate.

mdbook serve books/gonk --open                     # the prose; Run is disabled (no kernel)
./scripts/serve-with-drafts.sh --book gonk         # with its in-page kernel, on 127.0.0.1:3000
./scripts/test-transcripts.sh                      # every transcript in both books, against their pins

The third book: Building ikigai UIs

Building ikigai UIs — user interfaces where a view is a resource, taught by building a kernel inspector: the cache, golden threads, topology, catalog and scheduler of a running kernel, as pages that follow the kernel's cuts. Part I is the model (a page as a composed resource, graph to page with XSLT, views from JSON and from CSV with no RDF in them, live data and history), Part II the delivery targets (server-rendered HTML with htmx and push is written; GPUI, WebAssembly, WebTransport and the terminal are reserved), Part III components. Published at https://ikigai-rs.github.io/ikigai-tutorial/ui/, by the same run and through the same gates.

The inspector is split the way every target will be: crates/inspector is the model and its artifacts (XSLT stylesheets, compose templates, one atom), crates/inspector-htmx the thin HTTP host, and crates/ui-book-wasm the book's in-page kernel over the same crate. Its pages are held to snapshots, and checked by axe (ikigai-ui's reusable workflow) and in a real browser (a11y/inspector.mjs: 320 px reflow, the keyboard path, focus after a swap, Back).

cargo run -p inspector-htmx                         # the inspector, on 127.0.0.1:8071
./scripts/serve-with-drafts.sh --book ui            # the book with its in-page kernel

The book is tested

There is no separate "keep the docs up to date" chore, because there is a gate:

./scripts/test-books.sh

The script also needs Node.js 22 for the runnable-cell matcher and routing-command regression tests. Those tests use Node's built-in test runner and need no npm packages. The matcher cases are shared with cargo test -p book-transcripts; routing edits use the machine's own sed.

mdbook test compiles and runs every Rust block in the book against the real crates, and CI runs it on every push — the deploy to the URL above is downstream of that same job (.github/workflows/pages.yml), so a red book never publishes. The longer listings are not copied into the prose at all — they are pulled in from the crate by anchor:

```rust,ignore
{{#include ../../../crates/hello-camel/src/lib.rs:impl}}
```

So there is exactly one camel-case and it is the one that compiles.

This matters more than it sounds. A tutorial's examples rot silently: the API moves, the snippet still looks right, and the first person to hit it assumes they are the problem. Two claims in the first draft were wrong about the API — Description::id is a field rather than a method, and config_home lives in ikigai_core::config rather than the crate root — and the tests caught both before anyone read them.

⚠ Use the script rather than calling mdbook test by hand. It needs -L <deps>, and rustc refuses (E0464) when that directory holds more than one candidate for a crate — a shared target/ collects them, because cargo clippy leaves .rmeta beside cargo build's .rlib and a restored CI cache can carry stale ones. The script builds into a target directory of its own, wiped first. The error rustc gives says nothing about books, so this is worth not rediscovering.

The names in the prose are tested too

mdbook test compiles Rust blocks, which covers less of a tutorial than it sounds. Of the resource names this book prints, exactly one sits in a block it compiles. The rest are prose, ignore blocks, program output, and — the first command a new reader types — a shell line in a fenced bash block, which nothing runs. The book's correctness gate was thinnest exactly where a beginner's experience is most fragile.

So cargo test also runs a URN gate (crates/book-urns). It pulls every urn: literal out of the markdown and checks it against the authority that can actually answer for it:

where the name appears who confirms it
a Rust example hello_camel::space() / building_endpoints::space() / loadable_module::host_space() / your_endpoints::module::host_space() — hosts built right here — or, for urn:kernel:*, the kernel built over the first of them, since those names are intercepted rather than bound
a runnable cell's data-cmd hello_camel::space() alone — the kernel the page runs — plus urn:kernel:*
an ikigai … shell example books/ikigai/cli-vocabulary.txt — the book's written-down claim about the CLI, which is another crate on another release schedule
prose either

A name that is supposed not to resolve declares itself next to the claim it qualifies:

<!-- urn-gate: unbound urn:fn:toCamel — the name this endpoint used to be bound at. -->

unbound is checked in the other direction, so a paragraph saying "this used to be called X" goes red if somebody binds X again.

⚠ What it cannot do is confirm that cli-vocabulary.txt is still true of a newer CLI: that takes an ikigai binary, which cargo test does not build. The test that can is in the same file and marked #[ignore], so it announces itself in the test output rather than skipping quietly. CI runs it (ledger #1031) in the same step as the transcripts below, against the same pinned binary, so the file is checked against ikigai-cli at the version in books/ikigai/ikigai-cli.version on every commit. Against whatever ikigai you have:

cargo test -p book-urns --test book_urns -- --ignored --nocapture

And the transcripts

A ```text block whose lines start with ikigai> is the book saying "type this, see that", and nothing compiles one, so one was written to fit its prose. The front door's "Cut a thread" first showed a cut of urn:iki:fn:toUpper followed by not cached, while the CLI of the day said cached: a cut reached only the threads an endpoint declared, and a pure function declares none. crates/book-urns/tests/book_transcripts.rs was written to catch exactly that, and the block was corrected to cached. Then core 0.1.73 began hanging every cacheable read from a thread named after its own target, the real CLI went back to saying not cached, and the corrected block went stale in turn, because nothing ran the replay in CI (ledger #998). The page says not cached again now, for the new reason, and the replay is a CI step (below).

The test types every transcript's lines into one ikigai --quiet REPL on its stdin, the way a reader at the prompt does, and diffs what the REPL printed, stdout and stderr in the order they were written. --quiet (cli 0.1.55) prints only the answers, with no banner and no prompt when stdin is not a terminal, so nothing is stripped before the comparison (cache verdicts, durations and a file thread's generation normalized; … matches any run of lines). It does not pass them as -c … -c …: a -c batch whose stdin is not a terminal fetches and caches the contract of a bare source (cli 0.1.48 and later), so its urn:kernel:cache lists rows a reader's REPL never shows. A block that is the next part of the same sitting says <!-- transcript: continues --> and is replayed with everything before it: replayed alone, "cut, then probe" says not cached in a fresh process whatever the cut does, because nothing was ever cached there. A block that cannot be replayed says <!-- transcript: manual — why -->. Like the vocabulary probe it needs a binary, so it is #[ignore]d, and CI runs both: scripts/test-transcripts.sh (the transcripts job in pages.yml) installs ikigai-cli at the version in books/ikigai/ikigai-cli.version and runs the replay and the probe with that binary first on PATH. To replay against whatever ikigai you have instead:

cargo test -p book-urns --test book_transcripts -- --ignored --nocapture

And what the programs print

A page that says cargo run -p hello-camel and shows a block of output is making the same promise, for a program. Each program's crate has a test that runs its binary and compares what it prints with every copy on every page: hello-camel (README, "Running it", "What resolution buys you"), building-endpoints (one flag each in "The graph face", "Transreption" and "Configuration", whose setup lines run too, in a scratch config home) and loadable-module (README and Part II). The scanner they share is crates/book-transcripts/src/runs.rs, which says how a page writes a run. Its own test, program_runs.rs, scans every page and fails on any cargo run that no test checks and that does not say <!-- transcript: manual — why --> above its fence (the exercises crate, the tic-tac-toe host's sockets, the contrast survey), so a new run block cannot go unchecked by being new (ledger #165, #1072). Two blocks were wrong when it landed: the README's catalog began with an endpoint it does not begin with, and "The graph face" listed two of the thirteen endpoints its query returns.

And the claims about other repositories

The status chapters say things about ikigai-module, ikigai-cli and the browser demo that no test in this workspace can prove — they are claims about code on another release schedule. So every such claim carries the version it was true at in the prose, and crates/book-urns/tests/book_claims.rs holds the same claims as data: crate, version, file, the symbol that must be present (or absent). An always-on test checks the prose still carries each stamp; a #[ignore]d probe downloads each named crate from crates.io at that exact version and greps for the symbol, so a claim that stopped being true is a diff against a version, not a lie. The day ikigai-module 0.2.0 enforced a module's declared capability, the chapter that said "the host does not enforce it" was true at 0.1.10 and false at 0.2.0 — this is what makes that a sentence to update rather than a sentence to distrust.

cargo test -p book-urns --test book_claims -- --ignored --nocapture

That probe answers "is this sentence honest?", never "is this still the world?": a claim true at the stamped version stays green whatever a later release does. The second question is a separate, advisory probe that runs the same table against each crate's latest release (the demo's default branch) and only warns — a miss is a sentence to re-read and re-stamp, not a failure:

cargo test -p book-urns --test book_claims -- --ignored --nocapture claims_still_hold

And the cross-references

A resource name is not the only thing prose asserts about a world outside itself. [chapter 6](status.md) asserts where to go and what it is called there, and only the first half is checked by anything. Merging two books into one renumbered every chapter in the second part; five cross-references went on naming the old numbers while pointing at exactly the right files, so every link resolved and no link checker had a word to say.

The same test file now numbers SUMMARY.md the way mdbook does and checks any surviving [chapter N] against it — and refuses a bare chapter N outright, because with no target there is nothing to check it against. Both are fixed the same way, which is why neither is a nuisance: name the chapter. [Where this actually stands](../modules/status.md) says both halves and a reorder cannot falsify either.

And the order a reader goes in

Every check above runs a page on its own, in a scratch directory of its own, so a chapter that ignores what the chapters before it left behind passes all of them. A reader who goes front to back does not start from nothing: the previous chapter's server may still be running, its directory and names are still in their head, and "the next chapter" means the next one in SUMMARY.md. So every book change keeps serial-reader continuity (ledger #1623):

  • A change that adds, moves or removes setup (a server, a socket, a config home, an enrollment, an install, an environment variable, a scratch directory), cleanup, names or state reads the chapters before and after it.
  • A chapter says what a reader arriving from the previous chapter already has, and what to do with it: "if the gonk from that chapter is still running, stop it first", rather than starting a second one on the same port.
  • Every chapter still works on its own, for a reader who jumps in: acknowledge earlier setup, never delete it.
  • A forward reference says it is one ("later in the book"); a term is defined before a chapter leans on it; one thing keeps one name across chapters.

crates/book-urns/tests/book_continuity.rs checks the part of that a parser can decide, in every book: a page whose transcripts start a long-running piece (a <!-- transcript: serve --> block) must link, above that block, the nearest earlier page that started one, which is what a reader in order still has running; and a link that says the next or previous chapter must point at the neighboring page in SUMMARY.md. Reorder the chapters and both go red. The rest is review: each book's DESIGN.md says what to read for.

And the spelling

The book is written in American English, and a relapse is invisible in a diff that is about something else — the words drift in from briefs, quoted sources and habit. crates/book-urns/tests/book_spelling.rs fails on a short denylist of spellings that are British and nothing else, in the book's pages, scripts and styles and in every crate's sources and READMEs. The matcher and the marker are ikigai-core's, kept the same on purpose. A direct quote keeps its author's spelling and says so on its own line:

> "… the colour of the thing …" <!-- spelling: quote (a quoted source's own words) -->

And what changed

Every book has a What's new page (src/whats-new.md, linked near the top of its SUMMARY.md): the changes a reader would notice, newest first, each a date, a sentence or two written for the reader, and links to the pages it concerns, titled from SUMMARY.md. Nothing on it points at the repository; the history is only where the first entries came from.

The page is generated, from books/<book>/changes.toml, by crates/book-whats-new. ./scripts/test-books.sh writes it before mdbook build, and the generated page is committed, so mdbook serve shows it with nothing run first and a reviewer reads the page a change will publish. crates/book-whats-new/tests/pages.rs fails when the committed page and the entries disagree (an entry edited without regenerating, or the page edited by hand), and when an entry names a page SUMMARY.md does not list: a page that moves takes its new path in every entry that names it, and a page that is gone moves to the entry's removed, listed without a link.

[[change]]
date = "2026-10-15"
summary = "A new chapter, A query's authority is its dataset, runs one SPARQL text for three callers."
pages = ["beyond/datasets.md"]

A change to a book's pages must add or update an entry. The whats-new job in pages.yml runs book-whats-new check-diff over the change and fails, naming the files and printing the entry to add, when a book's published pages (any .md its SUMMARY.md lists, or SUMMARY.md itself) changed and its changes.toml gained no new or edited entry. A file a page pulls in with {{#include}} (a crate listing, say) counts as part of that page. Drafts and the generated page do not count. The escape hatch for upkeep with no news in it (a version move, a corrected link, a typo) is an entry with maintenance = true: kept in the file, left off the page. An entry rather than a commit trailer, because the check runs on the pull request, before the squash commit that would carry the trailer exists. Run it locally against your branch's base:

cargo run -p book-whats-new -- check-diff --base origin/main

Before you commit, --head WORKTREE compares the working tree (untracked files included) to the base instead of HEAD, so a gate run on uncommitted work sees the pages you changed: cargo run -p book-whats-new -- check-diff --base origin/main --head WORKTREE.

A new book under books/ is covered by being there: the generator and the check iterate books/*, and a book with no changes.toml is refused by both.

And the cells' markup

A runnable cell is raw HTML in the markdown, and CommonMark ends an HTML block that opens with <div at the first blank line. So a blank line inside a cell (an empty line of expected output is the easy one to write) renders the rest of it as markdown. On mdbook 0.5.4 that nested every later cell on the page inside one cell's expected output, or turned the output into a paragraph with curly quotes, or (inside data-cmd) dropped the cell; and mdbook, the URN gate and axe all stayed green on each. crates/book-urns/tests/book_cells.rs refuses the blank line in the source and names file:line; the cure is &#32; on an otherwise-empty line of output, which renders as a space and does not end the block. book-a11y checks the built page from the other end: no markup inside an expected output, no cell left open, and as many cells on each page as its chapter writes.

And the colors

mdbook is sound by default in the ways a generator can be — <html lang>, a <main>, a labeled <nav>, labeled theme buttons, no image without alt. Color is the exception, because a theme is a palette somebody chose by eye and nothing measures one.

So ./scripts/test-books.sh also runs crates/book-a11y, which reads the palette mdbook just generated plus this book's additional-css — in book.toml's order, because that is the cascade — and measures every pair a reader actually meets with ikigai-a11y, the ecosystem's own WCAG crate. Body text against 4.5:1 (SC 1.4.3), a non-text UI component against 3:1 (SC 1.4.11).

It found 22 pairs below the floor across the five themes, including the ones that hurt most in a book like this: on rust, the default, a link was 3.67:1 on the page and 2.69:1 inside a blockquote, and inline code — which this book uses in nearly every sentence — was 4.07:1 and 2.99:1. The repairs are in books/ikigai/css/a11y.css, each with the ratio it started from in a comment, and the gate is what says they worked. The tool prints the nearest passing color along with the fault, so a repair starts from a number rather than a guess:

cargo run -p book-a11y -- books/ikigai --survey   # every pair, pass or fail

That crate reads generated CSS rather than holding a table of hex values on purpose. A table would be a gate that goes stale the first time mdbook changes a theme, and stays green while it does.

The other half is a skip link, added by additional-js rather than by forking the theme: with a full-book sidebar, a keyboard or screen-reader user otherwise traverses every chapter link on every page before reaching the words (SC 2.4.1). The same command checks that the element it aims at is still in the built HTML — mdbook renamed that id once already (#content became #mdbook-content), and a skip link pointing at nothing looks exactly like one that works.

And the structure

Since the accessibility pass (2026-09-09), the same book-a11y run also checks the structure of every built page against WCAG 2.2 AA — the part a parser can decide: lang on the root, exactly one h1 in the content, heading levels that never skip, alt on every image, no empty or generic link text, no duplicate id, every ARIA reference pointing at an id that exists, a th in every table, a name on every button and input, and every runnable cell in the shape js/run.js expects. Every fault is reported by success criterion number. Two faults in mdbook's own search markup (an input named only by its placeholder, and an aria-describedby pointing at nothing) are repaired at load by js/a11y.js; the gate credits those repairs only while the script still contains them.

A second instrument runs in CI: a11y/axe.mjs drives axe-core over a jsdom of every page with the book's scripts run, which is the only way to see what JavaScript adds — the copy buttons, the Run cells, the search repairs. A third, a11y/axe-browser.mjs, runs axe-core in a real browser over the assembled site, in all five themes, with the in-page kernels loaded and every cell run: the only one that sees COLOR outside the theme's variables (a highlight.js token, an opacity, a link told from its sentence by hue alone). The three catch different things and all gate the deploy. What neither can judge — reading order, plain language, whether a link's purpose is clear beyond the generic phrases the gate refuses — is a reviewer's job, and docs/a11y.md is the assessment that says so.

The book's constitution, one line: every chapter goes through ./scripts/test-books.sh, which is now mdbook test + contrast + structure, and pages.yml adds axe twice (jsdom and a real browser) — so an accessibility regression is a red build, not a review comment.

⚠ Left alone, deliberately: two <h1>s per page — the book title in the menu bar and the chapter title — which is mdbook's own template, not ours. It is a best practice rather than an AA failure, and the two ways to fix it both cost more than it: overriding theme/index.hbs pins the whole page template, so future mdbook chrome changes stop reaching this book silently (which is exactly how the id above moved); or a11y.js could aria-hidden the menu title, which is three lines and no fork but hides a visible heading from assistive technology. A decision, not an oversight.

The audit also flagged an <h2> ("Keyboard shortcuts") before the first <h1>. Measured against the accessibility tree rather than the HTML, it is not there: mdbook's help popup is display: none until you press ?, so it is out of the tree entirely — worth recording, because a static scan of the markup will keep reporting it.

Accessibility

ACCESSIBILITY.md says what is in scope (both books as published, their in-page kernels, and mdbook's chrome as far as we can repair it), the target (WCAG 2.2 AA; an evaluation in progress, not a conformance claim), the evidence above and what it does not cover, the barriers we know about, and how to report one. Read it before changing a book's pages, styles, scripts or kernels.

Layout

books/                 mdbook sources — prose
crates/                the code each part teaches — compiled, linted, tested
                       (hello-camel, building-endpoints, loadable-module, two-hosts, …,
                       graph-authority, script-host, script-authority, sentence-draft)
crates/your-endpoints  the reader's crate: where the exercises are done, never quoted
examples/              the polyglot tracks' listings (Python, Deno, a notebook), run by hand
                       against a served kernel — not compiled here, not on PyPI/JSR yet
crates/book-urns       not a lesson: the prose gates above, and "never quoted" itself
crates/book-a11y       likewise: the contrast gate and the skip link's target
crates/ledger-host     The gonk Book's first chapter: the ledger and its store in a kernel
crates/gonk-book-wasm  The gonk Book's in-page kernel (the ikigai book's is book-wasm)
crates/resilience-harness  The ikigai Architecture's overlay chapter: real throttle governors
                       around a stub the reader controls, on a clock the reader advances
crates/architecture-book-wasm  The ikigai Architecture's in-page kernel (the ledger + the harness)
crates/book-transcripts  not a lesson: the shell-transcript gate (scripts/test-transcripts.sh)
scripts/               test-books.sh (every book), build-kernels.sh, assemble-site.sh (one
                       Pages artifact, each book where its site-url says), serve-with-drafts.sh

Dependencies are published crates, deliberately

The code depends on ikigai-core and ikigai-fn from crates.io, not on path references to sibling checkouts. Clone this repository on its own and it builds. A path reference would silently require the reader to have the whole ecosystem laid out beside it, which is exactly the friction onboarding material exists to remove.

Adding to it

A new part is a heading in books/ikigai/src/SUMMARY.md and a directory of chapters beside it. Put the code it teaches in a crate under crates/ so it is compiled and linted like anything else, and include that code into chapters by anchor rather than pasting it — paraphrase is how a tutorial starts lying. Read the chapters on either side of the one you change, as a reader in order would (And the order a reader goes in).

Start a genuinely separate book under books/ only when it is about something else (The gonk Book is the second); test-books.sh, axe, the no-kernel check and the link check run over every book they find, assemble-site.sh places each by its site-url, and a book with an in-page kernel adds one line to scripts/build-kernels.sh.

Planned:

  • Transports — embedded, IPC, QUIC, and capability-on-the-wire.
  • Graphs — RDF, SPARQL, transreption, and the vocabulary.

License

MIT — see LICENSE-MIT.

About

Onboarding material for ikigai: books, worked examples, and the code they teach. Each book is its own rustdoc — the examples are doctests, so the tutorial cannot silently rot.

Topics

Resources

Security policy

Accessibility

Stars

1 star

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages