SemText

Showcase

CLAUDE.md, in one file for every reader

Repository guidance is written once and read twice: an agent needs the rules as records it can quote, a contributor needs a page they can skim. As SemText, the same file is both — the agent record carries the name, bio and instructions a model follows, while the procedure and fact blocks are the same guidance rendered as this page. Point the agent at the file; hand the human the URL.

The document

Switch to Render to read it as a contributor does; the source is the same file the agent consumes. The facts carry ids, so an answer can cite g-main the way the instructions require.

claude-md example

claude.md · authored SemText
source
<sem-enhanced-document>
<agent>
<name>Repo Guide</name>
<bio>Answers build and release questions for this repository.</bio>
<instructions>Answer only from the sem-fact records on this page; cite fact ids. Never invent commands.</instructions>
</agent>
<h1 data-kind="title">Contributor guide</h1>
<sem-note variant="warning">Never push to <code>main</code> by hand — CI owns it.</sem-note>
<h2>Build</h2>
<sem-procedure kind="runbook" role="list">
<sem-step role="listitem" status="done">Install dependencies</sem-step>
<sem-step role="listitem" status="current">Run the dev server</sem-step>
<sem-step role="listitem">Build before every PR</sem-step>
</sem-procedure>
<h2>Invariants</h2>
<sem-facts view-as="list" controls="filter">
<sem-fact id="g-main" kind="invariant">
<statement>main is CI/CD-only</statement>
<conclusion>All merges into main are performed by automation; humans and agents merge to develop.</conclusion>
</sem-fact>
<sem-fact id="g-tests" kind="invariant">
<statement>Tests run against built pages</statement>
<conclusion>Run the build before the suite — the specs read the built output, not the sources.</conclusion>
</sem-fact>
</sem-facts>
</sem-enhanced-document>
render

Render view: this block wires to the SemText runtime bundle in the full example viewer (port-reference lane) — the source beside it is the same file, byte for byte.

Why this works

  • The agent record is machine-facing metadata — extraction names it a record; the browser leaves it invisible.
  • sem-procedure statuses (done / current / blocked) are canonical attributes, so both readers agree on where the process stands.
  • With scripts off nothing is hidden — the guidance reads as plain authored text, the record intact.

Elements used: agent, sem-note, sem-procedure, sem-facts. Their contracts live on the reference pages .