mirror of
https://github.com/carlrobertoh/ProxyAI.git
synced 2026-05-19 07:54:46 +00:00
feat: add support for placeholders in prompts (#458)
* fixes #432 adds support for Placeholders in Prompts - activate gradle plugin Git4Idea - adds PlaceholderUtil - adds DATE_ISO_8601 PlaceholderReplacer - adds BRANCH_NAME PlaceholderReplacer * convert to kotlin, improve ui and add int. test * fix: do not reuse projects from previous test runs --------- Co-authored-by: Carl-Robert Linnupuu <carlrobertoh@gmail.com>
This commit is contained in:
parent
f6a5113216
commit
2221d72430
10 changed files with 204 additions and 44 deletions
|
|
@ -28,6 +28,7 @@ import ee.carlrobert.codegpt.EncodingManager;
|
|||
import ee.carlrobert.codegpt.Icons;
|
||||
import ee.carlrobert.codegpt.completions.CompletionRequestService;
|
||||
import ee.carlrobert.codegpt.settings.GeneralSettings;
|
||||
import ee.carlrobert.codegpt.settings.configuration.CommitMessageTemplate;
|
||||
import ee.carlrobert.codegpt.ui.OverlayUtil;
|
||||
import ee.carlrobert.llm.client.openai.completion.ErrorDetails;
|
||||
import ee.carlrobert.llm.completion.CompletionEventListener;
|
||||
|
|
@ -94,7 +95,10 @@ public class GenerateGitCommitMessageAction extends AnAction {
|
|||
if (editor != null) {
|
||||
((EditorEx) editor).setCaretVisible(false);
|
||||
CompletionRequestService.getInstance()
|
||||
.generateCommitMessageAsync(gitDiff, getEventListener(project, editor.getDocument()));
|
||||
.generateCommitMessageAsync(
|
||||
project.getService(CommitMessageTemplate.class).getSystemPrompt(),
|
||||
gitDiff,
|
||||
getEventListener(project, editor.getDocument()));
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue