Skip to main content

📝 docullim

Latest Python Versions

auto-generate documentation for python code using llms.

asciicast

⚙️ installation

pip install docullim
poetry add docullim

💻 usage

add @docullim to the function or class you want to generate documention for. you can also pass a tag to the annotation like @docullim("custom_tag").

from docullim import docullim

@docullim
def add(a, b):
    return a + b

@docullim("custom_tag")
def sub(a, b):
    return a - b
docullim file1.py file2.py
docullim "src/**/*.py"
docullim --config docullim.json --model gpt-4 "src/**/*.py"
docullim --reset-cache --concurrency 3 --write file1.py "src/**/*.py"

config file is a json file that can have model as string, max_concurrency as number or prompts as string pairs.

docullim.json

{
  "model": "gpt-4",
  "max_concurrency": 5,
  "prompts": {
    "default": "Generate short and simple documentation explaing the code and include sample usage.",
    "custom_tag": "this is a a diffrent propmt being passed to the llm when @docullim('custom_tag') is passed"
  }
}

you should provide your llm api key provided as enviroment variable by default it requires OPENAI_API_KEY. you can switch models and provide other llm api keys. See supported llms

🛠️ development

Install the following tools are needed to have this project running

  • devbox manages all the packages needed by the project
  • direnv loads env variables and run devbox when in project directory

also rename .env.example to .env and add your llm api key.

Metadata

Release files for docullim 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 docullim 0.5.0
File Size Uploaded Provenance
docullim-0.5.0.tar.gz 7.0 kB Without provenance Details

Built distribution (wheel)

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

Total release size: 16.1 kB

Release files / docullim-0.5.0.tar.gz

Download URL docullim-0.5.0.tar.gz
Size 7.0 kB
Tags Source
SHA-256 checksum
How to use checksums
5e1290c956fdf790d3ec624973f830af9c158640ef9d5a690edb0e8067b78600
BLAKE2b-256 checksum
How to use checksums
19a19a3b40eb1a261b884d923d600a5a43c10bfc8ab68ef9b75d006f115f4423
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/2.0.1 CPython/3.12.8 Darwin/24.3.0

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

Download URL docullim-0.5.0-py3-none-any.whl
Size 9.1 kB
Tags Python 3
SHA-256 checksum
How to use checksums
fd7ce6501b70947a40a92672de39402adde9283fe7d4031a29e18f28c6be9d86
BLAKE2b-256 checksum
How to use checksums
e4e7d4f22498428a15350db5df31e5ab3055eed9a6b2073cdb5797884ce0f802
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/2.0.1 CPython/3.12.8 Darwin/24.3.0

Security for docullim 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