Skip to main content

A CLI tool that generates semantic Japanese commit message prompts for LLMs from Git diff information.

Project description

komitto(コミット)

git diffの情報から、セマンティックな日本語のコミットメッセージプロンプトを生成するためのCLIツールです。生成されたプロンプトは自動的にクリップボードにコピーされ、LLMに貼り付けることで、コミットメッセージを作成できます。

主な機能

  • ステージングされた変更(git diff --staged)を解析
  • 変更内容をLLMが理解しやすいXML形式に変換
  • コミットメッセージ生成用のシステムプロンプトと結合
  • 生成された最終的なプロンプトをクリップボードにコピー
  • 変更に関する追加のコンテキスト(補足情報)をコマンドライン引数で付与する機能

インストール

pip install .

もし開発用にインストールする場合は、以下のコマンドを使用してください。

pip install -e .

使い方

  1. リポジトリで変更を行い、git addでファイルをステージングします。

    git add <変更したファイル>
    
  2. komittoコマンドを実行します。

    komitto
    
  3. ✅ プロンプトをクリップボードにコピーしました! と表示されたら、お使いのLLMのインターフェースにプロンプトを貼り付けてください。

追加コンテキストを渡す

変更の意図や特記事項など、プロンプトに含めたい補足情報がある場合は、引数として渡すことができます。

komitto "この変更は緊急のバグ修正です"

仕組み

  1. git diff --staged を実行し、ステージングされたファイルの差分を取得します。
  2. 差分情報を、ファイルパス、関数/クラス名、変更の種類(追加、修正、削除)などを含む構造化されたXML形式に変換します。
  3. あらかじめ定義されたシステムプロンプト、ユーザーが指定した追加コンテキスト、XML形式の差分情報を結合して、最終的なプロンプTプを生成します。
  4. 生成されたプロンプトをクリップボードにコピーします。

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

komitto-0.1.1.tar.gz (6.8 kB view details)

Uploaded Source

Built Distribution

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

komitto-0.1.1-py3-none-any.whl (7.9 kB view details)

Uploaded Python 3

File details

Details for the file komitto-0.1.1.tar.gz.

File metadata

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

File hashes

Hashes for komitto-0.1.1.tar.gz
Algorithm Hash digest
SHA256 8848b868922bf17c0bf9e27547c72703b6bd137871b2c92059d03eabb9fd41fe
MD5 3169c4216d52363a7d27194a56445f4f
BLAKE2b-256 530283841c324da7164e5f72025b7057cfd9b768d5059cc035fb1cc803f31398

See more details on using hashes here.

Provenance

The following attestation bundles were made for komitto-0.1.1.tar.gz:

Publisher: publish.yaml on MXCAKE3893/komitto

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

File details

Details for the file komitto-0.1.1-py3-none-any.whl.

File metadata

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

File hashes

Hashes for komitto-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 58e4465f1b3635b529ef1758b6b84d16dc5208e06d55f6db85bebeb39f126543
MD5 c3fcea2ddfe7da116b029097f3e1a516
BLAKE2b-256 61c2e7144f771bd9bc6fdbf3a2d2fd2ab569da69ab4d8463ff9c722cac847295

See more details on using hashes here.

Provenance

The following attestation bundles were made for komitto-0.1.1-py3-none-any.whl:

Publisher: publish.yaml on MXCAKE3893/komitto

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