Skip to content

Commit 69c7917

Browse files
author
sd109
committed
Fix Mistral regex pattern
1 parent a24e9ca commit 69c7917

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

chart/web-app/app.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@
2525
# sure the web app works correctly with them. To do so, we detect when a
2626
# mistral model is specified using this regex and then handle it explicitly
2727
# when contructing the `context` list in the `inference` function below.
28-
MISTRAL_REGEX = re.compile(r"mi(s|x)tral", re.IGNORECASE)
28+
MISTRAL_REGEX = re.compile(r".*mi(s|x)tral.*", re.IGNORECASE)
2929
IS_MISTRAL_MODEL = (MISTRAL_REGEX.match(settings.model_name) is not None)
3030
if IS_MISTRAL_MODEL:
3131
print("Detected Mistral model - will alter LangChain conversation format appropriately.")

0 commit comments

Comments
 (0)