Knowledge Website
playbooks/knowledge-websiteChecked by automation only
still a draft
Written 2026-10-16 by ktl-librarian (automation). Last checked 2026-10-27 by ktl-librarian (automation).
The full record
- Checks
- 2026-10-27 by
ktl-librarian(automation)
- 2026-10-27 by
- Sources
- Depends on
- Graph
- Open this concept in the knowledge graph
- IRI
https://w3id.org/ktl/registrar/knowledge/playbooks/knowledge-website- Licence
- CC BY 4.0
- Files
- MarkdownJSON-LDSource on GitHubHistory on GitHub
Overview
Section titled “Overview”website/ builds the site that the Knowledge website workflow publishes to GitHub Pages at https://noelmcloughlin.github.io/obsidian-ktl-registrar/. The ktl-website skill installed both the folder and the workflow. Every page comes from a file the repository already holds, so a change to the site is a change to that file.
What the site is built from
Section titled “What the site is built from”-
Each concept in
.lokf/knowledge/becomes a page underknowledge/, with its trust label fromknowledge-report.sh, its sources and its typed relations both ways. -
The four files
lokf exportwrites are served underknowledge/, beside each concept’s own Markdown file and its JSON-LD. The bundle log is served as an Atom feed,knowledge/log.xml. -
The README becomes the home page, each page under
docs/becomes a page underdocs/, andCHANGELOG.mdbecomes a page per release underchangelog/, which search leaves out. Each release page links the repository, the docs and the bundle at the release’s tag. -
The LinkML schema’s pages and SQLite databases are shown only when
site.config.mjsshows them. This repository’ssite.config.mjssetsSCHEMAto"auto"andBROWSEtonull.
The commit that promotes a release’s changelog skips CI, so its page appears with the next build: the workflow’s weekly run at the latest, or a run by hand.
Preview it
Section titled “Preview it”You need Node.js 22.12 or later and uv. From website/, run npm ci, then npm run dev to serve the site at http://localhost:4321/obsidian-ktl-registrar/, or npm run build to write dist/ and check every link between its pages. Both commands run npm run sync first, which runs lokf export from the sidecar’s own environment in .lokf/ and writes the generated pages. Nothing the sync writes is committed.
What to edit
Section titled “What to edit”-
Edit a page’s words in the file it comes from: the README, a page under
docs/, or a concept, through the librarian and the curator like any other change to the bundle. -
Edit the site’s values and options (the addresses, the title, the logo, the home page’s tagline and buttons, the docs groups and the extra pages) in
site.config.mjs. -
Edit the site’s look in
src/styles/custom.css, which is this repository’s own.theme.cssandcatalogue.cssare the house style.
The workflow
Section titled “The workflow”.github/workflows/knowledge-website.yaml runs on a push to the default branch and on a pull request when either touches website/, the bundle, the README, docs/, .assets/, CHANGELOG.md, llms.txt, .linkml/, a justfile, a pyproject.toml, a uv.lock or the workflow itself. It also runs on Mondays at 05:23 UTC and on demand. It has two jobs, split for least privilege:
-
buildruns under a read-only token. It installs the lokf toolkit the sidecar pins withuv sync --locked, runsnpm ciandnpm run buildinwebsite/, and uploadswebsite/distas the Pages artifact. A pull request gets the same build and link check, and no deployment. -
deployruns only GitHub’s own deploy-pages action and holds thepages: writeandid-token: writescopes. It runs for the default branch only, and only once the repository variableKNOWLEDGE_WEBSITE_ENABLEDistrue.
Set KNOWLEDGE_WEBSITE_ENABLED under Repository variables, not on an environment, because a job’s if: sees only repository and organization variables. Before setting it, tell Pages once to take its site from Actions, under Settings > Pages > Source. A repository that already publishes Pages another way keeps the variable unset until that publisher is retired, because two publishers overwrite each other’s site.