rollback to non-shap
Browse files
app.py
CHANGED
@@ -44,17 +44,17 @@ def shap(txt, tok_level):
|
|
44 |
return list(zip(tokens, labels))
|
45 |
# return txt
|
46 |
|
47 |
-
demo = gr.Interface(
|
48 |
[
|
49 |
gr.Textbox(label="기사", lines=30, placeholder="기사를 입력하세요."),
|
50 |
-
gr.Radio(choices=["sentence", "word"], label="해설 표시 단위", value="sentence", info="문장 단위의 해설은 sentence를, 단어 단위의 해설은 word를 선택하세요.")
|
51 |
],
|
52 |
-
|
53 |
-
gr.HighlightedText(
|
54 |
-
|
55 |
-
|
56 |
-
|
57 |
-
|
58 |
theme=gr.themes.Base())
|
59 |
|
60 |
demo.launch()
|
|
|
44 |
return list(zip(tokens, labels))
|
45 |
# return txt
|
46 |
|
47 |
+
demo = gr.Interface(model,
|
48 |
[
|
49 |
gr.Textbox(label="기사", lines=30, placeholder="기사를 입력하세요."),
|
50 |
+
# gr.Radio(choices=["sentence", "word"], label="해설 표시 단위", value="sentence", info="문장 단위의 해설은 sentence를, 단어 단위의 해설은 word를 선택하세요.")
|
51 |
],
|
52 |
+
gr.Textbox(label="Slant Scores"),
|
53 |
+
#gr.HighlightedText(
|
54 |
+
# label="Diff",
|
55 |
+
# combine_adjacent=True,
|
56 |
+
# show_legend=True,
|
57 |
+
# color_map={"+": "red", "-": "green"}),
|
58 |
theme=gr.themes.Base())
|
59 |
|
60 |
demo.launch()
|