ayumi is used for agentic coding--it records user prompts sent to agents and inserts them into Git commit messages.
ayumi records only user instructions. It does not store AI responses, transcripts, reasoning, or tool output.
The name ayumi comes from the Japanese word 歩み which means the history or steps of something. This tool stores the steps took in agentic coding, hence the naming.
Warning
ayumi copies raw prompts into your git commit messages. Do not include secrets, credentials, or anything else you do not want published and recorded to commit messages (you probably shouldn't send them anyways as prompts to coding agents as well).
feat: add JWT middleware
AI Instructions:
> Add JWT authentication
> Move it into middleware
> Validate issuer and audience
Prompts are inserted as recorded. Each prompt is inserted as a Markdown quote block, with a blank line between prompts.
Install with go install like this:
go install github.com/stefafafan/ayumi@latestSetup the hooks for UserPromptSubmit hook like this:
{
"hooks": {
"UserPromptSubmit": [
{
"hooks": [
{
"type": "command",
"command": "/absolute/path/to/ayumi add"
}
]
}
]
}
}For Git 2.54 or newer, use Git's config-based hooks.
[hook "ayumi"]
event = prepare-commit-msg
command = sh -c '/absolute/path/to/ayumi inject "$1"' ayumiThe sh -c wrapper passes only Git's first prepare-commit-msg argument to ayumi inject. This avoids forwarding extra hook arguments such as message from git commit -m.
For older Git versions, create a prepare-commit-msg hook file like this and make it executable. Set it as a global hook if needed.
#!/bin/sh
/absolute/path/to/ayumi inject "$1"Configuration is read from ~/.config/ayumi/config.toml
Here are default settings, manually set these values if you want to update:
storage_dir = "~/.local/share/ayumi"
heading = "AI Instructions"Reads from standard input and stores the user prompt for the current Git repository and branch to file.
ayumi addAppends prompts recorded after the previous commit time to the commit message file.
ayumi inject .git/COMMIT_EDITMSGIf no prompts were recorded after the previous commit, nothing is inserted.
During rebase, cherry-pick, merge, and revert operations, ayumi inject does nothing so Git can reuse the existing commit message.
Prints the current ayumi version.
ayumi version