Spaces:
Running
on
Zero
Running
on
Zero
Trying "agentica-org/DeepScaleR-1.5B-Preview"
Browse files
app.py
CHANGED
@@ -13,7 +13,7 @@ from PIL import Image, ImageDraw, ImageFont
|
|
13 |
|
14 |
def generate_script(topic):
|
15 |
"""Uses an open-source LLM to generate an engaging script of 8-10 minutes."""
|
16 |
-
llm = pipeline("text-generation", model="
|
17 |
prompt = (f"Write an engaging and informative script on the topic '{topic}'. "
|
18 |
"The text should take about 8-10 minutes to read aloud at a normal pace.")
|
19 |
response = llm(prompt, max_length=1500, do_sample=True, temperature=0.7)
|
@@ -139,7 +139,7 @@ with gr.Blocks() as demo:
|
|
139 |
file_input = gr.File(label="Or upload a .txt file")
|
140 |
image_size_input = gr.Radio(choices=["640x480", "800x600", "1024x768"], label="Select Image Size", value="640x480")
|
141 |
use_diffusion_input = gr.Checkbox(label="Use Diffusion Images", value=True)
|
142 |
-
num_steps_input = gr.Slider(minimum=1, maximum=50, step=1, value=
|
143 |
process_btn = gr.Button("Generate Video")
|
144 |
output_video = gr.Video()
|
145 |
|
|
|
13 |
|
14 |
def generate_script(topic):
|
15 |
"""Uses an open-source LLM to generate an engaging script of 8-10 minutes."""
|
16 |
+
llm = pipeline("text-generation", model="agentica-org/DeepScaleR-1.5B-Preview")
|
17 |
prompt = (f"Write an engaging and informative script on the topic '{topic}'. "
|
18 |
"The text should take about 8-10 minutes to read aloud at a normal pace.")
|
19 |
response = llm(prompt, max_length=1500, do_sample=True, temperature=0.7)
|
|
|
139 |
file_input = gr.File(label="Or upload a .txt file")
|
140 |
image_size_input = gr.Radio(choices=["640x480", "800x600", "1024x768"], label="Select Image Size", value="640x480")
|
141 |
use_diffusion_input = gr.Checkbox(label="Use Diffusion Images", value=True)
|
142 |
+
num_steps_input = gr.Slider(minimum=1, maximum=50, step=1, value=40, label="Diffusion Model Steps")
|
143 |
process_btn = gr.Button("Generate Video")
|
144 |
output_video = gr.Video()
|
145 |
|