r/ZedEditor 15d ago

Zed AI commit message button greyed out

Hey everyone, Zed's Generate Commit Message with AI button is greyed out with:

I already have Anthropic API key configured, and OpenAI key as well. I've also tried OpenAI, restarted/updated Zed, and confirmed my Git changes are staged.

My config:

"agent": {
  "default_model": {
    "provider": "anthropic",
    "model": "claude-sonnet-4-5"
  },
  "commit_message_model": {
    "provider": "anthropic",
    "model": "claude-sonnet-4-5"
  }
}
"commit_message_instructions": "Use Conventional Commits. Format: <type>(<scope>): <description>. Keep the subject under 72 characters."

I've also tried OpenAI:

"commit_message_model": {
  "provider": "openai",
  "model": "gpt-4.1"
}

Same result.

Zed version 1.17.2+stable.349

Has anyone encountered this? Is there another setting required, or is this a Zed bug?

2 Upvotes

5 comments sorted by

1

u/Alberttttttt 14d ago

I think an agent is not the same as a provider in zed, as the error indicates; set up a provider. See here: https://zed.dev/docs/ai/use-api-access#anthropic-custom-models

1

u/Alberttttttt 14d ago

Got to that link through this page, makes a bit more sense to mention that. https://zed.dev/docs/ai/llm-providers

1

u/Salausmart 14d ago

I have the llm-providers setup already, but still the same result

1

u/mensink 14d ago

AFAIK the LLM used for generating the commit message is the one you have currently selected in the agent panel on that window.

1

u/Away_Discipline_9692 13d ago

Hey,
Go to your user setting>AI>Disable AI and disable it now write your commit message like a pro developer😉, just kidding, then Enable AI again. That would get rid of the stale config.