fixes issue with AWS model assignment when requesting legacy claude (claude-2.1, etc)

This commit is contained in:
khanon 2024-10-25 17:49:24 +00:00
parent 251ea6d412
commit fe61745e24
1 changed files with 1 additions and 2 deletions

View File

@ -195,7 +195,7 @@ function maybeReassignModel(req: Request) {
} }
const ver = minor ? `${major}.${minor}` : major; const ver = minor ? `${major}.${minor}` : major;
const name = rawName.match(/([a-z]+)/)?.[1]; const name = rawName?.match(/([a-z]+)/)?.[1] || "";
switch (ver) { switch (ver) {
case "1": case "1":
@ -222,7 +222,6 @@ function maybeReassignModel(req: Request) {
return; return;
} }
break; break;
case "3-5":
case "3.5": case "3.5":
switch (name) { switch (name) {
case "sonnet": case "sonnet":