diff --git a/README.md b/README.md index 2b7a6a3..43ea2f8 100644 --- a/README.md +++ b/README.md @@ -26,6 +26,9 @@ Experience the CogVideoX-5B model online at + LLM + FLUX + CogVideoX-I2V Space 🤗 + + """) + with gr.Row(): + with gr.Column(): + prompt = gr.Textbox(label="Prompt", placeholder="Enter your prompt here", lines=5) + generate_caption_button = gr.Button("Generate Caption") + caption = gr.Textbox(label="Caption", placeholder="Caption will appear here", lines=5) + generate_image_button = gr.Button("Generate Image") + image_output = gr.Image(label="Generated Image") + state_image = gr.State() + generate_caption_button.click(fn=generate_caption, inputs=prompt, outputs=caption) + generate_image_button.click(fn=generate_image, inputs=caption, outputs=[image_output, state_image]) + with gr.Column(): + video_output = gr.Video(label="Generated Video", width=720, height=480) + download_video_button = gr.File(label="📥 Download Video", visible=False) + download_gif_button = gr.File(label="📥 Download GIF", visible=False) + generate_video_button = gr.Button("Generate Video from Image") + generate_video_button.click(fn=generate_video, inputs=[caption, state_image], + outputs=[video_output, download_gif_button]) + +if __name__ == "__main__": + demo.launch()