Skip to content

[doc] Add a documentation CI steps overview to the PR CI guide - #64842

Closed
dstrodtman wants to merge 2 commits into
ray-project:masterfrom
dstrodtman:doc-1333-ci-pipeline-overview
Closed

dstrodtman wants to merge 2 commits into
ray-project:masterfrom
dstrodtman:doc-1333-ci-pipeline-overview

Conversation

@dstrodtman

Copy link
Copy Markdown
Contributor

Summary

Adds a "Documentation CI steps" section to the PR CI guide describing what runs when a PR changes docs:

  • The three build surfaces that share one Sphinx configuration: the make -C doc/ html Sphinx build, the Read the Docs render gate, and the Buildkite doc steps.
  • The Buildkite doc steps themselves: the API annotation and consistency checks, the per-team doc tests, and the always-on lints.
  • Which steps run post-merge rather than on your PR (doc: build and linkcheck).

Descriptive overview only; it links to the existing "How to write code snippets" and "Contributing to the Ray documentation" pages rather than duplicating them.

Stacked on #64450

This branch is built on top of #64450 (Add a guide for running the API consistency check locally), and the new overview links to that section. GitHub shows both commits here; the net-new change in this PR is the top commit ([doc] Add a documentation CI steps overview to the PR CI guide). Merge #64450 first; this then rebases onto master cleanly and the diff reduces to the single commit.

Why this isn't a duplicate

Checked open PRs with gh pr list --repo ray-project/ray --state open. Only #64450 (the branch this stacks on) touches doc/source/ray-contribute/ci.md.

Testing

Prose-only addition to an existing MyST page. Verified the two cross-file links (writing-code-snippets.md, docs.md) and the intra-page anchor to the API-consistency section resolve. The Read the Docs render gate exercises this page in CI.

AI assistance

Drafted with AI assistance (Claude Code) and reviewed by the submitter.

dstrodtman and others added 2 commits July 16, 2026 15:16
The API doc consistency check (the api_policy_check step / cmd_check_api_discrepancy.py)
imports the live @publicapi surface, so it needs an environment where Ray installs and
imports for real -- the opposite of the docs build environment, which deliberately
excludes Ray. No contributor doc covered how to run it, so add a section to ci.md: the
faithful path (the docbuild image), a lightweight local approximation (a uv venv + a
nightly wheel + setup-dev.py to link the local checkout), and the version-skew caveat.

The check mocks any absent optional backend from doc/source/api_mock_imports.py, so the
guide points readers there instead of hardcoding a dependency list, and describes the
docbuild image as it is built today (prebuilt ray-core and oss-ci-base_build base images
plus the docs dependency lock).

Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
Signed-off-by: Douglas Strodtman <[email protected]>
Describes what runs when a PR changes docs: the three build surfaces
that share one Sphinx config (the make html build, the Read the Docs
render gate, and the Buildkite doc steps), the per-team doc tests and
always-on lints, and which steps run post-merge rather than premerge.

Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
Signed-off-by: Douglas Strodtman <[email protected]>

@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 adds documentation explaining the Documentation CI steps and provides instructions on how to run the API consistency check locally. The reviewer identified an incorrect file path for the setup-dev.py script in the provided bash commands and suggested clarifying the mapping between the libraries mentioned in the doc tests and the team arguments accepted by the API consistency check script.

uv pip install --python ~/.virtualenvs/ray-apiref/bin/python \
"https://s3-us-west-2.amazonaws.com/ray-wheels/latest/ray-3.0.0.dev0-cp311-cp311-macosx_11_0_arm64.whl"
# Link your checkout's Python files over the wheel so the check walks your local @PublicAPI changes, not the wheel's:
~/.virtualenvs/ray-apiref/bin/python python/ray/setup-dev.py --yes

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 setup-dev.py script is located in the python/ directory, not python/ray/. Running python/ray/setup-dev.py will result in a "No such file or directory" error.

Suggested change
~/.virtualenvs/ray-apiref/bin/python python/ray/setup-dev.py --yes
~/.virtualenvs/ray-apiref/bin/python python/setup-dev.py --yes

