Skip to content

Commit

Permalink
Merge pull request #98 from berkingurcan/update-prompt
Browse files Browse the repository at this point in the history
Update prompt
  • Loading branch information
berkingurcan authored Feb 21, 2025
2 parents 7160396 + 24decc8 commit faa8149
Show file tree
Hide file tree
Showing 4 changed files with 25 additions and 10 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -95,9 +95,9 @@ Resets the Redis database.
npm run reset
```

## Commands *(Deprecated)*
## Commands _(Deprecated)_

It still can be run with ```npm run commandBot```but no we have buttons UI for smooth user experience.
It still can be run with `npm run commandBot`but no we have buttons UI for smooth user experience.

### /gptsurvey create

Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "discord-bot",
"type": "module",
"version": "0.4.6",
"version": "0.4.7",
"description": "",
"main": "index.js",
"scripts": {
Expand Down
8 changes: 5 additions & 3 deletions src/adminUtils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -636,8 +636,8 @@ export const handleModals = async (interaction, client, redisClient) => {
channelId,
);
} else if (interaction.customId.startsWith("postRespondModal-")) {
await interaction.deferReply({ ephemeral: true });
await interaction.deferReply({ ephemeral: true });

const surveyName = interaction.customId.split("-").slice(1).join("-");
const channelId = interaction.fields.getTextInputValue("channelId");

Expand All @@ -649,7 +649,9 @@ export const handleModals = async (interaction, client, redisClient) => {
client,
);

await interaction.editReply("Done if there is no problem about the survey :)");
await interaction.editReply(
"Done if there is no problem about the survey :)",
);
} else if (interaction.customId.startsWith("viewPublicModal-")) {
const surveyName = interaction.customId.split("-").slice(1).join("-");
const channelId = interaction.fields.getTextInputValue("channelId");
Expand Down
21 changes: 17 additions & 4 deletions src/helpers/prompts.ts
Original file line number Diff line number Diff line change
Expand Up @@ -38,19 +38,33 @@ export const FEEDBACK_SUMMARIZE_PROMPT = (
feedbacks,
) =>
`
# INSTRUCTIONS:
You are an AI assistant that specializes in summarizing project proposals and their associated feedbacks.
Your task is to generate a concise and insightful summary for the given project proposals and especially
Your task is to generate a concise and clear summary for the given project proposals and especially
their feedbacks for Mina Ecosystem Funding program. You need to include all meaningful summarized feedbacks.
# WARNINGS:
- If the provided feedbacks are few or very brief,
summarize only what is present and refrain from generating extra strengths, concerns, or themes etc.
- So, you don't have to generate everything in the guideline.
- Do not add any assumptions or conclusions that are not directly supported by the feedback data.
- Only include insights that are explicitly mentioned in the provided feedbacks. Do not infer or generate.
# GIVEN DATA FORMAT:
You are given these datas to summarize:
- Proposal Name: ${proposalName}
- Description: ${proposalDescription}
- Author: ${proposalAuthor}
- Funding Round ID: ${fundingRoundId}
- Feedbacks: ${formatFeedbacks(feedbacks)}
Summary Guideline:
Your response should focus primarily on analyzing and summarizing the feedback.
# SUMMARY GUIDELINE:
Your response should focus primarily on analyzing and summarizing the feedbacks. You can include these points:
* Brief Proposal Summary: A 2-3 sentence summary explaining the core idea, objective, and significance of the proposal.
* Key Strengths (Based on Feedbacks): Highlight the main positive aspects of the proposal as mentioned by users.
* Main Concerns (Based on Feedbacks): Identify common criticisms, potential risks, or areas that need improvement.
Expand All @@ -59,5 +73,4 @@ Include insights such as usability concerns, technical feasibility, business pot
* Overall Sentiment: Determine whether the general sentiment is positive, neutral, or negative based on user feedback.
* Constructive Suggestions: If applicable, provide recommendations for improving the proposal.
* Edge Opinions: Include edge sentiments if you thinks it is meaningful as an great AI Agent.
`.trim();

0 comments on commit faa8149

Please sign in to comment.