Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -4,7 +4,35 @@ from sentence_transformers import SentenceTransformer
|
|
| 4 |
import torch
|
| 5 |
import gradio as gr
|
| 6 |
import random
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 7 |
|
|
|
|
| 8 |
# Making requests to the model to generate responses:
|
| 9 |
client = InferenceClient('Qwen/Qwen2.5-72B-Instruct')
|
| 10 |
|
|
|
|
| 4 |
import torch
|
| 5 |
import gradio as gr
|
| 6 |
import random
|
| 7 |
+
#beginning of copilot
|
| 8 |
+
import gradio as gr
|
| 9 |
+
|
| 10 |
+
css = """
|
| 11 |
+
/* Style the checkbox itself */
|
| 12 |
+
input[type="checkbox"] {
|
| 13 |
+
border-color: red; /* Change border color */
|
| 14 |
+
background-color: yellow; /* Change background color (for the unchecked state) */
|
| 15 |
+
}
|
| 16 |
+
|
| 17 |
+
/* Style the checkbox when it's checked */
|
| 18 |
+
input[type="checkbox"]:checked {
|
| 19 |
+
background-color: green; /* Change background color when checked */
|
| 20 |
+
border-color: darkgreen;
|
| 21 |
+
}
|
| 22 |
+
|
| 23 |
+
/* You might also need to style the checkmark itself using pseudo-elements */
|
| 24 |
+
input[type="checkbox"]:checked::before {
|
| 25 |
+
content: "✔"; /* Add a checkmark symbol */
|
| 26 |
+
color: white; /* Color of the checkmark */
|
| 27 |
+
}
|
| 28 |
+
"""
|
| 29 |
+
|
| 30 |
+
with gr.Blocks(css=css) as demo:
|
| 31 |
+
gr.Checkbox(label="My Checkbox")
|
| 32 |
+
demo.launch()
|
| 33 |
+
|
| 34 |
|
| 35 |
+
#end of copilot
|
| 36 |
# Making requests to the model to generate responses:
|
| 37 |
client = InferenceClient('Qwen/Qwen2.5-72B-Instruct')
|
| 38 |
|