writing-prminxml
Skill4 starsChanged 8 months agoMITView on GitHub
How to use the PRM-in-XML tool, information about the PRM-in-XML format for RISC OS documentation. Use when reading, writing, editing or reviewing API documentation for RISC OS, or when asked to create PRM-in-XML (or PRMinXML) documents. PRM-in-XML should be used for interface and external documentation.
In this repository47 other files it gives its agents.
- allocating-resourcesSkill
- ci-testingSkill
- creating-pull-requestsSkill
- designing-modulesSkill
- porting-to-riscos-cSkill
- reading-assemblySkill
- riscos-commandsSkill
- riscos-desktop-fileractionSkill
- riscos-filer-likeSkill
- riscos-filesystemSkill
- riscos-graphics-convertersSkill
- riscos-network-dcistatisticsSkill
- riscos-network-resolverSkill
- riscos-outputSkill
- riscos-reSkill
- riscos-styleSkill
- riscos-throwbackSkill
- riscos-urls-fetchingSkill
- riscos-urls-launchingSkill
- riscos-wimp-appSkill
- riscos-wimpSkill
- riscos-wimp-templatesSkill
- updating-robe-skillsSkill
- using-bbcbasicSkill
- using-cmhgSkill
- using-ghSkill
- using-gitSkill
- using-libasmSkill
- using-libgcontextSkill
- using-liboslibSkill
- using-libriscoslibSkill
- using-libtoolboxSkill
- using-makefilesSkill
- using-perlSkill
- using-stronghelpSkill
- using-toolbox-imagefilegadgetSkill
- using-tooltesterSkill
- writing-assemblySkill
- writing-assembly-testsSkill
- writing-cmodulesSkill
- writing-cplusplusSkill
- writing-cSkill
- writing-fortranSkill
- writing-oslib-defsSkill
- writing-pascalSkill
- writing-pymodulesSkill
- writing-pyromaniac-integration-testsSkill
The file
Show its rules and text
We split this skill into the rules it gives an agent
16 rules. About 0 are common, 9 are distinctive, and 7 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈9
Distinctive · estimate
This author's own choices. Worth a look.
7
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 25
Create a skeleton document: riscos-prminxml -f skeleton -o <document>.xml
- Very specific: line 31
Never write HTML output to the same directory as the source XML with -O.
- Very specific: line 33
Create the output directory before using -O.
- Distinctive: line 38
When using this skill:
- Distinctive: line 42
Read only the focused reference files needed for the task.
- Very specific: line 46
If the user wants to inspect the result, open it with host-open.
- Distinctive: line 48
After creating or editing a PRM-in-XML document, always lint it and then build the HTML version to confirm that the syntax and structure …
- Distinctive: line 56
Write PRM documentation as authoritative user-facing guidance.
- Distinctive: line 59
Do not frame PRM documentation as a report about repository state, wrapper source, shipped help, or what another document currently says, …
- Distinctive: line 62
When a limitation or special case matters, document it directly as supported behaviour or a workflow boundary.
- Very specific: line 73
When creating a multi-file manual set intended to read as a book, prefer an indexed collection with a local index.xml, front matter, and a …
- Very specific: line 79
When converting an existing document set into PRM-in-XML, preserve the original document history and authorship in <history> where the …
- Very specific: line 83
When a converted source has substantial rationale or background material, prefer separate Introduction and Overview sections rather than …
- Distinctive: line 93
Read the focused reference file that matches the task:
- Distinctive: line 95
Document shape, chapter structure, prose rules, basic XML skeleton, paragraphs, lists, examples, cross-references, inline elements, and …
- Distinctive: line 110
Prefer reading only the references needed for the current task rather than loading the entire reference set.
≈ “Common” is an estimate: at least 1 in 5 of the 213,897 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
PRM-in-XML
Summary
PRM-in-XML defines documents in the style of the Programmer's Reference Manual as XML. Those documents can then be converted to HTML and other output formats, and are intended to remain machine-readable.
PRM-in-XML should be used for API and interface documentation. If asked to
create API or interface documentation, use PRM-in-XML by default.
Repository and implementation details should not use PRM-in-XML unless
explicitly requested; use Markdown for those instead. If asked to create a
README.md, always create Markdown.
Tools
- Create a skeleton document:
riscos-prminxml -f skeleton -o <document>.xml - Convert a document to HTML:
riscos-prminxml -f html5+xml -O <directory> <document>.xml - Lint a document:
riscos-prminxml -f lint <document>.xml - Build an indexed manual set:
riscos-prminxml -f index index.xml - Help on the tool itself:
riscos-prminxml --help
Never write HTML output to the same directory as the source XML with -O;
that would overwrite source files.
Create the output directory before using -O; the converter expects it to
exist already.
Agent workflow
When using this skill:
- Decide whether the task is PRM-in-XML at all.
- Choose the smallest useful document shape for the request.
- Read only the focused reference files needed for the task.
- Edit or create the XML.
- Lint the changed document or indexed set.
- Build HTML output to confirm the structure renders correctly.
- If the user wants to inspect the result, open it with
host-open.
After creating or editing a PRM-in-XML document, always lint it and then build the HTML version to confirm that the syntax and structure are correct.
Show the user generated documentation with host-open output/html or another
relevant built output directory once the result is ready.
Core rules
- Write PRM documentation as authoritative user-facing guidance.
- Explain what the documented tool, interface, or workflow does, how it is used, and what constraints users must follow.
- Do not frame PRM documentation as a report about repository state, wrapper source, shipped help, or what another document currently says, unless the subject itself is repository layout or source format.
- When a limitation or special case matters, document it directly as supported behaviour or a workflow boundary.
- For component or interface documents, ensure the
Overviewsection explains why the component exists and how it relates to other components. - For component or interface documents, ensure the
Technical Detailssection explains how the component is used and what its interfaces mean. - For multi-file manuals, do not force every chapter into the same heading template. Workflow, reference, and appendix chapters may use different structures when that makes the manual clearer.
- Appendix chapters may begin with
Overview, but do not need anExamplessection unless worked examples materially improve the appendix. - When creating a multi-file manual set intended to read as a book, prefer an
indexed collection with a local
index.xml, front matter, and aMakefilethat can build both per-chapter HTML and the indexed collection. - The metadata section should be updated with each major change. Populate the visible author or maintainer details with the user's full name where the document format expects that information.
- When converting an existing document set into PRM-in-XML, preserve the
original document history and authorship in
<history>where the source material provides it; the conversion revision should not erase earlier protocol or manual releases. - When a converted source has substantial rationale or background material,
prefer separate
IntroductionandOverviewsections rather than forcing everything intoIntroduction and Overview. - Canonical conversions should retain not just the final interface reference facts, but also important rationale, motivating examples, and workflow guidance from the original document when those explain how the interface is intended to be used.
Routing
Read the focused reference file that matches the task:
- Document shape, chapter structure, prose rules, basic XML skeleton, paragraphs, lists, examples, cross-references, inline elements, and entities: references/document-structure.md
- SWI, service, system-variable, VDU, star-command, and
<reference>details: references/definitions-and-references.md - Indexed manual sets,
index.xml, metadata, and localMakefilepatterns: references/indexed-manual-sets.md - BNF, table elements, common lint failures, conversion guidance, and quick reference material: references/tables-and-troubleshooting.md
- Existing-document review for accuracy or publication readiness: references/documentation-review.md
- Publishing PRM-in-XML output through GitHub Actions: references/github-ci.md
Prefer reading only the references needed for the current task rather than loading the entire reference set.
Primary source documents
The PRM-in-XML XML format is described in:
/riscos-resources/Install/Tools/Linux/riscos-prminxml-resources/docs/PRMinXML.txt
General authoring guidance is in:
/riscos-resources/Install/Tools/Linux/riscos-prminxml-resources/docs/HowTo.md
The DTD used by PRM-in-XML 1.03 is:
/riscos-resources/Install/Tools/Linux/riscos-prminxml-resources/gerph/103/prm.dtd
Validation
For single-document work, the normal validation loop is:
riscos-prminxml -f lint <file>.xmlriscos-prminxml -f html5+xml -O <output-dir> <file>.xml
For indexed manual sets, lint and build the index as well:
riscos-prminxml --lint -f index -L <log-dir> index.xmlriscos-prminxml -f index -L <log-dir> index.xml
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

