Th3r0 commited on
Commit
5db0d3c
1 Parent(s): 61357d4

frontend visual updates

Browse files
Files changed (1) hide show
  1. app.py +114 -38
app.py CHANGED
@@ -6,7 +6,7 @@ def chat1(message,history):
6
  if message.startswith("how many"):
7
  response = ("1 to 10")
8
  else:
9
- response = ("whatever man")
10
 
11
  history.append((message, response))
12
  return history, history
@@ -31,23 +31,49 @@ with gr.Blocks(
31
  with gr.Row():
32
  gr.Markdown("<h1>Efficient Fine Tuning for Text Classification</h1>")
33
  with gr.Row():
34
- with gr.Column(scale=0.3):
35
- inp = gr.Textbox(placeholder="Prompt",label= "Enter Query")
36
- btn = gr.Button("Run")
37
  gr.Markdown("""
38
- <p>Model: Tiny Bert <br>
39
- NLP Task: Text Classification <br>
40
- Dataset: IMDB Movie review dataset for sentiment analysis</p>
41
- <p>insert information on training parameters here</p>
 
42
  """)
 
 
 
 
 
 
 
 
 
 
 
 
 
43
 
44
- with gr.Row():
45
- with gr.Column():
46
- out = gr.Textbox(label= " Untrained Model")
47
- with gr.Column():
 
 
 
 
 
48
  out1 = gr.Textbox(label= " Conventionaly Fine Tuned Model")
49
- with gr.Column():
50
- out2 = gr.Textbox(label= " LoRA fine Tuned Model")
 
 
 
 
 
 
 
 
 
51
 
52
  btn.click(fn=chat1, inputs=inp, outputs=out)
53
  btn.click(fn=chat1, inputs=inp, outputs=out1)
@@ -57,45 +83,95 @@ with gr.Blocks(
57
  with gr.Row():
58
  gr.Markdown("<h1>Efficient Fine Tuning for Natual Languae Infrencing</h1>")
59
  with gr.Row():
60
- with gr.Column(scale=0.3):
61
- inp = gr.Textbox(placeholder="Prompt",label= "Enter Query")
62
- btn = gr.Button("Run")
63
  gr.Markdown("""
64
- <p>Model: ELECTRA Bert Small <br>
65
- NLP Task: Natual Languae Infrencing <br>
66
- Dataset: Stanford Natural Language Inference Dataset</p>
 
67
  <p>insert information on training parameters here</p>
68
  """)
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
69
 
70
- with gr.Row():
71
- with gr.Column():
72
- out = gr.Textbox(label= " Untrained Model")
73
- with gr.Column():
74
  out1 = gr.Textbox(label= " Conventionaly Fine Tuned Model")
75
- with gr.Column():
76
- out2 = gr.Textbox(label= " LoRA fine Tuned Model")
 
 
 
 
 
 
 
 
 
77
 
78
  with gr.Tab("Sematic Text Similarity"):
79
  with gr.Row():
80
  gr.Markdown("<h1>Efficient Fine Tuning for Semantic Text Similarity</h1>")
81
  with gr.Row():
82
- with gr.Column(scale=0.3):
83
- inp = gr.Textbox(placeholder="Prompt",label= "Enter Query")
84
- btn = gr.Button("Run")
85
  gr.Markdown("""
86
- <p>Model: Tiny Bert <br>
87
- NLP Task: Text Classification <br>
88
- Dataset: IMDB Movie review dataset for sentiment analysis</p>
 
89
  <p>insert information on training parameters here</p>
90
  """)
 
 
 
 
 
 
 
 
 
 
 
 
91
 
92
- with gr.Row():
93
- with gr.Column():
94
- out = gr.Textbox(label= " Untrained Model")
95
- with gr.Column():
 
 
 
 
 
96
  out1 = gr.Textbox(label= " Conventionaly Fine Tuned Model")
97
- with gr.Column():
98
- out2 = gr.Textbox(label= " LoRA fine Tuned Model")
 
 
 
 
 
 
 
 
 
99
 
100
  with gr.Tab("More information"):
101
  gr.Markdown("stuff to add")
 
6
  if message.startswith("how many"):
7
  response = ("1 to 10")
8
  else:
9
+ response = ("whatever man whatever manwhatever manwhatever manwhatever manwhatever manwhatever manwhatever manwhatever manwhatever manwhatever manwhatever man")
10
 
11
  history.append((message, response))
12
  return history, history
 
31
  with gr.Row():
32
  gr.Markdown("<h1>Efficient Fine Tuning for Text Classification</h1>")
33
  with gr.Row():
34
+ with gr.Column(scale=0.3,variant="panel"):
 
 
35
  gr.Markdown("""
36
+ <h2>Specifciations</h2>
37
+ <p><b>Model:</b> Tiny Bert <br>
38
+ <b>Dataset:</b> IMDB Movie review dataset <br>
39
+ <b>NLP Task:</b> Text Classification</p>
40
+ <p>I don’t know why but I just enjoy doing this. Maybe it’s my way of dealing with stress or something but I just do it about once every week. Generally I’ll carry around a sack and creep around in a sort of crouch-walking position making goblin noises, then I’ll walk around my house and pick up various different “trinkets” and put them in my bag while saying stuff like “I’ll be having that” and laughing maniacally in my goblin voice (“trinkets” can include anything from shit I find on the ground to cutlery or other utensils). The other day I was talking with my neighbours and they mentioned hearing weird noises like what I wrote about and I was just internally screaming the entire conversation.</p>
41
  """)
42
+
43
+ with gr.Column(scale=0.3,variant="panel"):
44
+ inp = gr.Textbox(placeholder="Prompt",label= "Enter Query")
45
+ btn = gr.Button("Run")
46
+ gr.Examples(
47
+ [
48
+ "I thought this was a bit contrived",
49
+ "You would need to be a child to enjoy this",
50
+ "Drive more like Drive away",
51
+ ],
52
+ inp,
53
+ label="Try asking",
54
+ )
55
 
56
+ with gr.Column():
57
+ with gr.Row(variant="panel"):
58
+ out = gr.Textbox(label= " Untrained Model")
59
+ gr.Markdown("""<div>
60
+ <span><center><B>Training Information</B><center></span>
61
+ <span><br><br><br><br><br></span>
62
+ </div>""")
63
+
64
+ with gr.Row(variant="panel"):
65
  out1 = gr.Textbox(label= " Conventionaly Fine Tuned Model")
66
+ gr.Markdown("""<div>
67
+ <span><center><B>Training Information</B><center></span>
68
+ <span><br><br><br><br><br></span>
69
+ </div>""")
70
+
71
+ with gr.Row(variant="panel"):
72
+ out2 = gr.Textbox(label= " LoRA Fine Tuned Model")
73
+ gr.Markdown("""<div>
74
+ <span><center><B>Training Information</B><center></span>
75
+ <span><br><br><br><br><br></span>
76
+ </div>""")
77
 
78
  btn.click(fn=chat1, inputs=inp, outputs=out)
79
  btn.click(fn=chat1, inputs=inp, outputs=out1)
 
83
  with gr.Row():
84
  gr.Markdown("<h1>Efficient Fine Tuning for Natual Languae Infrencing</h1>")
85
  with gr.Row():
86
+ with gr.Column(scale=0.3, variant="panel"):
 
 
87
  gr.Markdown("""
88
+ <h2>Specifciations</h2>
89
+ <p><b>Model:</b> ELECTRA Bert Small <br>
90
+ <b>Dataset:</b> Stanford Natural Language Inference Dataset <br>
91
+ <b>NLP Task:</b> Natual Languae Infrencing</p>
92
  <p>insert information on training parameters here</p>
93
  """)
94
+ with gr.Column(scale=0.3,variant="panel"):
95
+ inp = gr.Textbox(placeholder="Prompt",label= "Enter Query")
96
+ btn = gr.Button("Run")
97
+ gr.Examples(
98
+ [
99
+ "I thought this was a bit contrived",
100
+ "You would need to be a child to enjoy this",
101
+ "Drive more like Drive away",
102
+ ],
103
+ inp,
104
+ label="Try asking",
105
+ )
106
+
107
+ with gr.Column():
108
+ with gr.Row(variant="panel"):
109
+ out = gr.Textbox(label= " Untrained Model")
110
+ gr.Markdown("""<div>
111
+ <span><center><B>Training Information</B><center></span>
112
+ <span><br><br><br><br><br></span>
113
+ </div>""")
114
 
115
+ with gr.Row(variant="panel"):
 
 
 
116
  out1 = gr.Textbox(label= " Conventionaly Fine Tuned Model")
117
+ gr.Markdown("""<div>
118
+ <span><center><B>Training Information</B><center></span>
119
+ <span><br><br><br><br><br></span>
120
+ </div>""")
121
+
122
+ with gr.Row(variant="panel"):
123
+ out2 = gr.Textbox(label= " LoRA Fine Tuned Model")
124
+ gr.Markdown("""<div>
125
+ <span><center><B>Training Information</B><center></span>
126
+ <span><br><br><br><br><br></span>
127
+ </div>""")
128
 
129
  with gr.Tab("Sematic Text Similarity"):
130
  with gr.Row():
131
  gr.Markdown("<h1>Efficient Fine Tuning for Semantic Text Similarity</h1>")
132
  with gr.Row():
133
+ with gr.Column(scale=0.3,variant="panel"):
 
 
134
  gr.Markdown("""
135
+ <h2>Specifciations</h2>
136
+ <p><b>Model:</b> DeBERTa-v3-xsmall <br>
137
+ <b>Dataset:</b> Quora Question Pairs dataset <br>
138
+ <b>NLP Task:</b> Semantic Text Similarity</p>
139
  <p>insert information on training parameters here</p>
140
  """)
141
+ with gr.Column(scale=0.3,variant="panel"):
142
+ inp = gr.Textbox(placeholder="Prompt",label= "Enter Query")
143
+ btn = gr.Button("Run")
144
+ gr.Examples(
145
+ [
146
+ "I thought this was a bit contrived",
147
+ "You would need to be a child to enjoy this",
148
+ "Drive more like Drive away",
149
+ ],
150
+ inp,
151
+ label="Try asking",
152
+ )
153
 
154
+ with gr.Column():
155
+ with gr.Row(variant="panel"):
156
+ out = gr.Textbox(label= " Untrained Model")
157
+ gr.Markdown("""<div>
158
+ <span><center><B>Training Information</B><center></span>
159
+ <span><br><br><br><br><br></span>
160
+ </div>""")
161
+
162
+ with gr.Row(variant="panel"):
163
  out1 = gr.Textbox(label= " Conventionaly Fine Tuned Model")
164
+ gr.Markdown("""<div>
165
+ <span><center><B>Training Information</B><center></span>
166
+ <span><br><br><br><br><br></span>
167
+ </div>""")
168
+
169
+ with gr.Row(variant="panel"):
170
+ out2 = gr.Textbox(label= " LoRA Fine Tuned Model")
171
+ gr.Markdown("""<div>
172
+ <span><center><B>Training Information</B><center></span>
173
+ <span><br><br><br><br><br></span>
174
+ </div>""")
175
 
176
  with gr.Tab("More information"):
177
  gr.Markdown("stuff to add")