AIを活用した効果的なコミットメッセージの作成
AIが生成したdocstringと細かな修正をコミットする作業を行っています。docstringの生成でモデルのパフォーマンスに満足したため、git diff として表示されたコード変更に対して、意味のあるコミットメッセージも生成してもらうことにしました。これまでに、次のようなプロンプトを作成しました。
Based on the following code diff, write a commit message:
🟥 -def is_valid_account_number(account: str) -> bool:
🟥 - return account.isdigit()
🟩 +def is_valid_account_number(account: str) -> bool:
🟩 + if not account.isdigit():
🟩 + return False
🟩 + if len(account) != 10:
🟩 + return False
🟩 + return True
モデルをより効果的に誘導するために、このプロンプトに不足しているものは何でしょうか?
この演習はコースの一部です