ci/ray_ci/doc/cmd_check_api_discrepancy.py "$(pwd)" serve
```

Pass a single team (`core`, `data`, `serve`, `train`, `tune`, `rllib`) or omit the argument to check all of them.

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 list of teams accepted by the script (core, data, serve, train, tune, rllib) differs from the list of libraries mentioned in the Per-team doc tests section (core, data, ml, rllib, serve, llm). Specifically, ml maps to train and tune for the API consistency check, and llm is checked under data or serve. It would be helpful to add a brief note clarifying this mapping so users know which team argument to pass when testing ml or llm changes.

@github-actions

github-actions Bot commented Aug 1, 2026

Copy link
Copy Markdown

This pull request has been automatically marked as stale because it has not had
any activity for 14 days. It will be closed in another 14 days if no further activity occurs.
Thank you for your contributions.

You can always ask for help on our discussion forum or Ray's public slack channel.

If you'd like to keep this open, just leave any comment, and the stale label will be removed.

@github-actions github-actions Bot added the stale The issue is stale. It will be closed within 7 days unless there are further conversation label Aug 1, 2026
@dstrodtman dstrodtman added unstale A PR that has been marked unstale. It will not get marked stale again if this label is on it. and removed stale The issue is stale. It will be closed within 7 days unless there are further conversation labels Aug 3, 2026
@dstrodtman

Copy link
Copy Markdown
Contributor Author

Superseded by #65285.

This PR was written before #64775 landed, and its overview describes the pre-rework routing model: a single doc tag selecting the per-team doc test steps, and steps named <team>: doc tests. Neither is accurate on current master, where per-library <lib>_doc tags route executable doc assets by path and the steps are named <library>: docs example tests.

#65285 rewrites the overview against current master and carries over the section this PR shared with #64450. Closing in favor of that one.

dstrodtman added a commit to dstrodtman/ray that referenced this pull request Aug 7, 2026
…teps

The API consistency check takes six team names (core, data, serve,
train, tune, rllib) while the docs example test steps are named after
five libraries (core, data, ml, rllib, serve). Two don't translate
directly: ml covers train and tune, and there is no llm team because
ray.data.llm is walked under data and ray.serve.llm under serve.

Addresses review feedback left on ray-project#64842, which this branch supersedes.

Signed-off-by: Douglas Strodtman <[email protected]>
@dstrodtman

Copy link
Copy Markdown
Contributor Author

Closing in favor of #65285, which now carries this PR's scope in full.

For the record, both review comments left here were resolved rather than dropped:

@dstrodtman dstrodtman closed this Aug 7, 2026
dstrodtman added a commit that referenced this pull request Aug 7, 2026
…cipe (#65285)

## Why this change

`doc/source/ray-contribute/ci.md` explains what CI runs on a PR, but
stops at `microcheck` and the `go` label. It says nothing about what
runs when the PR changes documentation, which is the case the page's
likely reader is in.

This adds that, and folds in a recipe for reproducing the API
consistency check locally.

### What's new

**"Documentation CI checks"** covers, in the order a contributor meets
them:

- The Read the Docs render gate, including that `fail_on_warning: true`
makes any Sphinx warning a build failure, and when the preview build
skips.
- The two API surface checks, and the `doc_api` tag that lets an API
reference page edit reach them even though it's a documentation change.
- The per-library `<library>: docs example tests` steps, with a table
mapping path to step to tag, plus the Ray Core fallback and the Ray LLM
exception.
- That a prose-only or image-only change runs no library test steps at
all.
- The `docs-go` label and the `lint: validate docs-go scope` guard that
bounds it.
- The two post-merge-only steps, `doc: build` and `doc: linkcheck`.

**"Running the API consistency check locally"** documents the three
phases of `api_policy_check`, what the `docbuild` image does and doesn't
install (the deep-learning backends are mocked even in CI), and a `uv`
recipe that gets close enough for iteration.

It also updates one example commit message under the `microcheck`
section that named the old `serve doc tests` step label.

**`doc/.claude/CLAUDE.md`** carried the same staleness, so it's fixed in
the same PR. It still said the `doc` tag "covers content under `doc/`",
which stopped being true when #64775 landed. It now describes the
three-way split (`doc` for build and validation infra, `<lib>_doc` for
executable doc assets, `doc_api` for the API reference surface), records
that prose and images trigger nothing, and documents the `docs-go` label
and its scope guard. Two smaller drifts are corrected alongside: the
docs deplock rule emits `doc_api` now too, and the "tag it `doc`" advice
pointed at a tag that no longer selects content steps.

This file is an agent instruction file rather than published
documentation, so it's worth saying why it rides along here instead of
going out separately. `AGENTS.md` requires a dedicated PR for changes to
itself, which this isn't. `doc/.claude/` is on the skip rule in
`test.rules.txt` and excluded from the Read the Docs build guard, so
including it changes this PR's trigger set by nothing. And it's the same
factual correction as the page, from the same source reading — splitting
them would mean verifying the same CI configuration twice and risking
the two descriptions drifting apart again.

## Not a duplicate

This supersedes two of my own open PRs and replaces both:

- #64842 added a documentation CI overview. It was written before #64775
landed and describes the pre-rework model, where a single `doc` tag
selected the per-team doc test steps. That's no longer how routing
works, so landing it as-is would have documented the wrong thing.
- #64450 added the local API-check section. Its content is carried over
here essentially unchanged.

Both branched from the same pre-#64775 commit and added an identically
titled section, so they also conflicted with each other. Combining them
is cheaper to review than rebasing two PRs that overlap.

I'm not aware of another open PR touching this page. Checked with `gh pr
list --repo ray-project/ray --state open --search "ray-contribute
ci.md"`.

