Skip to main content

AI-powered Python documentation enhancer

Project description

PyDocEnhancer

AI-powered Python plugin to enhance documentation with summaries, code explanations, examples, and semantic search.

Features

  • Auto-Generated Summaries: Summarize modules, classes, and functions.
  • Code Explanations: Plain-English explanations of code logic.
  • Semantic Search: Query documentation with natural language (e.g., "find data processing functions").
  • Auto-Generated Examples: Create working code examples from docstrings.
  • Local LLM Support: Privacy-first processing with local models (e.g., LLaMA 3.2).
  • Integrations: Works with Sphinx, MkDocs, and Jupyter Notebooks.

Installation

pip install pydocenhancer

Quick Start

from pydocenhancer import DocEnhancer

# Initialize with a local LLM
enhancer = DocEnhancer(provider="local", model="llama3.2")
enhancer.generate_docs(module_path="my_project/utils.py", output_dir="docs")

# Search documentation
results = enhancer.search_docs("file handling functions", "docs")
print(results)

CLI Usage

# Generate documentation
pydocenhancer enhance --module my_project/utils.py --output docs/ --provider local --model llama3.2

# Search documentation
pydocenhancer search --query "data processing functions" --docs-dir docs/

Requirements

  • Python 3.8+
  • Local LLM (e.g., LLaMA 3.2 via llama-cpp-python) or API key for OpenAI/Anthropic
  • Optional: Sphinx or MkDocs for integration

Documentation

Full documentation is available at ReadTheDocs.

License

MIT © Your Name

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

pydocenhancer-0.1.0.tar.gz (6.5 kB view details)

Uploaded Source

Built Distribution

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

pydocenhancer-0.1.0-py3-none-any.whl (6.2 kB view details)

Uploaded Python 3

File details

Details for the file pydocenhancer-0.1.0.tar.gz.

File metadata

  • Download URL: pydocenhancer-0.1.0.tar.gz
  • Upload date:
  • Size: 6.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.10

File hashes

Hashes for pydocenhancer-0.1.0.tar.gz
Algorithm Hash digest
SHA256 3025da99b65b19b8f2245dfefcf4cef8524cb6b71377f77b470f192d6a01341a
MD5 aa5e27f30a7c8a1e27e28b22a90059e2
BLAKE2b-256 d52a043eba0480c7934e6026d2edf68b2ee137e5329b0999a179e2b83f017865

See more details on using hashes here.

File details

Details for the file pydocenhancer-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: pydocenhancer-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 6.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.10

File hashes

Hashes for pydocenhancer-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 29e34f55220ffe4550a1d8cda01245beeec2e07c11ada44cdec435df6e86064c
MD5 6fb9d413beb5d6fa72e88223d8142d00
BLAKE2b-256 1656027a3929b73fa0298b7dea66c829c7a4cb6946019d7c4fd15fcc7927e9bd

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