hotchpotch
commited on
Commit
•
0bef579
1
Parent(s):
6defcba
up
Browse files
app.py
CHANGED
@@ -10,17 +10,13 @@ if os.getenv("SPACE_ID"):
|
|
10 |
else:
|
11 |
USE_HF_SPACE = False
|
12 |
|
13 |
-
MODEL_NAME = os.environ.get("MODEL_NAME", "hotchpotch/
|
14 |
|
15 |
|
16 |
@st.cache_resource
|
17 |
def get_embedder(model_name: str = MODEL_NAME) -> SpladeEmbedder:
|
18 |
-
revision = None
|
19 |
-
if MODEL_NAME == "hotchpotch/wip-tmp-model-base-v1-pre-2":
|
20 |
-
revision = "a7db67721ea22165faefba6f0b7ee726b0f3a78f"
|
21 |
embedder = SpladeEmbedder(
|
22 |
model_name,
|
23 |
-
revision=revision,
|
24 |
)
|
25 |
return embedder
|
26 |
|
|
|
10 |
else:
|
11 |
USE_HF_SPACE = False
|
12 |
|
13 |
+
MODEL_NAME = os.environ.get("MODEL_NAME", "hotchpotch/japanese-splade-base-v1")
|
14 |
|
15 |
|
16 |
@st.cache_resource
|
17 |
def get_embedder(model_name: str = MODEL_NAME) -> SpladeEmbedder:
|
|
|
|
|
|
|
18 |
embedder = SpladeEmbedder(
|
19 |
model_name,
|
|
|
20 |
)
|
21 |
return embedder
|
22 |
|