Commit
Byte's commit system uses AI to generate meaningful commit messages by analyzing your staged changes. It automates the entire commit workflow - staging files, running linters, generating commit messages, and handling git operations.

Quick Start
Create an commit:
Byte will:
- Stage all changed files (with confirmation)
- Run configured linters on changed files
- Analyze the git diff with AI
- Generate a descriptive commit message
- Create the commit with the generated message
If the commit fails (for example, when pre-commit hooks modify files), Byte will:
- Display the error message
- Prompt you to stage the changes and try again
- Re-stage all changes if you confirm
- Retry the commit with the same message
This is common with pre-commit hooks that automatically format or modify files - the hooks run, change the files, and cause the commit to fail because the staging area no longer matches the working directory.
Configuration
Linting Integration
Control linting behavior via .byte/config.yaml:
lint:
enable: true # Disable to skip linting during commits
commands:
- command: "ruff format"
extensions: [".py"]
See Linting concept for detailed configuration.
Commit Message Format
The AI generates messages following conventional commit conventions:
Structure
Types
Common commit types the AI uses:
- feat - New feature
- fix - Bug fix
- docs - Documentation changes
- style - Code style changes (formatting, whitespace)
- refactor - Code restructuring without behavior change
- perf - Performance improvements
- test - Test additions or modifications
- chore - Build process, tooling, dependencies
Examples
Simple feature:
Bug fix with scope:
Breaking change:
feat!: redesign authentication API
BREAKING CHANGE: AuthService.login() now returns a Promise
instead of synchronous result. Update all callers to use await.