Skip to content

Fern docs migration with fidelity fixes - #1045

Merged
lbliii merged 15 commits into
mainfrom
lbliii/fix-fern-docs-fidelity-v2
Apr 24, 2026
Merged

lbliii merged 15 commits into
mainfrom
lbliii/fix-fern-docs-fidelity-v2

Conversation

@lbliii

@lbliii lbliii commented Apr 9, 2026 •

Copy link
Copy Markdown
Contributor

Summary

  • Migrates docs to Fern framework with CI workflows for preview builds and publishing
  • Fixes fidelity issues from the original conversion: duplicate page titles, verbose ToC entries, incorrect page ordering, and wrong nav structure
  • Moves "Generating Training Data" under Real-World Environment as a nested page
  • Moves benchmark pages (Add a Benchmark, Design a Customer Evaluation) into Environment Tutorials
  • Splits Quickstart into its own page under Get Started with a proper landing page
  • Adds custom CTAButtons and NavButton MDX components for landing page CTAs and tutorial wayfinding

Supersedes #1040 and #1044.

install fern:

npm install -g fern-api

generate api docs locally (git ignored):

fern docs md generate

generate local preview:

fern docs dev

Test plan

  • Run fern docs dev locally and verify sidebar navigation matches original docs site
  • Verify no duplicate page headings
  • Verify CTAButtons render on home page
  • Verify NavButton renders on tutorial pages
  • Verify all internal links resolve correctly

🤖 Generated with Claude Code

Address PR feedback on docs migration: fix ~22 verbose/changed page
titles to match originals, remove duplicate headings rendered by Fern
frontmatter, restore original nav structure (move benchmark pages into
Environment Tutorials, nest Real-World sub-pages), split Quickstart
into its own page under Get Started, add custom CTAButtons and
NavButton MDX components, and add CI workflows for preview builds
and publishing.

Co-Authored-By: Claude Opus 4.6 <[email protected]>
Signed-off-by: Lawrence Lane <[email protected]>
@lbliii lbliii self-assigned this Apr 9, 2026
lbliii and others added 4 commits April 14, 2026 14:50
…ocs (#1067)

Replace sphinx-build instructions with Fern workflow, update broken
redirect destination, clean up stale _nav_order.yml entries, and remove
obsolete Sphinx FAQ section from both doc versions.

Signed-off-by: Lawrence Lane <[email protected]>
Co-authored-by: Claude Opus 4.6 <[email protected]>
- Replace --- with em dashes in prose (Fern doesn't auto-convert like Sphinx)
- Convert plain markdown nav links to NavButton components
- Remove Source: validation artifacts from data/index pages
- Fix broken Tabs component in download-huggingface pages
- Add check rules for broken links and missing redirects
- Populate reference index page with Cards for child pages
- Add Python API autodocs via Fern libraries config with API Reference tab

Co-Authored-By: Claude Opus 4.6 <[email protected]>
Signed-off-by: Lawrence Lane <[email protected]>
Fern's acorn parser requires a blank line between import statements
and content in MDX files. The v0.2 pages were missing these.

Co-Authored-By: Claude Opus 4.6 <[email protected]>
Signed-off-by: Lawrence Lane <[email protected]>
Signed-off-by: Lawrence Lane <[email protected]>
Co-Authored-By: Claude Opus 4.6 <[email protected]>
Signed-off-by: Lawrence Lane <[email protected]>
@lbliii
lbliii requested review from bxyu-nvidia and cmunley1 April 16, 2026 18:01
lbliii and others added 6 commits April 17, 2026 11:41
- Fix stray quote and reword Command Line Usage intro in configuration.mdx
- "separate machine than" -> "separate machine from" in vllm.mdx
- Rename "Openai Compatible Http Server On Policy Correction" links to "On-Policy Corrections"
- Fix "similar to that of" and link text in nemotron-3-super.mdx

Co-Authored-By: Claude Opus 4.7 <[email protected]>
Signed-off-by: Lawrence Lane <[email protected]>
The original Sphinx docs used `{bdg-primary}` and `{bdg-secondary}` tags on
every grid card to signal scope (e.g. `start here`, `5 min`, `nemotron`,
`benchmark`). Those tags were dropped in the Fern migration. Re-added them
faithfully using Fern's `<Badge>` component as `<Card>` children, mirroring
the original mapping (`bdg-primary` → `intent="success"`,
`bdg-warning` → `intent="warning"`, `bdg-secondary` → default).

Co-Authored-By: Claude Opus 4.7 <[email protected]>
Signed-off-by: Lawrence Lane <[email protected]>
Fern's Badge component has no margin prop, so add CSS to give card
badges breathing room from the description text above and from each
other when grouped on the same line.

Co-Authored-By: Claude Opus 4.7 <[email protected]>
Signed-off-by: Lawrence Lane <[email protected]>
Adds a fern/package.json so the Fern CLI installs reproducibly via
`npm ci` rather than a manual global install, and bumps fern.config.json
to match the pinned 4.80.x install.

Adds four GitHub Actions workflows (sourced from the convert-to-fern
toolkit, originally from NVIDIA-NeMo/Curator):

- fern-docs-ci.yml: `fern check` validation on PRs touching fern/**
- fern-docs-preview-build.yml: uploads fern/ artifact on PR (no secrets)
- fern-docs-preview-comment.yml: builds preview, posts URL comment
- publish-fern-docs.yml: publishes on push to main (docs/** or fern/**),
  tag docs/v*, or manual dispatch

Workflows install Fern via `npm ci` against the pinned lockfile and use
the new package.json scripts (`npm run check`, `npm run generate`).
Preview and publish jobs require the `DOCS_FERN_TOKEN` repository or
organization secret.

Co-Authored-By: Claude Opus 4.7 <[email protected]>
Signed-off-by: Lawrence Lane <[email protected]>
@lbliii
lbliii requested a review from a team as a code owner April 21, 2026 17:51
lbliii and others added 2 commits April 21, 2026 13:55
Mirrors NVIDIA-NeMo/Curator's nemo-curator-docs skill, adapted for Gym:
two-version mirror rule (latest ↔ v0.2), Card+Badge fidelity mapping
from the original Sphinx docs, the new npm-based fern scripts, and
references to the CI workflows added in this PR.

Co-Authored-By: Claude Opus 4.7 <[email protected]>
Signed-off-by: Lawrence Lane <[email protected]>
@lbliii
lbliii enabled auto-merge (squash) April 24, 2026 13:24
@lbliii
lbliii merged commit f02577c into main Apr 24, 2026
8 of 9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants