Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion raft/raft.py
Original file line number Diff line number Diff line change
Expand Up @@ -188,6 +188,7 @@ def encode_question_gen(question: str, chunk: Any) -> list[str]:
- First provide step-by-step reasoning on how to answer the question.
- In the reasoning, if you need to copy paste some sentences from the context, include them in ##begin_quote## and ##end_quote##. This would mean that things outside of ##begin_quote## and ##end_quote## are not directly copy paste from the context.
- End your response with final answer in the form <ANSWER>: $answer, the answer should be succinct.
You MUST begin your final answer with the tag "<ANSWER>:".
""".format(question=question, context=str(chunk))
prompts.append({"role": "system", "content": "You are a helpful question answerer who can provide an answer given a question and relevant context."})
prompts.append({"role": "user", "content": prompt})
Expand Down Expand Up @@ -375,4 +376,4 @@ def main():

if __name__ == "__main__":
with MDC(progress="0%"):
main()
main()