Skip to content

Commit

Permalink
fix: added "atleast 1 corect answer" in multiple choices questions pr…
Browse files Browse the repository at this point in the history
…ompt
  • Loading branch information
3LL4N committed Dec 7, 2023
1 parent 1b54b87 commit d01ace6
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packages/api/src/functions/gptHandlers.ts
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ export const promptGenerators: {
maxCharsForQuestion = 100,
maxCharsForChoice = 68,
) =>
`Create a multiple choice question (maximum of ${maxCharsForQuestion} characters) about: "${message}" with ${numChoices} choices. Each choice must not exceed ${maxCharsForChoice} characters. Format as:
`Create a multiple choice question (maximum of ${maxCharsForQuestion} characters) about: "${message}" with ${numChoices} choices. Each choice must not exceed ${maxCharsForChoice} characters and there must be atleast 1 correct answer. Format as:
Question: [Your question here]
${generateChoicesPrompt(numChoices)}
Correct Answer: Option [Correct option number]
Expand Down Expand Up @@ -90,7 +90,7 @@ ${timeAndPointsPrompt}`,
maxCharsForQuestion = 100,
maxCharsForChoice = 68,
) =>
`Create a multiselect question (maximum of ${maxCharsForQuestion} characters) about: "${message}" with ${numChoices} choices. The choices must not exceed ${maxCharsForChoice} characters. Multiple answers can be correct. Format as:
`Create a multiselect question (maximum of ${maxCharsForQuestion} characters) about: "${message}" with ${numChoices} choices. The choices must not exceed ${maxCharsForChoice} characters and there must be atleast 1 correct answer. Multiple answers can be correct. Format as:
Question: [Your question here]
${generateChoicesPrompt(numChoices)}
Correct Answers: Options [Correct option numbers separated by commas, e.g., 1,3]
Expand Down

0 comments on commit d01ace6

Please sign in to comment.