Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -105,7 +105,7 @@ chat_model = ChatHuggingFace(llm=llm)
|
|
105 |
"""
|
106 |
|
107 |
|
108 |
-
with gr.Blocks(theme=gr.themes.Soft(text_size='lg', font=["monospace"], primary_hue=gr.themes.colors.green
|
109 |
text = gr.Textbox(label="Your text πͺΆ", value=ESSAY)
|
110 |
with gr.Row():
|
111 |
split_selection = gr.Dropdown(
|
@@ -114,16 +114,16 @@ with gr.Blocks(theme=gr.themes.Soft(text_size='lg', font=["monospace"], primary_
|
|
114 |
LABEL_RECURSIVE,
|
115 |
],
|
116 |
value=LABEL_TEXTSPLITTER,
|
117 |
-
label="Method to split chunks
|
118 |
)
|
119 |
separator_selection = gr.Textbox(
|
120 |
elem_id="textbox_id",
|
121 |
-
value=["
|
122 |
info="Separators used in RecursiveCharacterTextSplitter",
|
123 |
show_label=False, # or set label to an empty string if you want to keep its space
|
124 |
visible=False,
|
125 |
)
|
126 |
-
with gr.Row():
|
127 |
length_unit_selection = gr.Dropdown(
|
128 |
choices=[
|
129 |
"Character count",
|
|
|
105 |
"""
|
106 |
|
107 |
|
108 |
+
with gr.Blocks(theme=gr.themes.Soft(text_size='lg', font=["monospace"], primary_hue=gr.themes.colors.green)) as demo:
|
109 |
text = gr.Textbox(label="Your text πͺΆ", value=ESSAY)
|
110 |
with gr.Row():
|
111 |
split_selection = gr.Dropdown(
|
|
|
114 |
LABEL_RECURSIVE,
|
115 |
],
|
116 |
value=LABEL_TEXTSPLITTER,
|
117 |
+
label="Method to split chunks π",
|
118 |
)
|
119 |
separator_selection = gr.Textbox(
|
120 |
elem_id="textbox_id",
|
121 |
+
value=["### ", "\n\n", "\n", ".", " "],
|
122 |
info="Separators used in RecursiveCharacterTextSplitter",
|
123 |
show_label=False, # or set label to an empty string if you want to keep its space
|
124 |
visible=False,
|
125 |
)
|
126 |
+
with gr.Row(theme=gr.themes.Soft(text_size='lg', font=["monospace"], primary_hue=gr.themes.colors.red)):
|
127 |
length_unit_selection = gr.Dropdown(
|
128 |
choices=[
|
129 |
"Character count",
|