Update app.py
Browse files
app.py
CHANGED
@@ -16,12 +16,12 @@ def retrieve_search_df(question = "Which diet you want to eat?", top_k = 10):
|
|
16 |
return sdf[["question", "dialogue_text", "dialogue", "repo", "scores"]]
|
17 |
|
18 |
example_sample = [
|
19 |
-
["Which diet you want to eat?",
|
20 |
-
["Do you like this film?",
|
21 |
]
|
22 |
|
23 |
def demo_func(prefix, max_length):
|
24 |
-
max_length = max(int(max_length),
|
25 |
l = retrieve_search_df(prefix, max_length)["dialogue"].values.tolist()
|
26 |
assert type(l) == type([])
|
27 |
return {
|
|
|
16 |
return sdf[["question", "dialogue_text", "dialogue", "repo", "scores"]]
|
17 |
|
18 |
example_sample = [
|
19 |
+
["Which diet you want to eat?", 3],
|
20 |
+
["Do you like this film?", 5],
|
21 |
]
|
22 |
|
23 |
def demo_func(prefix, max_length):
|
24 |
+
max_length = max(int(max_length), 3)
|
25 |
l = retrieve_search_df(prefix, max_length)["dialogue"].values.tolist()
|
26 |
assert type(l) == type([])
|
27 |
return {
|