Skip to content

Commit c184947

Browse files
committed
docs: update README with Anthropic provider and language support
- Add Anthropic (Claude Code CLI) provider documentation - Document language configuration feature (en/es) - Update features list with new capabilities - Add requirements and usage examples for new features - Update CLI command descriptions
1 parent 423a0e7 commit c184947

1 file changed

Lines changed: 45 additions & 6 deletions

File tree

README.md

Lines changed: 45 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,10 @@ AI-powered Git commit message generator that analyzes your staged changes and ou
44

55
## Features
66

7-
- Generates 10 commit message suggestions from your staged diff
8-
- Providers: GitHub Copilot (default), OpenAI
9-
- Interactive config to pick provider/model and set keys
7+
- Generates configurable number of commit message suggestions from your staged diff
8+
- Providers: GitHub Copilot (default), OpenAI, Anthropic (Claude Code CLI)
9+
- Multi-language support: English and Spanish
10+
- Interactive config to pick provider/model/language and set keys
1011
- Simple output suitable for piping into TUI menus (one message per line)
1112

1213
## Installation
@@ -27,9 +28,9 @@ go build -o lazycommit main.go
2728

2829
- Root command: `lazycommit`
2930
- Subcommands:
30-
- `lazycommit commit` — prints 10 suggested commit messages to stdout, one per line, based on `git diff --cached`.
31-
- `lazycommit config get` — prints the active provider and model.
32-
- `lazycommit config set` — interactive setup for provider, API key, and model.
31+
- `lazycommit commit` — prints suggested commit messages to stdout, one per line, based on `git diff --cached`.
32+
- `lazycommit config get` — prints the active provider, model, and language.
33+
- `lazycommit config set` — interactive setup for provider, API key, model, and language.
3334

3435
Exit behaviors:
3536
- If no staged changes: prints "No staged changes to commit." and exits 0.
@@ -67,6 +68,7 @@ Contains API keys, tokens, and provider-specific settings. **Do not share this f
6768

6869
```yaml
6970
active_provider: copilot # default if a GitHub token is found
71+
language: en # commit message language: "en" (English) or "es" (Spanish)
7072
providers:
7173
copilot:
7274
api_key: "$GITHUB_TOKEN" # Uses GitHub token; token is exchanged internally
@@ -76,13 +78,28 @@ providers:
7678
api_key: "$OPENAI_API_KEY"
7779
model: "gpt-4o"
7880
# endpoint_url: "https://api.openai.com/v1" # Optional - uses default if not specified
81+
anthropic:
82+
model: "claude-haiku-4-5" # Uses Claude Code CLI - no API key needed
83+
num_suggestions: 10 # Number of commit suggestions to generate
7984
# Custom provider example (e.g., local Ollama):
8085
# local:
8186
# api_key: "not-needed"
8287
# model: "llama3.1:8b"
8388
# endpoint_url: "http://localhost:11434/v1"
8489
```
8590

91+
#### Anthropic Provider (Claude Code CLI)
92+
93+
The Anthropic provider integrates with your local [Claude Code CLI](https://github.com/anthropics/claude-code) installation:
94+
95+
- **No API key required**: Uses your existing Claude Code authentication
96+
- **Fast and cost-effective**: Leverages Claude Haiku model
97+
- **Configurable**: Set custom number of suggestions per provider
98+
99+
Requirements:
100+
- Claude Code CLI installed and authenticated
101+
- Command `claude` available in PATH
102+
86103
### 2. Prompt Configuration (`~/.config/.lazycommit.prompts.yaml`)
87104
Contains prompt templates and message configurations. **Safe to share in dotfiles and Git.**
88105

@@ -125,6 +142,28 @@ providers:
125142
<!-- endpoint_url: "https://api.z.ai/api/paas/v4/" -->
126143
<!-- ``` -->
127144

145+
### Language Configuration
146+
147+
lazycommit supports generating commit messages in different languages. Set the `language` field in your config:
148+
149+
```yaml
150+
language: es # Spanish
151+
# or
152+
language: en # English (default)
153+
```
154+
155+
You can also configure it interactively:
156+
157+
```bash
158+
lazycommit config set # Select language in the interactive menu
159+
```
160+
161+
The language setting automatically instructs the AI to generate commit messages in the specified language, regardless of the provider used.
162+
163+
**Supported languages:**
164+
- `en` - English (default)
165+
- `es` - Spanish (Español)
166+
128167
## Integration with TUI Git clients
129168

130169
Because `lazycommit commit` prints plain lines, it plugs nicely into menu UIs.

0 commit comments

Comments
 (0)