Skip to main content

pydocify: An LLM-based library that effortlessly auto-generates docstrings for your Python scripts and modules, enhancing code readability with ease.

Project description

pydocify - LLM-Based Documentation Generator Library for Python Code

Logo

Author : Rahul Bhoyar

Transform Your Python Code with pydocify!

Unlock the power of documentation with pydocify, an innovative LLM-based library that automatically generates clear and concise docstrings for your Python scripts and modules. Say goodbye to the hassle of writing documentation from scratch! Whether you're maintaining a small project or collaborating on a large codebase, pydocify enhances code readability and consistency, ensuring your functions and classes are well-documented and easy to understand. Elevate your coding experience and keep your projects organized with just a few simple commands!

Features

  • Automatically generates docstrings based on code content.
  • Archives original Python files before documentation is added.
  • Recursively processes all Python files in a specified directory.
  • Supports deleting archive files created during the documentation process.

Installation

Install pydocify with pip:

pip install pydocify

Usage

1. Documenting All Python Files in a Directory

Use the DirectoryStringGenerator class to recursively document all Python files in a specified directory:

from pydocify.core import DirectoryStringGenerator

doc_generator = DirectoryStringGenerator()
doc_generator.generate("/path/to/your/directory")

2. Deleting Archive Files during documentation process

Use delete_archives to remove any archive files created during the documentation process:

doc_generator.delete_archives("/path/to/your/directory")

3. Documenting a Python File

Use the FileStringGenerator class to document a Python file at specified path:

from pydocify.core import FileStringGenerator

file_doc_generator = FileStringGenerator()
file_doc_generator.generate("/path/to/your/file")

Requirements

Ensure that you have your OPENAI_API_KEY set up as an environment variable in a .env file.

License

pydocify is licensed under the MIT License.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pydocify-0.2.1.tar.gz (5.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pydocify-0.2.1-py3-none-any.whl (5.5 kB view details)

Uploaded Python 3

File details

Details for the file pydocify-0.2.1.tar.gz.

File metadata

  • Download URL: pydocify-0.2.1.tar.gz
  • Upload date:
  • Size: 5.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.8.8rc1

File hashes

Hashes for pydocify-0.2.1.tar.gz
Algorithm Hash digest
SHA256 8ee4fdd164686e8e455e86b9141fbf3fdac80285d5e77cd316bac23da73d006b
MD5 24e081a25069ad99cee020c6ceff48ff
BLAKE2b-256 c8b9fbfde3294c8ed5c84f1ceee05ca92d00f9cfa5039bc65b91a4b9533e38b0

See more details on using hashes here.

File details

Details for the file pydocify-0.2.1-py3-none-any.whl.

File metadata

  • Download URL: pydocify-0.2.1-py3-none-any.whl
  • Upload date:
  • Size: 5.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.8.8rc1

File hashes

Hashes for pydocify-0.2.1-py3-none-any.whl
Algorithm Hash digest
SHA256 67f9d125f741ada554e7910f07615e9b81ad3bdcb0ff90691a90a67d1220e27d
MD5 1d55c49b81e9935584702bfd4a8750ac
BLAKE2b-256 c8ca335325aeda1c10068d488effd0e431c1bc6ae15531f513a19bddac896177

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page