Skip to content

Commit

Permalink
[Serve][Doc] Refactor the Ray Serve API doc (ray-project#32307)
Browse files Browse the repository at this point in the history
- Add an index page to list all the APIs. (https://ray--32307.org.readthedocs.build/en/32307/serve/api/index.html)
- With this change, when you search specific python API e.g`ray.serve.run`. The search result will show core api link page. (Previously, the user can't get the correct search result, because we put all APIs on one page.)
<img width="604" alt="image" src="https://user-images.githubusercontent.com/6515354/217628692-720b9344-061d-44de-bc77-ee0c0ef27276.png">

Signed-off-by: Edward Oakes <[email protected]>
  • Loading branch information
sihanwang41 authored and edoakes committed Mar 22, 2023
1 parent 1d2787d commit da5259b
Show file tree
Hide file tree
Showing 7 changed files with 63 additions and 73 deletions.
2 changes: 1 addition & 1 deletion doc/source/_toc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -315,7 +315,7 @@ parts:
- file: serve/tutorials/deployment-graph-patterns/linear_pipeline
- file: serve/tutorials/deployment-graph-patterns/branching_input
- file: serve/tutorials/deployment-graph-patterns/conditional
- file: serve/package-ref
- file: serve/api/index

- file: rllib/index
title: Ray RLlib
Expand Down
2 changes: 1 addition & 1 deletion doc/source/ray-references/api.rst
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ API References
../data/api/api.rst
../train/api.rst
../tune/api_docs/overview.rst
../serve/package-ref.rst
../serve/api/index.rst
../rllib/package_ref/index.rst
../workflows/api/api.rst
../cluster/package-overview.rst
Expand Down
12 changes: 12 additions & 0 deletions doc/source/serve/api/index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
(serve-api)=
# Ray Serve API

```{toctree}
:maxdepth: '-1'
python_api
rest_api
serve_cli
```


49 changes: 49 additions & 0 deletions doc/source/serve/api/python_api.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
# Ray Serve Python API

(core-apis)=

```{eval-rst}
.. currentmodule:: ray
```

## Core APIs

```{eval-rst}
.. autosummary::
:toctree: doc/
serve.run
serve.start
serve.shutdown
serve.delete
```

(servehandle-api)=
## ServeHandle API

```{eval-rst}
.. autosummary::
:toctree: doc/
serve.handle.RayServeHandle
serve.handle.RayServeHandle.remote
serve.handle.RayServeHandle.options
```

## Batching Requests

```{eval-rst}
.. autosummary::
:toctree: doc/
serve.batch
```

## Deployment Graph APIs

```{eval-rst}
.. autosummary::
:toctree: doc/
serve.api.build
```
File renamed without changes.
File renamed without changes.
71 changes: 0 additions & 71 deletions doc/source/serve/package-ref.md

This file was deleted.

0 comments on commit da5259b

Please sign in to comment.