benjaminBeuster commited on
Commit
fc9c42a
·
verified ·
1 Parent(s): 4650911

Upload app.py with huggingface_hub

Browse files
Files changed (1) hide show
  1. app.py +24 -7
app.py CHANGED
@@ -40,15 +40,32 @@ def classify_text(text):
40
 
41
  return output
42
 
43
- # Example questions
44
  examples = [
45
- ["What is your age?"],
46
- ["How satisfied are you with the healthcare system?"],
 
 
 
 
 
47
  ["Trust in country's parliament"],
48
- ["What is your highest level of education?"],
49
- ["How often do you pray?"],
50
- ["What is your occupation?"],
51
- ["Do you feel safe walking alone at night?"],
 
 
 
 
 
 
 
 
 
 
 
 
52
  ]
53
 
54
  # Create Gradio interface
 
40
 
41
  return output
42
 
43
+ # Example questions from actual ESS training data
44
  examples = [
45
+ # EDUCATION (most common - 146 samples)
46
+ ["What is the highest level of education you have successfully completed?"],
47
+ ["What is the highest level of education your mother successfully completed?"],
48
+
49
+ # POLITICS (100 samples)
50
+ ["Which party did you vote for in the last national election?"],
51
+ ["How likely are governments in enough countries to take action to reduce climate change?"],
52
  ["Trust in country's parliament"],
53
+
54
+ # HEALTH (90 samples)
55
+ ["How satisfied are you with the healthcare system?"],
56
+ ["Which health problems that you had in the last 12 months hampered you in your daily activities?"],
57
+
58
+ # LABOUR AND EMPLOYMENT (82 samples)
59
+ ["What best describes what you have been doing for the last 7 days - in paid work?"],
60
+ ["Which description best describes the sort of work your mother did when you were 14?"],
61
+
62
+ # SOCIETY AND CULTURE (73 samples)
63
+ ["How often do you pray apart from at religious services?"],
64
+ ["How important is it to always behave properly and avoid doing anything people would say is wrong?"],
65
+
66
+ # Additional examples
67
+ ["What is your age?"],
68
+ ["Do you feel safe walking alone at night in your local area?"],
69
  ]
70
 
71
  # Create Gradio interface