Spaces:
Sleeping
Sleeping
app.py
CHANGED
@@ -21,7 +21,6 @@ def extract_json(gen_text, n_shot_learning=0):
|
|
21 |
return gen_text[start_index:end_index]
|
22 |
|
23 |
def score_model(model_uri, databricks_token, prompt):
|
24 |
-
prompt = "Korea is a"
|
25 |
ds_dict={
|
26 |
"model": "debisoft/mpt-7b-awq-tester",
|
27 |
"prompt": prompt,
|
@@ -128,5 +127,5 @@ Give a score for the product. Format your response as a JSON object with \
|
|
128 |
#iface.launch()
|
129 |
|
130 |
#iface = gr.Interface(fn=greet, inputs=[gr.Textbox(label="Text to find entities", lines=2)], outputs=[gr.HighlightedText(label="Text with entities")], title="NER with dslim/bert-base-NER", description="Find entities using the `dslim/bert-base-NER` model under the hood!", allow_flagging="never", examples=["My name is Andrew and I live in California", "My name is Poli and work at HuggingFace"])
|
131 |
-
iface = gr.Interface(fn=greet, inputs=[gr.Textbox(label="Elevator pitch", lines=3)], outputs="
|
132 |
iface.launch()
|
|
|
21 |
return gen_text[start_index:end_index]
|
22 |
|
23 |
def score_model(model_uri, databricks_token, prompt):
|
|
|
24 |
ds_dict={
|
25 |
"model": "debisoft/mpt-7b-awq-tester",
|
26 |
"prompt": prompt,
|
|
|
127 |
#iface.launch()
|
128 |
|
129 |
#iface = gr.Interface(fn=greet, inputs=[gr.Textbox(label="Text to find entities", lines=2)], outputs=[gr.HighlightedText(label="Text with entities")], title="NER with dslim/bert-base-NER", description="Find entities using the `dslim/bert-base-NER` model under the hood!", allow_flagging="never", examples=["My name is Andrew and I live in California", "My name is Poli and work at HuggingFace"])
|
130 |
+
iface = gr.Interface(fn=greet, inputs=[gr.Textbox(label="Elevator pitch", lines=3)], outputs="json")
|
131 |
iface.launch()
|