mirror of
https://github.com/mii443/tokenizers.git
synced 2025-08-22 16:25:30 +00:00
Doc - Basic README + last CI updates
This commit is contained in:
2
.github/workflows/docs-check.yml
vendored
2
.github/workflows/docs-check.yml
vendored
@ -32,7 +32,7 @@ jobs:
|
||||
|
||||
- name: Build documentation
|
||||
working-directory: ./docs
|
||||
run: make clean && make html O="-W --keep-going"
|
||||
run: make clean && make html_all O="-W --keep-going"
|
||||
|
||||
- name: Upload built doc
|
||||
uses: actions/upload-artifact@v2
|
||||
|
4
.github/workflows/docs-deploy.yml
vendored
4
.github/workflows/docs-deploy.yml
vendored
@ -2,8 +2,8 @@ name: Deploy Documentation
|
||||
|
||||
on:
|
||||
push:
|
||||
# branches:
|
||||
# - master
|
||||
branches:
|
||||
- master
|
||||
|
||||
jobs:
|
||||
deploy:
|
||||
|
38
docs/README.md
Normal file
38
docs/README.md
Normal file
@ -0,0 +1,38 @@
|
||||
## Requirements
|
||||
|
||||
In order to generate the documentation, it is necessary to have a Python environment with the
|
||||
following:
|
||||
```python
|
||||
pip install sphinx sphinx_rtd_theme setuptools_rust
|
||||
```
|
||||
|
||||
It is also necessary to have the `tokenizers` library in this same environment, for Sphinx to
|
||||
generate all the API Reference and links properly. If you want to visualize the documentation with
|
||||
some modifications made to the Python bindings, make sure you build it from source.
|
||||
|
||||
## Building the documentation
|
||||
|
||||
Once everything is setup, you can build the documentation automatically for all the languages
|
||||
using the following command in the `/docs` folder:
|
||||
|
||||
```bash
|
||||
make html_all
|
||||
```
|
||||
|
||||
If you want to build only for a specific language, you can use:
|
||||
|
||||
```bash
|
||||
make html O="-t python"
|
||||
```
|
||||
|
||||
(Replacing `python` by the target language among `rust`, `node`, and `python`)
|
||||
|
||||
|
||||
**NOTE**
|
||||
|
||||
If you are making any structural change to the documentation, it is recommended to clean the build
|
||||
directory before rebuilding:
|
||||
|
||||
```bash
|
||||
make clean && make html_all
|
||||
```
|
Reference in New Issue
Block a user