-
Notifications
You must be signed in to change notification settings - Fork 14
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- 支持 issue 多轮会话
- Loading branch information
Showing
6 changed files
with
129 additions
and
27 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 |
---|---|---|
@@ -0,0 +1,33 @@ | ||
ISSUE_PROMPT = """ | ||
# Task | ||
You have required to resolve an issue {issue_url} now: | ||
## Issue Content: | ||
{issue_content} | ||
# Constraints: | ||
First, carefully analyze the user’s requirements. | ||
Then, search similar issues. | ||
Make sure your suggestions are well-explained and align with the user’s needs. | ||
""" | ||
|
||
ISSUE_COMMENT_PROMPT = """ | ||
# Task | ||
You have required to resolve an issue {issue_url} now: | ||
## Issue Content: | ||
{issue_content} | ||
# Constraints: | ||
- Summarize user needs based on the issue content and information. | ||
- Avoid repeating answers. If you have previously given a similar response, please apologize. | ||
""" | ||
|
||
def generate_issue_prompt(issue_url: str, issue_content: str): | ||
return ISSUE_PROMPT.format(issue_url=issue_url, issue_content=issue_content) | ||
|
||
def generate_issue_comment_prompt(issue_url: str, issue_content: str): | ||
return ISSUE_COMMENT_PROMPT.format(issue_url=issue_url, issue_content=issue_content) | ||
|
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
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
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