Browse Source

Merge pull request #3680 from digger-yu/digger-yu-patch-2

fix spelling error with applications/Chat/evaluate/
pull/3688/head
Tong Li 2 years ago committed by GitHub
parent
commit
b36e67cb2b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 2
      applications/Chat/evaluate/evaluate.py
  2. 2
      applications/Chat/evaluate/generate_gpt35_answers.py

2
applications/Chat/evaluate/evaluate.py

@ -130,7 +130,7 @@ def evaluate(args):
assert answer1_jsons[i]['id'] == answer2_jsons[i]['id']
answer_id = answer1_jsons[i]['id']
ques = answer1_jsons[i]['instruction'] if answer1_jsons[i]['input'] == "" else answer1_jsons[i]['instuction'] + \
ques = answer1_jsons[i]['instruction'] if answer1_jsons[i]['input'] == "" else answer1_jsons[i]['instruction'] + \
" " + answer1_jsons[i]['input']
cat = answer1_jsons[i]['category']
ans1 = answer1_jsons[i]['output']

2
applications/Chat/evaluate/generate_gpt35_answers.py

@ -35,7 +35,7 @@ logger = logging.getLogger(__name__)
def get_answer(question: str, max_tokens: int):
answer = question
prompt = question['instruction'] if question['input'] == "" else question['instuction'] + \
prompt = question['instruction'] if question['input'] == "" else question['instruction'] + \
" " + question['input']
for _ in range(MAX_API_RETRY):
try:

Loading…
Cancel
Save