Skip to content

Commit

Permalink
- add default model for testing
Browse files Browse the repository at this point in the history
  • Loading branch information
gabewillen committed Feb 6, 2025
1 parent 0dd7060 commit 134ac8f
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions src/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,9 @@ def backend(self):
@cached_property
def model_names(self) -> list[str]:
# check if the legacy env var is defined
deprecated_model_names = os.environ.get("MODEL_NAMES", "")
deprecated_model_names = os.environ.get(
"MODEL_NAMES", "/BAAI/bge-small-en-v1.5"
)
if not deprecated_model_names:
logger.warn(
CONFIG_MESSAGE_TEMPLATE.format(
Expand All @@ -59,7 +61,11 @@ def model_names(self) -> list[str]:
for repository_and_revision in (
repository.rsplit(":", 1)
for repository in (
*(os.environ.get("RUNPOD_HUGGINGFACE_MODEL", "").split(",")),
*(
os.environ.get(
"RUNPOD_HUGGINGFACE_MODEL", deprecated_model_names
).split(",")
),
*deprecated_model_names.split(";"),
)
)
Expand Down

0 comments on commit 134ac8f

Please sign in to comment.