Skip to content

[doc] Add rst-to-myst conversion skill - #64135

Merged
elliot-barn merged 1 commit into
ray-project:masterfrom
dstrodtman:djs-260615-rst-to-myst-skill
Jun 22, 2026
Merged

elliot-barn merged 1 commit into
ray-project:masterfrom
dstrodtman:djs-260615-rst-to-myst-skill

Conversation

@dstrodtman

Copy link
Copy Markdown
Contributor

Description

Add a user-invocable rst-to-myst skill under doc/.claude/skills/ that captures the playbook for converting Ray documentation pages from reStructuredText to MyST Markdown.

MyST is the standard for new doc pages (a lint check rejects newly-added .rst), and many doc/source/ pages still need conversion. The conversion has a handful of constructs that silently break the fail_on_warning Sphinx build or drop doctest coverage if mishandled — this skill encodes them so each conversion is consistent and safe. Distilled from migrating the ray-contribute/ developer guides.

Contents:

  • RST→MyST mapping table for every construct.
  • Five build-breaking hard rules: preserve label names exactly; .md→.rst whole-doc links must use {doc}`…`; heading levels follow RST's order-of-first-appearance (not the underline character); the doctest literal-vs-executed split; and rewrite doc/BUILD.bazel doctest exclude entries .rst→.md in the same PR.
  • Construct-by-construct notes, a reference-update checklist (what changes vs what's a no-op), reusable static-check snippets, build + doctest verification, and the verified Ray-specific facts (default_role = "code", linkify off, colon_fence on, the doctest glob, vale/prettier scope).

The skill is user-invocable and is discovered when working in doc/.

Related issues

None.

Additional information

Validated that the SKILL.md frontmatter parses and its fenced examples are balanced. The skill lives outside doc/source/, so it isn't part of the Sphinx build.

@dstrodtman
dstrodtman requested a review from a team as a code owner June 16, 2026 11:28

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request introduces a new Claude skill file, SKILL.md, which provides comprehensive guidelines and a verification script for converting Ray documentation from reStructuredText (.rst) to MyST Markdown (.md). The review feedback suggests improving the robustness of the Python verification script's regex patterns to better detect residual RST constructs, such as supporting additional underline characters and handling double underscores in external links.

Important

The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.

Comment thread doc/.claude/skills/rst-to-myst/SKILL.md Outdated
for i, ln in enumerate(t.splitlines(), 1):
if ln.lstrip().startswith('```'): infence = not infence; continue
if infence: continue
for pat in (r':(ref|doc):`', r'^\.\. ', r'`[^`]*<[^>]*>`_', r'[^:]::\s*$', r'^(=+|~+)\s*$'):

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

The verification script's regex patterns have a few gaps that can be improved for robustness:

  1. Support for other underline characters: The original regex r'^(=+|~+)\s*$' only checks for = and ~ underlines. However, -, ^, and * are also very common RST underline characters (with - explicitly mentioned in the mapping table on line 100). Using r'^([=-~^+*#])\1+\s*$' matches any repeating sequence of these characters (at least 2), which is much more robust and avoids false positives on single bullet points.
  2. Handling :: on its own line: The original r'[^:]::\s*$' requires a non-colon character before ::, meaning it fails to match a line that consists solely of ::. Changing it to r'(?:^|[^:])::\s*$' fixes this.
  3. Handling double underscores in external links: RST external links can end with _ or __ (as shown in the mapping table on line 103). Changing the suffix to _+ ensures both are matched.
  4. Using hex escapes for backticks: Using \x60 instead of literal backticks in the regexes makes the script cleaner and avoids any potential issues with markdown/JSON parsing of backticks.
Suggested change
for pat in (r':(ref|doc):`', r'^\.\. ', r'`[^`]*<[^>]*>`_', r'[^:]::\s*$', r'^(=+|~+)\s*$'):
for pat in (r':(ref|doc):\x60', r'^\.\. ', r'\x60[^\x60]*<[^>]*>\x60_+', r'(?:^|[^:])::\s*$', r'^([=-~^+*#])\1+\s*$'):

## Why

Ray is migrating doc/source/ pages from reStructuredText to MyST Markdown
(MyST is the standard for new pages; a lint check rejects newly-added
`.rst`). Many pages remain. The conversion has a handful of constructs
that silently break the `fail_on_warning` build or drop doctest coverage
if mishandled, and re-discovering them each time is error-prone.

## What

Add a user-invocable `rst-to-myst` skill under `doc/.claude/skills/` that
captures the conversion playbook learned migrating the `ray-contribute/`
guides:

- the RST→MyST directive mapping table;
- five build-breaking hard rules — label preservation, `{doc}` vs bare
  cross-extension links, heading levels by order-of-appearance, doctest
  literal-vs-executed, and the `doc/BUILD.bazel` doctest exclude entries;
- construct-by-construct notes, a reference-update checklist, reusable
  static-check snippets, and the build + doctest verification steps.

The skill is discovered when working in `doc/`.

Signed-off-by: Douglas Strodtman <[email protected]>
Co-authored-by: Claude Opus 4.8 (1M context) <[email protected]>
@dstrodtman
dstrodtman force-pushed the djs-260615-rst-to-myst-skill branch from 6a5fb7d to 35e00cf Compare June 16, 2026 14:07
@ray-gardener ray-gardener Bot added usability docs An issue or change related to documentation core Issues that should be addressed in Ray Core labels Jun 16, 2026
@dstrodtman dstrodtman added the go add ONLY when ready to merge, run all tests label Jun 16, 2026
@elliot-barn
elliot-barn merged commit d386050 into ray-project:master Jun 22, 2026
7 checks passed
elliot-barn pushed a commit that referenced this pull request Jun 22, 2026
…vement to MyST (#64136)

## Description

Convert the final three contributor-facing **Developer Guides** pages in
`doc/source/ray-contribute/` from reStructuredText to MyST Markdown,
completing the section's migration to MyST (the declared standard for
new pages). These are the hub/entry pages — the most coupled in the
section.

Pages converted:

- `getting-involved` — the contributor hub
- `development` — building Ray from source
- `involvement` — the community-links partial included by
`getting-involved`

**Faithful format conversion only — no content restructuring.** Notable
handling:

- **`development`** — the sphinx-design `.. tab-set::` / `.. tab-item::`
and two `.. dropdown::` blocks become colon-fence directives
(`::::{tab-set}` / `:::{tab-item}` / `:::{dropdown}`) so the nested code
fences compose cleanly. All 8 cross-reference labels are preserved
(`building-ray`, `fork-ray-repo`, `prepare-venv`, `python-develop`,
`python-develop-uninstall`, `build-distributable-wheel`,
`build-ray-image`, `full-source-build`) — referenced internally and from
`getting-involved`.
- **`getting-involved`** — its two `.. testcode::` blocks (the canonical
pydoc examples) become `{testcode}`; the page stays excluded from the
doctest rule, so its `doc/BUILD.bazel` exclude entry is updated `.rst` →
`.md`. The `.. include::` of `involvement` becomes `{include}
involvement.md`, and the shared `_includes/_latest_contribution_doc.rst`
banner stays an include via `{include}` with `:parser: rst`. The
`getting-involved` label is preserved.
- **`involvement`** — a content partial (no frontmatter); its
named-reference links are inlined, which also removes the duplicate `on
GitHub` target it shared with `getting-involved`.

Companion **`.claude/`** updates point at the new `.md` paths (root
`CLAUDE.md`, the `lint` and `rebuild` skills, the python-guidelines
rule). Toctree entries are extensionless and unchanged; `.html` redirect
targets are unaffected.

**One forced rendering change:** the lettered sub-list (a/b/c) under
"Fork the Ray repository" becomes a numbered sub-list (1/2/3), since
MyST/CommonMark has no alpha-enumerated lists.

## Related issues

None.

## Additional information

Verified locally: frontmatter parses; backtick and `:::` colon fences
balance (60/60 and 10/10); all 9 labels present;
`{testcode}`/`{toctree}`/`{include}`/`{tab-set}`/`{tab-item}`/`{dropdown}`
counts are exact; no residual RST outside fences; and the
blockquote-wrapped code, the Windows nested numbered list, and the
python-develop column-0 code-block list all render correctly via
markdown-it. The RtD preview build is the authoritative check for the
sphinx-design directives and cross-references.

Completes the `ray-contribute/` RST→MyST migration (Tier A #64100, Tier
B #64111, Tier C #64115, plus the `rst-to-myst` skill #64135).

**Cross-reference fixes** (flagged by the initial RtD build):
`docs.md`'s link to the renamed `getting-involved` is now extensionless,
and `getting-involved`'s two intra-page section links use MyST `#anchor`
fragments — the original `.html#anchor` form isn't resolved by MyST and
emits `myst.xref_missing`.

Signed-off-by: Douglas Strodtman <[email protected]>
Co-authored-by: Claude Opus 4.8 (1M context) <[email protected]>
limarkdcunha pushed a commit to limarkdcunha/ray that referenced this pull request Jun 30, 2026
## Description

Add a user-invocable `rst-to-myst` skill under `doc/.claude/skills/`
that captures the playbook for converting Ray documentation pages from
reStructuredText to MyST Markdown.

MyST is the standard for new doc pages (a lint check rejects newly-added
`.rst`), and many `doc/source/` pages still need conversion. The
conversion has a handful of constructs that silently break the
`fail_on_warning` Sphinx build or drop doctest coverage if mishandled —
this skill encodes them so each conversion is consistent and safe.
Distilled from migrating the `ray-contribute/` developer guides.

Contents:

- **RST→MyST mapping table** for every construct.
- **Five build-breaking hard rules**: preserve label names exactly;
`.md`→`.rst` whole-doc links must use `` {doc}`…` ``; heading levels
follow RST's order-of-first-appearance (not the underline character);
the doctest literal-vs-executed split; and rewrite `doc/BUILD.bazel`
doctest exclude entries `.rst`→`.md` in the same PR.
- Construct-by-construct notes, a reference-update checklist (what
changes vs what's a no-op), reusable static-check snippets, build +
doctest verification, and the verified Ray-specific facts (`default_role
= "code"`, `linkify` off, `colon_fence` on, the doctest glob,
vale/prettier scope).

The skill is `user-invocable` and is discovered when working in `doc/`.

## Related issues

None.

## Additional information

Validated that the SKILL.md frontmatter parses and its fenced examples
are balanced. The skill lives outside `doc/source/`, so it isn't part of
the Sphinx build.

Signed-off-by: Douglas Strodtman <[email protected]>
Co-authored-by: Claude Opus 4.8 (1M context) <[email protected]>
limarkdcunha pushed a commit to limarkdcunha/ray that referenced this pull request Jun 30, 2026
…vement to MyST (ray-project#64136)

## Description

Convert the final three contributor-facing **Developer Guides** pages in
`doc/source/ray-contribute/` from reStructuredText to MyST Markdown,
completing the section's migration to MyST (the declared standard for
new pages). These are the hub/entry pages — the most coupled in the
section.

Pages converted:

- `getting-involved` — the contributor hub
- `development` — building Ray from source
- `involvement` — the community-links partial included by
`getting-involved`

**Faithful format conversion only — no content restructuring.** Notable
handling:

- **`development`** — the sphinx-design `.. tab-set::` / `.. tab-item::`
and two `.. dropdown::` blocks become colon-fence directives
(`::::{tab-set}` / `:::{tab-item}` / `:::{dropdown}`) so the nested code
fences compose cleanly. All 8 cross-reference labels are preserved
(`building-ray`, `fork-ray-repo`, `prepare-venv`, `python-develop`,
`python-develop-uninstall`, `build-distributable-wheel`,
`build-ray-image`, `full-source-build`) — referenced internally and from
`getting-involved`.
- **`getting-involved`** — its two `.. testcode::` blocks (the canonical
pydoc examples) become `{testcode}`; the page stays excluded from the
doctest rule, so its `doc/BUILD.bazel` exclude entry is updated `.rst` →
`.md`. The `.. include::` of `involvement` becomes `{include}
involvement.md`, and the shared `_includes/_latest_contribution_doc.rst`
banner stays an include via `{include}` with `:parser: rst`. The
`getting-involved` label is preserved.
- **`involvement`** — a content partial (no frontmatter); its
named-reference links are inlined, which also removes the duplicate `on
GitHub` target it shared with `getting-involved`.

Companion **`.claude/`** updates point at the new `.md` paths (root
`CLAUDE.md`, the `lint` and `rebuild` skills, the python-guidelines
rule). Toctree entries are extensionless and unchanged; `.html` redirect
targets are unaffected.

**One forced rendering change:** the lettered sub-list (a/b/c) under
"Fork the Ray repository" becomes a numbered sub-list (1/2/3), since
MyST/CommonMark has no alpha-enumerated lists.

## Related issues

None.

## Additional information

Verified locally: frontmatter parses; backtick and `:::` colon fences
balance (60/60 and 10/10); all 9 labels present;
`{testcode}`/`{toctree}`/`{include}`/`{tab-set}`/`{tab-item}`/`{dropdown}`
counts are exact; no residual RST outside fences; and the
blockquote-wrapped code, the Windows nested numbered list, and the
python-develop column-0 code-block list all render correctly via
markdown-it. The RtD preview build is the authoritative check for the
sphinx-design directives and cross-references.

Completes the `ray-contribute/` RST→MyST migration (Tier A ray-project#64100, Tier
B ray-project#64111, Tier C ray-project#64115, plus the `rst-to-myst` skill ray-project#64135).

**Cross-reference fixes** (flagged by the initial RtD build):
`docs.md`'s link to the renamed `getting-involved` is now extensionless,
and `getting-involved`'s two intra-page section links use MyST `#anchor`
fragments — the original `.html#anchor` form isn't resolved by MyST and
emits `myst.xref_missing`.

Signed-off-by: Douglas Strodtman <[email protected]>
Co-authored-by: Claude Opus 4.8 (1M context) <[email protected]>
richardliaw pushed a commit that referenced this pull request Jul 1, 2026
## Why

The Ray docs build with `fail_on_warning: true`, so any single Sphinx
warning fails the build. The expensive part of a docs change is usually
not the edit — it's *locating* the warning, a manual, token-heavy chain
(one RST→MyST conversion tier took three ~6-minute Read the Docs cycles
just to find the failure). These failures are a small, classifiable set
with mechanical, canonical fixes.

## What

Adds `sphinx-fix`, a deterministic, read-only Claude Code skill under
`doc/.claude/skills/` that turns a Sphinx warning stream into a
severity-ordered list of findings, each with its canonical fix:

- **`rules.yaml`** — the canonical category/signature → cause → fix
table (10 seed rules plus known-benign suppressions). It is the single
source the `rst-to-myst` skill now points at for the shared MyST link
classes.
- **`sphinx_fix.py`** — a stdlib-only engine (prefers PyYAML, falls back
to a bundled parser so it runs anywhere) that parses the warning stream
(a Read the Docs log, a local build, or pasted text), classifies each
warning, detects a hard-broken build first, triages by severity tier
(fatal → structural → plain), segregates suppressed classes, and lists
every unclassified warning so the table can grow from real misses. v0 is
human-in-the-loop: it proposes fixes and never edits files.
- **`SKILL.md`** — when and how to use it, the severity-tier iterate
loop, applying fixes, and the unclassified→follow-up feedback loop.
- **Tests** — eight fixtures plus golden files, run via `python
doc/.claude/skills/sphinx-fix/sphinx_fix.py --selftest` (which also
cross-checks the fallback parser against PyYAML).

The new files live under `doc/.claude/skills/` and do not participate in
the Sphinx build or doctest (those globs start at `doc/source/`).
Verified end-to-end against a real Read the Docs build log.

## Notes for reviewers

- **Stacked on #64135** (the `rst-to-myst` skill, which introduces
`doc/.claude/skills/`). This draft's diff includes that PR until it
merges; I'll rebase onto `master` for a clean diff and mark ready then.
- Kept as a draft until #64135 lands.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

---------

Signed-off-by: Douglas Strodtman <[email protected]>
Co-authored-by: Claude Opus 4.8 (1M context) <[email protected]>
elliot-barn pushed a commit that referenced this pull request Jul 9, 2026
## Why

The Ray docs build with `fail_on_warning: true`, so any single Sphinx
warning fails the build. The expensive part of a docs change is usually
not the edit — it's *locating* the warning, a manual, token-heavy chain
(one RST→MyST conversion tier took three ~6-minute Read the Docs cycles
just to find the failure). These failures are a small, classifiable set
with mechanical, canonical fixes.

## What

Adds `sphinx-fix`, a deterministic, read-only Claude Code skill under
`doc/.claude/skills/` that turns a Sphinx warning stream into a
severity-ordered list of findings, each with its canonical fix:

- **`rules.yaml`** — the canonical category/signature → cause → fix
table (10 seed rules plus known-benign suppressions). It is the single
source the `rst-to-myst` skill now points at for the shared MyST link
classes.
- **`sphinx_fix.py`** — a stdlib-only engine (prefers PyYAML, falls back
to a bundled parser so it runs anywhere) that parses the warning stream
(a Read the Docs log, a local build, or pasted text), classifies each
warning, detects a hard-broken build first, triages by severity tier
(fatal → structural → plain), segregates suppressed classes, and lists
every unclassified warning so the table can grow from real misses. v0 is
human-in-the-loop: it proposes fixes and never edits files.
- **`SKILL.md`** — when and how to use it, the severity-tier iterate
loop, applying fixes, and the unclassified→follow-up feedback loop.
- **Tests** — eight fixtures plus golden files, run via `python
doc/.claude/skills/sphinx-fix/sphinx_fix.py --selftest` (which also
cross-checks the fallback parser against PyYAML).

The new files live under `doc/.claude/skills/` and do not participate in
the Sphinx build or doctest (those globs start at `doc/source/`).
Verified end-to-end against a real Read the Docs build log.

## Notes for reviewers

- **Stacked on #64135** (the `rst-to-myst` skill, which introduces
`doc/.claude/skills/`). This draft's diff includes that PR until it
merges; I'll rebase onto `master` for a clean diff and mark ready then.
- Kept as a draft until #64135 lands.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

---------

Signed-off-by: Douglas Strodtman <[email protected]>
Co-authored-by: Claude Opus 4.8 (1M context) <[email protected]>
Signed-off-by: elliot-barn <[email protected]>
400Ping pushed a commit to 400Ping/ray that referenced this pull request Aug 18, 2026
## Description

Add a user-invocable `rst-to-myst` skill under `doc/.claude/skills/`
that captures the playbook for converting Ray documentation pages from
reStructuredText to MyST Markdown.

MyST is the standard for new doc pages (a lint check rejects newly-added
`.rst`), and many `doc/source/` pages still need conversion. The
conversion has a handful of constructs that silently break the
`fail_on_warning` Sphinx build or drop doctest coverage if mishandled —
this skill encodes them so each conversion is consistent and safe.
Distilled from migrating the `ray-contribute/` developer guides.

Contents:

- **RST→MyST mapping table** for every construct.
- **Five build-breaking hard rules**: preserve label names exactly;
`.md`→`.rst` whole-doc links must use `` {doc}`…` ``; heading levels
follow RST's order-of-first-appearance (not the underline character);
the doctest literal-vs-executed split; and rewrite `doc/BUILD.bazel`
doctest exclude entries `.rst`→`.md` in the same PR.
- Construct-by-construct notes, a reference-update checklist (what
changes vs what's a no-op), reusable static-check snippets, build +
doctest verification, and the verified Ray-specific facts (`default_role
= "code"`, `linkify` off, `colon_fence` on, the doctest glob,
vale/prettier scope).

The skill is `user-invocable` and is discovered when working in `doc/`.

## Related issues

None.

## Additional information

Validated that the SKILL.md frontmatter parses and its fenced examples
are balanced. The skill lives outside `doc/source/`, so it isn't part of
the Sphinx build.

Signed-off-by: Douglas Strodtman <[email protected]>
Co-authored-by: Claude Opus 4.8 (1M context) <[email protected]>
Signed-off-by: 400Ping <[email protected]>
400Ping pushed a commit to 400Ping/ray that referenced this pull request Aug 18, 2026
…vement to MyST (ray-project#64136)

## Description

Convert the final three contributor-facing **Developer Guides** pages in
`doc/source/ray-contribute/` from reStructuredText to MyST Markdown,
completing the section's migration to MyST (the declared standard for
new pages). These are the hub/entry pages — the most coupled in the
section.

Pages converted:

- `getting-involved` — the contributor hub
- `development` — building Ray from source
- `involvement` — the community-links partial included by
`getting-involved`

**Faithful format conversion only — no content restructuring.** Notable
handling:

- **`development`** — the sphinx-design `.. tab-set::` / `.. tab-item::`
and two `.. dropdown::` blocks become colon-fence directives
(`::::{tab-set}` / `:::{tab-item}` / `:::{dropdown}`) so the nested code
fences compose cleanly. All 8 cross-reference labels are preserved
(`building-ray`, `fork-ray-repo`, `prepare-venv`, `python-develop`,
`python-develop-uninstall`, `build-distributable-wheel`,
`build-ray-image`, `full-source-build`) — referenced internally and from
`getting-involved`.
- **`getting-involved`** — its two `.. testcode::` blocks (the canonical
pydoc examples) become `{testcode}`; the page stays excluded from the
doctest rule, so its `doc/BUILD.bazel` exclude entry is updated `.rst` →
`.md`. The `.. include::` of `involvement` becomes `{include}
involvement.md`, and the shared `_includes/_latest_contribution_doc.rst`
banner stays an include via `{include}` with `:parser: rst`. The
`getting-involved` label is preserved.
- **`involvement`** — a content partial (no frontmatter); its
named-reference links are inlined, which also removes the duplicate `on
GitHub` target it shared with `getting-involved`.

Companion **`.claude/`** updates point at the new `.md` paths (root
`CLAUDE.md`, the `lint` and `rebuild` skills, the python-guidelines
rule). Toctree entries are extensionless and unchanged; `.html` redirect
targets are unaffected.

**One forced rendering change:** the lettered sub-list (a/b/c) under
"Fork the Ray repository" becomes a numbered sub-list (1/2/3), since
MyST/CommonMark has no alpha-enumerated lists.

## Related issues

None.

## Additional information

Verified locally: frontmatter parses; backtick and `:::` colon fences
balance (60/60 and 10/10); all 9 labels present;
`{testcode}`/`{toctree}`/`{include}`/`{tab-set}`/`{tab-item}`/`{dropdown}`
counts are exact; no residual RST outside fences; and the
blockquote-wrapped code, the Windows nested numbered list, and the
python-develop column-0 code-block list all render correctly via
markdown-it. The RtD preview build is the authoritative check for the
sphinx-design directives and cross-references.

Completes the `ray-contribute/` RST→MyST migration (Tier A ray-project#64100, Tier
B ray-project#64111, Tier C ray-project#64115, plus the `rst-to-myst` skill ray-project#64135).

**Cross-reference fixes** (flagged by the initial RtD build):
`docs.md`'s link to the renamed `getting-involved` is now extensionless,
and `getting-involved`'s two intra-page section links use MyST `#anchor`
fragments — the original `.html#anchor` form isn't resolved by MyST and
emits `myst.xref_missing`.

Signed-off-by: Douglas Strodtman <[email protected]>
Co-authored-by: Claude Opus 4.8 (1M context) <[email protected]>
Signed-off-by: 400Ping <[email protected]>
400Ping pushed a commit to 400Ping/ray that referenced this pull request Aug 18, 2026
…t#64147)

## Why

The Ray docs build with `fail_on_warning: true`, so any single Sphinx
warning fails the build. The expensive part of a docs change is usually
not the edit — it's *locating* the warning, a manual, token-heavy chain
(one RST→MyST conversion tier took three ~6-minute Read the Docs cycles
just to find the failure). These failures are a small, classifiable set
with mechanical, canonical fixes.

## What

Adds `sphinx-fix`, a deterministic, read-only Claude Code skill under
`doc/.claude/skills/` that turns a Sphinx warning stream into a
severity-ordered list of findings, each with its canonical fix:

- **`rules.yaml`** — the canonical category/signature → cause → fix
table (10 seed rules plus known-benign suppressions). It is the single
source the `rst-to-myst` skill now points at for the shared MyST link
classes.
- **`sphinx_fix.py`** — a stdlib-only engine (prefers PyYAML, falls back
to a bundled parser so it runs anywhere) that parses the warning stream
(a Read the Docs log, a local build, or pasted text), classifies each
warning, detects a hard-broken build first, triages by severity tier
(fatal → structural → plain), segregates suppressed classes, and lists
every unclassified warning so the table can grow from real misses. v0 is
human-in-the-loop: it proposes fixes and never edits files.
- **`SKILL.md`** — when and how to use it, the severity-tier iterate
loop, applying fixes, and the unclassified→follow-up feedback loop.
- **Tests** — eight fixtures plus golden files, run via `python
doc/.claude/skills/sphinx-fix/sphinx_fix.py --selftest` (which also
cross-checks the fallback parser against PyYAML).

The new files live under `doc/.claude/skills/` and do not participate in
the Sphinx build or doctest (those globs start at `doc/source/`).
Verified end-to-end against a real Read the Docs build log.

## Notes for reviewers

- **Stacked on ray-project#64135** (the `rst-to-myst` skill, which introduces
`doc/.claude/skills/`). This draft's diff includes that PR until it
merges; I'll rebase onto `master` for a clean diff and mark ready then.
- Kept as a draft until ray-project#64135 lands.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

---------

Signed-off-by: Douglas Strodtman <[email protected]>
Co-authored-by: Claude Opus 4.8 (1M context) <[email protected]>
Signed-off-by: 400Ping <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

core Issues that should be addressed in Ray Core docs An issue or change related to documentation go add ONLY when ready to merge, run all tests usability

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants