Switch to Claude for issue description generation
What does this MR do and why?
Related to #417248
You can have LLMs rewrite and generate issue descriptions based off a text. For example, you may type "I discovered a XSS vulnerability" to generate a fuller description:
Description generation demo
The described feature is already in production and uses OpenAI's completion API.
This MR ports the feature to use Anthropic's Claude which supports a higher number of tokens.
The ported version will be gated with a new feature flag and after the rollout the existing version will be removed. claude_description_generation
is the name of the new feature flag.
Existing version | Ported version created in this MR |
---|---|
ee/lib/gitlab/llm/open_ai/completions/generate_description.rb |
ee/lib/gitlab/llm/anthropic/completions/generate_description.rb |
ee/lib/gitlab/llm/open_ai/templates/generate_description.rb |
ee/lib/gitlab/llm/templates/generate_description.rb |
ee/lib/gitlab/llm/anthropic/response_modifiers/generate_description.rb |
How to set up and validate locally
You need to setup your GDK to run AI features first.
Enable the new feature flag in the console:
Feature.enable(:claude_description_generation)
Create a new issue and use the tanuki icon in the text editor's toolbar to access the feature:
Screen_Recording_2023-11-02_at_13.37.41
MR acceptance checklist
This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.
-
I have evaluated the MR acceptance checklist for this MR.