Cristóbal Hernández commited on
Commit
a9b576d
·
1 Parent(s): a7c6e6a

Add application file

Browse files
Files changed (1) hide show
  1. app.py +14 -6
app.py CHANGED
@@ -136,14 +136,22 @@ demo = gr.Interface(fn=classify_output, inputs=txtbx, outputs=txtbxopt,
136
  title = 'EEMM Item Classification Machine V 0.5',
137
  description = """
138
 
139
- ¡Hello! This use two machine learning models to classify items and phrases into the EEMM grid. It will output a classification for dimensions as Cognition, Self, Affect, Motivation, Attention, Overt Behavior or Context. It Will also output levels as Social, Psychological or Physical.
140
-
141
- This is a proof of concept, so the model will not be perfect right away and may make some mistakes. **You can help us improve the models by flagging wrong answers**. Using the buttons below the output you can tell us the output lacks a category, or if levels and/or dimensions are wrong. When flagging, your item/phrase will be saved with your answer. We only save flagged items.
142
-
143
- **Please note that the machine goes idle after a period of inactivity.** If this occurs, waking it up may take around 20 seconds. Be patient ;)""",
 
 
 
 
 
 
 
 
144
  article = article_text,
145
  allow_flagging = 'manual',
146
- flagging_options = ['Wrong dimension/level','Lacks dimension/level', 'Wrong and lacking :('],
147
  flagging_callback= hf_writer
148
  )
149
  demo.launch()
 
136
  title = 'EEMM Item Classification Machine V 0.5',
137
  description = """
138
 
139
+ ¡Hello! This app showcases two machine learning models to classify items and phrases into the EEMM grid.
140
+ It will output a classification for dimensions as *Cognition, Self, Affect, Motivation, Attention, Overt Behavior or Context*. I
141
+ t Will also output levels as *Social, Psychological or Physical*.
142
+ You will also see the probability assigned by the model in parentheses (e.g: Affect (0.92))
143
+
144
+ This is a proof of concept, so the model will not be perfect right away and may make some mistakes.
145
+ **You can help us improve the models by flagging wrong answers**.
146
+ Using the buttons below the output you can tell us the output lacks a category,
147
+ if levels and/or dimensions are wrong, or if you want to tell us that the model did well. When flagging, your item/phrase will be saved with your answer.
148
+ Only flagged items will be saved for model improvement.
149
+
150
+ **Please note that the machine goes idle after a period of inactivity.**
151
+ If this occurs, waking it up may take around 20 seconds. Be patient ;)""",
152
  article = article_text,
153
  allow_flagging = 'manual',
154
+ flagging_options = ['wrong dimension/level','lacks dimension/level', 'wrong and lacking :(', 'spot on! :)'],
155
  flagging_callback= hf_writer
156
  )
157
  demo.launch()