Home /Modules/manifesto/SLEELADOC.WIKI.md

SLEELADOC.WIKI.md

manifesto/SLEELADOC.WIKI.md · 116 line(s) · markdown

SleelaDoc — the compiler's built-in documentation outputs (--wiki + originated twin)

Beyond the sleeladoc extractor, which renders the authored intent of a unit, the compiler itself produces documentation for an author-marked document as a consequence of compilation. These are the sanctioned, zero-dependency API-doc outputs: you already run the compiler, so you already have them.

There are two such outputs, both gated on the author; / authorial document marker (syntax 2.4+):

OutputFlagWhat it isImplemented in
Originated source twin(automatic for author-marked)a regenerated .sleela source in which every field and method is located and originated and carries a ∴ branderimpl/frontend/originate.{h,cpp}
Wikitext emanation--wiki / --wiki-dir=<dir>a structured MediaWiki page — infobox, a sortable wikitable of every class and member, and a declaration-order "Movement" sectionimpl/frontend/wikigen.{h,cpp}

The author marker

Both outputs require the document to be author-marked. Add the author; (or authorial) marker near the top of the file, alongside material;:

#sleela 2.5
author;
material;
<< ... >>
class MyUnit { ... }

Without the marker, the compiler emits only the runnable artifact; the originated twin and the wiki page are not produced.

Running it

# from the repository root, with the SHA-256 manifest selected
SLEELA_SHA256_MANIFEST="$(pwd)/security/sha256-manifest.json" \
  ./impl/build/sleela compile <file.sleela> \
    --wiki --wiki-dir=out -o out/<file>.sleela

Typical console output:

sleelvac: <file>.sleela -> out/<file>.sleela (runnable Sleela Core artifact)
sleelvac: originated source -> <file>.originated.sleela
sleelvac: wikitext emanated -> out/<file>.wiki

Flags:

Note. The originated twin is written next to the source by default, so it can appear as a new *.originated.sleela file in your working tree. Point --originate-dir at a build/output directory to keep the source tree clean — and remember that files written under lib/** participate in the SHA-256 manifest gate.

What the wiki page contains

The emanation is factual and structured — a catalog of the declared surface, not prose. For each unit it writes:

The output scales with the size of the program: a larger work produces a larger corpus. It is MediaWiki markup intended for a self-hosted wiki — it is not a submission to any public encyclopedia, and auto-generated pages should not be submitted to one without that project's approval.

The originated twin

The *.originated.sleela document is the auditable twin of the runnable artifact: a clean, regenerated source in which every member is located and originated and carries the ∴ brander (the house analogue of Java's @). The brander records the member's declaration-order id, its SHA-256 hash, the document name, the member name, the parameter signature, and the edit date (see SLEELA.syntax §18).

Choosing between the three

SLeeLa offers three complementary documentation facilities:

FacilityRendersFormBest for
sleeladoc extractorauthored intent (@doc prose + tags)Markdown / HTMLintent-level API pages, like javadoc
--wiki emanation (this doc)the declared surface (every class/member + brander)MediaWikia branded, member-by-member catalog on a self-hosted wiki
originated twinthe located, branded source.sleelaan auditable, brander-stamped copy of the artifact

Use sleeladoc when you want to publish the meaning a developer wrote; use --wiki when you want a structured inventory of the surface as a byproduct of every compile; use the originated twin for provenance and audit.

Cross-references