-
Notifications
You must be signed in to change notification settings - Fork 603
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1252 from Codium-ai/tr/prompts_refactor
improve code suggestion prompt
- Loading branch information
Showing
5 changed files
with
94 additions
and
193 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,30 +1,18 @@ | ||
## PR-Agent Pro Models | ||
|
||
The default models used by PR-Agent Pro are OpenAI's GPT-4 models. We use a combination of GPT-4-Turbo and GPT-4o to strike a balance between speed and quality. | ||
The default models used by PR-Agent Pro are a combination of Claude-3.5-sonnet and OpenAI's GPT-4 models. | ||
|
||
However, users can change the model used by PR-Agent Pro to Claude-3.5-sonnet, which also excels at code tasks. | ||
To do so, add the following to your [configuration](https://pr-agent-docs.codium.ai/usage-guide/configuration_options/) file: | ||
Users can configure PR-Agent Pro to use solely a specific model by editing the [configuration](https://pr-agent-docs.codium.ai/usage-guide/configuration_options/) file. | ||
|
||
For example, to restrict PR-Agent Pro to using only `Claude-3.5-sonnet`, add this setting: | ||
|
||
``` | ||
[config] | ||
model="claude-3-5-sonnet" | ||
``` | ||
|
||
Note that Claude models tend to give lower scores for each suggestion, so if you are using a [threshold](https://pr-agent-docs.codium.ai/tools/improve/#configuration-options): | ||
``` | ||
[pr_code_suggestions] | ||
suggestions_score_threshold=... | ||
``` | ||
You might need to adjust this value when switching models. | ||
|
||
### Dedicated models per tool | ||
|
||
You can also use different models for different tools. For example, you can use the Claude-3.5-sonnet model only for the `improve` tool (and keep the default GPT-4 model for the other tools) by adding the following to your configuration file: | ||
Or to restrict PR-Agent Pro to using only `GPT-4o`, add this setting: | ||
``` | ||
[github_app] | ||
pr_commands = [ | ||
"/describe --pr_description.final_update_message=false", | ||
"/review --pr_reviewer.num_code_suggestions=0", | ||
"/improve --config.model=claude-3-5-sonnet", | ||
] | ||
[config] | ||
model="gpt-4o" | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.