## Verification

Every factual claim was checked against `master` at `695a8814ea` rather
than carried over from the superseded PRs:

- Step labels, tags, and `if:` guards read from
`.buildkite/doc.rayci.yml`, `core.rayci.yml`, `data.rayci.yml`,
`ml.rayci.yml`, `rllib.rayci.yml`, `serve.rayci.yml`, and
`lint.rayci.yml`.
- Path-to-tag routing read from `.buildkite/test.rules.txt`.
- The render gate behavior read from `.readthedocs.yaml`
(`fail_on_warning: true`, the `post_checkout` skip guard) and
`doc/Makefile`.
- The mocked-backend claim checked against
`ci/docker/doc.build.Dockerfile`, which stages the `ray-core` and
`ray-dashboard` artifacts and installs only the docs lock, and
`doc/source/api_mock_imports.py`, which lists `torch`, `transformers`,
and `tensorflow`. This corrects #64842, which claimed the base images
supply those libraries for real.
- `doc: build`'s upload behavior read from `ci/ray_ci/doc/cmd_build.py`
(postmerge, `master` only).
- The `docs/readthedocs.com:anyscale-ray` check name confirmed from the
status checks on an open PR.

Commands run:

```
vale --config=.vale.ini doc/source/ray-contribute/ci.md
python doc/test_no_new_rst.py
pre-commit run --files doc/source/ray-contribute/ci.md
```

`test_no_new_rst.py` passes. `pre-commit` reports no applicable hooks
for a Markdown file under `doc/source/`. Vale surfaces no new findings
in the added text beyond spelling hits on project vocabulary
(`Buildkite`, `premerge`, `docbuild`, `autodoc`, `autosummary`,
`toctree`); note that CI's `documentation_style` lint scopes Vale to
`doc/source/data` and `doc/source/ray-overview/examples`, so this page
isn't in its path set.

The same source reading backs the `doc/.claude/CLAUDE.md` edit; it
asserts nothing the page doesn't.

Rendering verified by parsing the page with `myst-parser` using the
repo's `myst_heading_anchors = 4`: the table, the `{warning}` directive,
and the heading hierarchy all parse, with no skipped heading levels.
Both cross-references (`writing-code-snippets.md`,
`docs.md#building-the-ray-documentation`) point at existing `.md`
sources and an existing heading. The Read the Docs preview on this PR is
the real render check.

## AI assistance

AI assistance (Claude Code) was used to draft this change and to
cross-check the claims against the CI configuration. I've reviewed every
line.

---------

