Stéphane G commited on
Commit ·
1f9e56a
1
Parent(s): c114add
tidy up
Browse files
app.py
CHANGED
|
@@ -124,15 +124,14 @@ select_chain_type = pn.widgets.RadioButtonGroup(
|
|
| 124 |
|
| 125 |
def toggle_github_inputs(event):
|
| 126 |
if event.new == "Custom":
|
| 127 |
-
input_url_repo.
|
| 128 |
-
input_branch_repo.
|
| 129 |
else:
|
| 130 |
-
input_url_repo.
|
| 131 |
-
input_branch_repo.
|
| 132 |
|
| 133 |
select_repo.param.watch(toggle_github_inputs, 'value')
|
| 134 |
|
| 135 |
-
|
| 136 |
#------------------------------------------------------------------------------
|
| 137 |
def init_embedding_openai():
|
| 138 |
return OpenAIEmbeddings(
|
|
|
|
| 124 |
|
| 125 |
def toggle_github_inputs(event):
|
| 126 |
if event.new == "Custom":
|
| 127 |
+
input_url_repo.disabled = False
|
| 128 |
+
input_branch_repo.disabled = False
|
| 129 |
else:
|
| 130 |
+
input_url_repo.disabled = True
|
| 131 |
+
input_branch_repo.disabled = True
|
| 132 |
|
| 133 |
select_repo.param.watch(toggle_github_inputs, 'value')
|
| 134 |
|
|
|
|
| 135 |
#------------------------------------------------------------------------------
|
| 136 |
def init_embedding_openai():
|
| 137 |
return OpenAIEmbeddings(
|