chore: bump cortex with cors fix

This commit is contained in:
Louis 2025-03-26 15:39:02 +07:00
parent fc521ecda9
commit c597cb6af6
No known key found for this signature in database
GPG Key ID: 44FA9F4D33C37DE2
2 changed files with 6 additions and 1 deletions

View File

@ -14,7 +14,7 @@ download() {
} }
# Read CORTEX_VERSION # Read CORTEX_VERSION
CORTEX_VERSION=1.0.12 CORTEX_VERSION=1.0.13-rc1
ENGINE_VERSION=0.1.55 ENGINE_VERSION=0.1.55
CORTEX_RELEASE_URL="https://github.com/menloresearch/cortex.cpp/releases/download" CORTEX_RELEASE_URL="https://github.com/menloresearch/cortex.cpp/releases/download"
ENGINE_DOWNLOAD_URL="https://github.com/menloresearch/cortex.llamacpp/releases/download/v${ENGINE_VERSION}/cortex.llamacpp-${ENGINE_VERSION}" ENGINE_DOWNLOAD_URL="https://github.com/menloresearch/cortex.llamacpp/releases/download/v${ENGINE_VERSION}/cortex.llamacpp-${ENGINE_VERSION}"
@ -58,6 +58,7 @@ elif [ "$OS_TYPE" == "Darwin" ]; then
rm -rf ./cortex-beta rm -rf ./cortex-beta
chmod +x "./cortex-server" chmod +x "./cortex-server"
mv ./cortex-server ./cortex-server-universal-apple-darwin mv ./cortex-server ./cortex-server-universal-apple-darwin
cp ./cortex-server-universal-apple-darwin ./cortex-server-aarch64-apple-darwin
# Download engines for macOS # Download engines for macOS
download "${ENGINE_DOWNLOAD_URL}-mac-arm64.tar.gz" "${SHARED_PATH}/engines/cortex.llamacpp/mac-arm64/v${ENGINE_VERSION}" download "${ENGINE_DOWNLOAD_URL}-mac-arm64.tar.gz" "${SHARED_PATH}/engines/cortex.llamacpp/mac-arm64/v${ENGINE_VERSION}"

View File

@ -202,6 +202,10 @@ pub fn setup_sidecar(app: &App) -> Result<(), String> {
.unwrap() .unwrap()
.to_str() .to_str()
.unwrap(), .unwrap(),
"--cors",
"ON",
"--allowed_origins",
"http://localhost:3000",
"config", "config",
"--api_keys", "--api_keys",
app_state.inner().app_token.as_deref().unwrap_or(""), app_state.inner().app_token.as_deref().unwrap_or(""),