Signed-off-by: Douglas Strodtman <[email protected]>
Artimislyy pushed a commit to Artimislyy/ray that referenced this pull request Aug 11, 2026
…cipe (ray-project#65285)

## Why this change

`doc/source/ray-contribute/ci.md` explains what CI runs on a PR, but
stops at `microcheck` and the `go` label. It says nothing about what
runs when the PR changes documentation, which is the case the page's
likely reader is in.

This adds that, and folds in a recipe for reproducing the API
consistency check locally.

### What's new

**"Documentation CI checks"** covers, in the order a contributor meets
them:

- The Read the Docs render gate, including that `fail_on_warning: true`
makes any Sphinx warning a build failure, and when the preview build
skips.
- The two API surface checks, and the `doc_api` tag that lets an API
reference page edit reach them even though it's a documentation change.
- The per-library `<library>: docs example tests` steps, with a table
mapping path to step to tag, plus the Ray Core fallback and the Ray LLM
exception.
- That a prose-only or image-only change runs no library test steps at
all.
- The `docs-go` label and the `lint: validate docs-go scope` guard that
bounds it.
- The two post-merge-only steps, `doc: build` and `doc: linkcheck`.

**"Running the API consistency check locally"** documents the three
phases of `api_policy_check`, what the `docbuild` image does and doesn't
install (the deep-learning backends are mocked even in CI), and a `uv`
recipe that gets close enough for iteration.

It also updates one example commit message under the `microcheck`
section that named the old `serve doc tests` step label.

**`doc/.claude/CLAUDE.md`** carried the same staleness, so it's fixed in
the same PR. It still said the `doc` tag "covers content under `doc/`",
which stopped being true when ray-project#64775 landed. It now describes the
three-way split (`doc` for build and validation infra, `<lib>_doc` for
executable doc assets, `doc_api` for the API reference surface), records
that prose and images trigger nothing, and documents the `docs-go` label
and its scope guard. Two smaller drifts are corrected alongside: the
docs deplock rule emits `doc_api` now too, and the "tag it `doc`" advice
pointed at a tag that no longer selects content steps.

This file is an agent instruction file rather than published
documentation, so it's worth saying why it rides along here instead of
going out separately. `AGENTS.md` requires a dedicated PR for changes to
itself, which this isn't. `doc/.claude/` is on the skip rule in
`test.rules.txt` and excluded from the Read the Docs build guard, so
including it changes this PR's trigger set by nothing. And it's the same
factual correction as the page, from the same source reading — splitting
them would mean verifying the same CI configuration twice and risking
the two descriptions drifting apart again.

## Not a duplicate

This supersedes two of my own open PRs and replaces both:

- ray-project#64842 added a documentation CI overview. It was written before ray-project#64775
landed and describes the pre-rework model, where a single `doc` tag
selected the per-team doc test steps. That's no longer how routing
works, so landing it as-is would have documented the wrong thing.
- ray-project#64450 added the local API-check section. Its content is carried over
here essentially unchanged.

Both branched from the same pre-ray-project#64775 commit and added an identically
titled section, so they also conflicted with each other. Combining them
is cheaper to review than rebasing two PRs that overlap.

I'm not aware of another open PR touching this page. Checked with `gh pr
list --repo ray-project/ray --state open --search "ray-contribute
ci.md"`.

## Verification

Every factual claim was checked against `master` at `695a8814ea` rather
than carried over from the superseded PRs:

- Step labels, tags, and `if:` guards read from
`.buildkite/doc.rayci.yml`, `core.rayci.yml`, `data.rayci.yml`,
`ml.rayci.yml`, `rllib.rayci.yml`, `serve.rayci.yml`, and
`lint.rayci.yml`.
- Path-to-tag routing read from `.buildkite/test.rules.txt`.
- The render gate behavior read from `.readthedocs.yaml`
(`fail_on_warning: true`, the `post_checkout` skip guard) and
`doc/Makefile`.
- The mocked-backend claim checked against
`ci/docker/doc.build.Dockerfile`, which stages the `ray-core` and
`ray-dashboard` artifacts and installs only the docs lock, and
`doc/source/api_mock_imports.py`, which lists `torch`, `transformers`,
and `tensorflow`. This corrects ray-project#64842, which claimed the base images
supply those libraries for real.
- `doc: build`'s upload behavior read from `ci/ray_ci/doc/cmd_build.py`
(postmerge, `master` only).
- The `docs/readthedocs.com:anyscale-ray` check name confirmed from the
status checks on an open PR.

Commands run:

```
vale --config=.vale.ini doc/source/ray-contribute/ci.md
python doc/test_no_new_rst.py
pre-commit run --files doc/source/ray-contribute/ci.md
```

`test_no_new_rst.py` passes. `pre-commit` reports no applicable hooks
for a Markdown file under `doc/source/`. Vale surfaces no new findings
in the added text beyond spelling hits on project vocabulary
(`Buildkite`, `premerge`, `docbuild`, `autodoc`, `autosummary`,
`toctree`); note that CI's `documentation_style` lint scopes Vale to
`doc/source/data` and `doc/source/ray-overview/examples`, so this page
isn't in its path set.

The same source reading backs the `doc/.claude/CLAUDE.md` edit; it
asserts nothing the page doesn't.

Rendering verified by parsing the page with `myst-parser` using the
repo's `myst_heading_anchors = 4`: the table, the `{warning}` directive,
and the heading hierarchy all parse, with no skipped heading levels.
Both cross-references (`writing-code-snippets.md`,
`docs.md#building-the-ray-documentation`) point at existing `.md`
sources and an existing heading. The Read the Docs preview on this PR is
the real render check.

## AI assistance

AI assistance (Claude Code) was used to draft this change and to
cross-check the claims against the CI configuration. I've reviewed every
line.

---------

Signed-off-by: Douglas Strodtman <[email protected]>
400Ping pushed a commit to 400Ping/ray that referenced this pull request Aug 18, 2026
…cipe (ray-project#65285)

## Why this change

`doc/source/ray-contribute/ci.md` explains what CI runs on a PR, but
stops at `microcheck` and the `go` label. It says nothing about what
runs when the PR changes documentation, which is the case the page's
likely reader is in.

This adds that, and folds in a recipe for reproducing the API
consistency check locally.

### What's new

**"Documentation CI checks"** covers, in the order a contributor meets
them:

- The Read the Docs render gate, including that `fail_on_warning: true`
makes any Sphinx warning a build failure, and when the preview build
skips.
- The two API surface checks, and the `doc_api` tag that lets an API
reference page edit reach them even though it's a documentation change.
- The per-library `<library>: docs example tests` steps, with a table
mapping path to step to tag, plus the Ray Core fallback and the Ray LLM
exception.
- That a prose-only or image-only change runs no library test steps at
all.
- The `docs-go` label and the `lint: validate docs-go scope` guard that
bounds it.
- The two post-merge-only steps, `doc: build` and `doc: linkcheck`.

**"Running the API consistency check locally"** documents the three
phases of `api_policy_check`, what the `docbuild` image does and doesn't
install (the deep-learning backends are mocked even in CI), and a `uv`
recipe that gets close enough for iteration.

It also updates one example commit message under the `microcheck`
section that named the old `serve doc tests` step label.

**`doc/.claude/CLAUDE.md`** carried the same staleness, so it's fixed in
the same PR. It still said the `doc` tag "covers content under `doc/`",
which stopped being true when ray-project#64775 landed. It now describes the
three-way split (`doc` for build and validation infra, `<lib>_doc` for
executable doc assets, `doc_api` for the API reference surface), records
that prose and images trigger nothing, and documents the `docs-go` label
and its scope guard. Two smaller drifts are corrected alongside: the
docs deplock rule emits `doc_api` now too, and the "tag it `doc`" advice
pointed at a tag that no longer selects content steps.

This file is an agent instruction file rather than published
documentation, so it's worth saying why it rides along here instead of
going out separately. `AGENTS.md` requires a dedicated PR for changes to
itself, which this isn't. `doc/.claude/` is on the skip rule in
`test.rules.txt` and excluded from the Read the Docs build guard, so
including it changes this PR's trigger set by nothing. And it's the same
factual correction as the page, from the same source reading — splitting
them would mean verifying the same CI configuration twice and risking
the two descriptions drifting apart again.

## Not a duplicate

This supersedes two of my own open PRs and replaces both:

- ray-project#64842 added a documentation CI overview. It was written before ray-project#64775
landed and describes the pre-rework model, where a single `doc` tag
selected the per-team doc test steps. That's no longer how routing
works, so landing it as-is would have documented the wrong thing.
- ray-project#64450 added the local API-check section. Its content is carried over
here essentially unchanged.

Both branched from the same pre-ray-project#64775 commit and added an identically
titled section, so they also conflicted with each other. Combining them
is cheaper to review than rebasing two PRs that overlap.

I'm not aware of another open PR touching this page. Checked with `gh pr
list --repo ray-project/ray --state open --search "ray-contribute
ci.md"`.

## Verification

Every factual claim was checked against `master` at `695a8814ea` rather
than carried over from the superseded PRs:

- Step labels, tags, and `if:` guards read from
`.buildkite/doc.rayci.yml`, `core.rayci.yml`, `data.rayci.yml`,
`ml.rayci.yml`, `rllib.rayci.yml`, `serve.rayci.yml`, and
`lint.rayci.yml`.
- Path-to-tag routing read from `.buildkite/test.rules.txt`.
- The render gate behavior read from `.readthedocs.yaml`
(`fail_on_warning: true`, the `post_checkout` skip guard) and
`doc/Makefile`.
- The mocked-backend claim checked against
`ci/docker/doc.build.Dockerfile`, which stages the `ray-core` and
`ray-dashboard` artifacts and installs only the docs lock, and
`doc/source/api_mock_imports.py`, which lists `torch`, `transformers`,
and `tensorflow`. This corrects ray-project#64842, which claimed the base images
supply those libraries for real.
- `doc: build`'s upload behavior read from `ci/ray_ci/doc/cmd_build.py`
(postmerge, `master` only).
- The `docs/readthedocs.com:anyscale-ray` check name confirmed from the
status checks on an open PR.

Commands run:

```
vale --config=.vale.ini doc/source/ray-contribute/ci.md
python doc/test_no_new_rst.py
pre-commit run --files doc/source/ray-contribute/ci.md
```

`test_no_new_rst.py` passes. `pre-commit` reports no applicable hooks
for a Markdown file under `doc/source/`. Vale surfaces no new findings
in the added text beyond spelling hits on project vocabulary
(`Buildkite`, `premerge`, `docbuild`, `autodoc`, `autosummary`,
`toctree`); note that CI's `documentation_style` lint scopes Vale to
`doc/source/data` and `doc/source/ray-overview/examples`, so this page
isn't in its path set.

The same source reading backs the `doc/.claude/CLAUDE.md` edit; it
asserts nothing the page doesn't.

Rendering verified by parsing the page with `myst-parser` using the
repo's `myst_heading_anchors = 4`: the table, the `{warning}` directive,
and the heading hierarchy all parse, with no skipped heading levels.
Both cross-references (`writing-code-snippets.md`,
`docs.md#building-the-ray-documentation`) point at existing `.md`
sources and an existing heading. The Read the Docs preview on this PR is
the real render check.

## AI assistance

AI assistance (Claude Code) was used to draft this change and to
cross-check the claims against the CI configuration. I've reviewed every
line.

---------

Signed-off-by: Douglas Strodtman <[email protected]>
Signed-off-by: 400Ping <[email protected]>
nadongjun pushed a commit to nadongjun/ray that referenced this pull request Oct 6, 2026
…cipe (ray-project#65285)

## Why this change

`doc/source/ray-contribute/ci.md` explains what CI runs on a PR, but
stops at `microcheck` and the `go` label. It says nothing about what
runs when the PR changes documentation, which is the case the page's
likely reader is in.

This adds that, and folds in a recipe for reproducing the API
consistency check locally.

### What's new

**"Documentation CI checks"** covers, in the order a contributor meets
them:

- The Read the Docs render gate, including that `fail_on_warning: true`
makes any Sphinx warning a build failure, and when the preview build
skips.
- The two API surface checks, and the `doc_api` tag that lets an API
reference page edit reach them even though it's a documentation change.
- The per-library `<library>: docs example tests` steps, with a table
mapping path to step to tag, plus the Ray Core fallback and the Ray LLM
exception.
- That a prose-only or image-only change runs no library test steps at
all.
- The `docs-go` label and the `lint: validate docs-go scope` guard that
bounds it.
- The two post-merge-only steps, `doc: build` and `doc: linkcheck`.

**"Running the API consistency check locally"** documents the three
phases of `api_policy_check`, what the `docbuild` image does and doesn't
install (the deep-learning backends are mocked even in CI), and a `uv`
recipe that gets close enough for iteration.

It also updates one example commit message under the `microcheck`
section that named the old `serve doc tests` step label.

**`doc/.claude/CLAUDE.md`** carried the same staleness, so it's fixed in
the same PR. It still said the `doc` tag "covers content under `doc/`",
which stopped being true when ray-project#64775 landed. It now describes the
three-way split (`doc` for build and validation infra, `<lib>_doc` for
executable doc assets, `doc_api` for the API reference surface), records
that prose and images trigger nothing, and documents the `docs-go` label
and its scope guard. Two smaller drifts are corrected alongside: the
docs deplock rule emits `doc_api` now too, and the "tag it `doc`" advice
pointed at a tag that no longer selects content steps.

This file is an agent instruction file rather than published
documentation, so it's worth saying why it rides along here instead of
going out separately. `AGENTS.md` requires a dedicated PR for changes to
itself, which this isn't. `doc/.claude/` is on the skip rule in
`test.rules.txt` and excluded from the Read the Docs build guard, so
including it changes this PR's trigger set by nothing. And it's the same
factual correction as the page, from the same source reading — splitting
them would mean verifying the same CI configuration twice and risking
the two descriptions drifting apart again.

## Not a duplicate

This supersedes two of my own open PRs and replaces both:

- ray-project#64842 added a documentation CI overview. It was written before ray-project#64775
landed and describes the pre-rework model, where a single `doc` tag
selected the per-team doc test steps. That's no longer how routing
works, so landing it as-is would have documented the wrong thing.
- ray-project#64450 added the local API-check section. Its content is carried over
here essentially unchanged.

Both branched from the same pre-ray-project#64775 commit and added an identically
titled section, so they also conflicted with each other. Combining them
is cheaper to review than rebasing two PRs that overlap.

I'm not aware of another open PR touching this page. Checked with `gh pr
list --repo ray-project/ray --state open --search "ray-contribute
ci.md"`.

## Verification

Every factual claim was checked against `master` at `695a8814ea` rather
than carried over from the superseded PRs:

- Step labels, tags, and `if:` guards read from
`.buildkite/doc.rayci.yml`, `core.rayci.yml`, `data.rayci.yml`,
`ml.rayci.yml`, `rllib.rayci.yml`, `serve.rayci.yml`, and
`lint.rayci.yml`.
- Path-to-tag routing read from `.buildkite/test.rules.txt`.
- The render gate behavior read from `.readthedocs.yaml`
(`fail_on_warning: true`, the `post_checkout` skip guard) and
`doc/Makefile`.
- The mocked-backend claim checked against
`ci/docker/doc.build.Dockerfile`, which stages the `ray-core` and
`ray-dashboard` artifacts and installs only the docs lock, and
`doc/source/api_mock_imports.py`, which lists `torch`, `transformers`,
and `tensorflow`. This corrects ray-project#64842, which claimed the base images
supply those libraries for real.
- `doc: build`'s upload behavior read from `ci/ray_ci/doc/cmd_build.py`
(postmerge, `master` only).
- The `docs/readthedocs.com:anyscale-ray` check name confirmed from the
status checks on an open PR.

Commands run:

```
vale --config=.vale.ini doc/source/ray-contribute/ci.md
python doc/test_no_new_rst.py
pre-commit run --files doc/source/ray-contribute/ci.md
```

`test_no_new_rst.py` passes. `pre-commit` reports no applicable hooks
for a Markdown file under `doc/source/`. Vale surfaces no new findings
in the added text beyond spelling hits on project vocabulary
(`Buildkite`, `premerge`, `docbuild`, `autodoc`, `autosummary`,
`toctree`); note that CI's `documentation_style` lint scopes Vale to
`doc/source/data` and `doc/source/ray-overview/examples`, so this page
isn't in its path set.

The same source reading backs the `doc/.claude/CLAUDE.md` edit; it
asserts nothing the page doesn't.

Rendering verified by parsing the page with `myst-parser` using the
repo's `myst_heading_anchors = 4`: the table, the `{warning}` directive,
and the heading hierarchy all parse, with no skipped heading levels.
Both cross-references (`writing-code-snippets.md`,
`docs.md#building-the-ray-documentation`) point at existing `.md`
sources and an existing heading. The Read the Docs preview on this PR is
the real render check.

## AI assistance

AI assistance (Claude Code) was used to draft this change and to
cross-check the claims against the CI configuration. I've reviewed every
line.

---------

Signed-off-by: Douglas Strodtman <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

unstale A PR that has been marked unstale. It will not get marked stale again if this label is on it.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant