Skip to content

Commit

Permalink
fix prompt
Browse files Browse the repository at this point in the history
  • Loading branch information
PHAN Xuan Quang committed Sep 12, 2024
1 parent f29b46d commit 55210e3
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 14 deletions.
24 changes: 12 additions & 12 deletions Entities/Enums/QuizzType.cs
Original file line number Diff line number Diff line change
Expand Up @@ -4,40 +4,40 @@ namespace Entities.Enums
{
public enum QuizzType
{
[Description("Chọn từ thích hợp nhất (Most Suitable Word)")]
[Description("Most Suitable Word (Chọn từ thích hợp nhất)")]
WordChoice = 1,

[Description("Chia động từ (Verb Conjugation)")]
[Description("Verb Conjugation (Chia động từ)")]
VerbConjugation = 2,

[Description("Câu điều kiện (Conditional Sentences)")]
[Description("Conditional Sentences (Câu điều kiện)")]
ConditionalSentences = 3,

[Description("Câu gián tiếp (Indirect Speech)")]
[Description("Indirect Speech (Câu gián tiếp)")]
IndirectSpeech = 4,

[Description("Điền vào chỗ trống (Sentence Completion)")]
[Description("Sentence Completion (Điền vào chỗ trống)")]
FillTheBlank = 5,

[Description("Đọc hiểu văn bản (Reading Comprehension)")]
[Description("Reading Comprehension (Đọc hiểu văn bản)")]
ReadingComprehension = 6,

[Description("Ngữ pháp (Grammar)")]
[Description("Grammar (Ngữ pháp)")]
Grammar = 7,

[Description("Phối hợp từ (Collocation)")]
[Description("Collocation (Phối hợp từ)")]
Collocations = 8,

[Description("Từ đồng nghĩa/trái nghĩa (Synonym/Antonym)")]
[Description("Synonym/Antonym (Từ đồng nghĩa/trái nghĩa)")]
SynonymAndAntonym = 9,

[Description("Từ vựng (Vocabulary)")]
[Description("Vocabulary (Từ vựng)")]
Vocabulary = 10,

[Description("Xác định lỗi sai (Error Identification)")]
[Description("Error Identification (Xác định lỗi sai)")]
ErrorIdentification = 11,

[Description("Chuyển đổi từ loại (Word Formation)")]
[Description("Word Formation (Chuyển đổi từ loại)")]
WordFormation = 12
}

Expand Down
4 changes: 2 additions & 2 deletions Events/QuizScope.cs
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ private static async Task<List<Quiz>> GenerateQuizesForLessThan15(string apiKey,
var userLevel = GeneralHelper.GetEnumDescription(level);
var types = string.Join(", ", quizzTypes.Select(t => GeneralHelper.GetEnumDescription(t)).ToList());

promptBuilder.AppendLine($"You are an English teacher with over 20 years of experience. My English level according to the CEFR standard is {userLevel}. ");
promptBuilder.AppendLine($"You are an English teacher with over 20 years of experience, you have worked in a Vietnamese high school for over 10 years. I am a Vietnamese whose English level according to the CEFR standard is {userLevel}. ");
promptBuilder.Append($"Please provide a set of multiple-choice English questions consisting of {questionsCount} to {questionsCount + 5} questions related to the topic '{topic.Trim()}' for practice. ");
promptBuilder.Append("The content of the questions should not exceed my English level. ");
promptBuilder.Append($"Each question in the quiz should have only 4 options with exactly 1 correct choice, and the quiz should be of the types: {types}");
Expand Down Expand Up @@ -128,7 +128,7 @@ private static async Task<List<Quiz>> GenerateQuizesByType(string apiKey, string
var userLevel = GeneralHelper.GetEnumDescription(level);
var type = GeneralHelper.GetEnumDescription(quizzType);

promptBuilder.AppendLine($"You are an English teacher with over 20 years of experience. My English level according to the CEFR standard is {userLevel}. ");
promptBuilder.AppendLine($"You are an English teacher with over 20 years of experience, you have worked in a Vietnamese high school for over 10 years. I am a Vietnamese whose English level according to the CEFR standard is {userLevel}. ");
promptBuilder.Append($"Please provide a set of multiple-choice English questions consisting of {questionsCount} to {questionsCount + 5} questions related to the topic '{topic.Trim()}' for practice. ");
promptBuilder.Append("The content of the questions should not exceed my English level. ");
promptBuilder.Append($"Each question in the quiz should have only 4 options with exactly 1 correct choice, and the type of the quizzes must be: {type}");
Expand Down

0 comments on commit 55210e3

Please sign in to comment.