Skip to main content

AI-Assisted Documentation Authoring

3 min readStableIntermediate

OwnDocs ships with an AI skill that writes documentation pages for you. Give it a source, and it reviews that source, picks the right page type, and writes an MDX page that follows this project's own templates and component rules.

Prerequisites

  • OwnDocs cloned and running locally. See Installation if you haven't set it up yet.
  • An AI coding assistant that can read this repository. Claude Code gets the full workflow (a skill, a review agent, and a slash command); any other AI coding agent that reads Markdown skill files can use the same skill from .agents/skills/docs-page-templates/SKILL.md.
  • A source to write from: raw text you paste in, a local file or folder, or a git repository URL.

Steps

  1. Give Claude Code a source and, optionally, a page type

    Run the /create-doc-page command with your source, and name a page type if you already know it:

    Bash
    Bash
    /create-doc-page path/to/my-notes.md how-to

    Leave the page type off and the skill classifies it for you. Add --scope section --pages 3 when you're generating more than one page at once, or --dry-run to see the plan without writing anything.

  2. The skill reviews the source before writing anything

    For one page, it reads the source directly. For a multi-page scope, it fans out parallel docs-source-reviewer agents, one per page, so every page gets its own grounded review at the same time. Every claim on the finished page has to trace back to something the source actually said.

  3. It picks the page type

    The skill matches your source against five templates - index/hub, feature example, how-to, reference, and concept - using the Diataxis framework: does the reader need to learn from zero, follow steps, look up exact details, understand why something works, or get routed to the right subpage. Name the type yourself in step 1 to skip this.

  4. It writes the page, then edits its own prose

    The page comes from the matching template, using only the components registered for this project (cards, tabs, steps, and the rest). Before the skill calls it done, it runs its own edit pass on the text: cutting filler phrases, mixing sentence lengths, and checking every number or claim against the source it reviewed.

  5. It checks its own work

    The skill runs npx prettier --check, npx remark --frail, and npm run build on the new page, since a new page changes the sidebar and the search index too.

For an AI agent other than Claude Code, point it at .agents/skills/docs-page-templates/SKILL.md and describe your source and page type the same way. It follows the same review-write-check workflow, reviewing one page at a time instead of running reviewers in parallel.

Result

A new .mdx file lands under content/, in the right template, using only this project's registered components. With the dev server already running, the page shows up in the sidebar and search on your next request - no restart, no extra configuration. It's the same file-based routing every page here uses.

Troubleshooting

  • The skill stops and asks for a source - it won't write a page from a source it couldn't read. Point it at a file, folder, or URL it can reach.
  • The page type looks wrong - name it explicitly in your source command (how-to, reference, concept, feature-example, or index) instead of leaving it to auto-detection.
Last updated Contributors: Md. Sazzad Hossain Sharkar
Was this page helpful?

© 2026 DevOps. All rights reserved.