infra: api docs quick preview (#22093)

pull/21285/head
Bagatur 2 months ago committed by GitHub
parent fe26f937e4
commit 38783d07c9
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

@ -32,10 +32,16 @@ api_docs_build:
poetry run python docs/api_reference/create_api_rst.py
cd docs/api_reference && poetry run make html
api_docs_quick_preview:
poetry run python docs/api_reference/create_api_rst.py text-splitters
cd docs/api_reference && poetry run make html
open docs/api_reference/_build/html/text_splitters_api_reference.html
## api_docs_clean: Clean the API Reference documentation build artifacts.
api_docs_clean:
find ./docs/api_reference -name '*_api_reference.rst' -delete
cd docs/api_reference && poetry run make clean
git clean -fdX ./docs/api_reference
## api_docs_linkcheck: Run linkchecker on the API Reference documentation.
api_docs_linkcheck:

@ -71,6 +71,8 @@ make docs_clean
make api_docs_clean
```
Next, you can build the documentation as outlined below:
```bash
@ -78,6 +80,18 @@ make docs_build
make api_docs_build
```
:::tip
The `make api_docs_build` command takes a long time. If you're making cosmetic changes to the API docs and want to see how they look, use:
```bash
make api_docs_quick_preview
```
which will just build a small subset of the API reference.
:::
Finally, run the link checker to ensure all links are valid:
```bash

Loading…
Cancel
Save