## Example usage

This commit is contained in:
mrT23
2024-04-18 10:04:38 +03:00
parent 0f99db65a9
commit ea4d4ab618
10 changed files with 52 additions and 20 deletions

View File

@ -5,14 +5,24 @@ It can be invoked manually by commenting on any PR:
```
/add_docs
```
For example:
## Example usage
Invoke the tool manually by commenting `/add_docs` on any PR:
![Docs command](https://codium.ai/images/pr_agent/docs_command.png){width=768}
The tool will generate documentation for all the components that changed in the PR:
![Docs component](https://codium.ai/images/pr_agent/docs_components.png){width=768}
![Docs single component](https://codium.ai/images/pr_agent/docs_single_component.png){width=768}
You can state a name of a specific component in the PR to get documentation only for that component:
```
/add_docs component_name
```
## Configuration options
- `docs_style`: The exact style of the documentation (for python docstring). you can choose between: `google`, `numpy`, `sphinx`, `restructuredtext`, `plain`. Default is `sphinx`.
- `extra_instructions`: Optional extra instructions to the tool. For example: "focus on the changes in the file X. Ignore change in ...".
@ -20,5 +30,4 @@ For example:
**Notes**
- Language that are currently fully supported: Python, Java, C++, JavaScript, TypeScript, C#.
- For languages that are not fully supported, the tool will suggest documentation only for new components in the PR.
- A previous version of the tool, that offered support only for new components, was deprecated.
- This tool can also be triggered interactively by using the [`analyze`](./analyze.md) tool.