perf: remove unused tiktoken encodings from node_modules

This commit is contained in:
AnotiaWang
2025-02-13 13:59:20 +08:00
parent 448b9eb7e5
commit 1d4d1e8113
2 changed files with 49 additions and 0 deletions

View File

@ -5,6 +5,8 @@ WORKDIR /app
COPY package.json pnpm-lock.yaml ./
RUN npm i -g --force pnpm@9
RUN pnpm install --frozen-lockfile
# Remove unused encodings from `js-tiktoken`
RUN node scripts/cleanup-js-tiktoken.js
COPY . .
ENV NODE_OPTIONS="--max_old_space_size=2048"