Created
April 20, 2024 07:43
-
-
Save andyjessop/a96fc751f25c142bba180fa3c358041e to your computer and use it in GitHub Desktop.
A prompt to categorise and analyse sentiment for GitHub issues
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
Please analyze the following GitHub issue data, which is provided as a JSON object: | |
{ | |
"title": "🐛 BUG: WebSocket typing doesn't work in apps that also pull in DOM types", | |
"body": "Which Cloudflare product(s) does this pertain to?", | |
} | |
Provide a response with the following structure: | |
<json> | |
{ | |
"sentiment": { | |
"score": <integer between 0-100>, | |
"explanation": <brief explanation of the reasoning behind the score> | |
}, | |
"categorization": { | |
"tags": [ | |
<up to 5 tags, either from the provided labels or generated by the AI> | |
] | |
}, | |
"feature_requests": [ | |
{ | |
"tags": <up to 5 tags that categorize the feature request>, | |
"summary": <brief summary of any feature requests found in the issue> | |
} | |
], | |
"bug_reports": [ | |
{ | |
"tags": <up to 5 tags that categorize the bug report>, | |
"summary": <brief summary of any bug reports found in the issue> | |
} | |
] | |
} | |
</json> | |
Note that the JSON is bounded by <json> html tags. This is very important. | |
For sentiment analysis, use the following process: | |
1. Identify the main topics, keywords, and phrases in the title and description. | |
2. Determine the emotional tone associated with each topic, keyword, or phrase (positive, negative, or neutral). | |
3. Consider the context of the issue (e.g., a bug report might have a more negative sentiment than a feature request). | |
4. Assign an initial sentiment score based on the overall emotional tone and context. | |
5. Reflect on the initial score and adjust it if necessary, considering factors such as the severity of the issue, the language used, and any potential biases. | |
6. Provide a brief explanation of the reasoning behind the final sentiment score. | |
Use the following scale for the final sentiment scores: | |
- 0-20: Very negative | |
- 21-40: Negative | |
- 41-60: Neutral | |
- 61-80: Positive | |
- 81-100: Very Positive | |
Examples: | |
- "This feature is amazing!": 95 (Very Positive) | |
- "I like the way you have built this.": 65 (Positive) | |
- "The documentation needs improvement.": 45 (Neutral) | |
- "There is a bug in the code analyser.": 51 (Neutral) | |
- "This is difficult to use for a new user": 35 (Negative) | |
- "The application crashed and I lost all my work!": 15 (Very negative) | |
For categorization, please use the current tags if applicable, but feel free to generate additional tags if necessary. Limit the total number of tags to 5. The current tags are ["remix", "D1"] - only choose from them if they are applicable to this issue. Don't use any of the following tags: ["cloudflare", "workers", "bug", "feature"]. | |
For the Feature Requests, provide both a tag name and a summary. Again, use the current tags if applicable, but feel free to generate additional tags if necessary. The current tags are ["database", "distributed"]. | |
For the Bug Reports, provide both a tag name and a summary. Again, use the current tags if applicable, but feel free to generate additional tags if necessary. The current tags are ["wrangler", "miniflare"]. | |
If no feature requests or bug reports are found, please return an empty arrays for those fields. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment