Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -10,13 +10,17 @@ st.header("Wikipedia Search Engine app")
|
|
10 |
st_model_load = st.text('Loading wikipedia embedding...')
|
11 |
|
12 |
@st.cache_resource
|
13 |
-
def
|
14 |
print("Loading embedding...")
|
15 |
hf_hub_download(repo_id="abokbot/wikipedia-embedding", filename="simple_wikipedia_embedding.pt")
|
16 |
wikipedia_embedding = torch.load("wikipedia-embedding/simple_wikipedia_embedding.pt")
|
17 |
print("Embedding loaded!")
|
18 |
return wikipedia_embedding
|
19 |
|
|
|
|
|
|
|
|
|
20 |
"""
|
21 |
|
22 |
|
|
|
10 |
st_model_load = st.text('Loading wikipedia embedding...')
|
11 |
|
12 |
@st.cache_resource
|
13 |
+
def load_load_embedding():
|
14 |
print("Loading embedding...")
|
15 |
hf_hub_download(repo_id="abokbot/wikipedia-embedding", filename="simple_wikipedia_embedding.pt")
|
16 |
wikipedia_embedding = torch.load("wikipedia-embedding/simple_wikipedia_embedding.pt")
|
17 |
print("Embedding loaded!")
|
18 |
return wikipedia_embedding
|
19 |
|
20 |
+
wikipedia_embedding = load_embedding()
|
21 |
+
st.success('Embedding loaded!')
|
22 |
+
st_model_load.text("")
|
23 |
+
|
24 |
"""
|
25 |
|
26 |
|