You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: src/content-script/menu-tools/index.mjs
+1-1Lines changed: 1 addition & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -13,7 +13,7 @@ export const config = {
13
13
summarizePage: {
14
14
label: 'Summarize Page',
15
15
genPrompt: async()=>{
16
-
return`The following is the text content of a web page, analyze the core content and summarize:\n${getCoreContentText()}`
16
+
return`You are an expert summarizer. Carefully analyze the following web page content and provide a concise summary focusing on the key points:\n${getCoreContentText()}`
Copy file name to clipboardExpand all lines: src/content-script/selection-tools/index.mjs
+14-9Lines changed: 14 additions & 9 deletions
Original file line number
Diff line number
Diff line change
@@ -27,10 +27,10 @@ const createGenPrompt =
27
27
}
28
28
29
29
letfullMessage=isTranslation
30
-
? `Translate the following into ${preferredLanguage}and only show me the translated content`
30
+
? `You are a professional translator. Translate the following text into ${preferredLanguage}, preserving meaning, tone, and formatting. Only provide the translated result.`
31
31
: message
32
32
if(enableBidirectional){
33
-
fullMessage+=`. If it is already in ${preferredLanguage}, translate it into English and only show me the translated content`
33
+
fullMessage+=` If the text is already in ${preferredLanguage}, translate it into English instead following the same requirements. Only provide the translated result.`
34
34
}
35
35
constprefix=includeLanguagePrefix ? `Reply in ${preferredLanguage}.` : ''
'You are an expert teacher. Explain the following content in simple terms and highlight the key points',
45
46
includeLanguagePrefix: true,
46
47
}),
47
48
},
@@ -80,7 +81,8 @@ export const config = {
80
81
icon: <CardHeading/>,
81
82
label: 'Summary',
82
83
genPrompt: createGenPrompt({
83
-
message: 'Summarize the following as concisely as possible',
84
+
message:
85
+
'You are a professional summarizer. Summarize the following content in a few sentences, focusing on the key points',
84
86
includeLanguagePrefix: true,
85
87
}),
86
88
},
@@ -89,38 +91,41 @@ export const config = {
89
91
label: 'Polish',
90
92
genPrompt: createGenPrompt({
91
93
message:
92
-
'Check the following content for possible diction and grammar problems, and polish it carefully',
94
+
'Act as a skilled editor. Correct grammar and word choice in the following text, improve readability and flow while preserving the original meaning, and return only the polished version',
93
95
}),
94
96
},
95
97
sentiment: {
96
98
icon: <EmojiSmile/>,
97
99
label: 'Sentiment Analysis',
98
100
genPrompt: createGenPrompt({
99
101
message:
100
-
'Analyze the sentiments expressed in the following content and make a brief summary of the sentiments',
102
+
'You are an expert in sentiment analysis. Analyze the following content and provide a brief summary of the overall emotional tone, labeling it with a short descriptive word or phrase',
101
103
includeLanguagePrefix: true,
102
104
}),
103
105
},
104
106
divide: {
105
107
icon: <CardList/>,
106
108
label: 'Divide Paragraphs',
107
109
genPrompt: createGenPrompt({
108
-
message: 'Divide the following into paragraphs that are easy to read and understand',
110
+
message:
111
+
'You are a skilled editor. Divide the following text into clear, easy-to-read and easy-to-understand paragraphs',
109
112
}),
110
113
},
111
114
code: {
112
115
icon: <Braces/>,
113
116
label: 'Code Explain',
114
117
genPrompt: createGenPrompt({
115
-
message: 'Explain the following code',
118
+
message:
119
+
'You are a senior software engineer and system architect. Break down the following code step by step, explain how each part works and why it was designed that way, note any potential issues, and summarize the overall purpose',
116
120
includeLanguagePrefix: true,
117
121
}),
118
122
},
119
123
ask: {
120
124
icon: <QuestionCircle/>,
121
125
label: 'Ask',
122
126
genPrompt: createGenPrompt({
123
-
message: 'Analyze the following content and express your opinion, or give your answer',
127
+
message:
128
+
'Analyze the following content carefully and provide a concise answer or opinion with a short explanation',
Copy file name to clipboardExpand all lines: src/content-script/site-adapters/github/index.mjs
+14-4Lines changed: 14 additions & 4 deletions
Original file line number
Diff line number
Diff line change
@@ -89,10 +89,16 @@ function createChatGPtSummaryPrompt(issueData, isIssue = true) {
89
89
90
90
if(isIssue){
91
91
prompt=
92
-
'Please summarize the following GitHub issue thread.\nWhat is the main issue and key points discussed in this thread?\n\n'
92
+
`You are an expert in analyzing GitHub discussions. `+
93
+
`Please provide a concise summary of the following GitHub issue thread. `+
94
+
`Identify the main problem reported, key points discussed by participants, proposed solutions (if any), and the current status or next steps. `+
95
+
`Present the summary in a structured markdown format.\n\n`
93
96
}else{
94
97
prompt=
95
-
'Please summarize the following GitHub pull request thread.\nWhat is the main issue this pull request is trying to solve?\n\n'
98
+
`You are an expert in analyzing GitHub discussions and code reviews. `+
99
+
`Please provide a concise summary of the following GitHub pull request thread. `+
100
+
`Identify the main problem this pull request aims to solve, the proposed changes, key discussion points from the review, and the overall status of the PR (e.g., approved, needs changes, merged). `+
101
+
`Present the summary in a structured markdown format.\n\n`
96
102
}
97
103
98
104
prompt+='---\n\n'
@@ -153,8 +159,12 @@ export default {
153
159
if(!patchData)return
154
160
155
161
returnawaitcropText(
156
-
`Analyze the contents of a git commit,provide a suitable commit message,and summarize the contents of the commit.`+
157
-
`The patch contents of this commit are as follows:\n${patchData}`,
162
+
`You are an expert in analyzing git commits and crafting clear, concise commit messages. `+
163
+
`Based on the following git patch, please perform two tasks:\n`+
164
+
`1. Generate a suitable commit message. It should follow standard conventions: a short imperative subject line (max 50 chars), `+
165
+
`followed by a blank line and a more detailed body if necessary, explaining the "what" and "why" of the changes.\n`+
166
+
`2. Provide a brief summary of the changes introduced in this commit, highlighting the main purpose and impact.\n\n`+
167
+
`The patch contents are as follows:\n${patchData}`,
`You are an expert content analyst and summarizer. `+
25
+
`Please analyze the following Juejin article and its comments. Provide a summary of the article (including author), your opinion on it, and a summary of the comments.\n`+
0 commit comments