Skip to main content

Assists with git workflows using LLMs.

Project description

DiffWeave AI

DiffWeave is a tool that automatically generates meaningful Git commit messages and pull request descriptions using large language models (LLMs). It analyzes your staged changes and creates descriptive commit messages, saving you time and ensuring consistent documentation.

Documentation available here

Demo

Installation & Quick Start

You can run DiffWeave via uvx diffweave-ai or from a local checkout using uv run diffweave-ai while developing this repo.

DiffWeave is installed as an isolated tool using uv:

# Make sure you have uv installed first
# https://docs.astral.sh/uv/getting-started/installation/

uvx diffweave-ai

Usage

Configure a model

Before generating commit messages, configure your model. DiffWeave supports two authentication types:

Token-based (OpenAI-compatible endpoints):

uvx diffweave-ai set-token-model "your-model-name" \
  --token "$YOUR_API_TOKEN" \
  --endpoint "https://your-endpoint-url"

The --endpoint flag defaults to https://api.openai.com/v1/responses if omitted.

Databricks (browser-based authentication):

uvx diffweave-ai set-databricks-browser-model "your-model-name" \
  --account "your-databricks-account"

This opens a browser window for authentication and caches the resulting token automatically.

Generate a commit message

Once you have a model configured and some changes staged in your current Git repository, run:

uvx diffweave-ai

This will:

  • Show the current git status.
  • Prompt you to stage files interactively.
  • Generate a commit message using your configured model.
  • Let you review and refine the message before committing.
  • Run git commit, then prompt whether to git push.
  • Optionally open the repository in a browser (requires --open-browser).

If you prefer a simpler, natural-language style instead of Conventional Commits, pass --simple:

uvx diffweave-ai --simple

To preview a message without committing:

uvx diffweave-ai --dry-run

For scripted or automated workflows (skips all prompts, commits, and pushes automatically):

uvx diffweave-ai --non-interactive

Generate a pull request description

To generate a PR title and body based on the diff between your branch and main:

uvx diffweave-ai pr

The result is copied to your clipboard automatically. Use --branch to diff against a branch other than main:

uvx diffweave-ai pr --branch my-base-branch

Features

  • AI-powered commit message generation based on staged diffs
  • Pull request description generation with automatic clipboard copy
  • Interactive or non-interactive workflows
  • Token-based (OpenAI-compatible) and Databricks browser authentication
  • Optional simpler commit style via --simple
  • Optional push and browser-open flow after committing

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

diffweave_ai-2.0.1.tar.gz (555.9 kB view details)

Uploaded Source

Built Distribution

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

diffweave_ai-2.0.1-py3-none-any.whl (21.0 kB view details)

Uploaded Python 3

File details

Details for the file diffweave_ai-2.0.1.tar.gz.

File metadata

  • Download URL: diffweave_ai-2.0.1.tar.gz
  • Upload date:
  • Size: 555.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for diffweave_ai-2.0.1.tar.gz
Algorithm Hash digest
SHA256 1f80e8d1040672b1f14bdba8a141f6e13a4861b3bf84d2f893b6e157a7e69503
MD5 acee5ca4c74552c68b26ce8a503b9ca3
BLAKE2b-256 1aceff7c80824b2245b893591e47cd2957b573e44dfff131bf1c2ac1e1745af0

See more details on using hashes here.

Provenance

The following attestation bundles were made for diffweave_ai-2.0.1.tar.gz:

Publisher: release.yml on block/diffweave-ai

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file diffweave_ai-2.0.1-py3-none-any.whl.

File metadata

  • Download URL: diffweave_ai-2.0.1-py3-none-any.whl
  • Upload date:
  • Size: 21.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for diffweave_ai-2.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 f3fd245a6c19fe90dd50c8e4b33e517317cfc90e24ff66b59472bc8ec5029e71
MD5 7bbc4817f0bb88ca8402225f2eec2fc0
BLAKE2b-256 a712da966ee67e170578892056598e7735a37cba9c74ebaafa44d8dcdfb30874

See more details on using hashes here.

Provenance

The following attestation bundles were made for diffweave_ai-2.0.1-py3-none-any.whl:

Publisher: release.yml on block/diffweave-ai

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

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