Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
|
@@ -147,10 +147,6 @@ def chat(message, history):
|
|
| 147 |
yield generated_text_without_prompt
|
| 148 |
|
| 149 |
CSS ="""
|
| 150 |
-
.contain { display: flex; flex-direction: column;
|
| 151 |
-
height: 200%; /* Tăng chiều cao của container gấp đôi */
|
| 152 |
-
}
|
| 153 |
-
#component-0 { height: 100%; }
|
| 154 |
#component-4 {
|
| 155 |
height: 30dvh !important;
|
| 156 |
transform-origin: top; /* Đảm bảo rằng phần tử mở rộng từ trên xuống */
|
|
@@ -162,14 +158,15 @@ CSS ="""
|
|
| 162 |
}
|
| 163 |
"""
|
| 164 |
|
| 165 |
-
|
| 166 |
-
|
| 167 |
-
|
| 168 |
-
|
| 169 |
-
|
| 170 |
-
|
| 171 |
-
|
| 172 |
-
|
| 173 |
-
|
| 174 |
-
|
|
|
|
| 175 |
demo.queue().launch()
|
|
|
|
| 147 |
yield generated_text_without_prompt
|
| 148 |
|
| 149 |
CSS ="""
|
|
|
|
|
|
|
|
|
|
|
|
|
| 150 |
#component-4 {
|
| 151 |
height: 30dvh !important;
|
| 152 |
transform-origin: top; /* Đảm bảo rằng phần tử mở rộng từ trên xuống */
|
|
|
|
| 158 |
}
|
| 159 |
"""
|
| 160 |
|
| 161 |
+
|
| 162 |
+
demo = gr.ChatInterface(
|
| 163 |
+
fn=chat,
|
| 164 |
+
description="""Try [Vintern-1B](https://huggingface.co/5CD-AI/Viet-InternVL2-1B) in this demo. Vintern 1B is a multimodal large language model series, featuring models of various sizes. For each size, we release instruction-tuned models optimized for multimodal tasks. Vintern-1B consists of [InternViT-300M-448px](https://huggingface.co/OpenGVLab/InternViT-300M-448px), an MLP projector, and [Qwen2-0.5B-Instruct](https://huggingface.co/Qwen/Qwen2-0.5B-Instruct).""",
|
| 165 |
+
examples=[{"text": "Mô tả hình ảnh.", "files":["./demo_3.jpg"]},
|
| 166 |
+
{"text": "Trích xuất các thông tin từ ảnh.", "files":["./demo_1.jpg"]},
|
| 167 |
+
{"text": "Mô tả hình ảnh một cách chi tiết.", "files":["./demo_2.jpg"]}],
|
| 168 |
+
title="❄️ Vintern-1B ❄️",
|
| 169 |
+
multimodal=True,
|
| 170 |
+
css=CSS
|
| 171 |
+
)
|
| 172 |
demo.queue().launch()
|