Spaces:
Sleeping
Sleeping
simonschoe
commited on
Commit
•
53e63bc
1
Parent(s):
75d5899
update app interface
Browse files
app.py
CHANGED
@@ -38,30 +38,32 @@ with app:
|
|
38 |
gr.Markdown("## Detect Transformation Sentences in Quarterly Earnings Conference Calls")
|
39 |
with gr.Row():
|
40 |
with gr.Column():
|
41 |
-
text_in = gr.Textbox(lines=1, placeholder="Insert text", label="
|
42 |
with gr.Row():
|
43 |
-
compute_bt = gr.Button("
|
44 |
-
score_out = gr.Number(label="
|
45 |
html_out = gr.HTML(label="Explanation")
|
46 |
with gr.Column():
|
47 |
gr.Markdown(
|
48 |
"""
|
49 |
#### Project Description
|
50 |
-
|
51 |
-
The model is trained on a large sample of quarterly earnings conference calls, held by U.S. firms during the 2006-2022 period. In particular, the training data is restriced to the (rather sponentous) executives' remarks of the Q&A section of the call. The data has been preprocessed prior to model training via stop word removal, lemmatization, named entity masking, and coocurrence modeling.
|
52 |
"""
|
53 |
)
|
54 |
gr.Markdown(
|
55 |
"""
|
56 |
#### App usage
|
57 |
-
The model is intented to be used for **
|
58 |
-
|
59 |
-
|
60 |
-
2. *Multi Search:* The input query may consist of several words or n-grams, seperated by comma, semi-colon or newline. It then computes the average vector over all inputs and performs semantic search based on the average input token.
|
61 |
"""
|
62 |
)
|
63 |
gr.Examples(
|
64 |
-
examples=[
|
|
|
|
|
|
|
|
|
65 |
inputs=[text_in],
|
66 |
outputs=[score_out, html_out],
|
67 |
fn=classify,
|
@@ -72,7 +74,7 @@ with app:
|
|
72 |
<p style="text-align: center;">
|
73 |
TIClassifier by X and Y
|
74 |
<br>
|
75 |
-
<img id="visitor-badge" alt="visitor badge" src="https://visitor-badge.glitch.me/badge?page_id=simonschoe.
|
76 |
</p>
|
77 |
"""
|
78 |
)
|
|
|
38 |
gr.Markdown("## Detect Transformation Sentences in Quarterly Earnings Conference Calls")
|
39 |
with gr.Row():
|
40 |
with gr.Column():
|
41 |
+
text_in = gr.Textbox(lines=1, placeholder="Insert text", label="Input Sentence")
|
42 |
with gr.Row():
|
43 |
+
compute_bt = gr.Button("Classify")
|
44 |
+
score_out = gr.Number(label="Score", interactive=False)
|
45 |
html_out = gr.HTML(label="Explanation")
|
46 |
with gr.Column():
|
47 |
gr.Markdown(
|
48 |
"""
|
49 |
#### Project Description
|
50 |
+
Placeholder
|
|
|
51 |
"""
|
52 |
)
|
53 |
gr.Markdown(
|
54 |
"""
|
55 |
#### App usage
|
56 |
+
The model is intented to be used for **sequence classification**: It encodes the input sentence (entered in the textbox on the left) in a dense vector space and runs it through a deep neural network classifier (*Distill-RoBERTa*).
|
57 |
+
It returns a confidence score that indicates the probability of the sentence containing a discussion on transformation activities. A value of 1 (0) signals a high confidence of the sentence being transformation-related (generic). A score in the range of [0.25; 0.75] implies that the model is rather undecided about the correct label.
|
58 |
+
In addition, the app returns the tokenized version of the sentence, alongside word importances that are indicated by color codes. Those visuals illustrates the ability of the context-aware classifier to simultaneously pay attention to various parts in the input sentence to derive a final label.
|
|
|
59 |
"""
|
60 |
)
|
61 |
gr.Examples(
|
62 |
+
examples=[
|
63 |
+
["If we look at the plans for 2018, it is to introduce 650 new products, which is an absolute all- time high."],
|
64 |
+
["We have been doing kind of an integrated campaign, so it's TV, online, we do the Google Ad Words - all those different elements together."],
|
65 |
+
["So that turned out to be beneficial for us, and I think, we'll just see how the market and interest rates move over the course of the year,"]
|
66 |
+
],
|
67 |
inputs=[text_in],
|
68 |
outputs=[score_out, html_out],
|
69 |
fn=classify,
|
|
|
74 |
<p style="text-align: center;">
|
75 |
TIClassifier by X and Y
|
76 |
<br>
|
77 |
+
<img id="visitor-badge" alt="visitor badge" src="https://visitor-badge.glitch.me/badge?page_id=simonschoe.TIC&left_color=green&right_color=blue" style="display: block; margin-left: auto; margin-right: auto;"/>
|
78 |
</p>
|
79 |
"""
|
80 |
)
|