Skip to main content

documentation-generator

Overeview

This is a python library for generating documentation for python projects. It is built to:

  • Generate function docstrings
  • Generate class docstrings include class method docstrings (still under development)
  • Generate sphinx documentation (still under development)

The library uses openai's gpt model to generate the function docstrings. You pass it a file or folder path togther with an openai api key. It then parses the folder for python files, then for each file, it finds the functions and classes, generates their documentation and updates their docstrings.

Requirements

  • Python 3.10+
  • Works on Linux, Windows, macOS, BSD

Installation

pip install oryks-docstring-generator

Usage

First, provide the openai api key:

export OPENAI_API_KEY=sk-xxxxxxxxxxx

Then run the application, providing the path to the python file to generate docs for or the folder containing the python files:

python -m docstring_generator --path /home/lyle/tutorial/test-docstrings-generator/test/ --directories-ignore venv
--files-ignore test.py --overwrite-function-docstring True --overwrite-class-docstring True --overwrite-class-methods-docstring True --documentation-style Numpy-Style

Documentation and Tutorials

To learn more about the library including the documentation and tutorials, check out the libraries' documentation.

How to Contribute

To contribute, chack out the contribution guideline.

License

The API uses an MIT License

Developer

Lyle Okoth – @lyleokoth on twitter

lyle okoth on medium

My email is lyceokoth@gmail.com

Here is my GitHub Profile

You can also find me on Linkedin

Metadata

Release files for oryks-docstring-generator 0.5.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for oryks-docstring-generator 0.5.0
File Size Uploaded Provenance
oryks-docstring-generator-0.5.0.tar.gz 9.1 kB Without provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for oryks-docstring-generator 0.5.0
File Interpreter ABI Platform
oryks_docstring_generator-0.5.0-py3-none-any.whl Python 3 none any Details

Total release size: 19.2 kB

Release files / oryks-docstring-generator-0.5.0.tar.gz

Download URL oryks-docstring-generator-0.5.0.tar.gz
Size 9.1 kB
Tags Source
SHA-256 checksum
How to use checksums
c8ad11ee0a3f88fb57984c412461f5697565dd35f7f2cdae34ea558ceb036da9
BLAKE2b-256 checksum
How to use checksums
babde20b84148bb676eecce71255658c8dfa82d2051c1f3b5c8071039f541eef
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.10.12

Release files / oryks_docstring_generator-0.5.0-py3-none-any.whl

Download URL oryks_docstring_generator-0.5.0-py3-none-any.whl
Size 10.1 kB
Tags Python 3
SHA-256 checksum
How to use checksums
34b14794e77bafff6733c1986d58d7a1243b4387ce2f52f70758e475953cd7a7
BLAKE2b-256 checksum
How to use checksums
9d8d8da6100f2290d2ca8c1a44176c0d2a5acf6b7d26f3f16482948aeff10904
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.10.12

Security for oryks-docstring-generator 0.5.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page