Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -79,7 +79,7 @@ class ThreadManager:
|
|
79 |
|
80 |
|
81 |
def respond(prompt, max_tokens):
|
82 |
-
print(prompt)
|
83 |
|
84 |
streamer = TextIteratorStreamer(
|
85 |
tokenizer, skip_prompt=True, skip_special_tokens=True
|
@@ -104,7 +104,7 @@ def respond(prompt, max_tokens):
|
|
104 |
for output in streamer:
|
105 |
if not output:
|
106 |
continue
|
107 |
-
print(output)
|
108 |
response += output
|
109 |
yield response, gr.update(interactive=False), gr.update(interactive=False),
|
110 |
yield (
|
@@ -125,7 +125,7 @@ def no_interactive():
|
|
125 |
with gr.Blocks() as demo:
|
126 |
gr.HTML("""<h1 align="center">plamo-2-1b CPU demo</h1>""")
|
127 |
gr.Markdown(
|
128 |
-
"2 vCPU, 16 GB RAMでのデモです。
|
129 |
)
|
130 |
with gr.Column(elem_id="col_container") as main_block:
|
131 |
with gr.Row():
|
|
|
79 |
|
80 |
|
81 |
def respond(prompt, max_tokens):
|
82 |
+
# print(prompt)
|
83 |
|
84 |
streamer = TextIteratorStreamer(
|
85 |
tokenizer, skip_prompt=True, skip_special_tokens=True
|
|
|
104 |
for output in streamer:
|
105 |
if not output:
|
106 |
continue
|
107 |
+
# print(output)
|
108 |
response += output
|
109 |
yield response, gr.update(interactive=False), gr.update(interactive=False),
|
110 |
yield (
|
|
|
125 |
with gr.Blocks() as demo:
|
126 |
gr.HTML("""<h1 align="center">plamo-2-1b CPU demo</h1>""")
|
127 |
gr.Markdown(
|
128 |
+
"2 vCPU, 16 GB RAMでのデモです。10年前くらいのノートパソコンくらい。(GPUなしのHF中国镜像站の無料インスタンスで動いています。)vllmとかllama.cppが対応すればもっと高速に動くはず。"
|
129 |
)
|
130 |
with gr.Column(elem_id="col_container") as main_block:
|
131 |
with gr.Row():
|