replace textbox with quicksearch component
Browse files
app.py
CHANGED
@@ -1,5 +1,6 @@
|
|
1 |
import gradio as gr
|
2 |
import yaml
|
|
|
3 |
|
4 |
MARKDOWN_DESCRIPTION = """
|
5 |
# mergekit config.yaml generator
|
@@ -53,7 +54,12 @@ with gr.Blocks() as demo:
|
|
53 |
gr.Markdown(MARKDOWN_DESCRIPTION)
|
54 |
with gr.Row():
|
55 |
# model_name_input = gr.Textbox(label="Model Name", value="my-merge")
|
56 |
-
model1_input =
|
|
|
|
|
|
|
|
|
|
|
57 |
model1_layers_input = gr.Textbox(
|
58 |
label="Model 1 Layer Range", placeholder="[start, end]", value="[0, 32]"
|
59 |
)
|
@@ -63,6 +69,12 @@ with gr.Blocks() as demo:
|
|
63 |
model2_layers_input = gr.Textbox(
|
64 |
label="Model 2 Layer Range", placeholder="[start, end]", value="[0, 32]"
|
65 |
)
|
|
|
|
|
|
|
|
|
|
|
|
|
66 |
merge_method_input = gr.Dropdown(
|
67 |
label="Merge Method", choices=["slerp", "linear"], value="slerp"
|
68 |
)
|
@@ -95,4 +107,4 @@ with gr.Blocks() as demo:
|
|
95 |
|
96 |
gr.Markdown("A Space by [1littlecoder](https://huggingface.co/1littlecoder)")
|
97 |
|
98 |
-
demo.launch()
|
|
|
1 |
import gradio as gr
|
2 |
import yaml
|
3 |
+
from gradio_huggingfacehub_search import HuggingfaceHubSearch
|
4 |
|
5 |
MARKDOWN_DESCRIPTION = """
|
6 |
# mergekit config.yaml generator
|
|
|
54 |
gr.Markdown(MARKDOWN_DESCRIPTION)
|
55 |
with gr.Row():
|
56 |
# model_name_input = gr.Textbox(label="Model Name", value="my-merge")
|
57 |
+
model1_input = HuggingfaceHubSearch(
|
58 |
+
label="Model 1",
|
59 |
+
placeholder="Search for model 1 on Huggingface",
|
60 |
+
search_type="model",
|
61 |
+
value="BioMistral/BioMistral-7B"
|
62 |
+
)
|
63 |
model1_layers_input = gr.Textbox(
|
64 |
label="Model 1 Layer Range", placeholder="[start, end]", value="[0, 32]"
|
65 |
)
|
|
|
69 |
model2_layers_input = gr.Textbox(
|
70 |
label="Model 2 Layer Range", placeholder="[start, end]", value="[0, 32]"
|
71 |
)
|
72 |
+
model2_input = HuggingfaceHubSearch(
|
73 |
+
label="Model 2",
|
74 |
+
placeholder="Search for model 2 on Huggingface",
|
75 |
+
search_type="model",
|
76 |
+
value="CorticalStack/pastiche-crown-clown-7b-dare-dpo"
|
77 |
+
)
|
78 |
merge_method_input = gr.Dropdown(
|
79 |
label="Merge Method", choices=["slerp", "linear"], value="slerp"
|
80 |
)
|
|
|
107 |
|
108 |
gr.Markdown("A Space by [1littlecoder](https://huggingface.co/1littlecoder)")
|
109 |
|
110 |
+
demo.launch()
|