You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: pydoc/README.md
+4-28Lines changed: 4 additions & 28 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -4,36 +4,12 @@ You can find Haystack's documentation at https://docs.haystack.deepset.ai/.
4
4
5
5
# API Reference
6
6
7
-
We use Pydoc-Markdown to create Markdown files from the docstrings in our code. There is a Github Action that regenerates the API pages when tags are pushed or when manually triggered.
7
+
We use [haystack-pydoc-tools](https://github.com/deepset-ai/haystack-pydoc-tools) to create Markdown files from the docstrings in our code. There is a [Github workflow](https://github.com/deepset-ai/haystack-experimental/blob/main/.github/workflows/docusaurus_sync.yml) that regenerates the API reference at release time.
8
8
9
-
If you want to generate a new Markdown file for a new Haystack module, create a `.yml` file in `pydoc` which configures how Pydoc-Markdown will generate the page and commit it to main.
9
+
If you want to generate a new Markdown file for a new Haystack module, create a `.yml` file in `pydoc` which configures how haystack-pydoc-tools will generate the page and commit it to main.
10
10
11
-
All the updates to docstrings get pushed to documentation when a new version is released.
11
+
All the updates to API reference get pushed to documentation when a new version is released.
12
12
13
13
### Configuration
14
14
15
-
Pydoc will read the configuration from a `.yml` file which is located under `pydoc`. Our files contain three main sections:
16
-
17
-
-**loaders**: A list of plugins that load API objects from python source files.
18
-
-**type**: Loader for python source files (we use `haystack_pydoc_tools.loaders.CustomPythonLoader`)
19
-
-**search_path**: Location of source files (relative to the config file)
20
-
-**modules**: Modules which are used for generating the markdown file
21
-
-**ignore_when_discovered**: Define which files should be ignored
22
-
-**processors**: A list of plugins that process API objects to modify their docstrings (e.g. to adapt them from a documentation format to Markdown or to remove items that should not be rendered into the documentation).
23
-
-**type: filter**: Filter for specific modules
24
-
-**documented_only**: Only documented API objects
25
-
-**do_not_filter_modules**: Do not filter module objects
26
-
-**skip_empty_modules**: Skip modules without content
27
-
-**type: smart**: Smart processor for docstring processing
28
-
-**type: crossref**: Cross-reference processor
29
-
-**renderer**: A plugin that produces the output files. We use a custom DocusaurusRenderer based on the Markdown renderer. It makes sure the Markdown files comply with Docusaurus requirements.
30
-
-**type**: Define the renderer which you want to use. We are using the DocusaurusRenderer to make sure the files display properly in Docusaurus.
31
-
-**description**: Add a short description of the page. It shows up right below the page title.
32
-
-**id**: This is the Docusaurus page ID to make sure the doc lands in the right section of Haystack docs.
33
-
-**title**: The title of the doc as it will appear on the website. Make sure you always add "API" at the end.
34
-
-**markdown**:
35
-
-**descriptive_class_title**: Remove the word "Object" from class titles.
36
-
-**descriptive_module_title**: Adding the word "Module" before the module name.
37
-
-**add_method_class_prefix**: Add the class name as a prefix to method names.
38
-
-**add_member_class_prefix**: Add the class name as a prefix to member names.
39
-
-**filename**: File name of the generated file, use underscores to separate each word.
15
+
For configuration details, see the [haystack-pydoc-tools documentation](https://github.com/deepset-ai/haystack-pydoc-tools/blob/main/README.md#configuration) or inspect the existing `.yml` files in `pydoc`.
0 commit comments