45 lines
1.8 KiB
Python
45 lines
1.8 KiB
Python
from typing import List, Dict
|
|
|
|
|
|
def get_writing_args_general(task: int, topic: str, difficulty: str) -> List[Dict]:
|
|
writing_args = {
|
|
"1": {
|
|
"prompt": (
|
|
'Craft a prompt for an IELTS Writing Task 1 General Training exercise that instructs the '
|
|
'student to compose a letter. The prompt should present a specific scenario or situation, '
|
|
f'based on the topic of "{topic}", requiring the student to provide information, '
|
|
'advice, or instructions within the letter. Make sure that the generated prompt is '
|
|
f'of {difficulty} CEFR level difficulty and does not contain forbidden subjects in muslim countries.'
|
|
),
|
|
"instructions": (
|
|
'The prompt should end with "In the letter you should" followed by 3 bullet points of what '
|
|
'the answer should include.'
|
|
)
|
|
},
|
|
"2": {
|
|
# TODO: Should the muslim disclaimer be here as well?
|
|
"prompt": (
|
|
f'Craft a comprehensive question of {difficulty} CEFR level difficulty like the ones for IELTS '
|
|
'Writing Task 2 General Training that directs the candidate to delve into an in-depth '
|
|
f'analysis of contrasting perspectives on the topic of "{topic}".'
|
|
),
|
|
"instructions": (
|
|
'The question should lead to an answer with either "theories", "complicated information" or '
|
|
'be "very descriptive" on the topic.'
|
|
)
|
|
}
|
|
}
|
|
|
|
messages = [
|
|
{
|
|
"role": "user",
|
|
"content": writing_args[str(task)]["prompt"]
|
|
},
|
|
{
|
|
"role": "user",
|
|
"content": writing_args[str(task)]["instructions"]
|
|
}
|
|
]
|
|
|
|
return messages
|