Use AI agent to analyze if a method's documentation is correct and sufficient.
Reason this release was yanked:
Broken version, fix pending
Project description
Library to automate the generation of docstrings.
What is it?
The aim of the project is to employ AI to evaluate documented (and undocumented) code to establish their accuracy, and improving said documentation automatically.
Requirements
genpydoc supports Python 3.11 and above.
Currently, we only support OpenAI models, so you must provide a valid OpenAI API key.
export OPENAI_API_KEY=<your-key>
Installation
Usage
Run it on one of your projects:
genpydoc [PATH]
Configuration
You can specify the following parameters, either in the pyproject.toml or through command line.
pyproject.toml Configuration
[tool.genpydoc]
ignore-magic = false
ignore-nested-classes = false
ignore-nested-functions = false
ignore-overloaded-functions = false
ignore-private = false
ignore-property-decorators = false
ignore-setters = false
ignore-semiprivate = false
include-only-covered = false
run-on-diff = false
use-llm-provider = "llama"
use-model = "gpt-5-nano"
style = "google"
Command line options
Usage: python -m genpydoc [OPTIONS] [PATHS]...
Options:
-m, --ignore-magic Ignore all magic methods of classes.
[default: False]
NOTE: This does not include the `__init__`
method. To ignore `__init__` methods, use
`--ignore-init-method`.
-C, --ignore-nested-classes Ignore nested classes.
-n, --ignore-nested-functions Ignore nested functions and methods.
-O, --ignore-overloaded-functions
Ignore `@typing.overload`-decorated
functions.
-p, --ignore-private Ignore private classes, methods, and
functions starting with two underscores.
[default: False]
NOTE: This does not include magic methods;
use `--ignore-magic` and/or `--ignore-init-
method` instead.
-P, --ignore-property-decorators
Ignore methods with property
setter/getter/deleter decorators.
-S, --ignore-setters Ignore methods with property setter
decorators.
-s, --ignore-semiprivate Ignore semiprivate classes, methods, and
functions starting with a single underscore.
-o, --include-only-covered Only include Node that have a docstring in
the processing.
-D, --run-on-diff Only run the evaluator on Git diffed Nodes.
--use-llm-provider [openai] Select the LLM provider. [default: openai]
--use-model [gpt-5-nano] Select which LLM model to use for
documenting. [default: gpt-5-nano]
--style [google|numpy|epytext|reST]
Docstring types allowed. [default: google]
-h, --help Show this message and exit.
-c, --config FILE Read configuration from `pyproject.toml`.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file genpydoc-1.0.8.tar.gz.
File metadata
- Download URL: genpydoc-1.0.8.tar.gz
- Upload date:
- Size: 13.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
d3d4cd0a75edc19768bdb54e69f631928b2f481afbbd2a74006d7ba14d96fe1e
|
|
| MD5 |
f24262399a0d2421ff1c549750ef575e
|
|
| BLAKE2b-256 |
c894be7a0e8e89de470b35063b589391d5bf462bf6382bb6219abf287640bfb2
|
Provenance
The following attestation bundles were made for genpydoc-1.0.8.tar.gz:
Publisher:
publish.yml on ernestvmo/genpydoc
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
genpydoc-1.0.8.tar.gz -
Subject digest:
d3d4cd0a75edc19768bdb54e69f631928b2f481afbbd2a74006d7ba14d96fe1e - Sigstore transparency entry: 982283978
- Sigstore integration time:
-
Permalink:
ernestvmo/genpydoc@4d00d33c46aa67e9d47b56ef44da7a286ae4e9bc -
Branch / Tag:
refs/tags/v1.0.8 - Owner: https://github.com/ernestvmo
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@4d00d33c46aa67e9d47b56ef44da7a286ae4e9bc -
Trigger Event:
push
-
Statement type:
File details
Details for the file genpydoc-1.0.8-py3-none-any.whl.
File metadata
- Download URL: genpydoc-1.0.8-py3-none-any.whl
- Upload date:
- Size: 16.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
fa308caca05a92b51b1fd8dde83e6900baea052d24288e9c044385443ddfa2c7
|
|
| MD5 |
b9a5cb22be45b351c25f705290c665a5
|
|
| BLAKE2b-256 |
44b8ed1824549ef709b716128973a083e968f250ca15f596456d25a64110c848
|
Provenance
The following attestation bundles were made for genpydoc-1.0.8-py3-none-any.whl:
Publisher:
publish.yml on ernestvmo/genpydoc
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
genpydoc-1.0.8-py3-none-any.whl -
Subject digest:
fa308caca05a92b51b1fd8dde83e6900baea052d24288e9c044385443ddfa2c7 - Sigstore transparency entry: 982284004
- Sigstore integration time:
-
Permalink:
ernestvmo/genpydoc@4d00d33c46aa67e9d47b56ef44da7a286ae4e9bc -
Branch / Tag:
refs/tags/v1.0.8 - Owner: https://github.com/ernestvmo
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@4d00d33c46aa67e9d47b56ef44da7a286ae4e9bc -
Trigger Event:
push
-
Statement type: