Spaces:
Runtime error
Runtime error
File size: 574 Bytes
3eb63d1 62858fa 3eb63d1 3efd7d2 0c8c4f5 3efd7d2 0c8c4f5 c13a07b 0c8c4f5 319b4d3 0010001 8a97208 0010001 eb443cd 4789c94 c928ad3 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 |
from gpt4all import GPT4All
import gradio as gr
# Specify the local path to the downloaded model file
model_path = "wizardlm-13b-v1.1-superhot-8k.ggmlv3.q4_0.bin"
# Initialize the model using the local path
model = GPT4All(model_path)
def generate_text(prompt):
result = model.generate(prompt)
return result
text_generation_interface = gr.Interface(
fn=generate_text,
inputs=[
gr.inputs.Textbox(label="Input Text"),
],
outputs=gr.outputs.Textbox(label="Generated Text"),
title="GPT-4 Text Generation",
).launch()
# model_name = ""
|