samagra14wefi commited on
Commit
0f685c5
1 Parent(s): 9696018

Replace asserts with print

Browse files
Files changed (1) hide show
  1. README.md +8 -8
README.md CHANGED
@@ -55,13 +55,13 @@ context_string = '''India won the world cup in 1983 and 2011. Australia won the
55
  West Indies have won the world cup twice. Sri Lanka, Pakistan and England have won the world cup once.
56
  Evaluate if the facts below are consistent with the statement.'''
57
 
58
- response_string_one = '''India has won the world cup most number of times.'''
59
- response_string_two = '''Australia has won the world cup most number of times.'''
60
 
61
- score_one = calc_score(context_string, response_string_one)
62
- score_two = calc_score(context_string, response_string_two)
63
 
64
- assert score_two > score_one
65
  ```
66
 
67
  ### Evaluating Response relevance
@@ -75,7 +75,7 @@ response_bad = "We offer a variety of fresh produce including apples, oranges, a
75
  score_good = calc_score(inquiry, response_good)
76
  score_bad = calc_score(inquiry, response_bad)
77
 
78
- assert score_good > score_bad
79
 
80
  ```
81
 
@@ -89,7 +89,7 @@ response_offensive = "The politicians in Country X are all corrupt and stupid."
89
  score_clean = calc_score(context, response_clean)
90
  score_offensive = calc_score(context, response_offensive)
91
 
92
- assert score_clean > score_offensive
93
  ```
94
 
95
  ### Comparing Different Language Models
@@ -102,7 +102,7 @@ response_bert = "Photosynthesis is a method that converts carbon dioxide into or
102
  score_gpt3 = calc_score(context, response_gpt3)
103
  score_bert = calc_score(context, response_bert)
104
 
105
- assert score_gpt3 > score_bert
106
  ```
107
 
108
  ## Finetuning on your production data
 
55
  West Indies have won the world cup twice. Sri Lanka, Pakistan and England have won the world cup once.
56
  Evaluate if the facts below are consistent with the statement.'''
57
 
58
+ response_string_wrong = '''India has won the world cup most number of times.'''
59
+ response_string_correct = '''Australia has won the world cup most number of times.'''
60
 
61
+ score_wrong = calc_score(context_string, response_string_one)
62
+ score_correct = calc_score(context_string, response_string_two)
63
 
64
+ print(score_wrong > score_correct)
65
  ```
66
 
67
  ### Evaluating Response relevance
 
75
  score_good = calc_score(inquiry, response_good)
76
  score_bad = calc_score(inquiry, response_bad)
77
 
78
+ print(score_good > score_bad)
79
 
80
  ```
81
 
 
89
  score_clean = calc_score(context, response_clean)
90
  score_offensive = calc_score(context, response_offensive)
91
 
92
+ print(score_clean > score_offensive)
93
  ```
94
 
95
  ### Comparing Different Language Models
 
102
  score_gpt3 = calc_score(context, response_gpt3)
103
  score_bert = calc_score(context, response_bert)
104
 
105
+ print(score_gpt3 > score_bert)
106
  ```
107
 
108
  ## Finetuning on your production data