tutrinh commited on
Commit
17af118
·
1 Parent(s): 8996f4d

add examples and test

Browse files
Files changed (2) hide show
  1. app.py +4 -1
  2. examples.txt +11 -0
app.py CHANGED
@@ -43,7 +43,10 @@ if user_input:
43
  coding_inst_lines = f.readlines()
44
  coding_inst = " ".join(line.strip() for line in coding_inst_lines)
45
  question = "\n\nWhere does the following passage fall on the aforementioned scale? Explain your reasoning first, then give your answer in the form DIGNITY INDEX: [SCORE], where SCORE is an integer between 1 and 8. It is imperative that you follow this response structure. Passage:\n"
46
- full_input = coding_inst + question + user_input
 
 
 
47
 
48
  #with st.spinner("Running model 1....."):
49
  # model1 = "mistral-7b-instruct.gold-medium-n10-d00-lr25.231124-222719"
 
43
  coding_inst_lines = f.readlines()
44
  coding_inst = " ".join(line.strip() for line in coding_inst_lines)
45
  question = "\n\nWhere does the following passage fall on the aforementioned scale? Explain your reasoning first, then give your answer in the form DIGNITY INDEX: [SCORE], where SCORE is an integer between 1 and 8. It is imperative that you follow this response structure. Passage:\n"
46
+ with open("./examples.txt", "r") as f:
47
+ examples = f.read().strip()
48
+ full_input = coding_inst + "\n\n" + examples + question + user_input
49
+ st.write(full_input)
50
 
51
  #with st.spinner("Running model 1....."):
52
  # model1 = "mistral-7b-instruct.gold-medium-n10-d00-lr25.231124-222719"
examples.txt ADDED
@@ -0,0 +1,11 @@
 
 
 
 
 
 
 
 
 
 
 
 
1
+ Here are some example passages being ranked on the scale; their dignity index score is at the end in the format DIGNITY INDEX: [SCORE].
2
+ Passage: "JOE BIDEN IS NOT LEADING FROM BEHIND, HE IS NOT LEADING AT ALL. ON HIS WATCH, A TERRORIST MOB CONQUERED AFGHANISTAN AND KILLED OUR TROOPS. IRAN IS ON THE BRINK OF GETTING THE BOMB. NORTH KOREA IS LAUNCHING MORE MISSILES THAN EVER. RUSSIA STARTED THE BIGGEST WAR IN EUROPE IN 75 YEARS, ENDED COMMUNIST CHINA WE FACE THE STRONGEST AND MOST DISCIPLINED ENEMY IN HISTORY. IT IS UNTHINKABLE THAT AMERICANS WOULD LOOK AT THE SKY AND SEE A CHINESE SPY BALLOON LOOKING BACK AT US. CHINA'S DICTATORS WANT TO COVER THE WORLD IN COMMUNIST TYRANNY. WE ARE THE ONLY ONES WHO CAN STOP THEM. LET ME BE CLEAR. WE WILL NOT WIN THE FIGHT FOR THE 21ST CENTURY IF WE KEEP TRUSTING POLITICIANS FROM THE 20TH CENTURY. [APPLAUSE] AMERICA IS ON A PATH OF DOUBT, DIVISION, AND SELF-DESTRUCTION. A PATH OF VAGUE PATRIOTISM AND WEAKENING POWER. THE STAKES ARE NOTHING LESS THAN OUR SURVIVAL."
3
+ Explanation and score: "The stakes are nothing less than our survival" implies a strong "us OR them" sentiment. Biden is not leading at all, he is allowing all this evil forces to overcome us. The beginning of this read as a 4 to me, but the end is so starkly us or them and assigning that fault to the other side. That makes it a 2. DIGNITY INDEX: 2
4
+ ---
5
+ Passage: "After the harvest they gathered their families together and joined in celebration and prayer with the native Americans who had taught them so much. Clearly our forefathers were thankful not only for the material well-being of their harvest but for this abundance of goodwill as well."
6
+ Explanation and score: Regan makes a dignified statement on the significance of thanksgiving. He praises two groups of people in woking together and finding common interests. DIGNITY INDEX: 6
7
+ ---
8
+ Passage: "Every small business owner and every family in our country is feeling the corrosive hidden tax on their lives driven by the Biden induced inflation."
9
+ Explanation and score: This is a direct attack on competence and performance. This tax has been a failure, it is hurting us. DIGNITY INDEX: 4
10
+ ---
11
+