briankchan commited on
Commit
33741fc
·
1 Parent(s): f2608fd

Update body prompts; fix body description

Browse files
Files changed (1) hide show
  1. app.py +9 -7
app.py CHANGED
@@ -30,16 +30,18 @@ Score: X%. Feedback goes here.
30
  ---
31
  Intro paragraph:
32
  {content}"""
33
- BODY_PROMPT1 = """Complete the following tasks for the following essay paragraph:
34
- 1. Identify the topic sentence and determine whether it introduces an argument
35
- 2. Outline a bullet list of key points
36
- 3. Give a bullet list of parts of the paragraph that use quotes or other textual evidence from the book
37
 
38
  {content}"""
39
  BODY_PROMPT2 = """4. Give advice on how the topic sentence could be made stronger or clearer
40
  5. In a bullet list, state how each key point supports the topic (or if any doesn't support it)
41
- 6. In a bullet list for each textual evidence, state whether the evidence is based on the book or uses outside sources
42
- 7. Group the textual evidence from the book into different bullet lists based on which key point they support"""
 
 
43
 
44
  def load_chain(api_key):
45
  api_key = os.environ["OPENAI_API_KEY"] if api_key == "" or api_key.isspace() else api_key
@@ -241,7 +243,7 @@ with block:
241
  4. suggests topic sentence improvements
242
  5. checks that the outline matches the topic
243
  6. checks whether the quotes/evidence are from the book
244
- 7. checks which key points each piece of textual evidence""")
245
  submit_body = gr.Button(
246
  value="Run"
247
  ).style(full_width=False)
 
30
  ---
31
  Intro paragraph:
32
  {content}"""
33
+ BODY_PROMPT1 = """You are a university English teacher. Complete the following tasks for the following essay paragraph about a book:
34
+ 1. Topic sentence: Identify the topic sentence and determine whether it introduces an argument
35
+ 2. Key points: Outline a bullet list of key points
36
+ 3. Textual evidence: Give a bullet list of parts of the paragraph that use quotes or other textual evidence from the book
37
 
38
  {content}"""
39
  BODY_PROMPT2 = """4. Give advice on how the topic sentence could be made stronger or clearer
40
  5. In a bullet list, state how each key point supports the topic (or if any doesn't support it)
41
+ 6. In a bullet list for each textual evidence, state if the evidence is an event/detail from the book, or if it's from outside sources
42
+ 7. In a bullet list for each textual evidence, state which key point the evidence supports.
43
+ """
44
+ # 7. Make a section for each key point. In each section, make a bullet list of textual evidence from task 3 that relate to that key point.
45
 
46
  def load_chain(api_key):
47
  api_key = os.environ["OPENAI_API_KEY"] if api_key == "" or api_key.isspace() else api_key
 
243
  4. suggests topic sentence improvements
244
  5. checks that the outline matches the topic
245
  6. checks whether the quotes/evidence are from the book
246
+ 7. determines which key point from the outline that each textual evidence supports""")
247
  submit_body = gr.Button(
248
  value="Run"
249
  ).style(full_width=False)