From 1479fa348fd76f6baff141d187fc7302f62ed49a Mon Sep 17 00:00:00 2001 From: arvinxx Date: Sun, 22 Oct 2023 14:43:37 +0800 Subject: [PATCH] :art: fix: clean deps --- package.json | 9 --------- src/ProChat/utils/tokenizer.ts | 5 ----- 2 files changed, 14 deletions(-) delete mode 100644 src/ProChat/utils/tokenizer.ts diff --git a/package.json b/package.json index d02a1d4c..c4235c6d 100644 --- a/package.json +++ b/package.json @@ -59,37 +59,28 @@ ] }, "dependencies": { - "@ant-design/colors": "^7", "@ant-design/icons": "^5", "@babel/runtime": "^7", - "@floating-ui/react": "^0", - "@lobehub/chat-plugin-sdk": "latest", "ahooks": "^3", "chroma-js": "^2", "copy-to-clipboard": "^3", "dayjs": "^1", "emoji-regex": "^10", "fast-deep-equal": "^3", - "gpt-tokenizer": "^2.1.2", "immer": "^10", "lodash-es": "^4", "lucide-react": "^0.288.0", "nanoid": "^5", "polished": "^4", - "prism-react-renderer": "^2", - "re-resizable": "^6", "react-error-boundary": "^4", "react-intersection-observer": "^9.5.2", "react-layout-kit": "^1.7.1", "react-markdown": "^8", - "react-rnd": "^10", "rehype-katex": "^6", "remark-gfm": "^3", "remark-math": "^5", "shikiji": "^0", "swr": "^2", - "ts-md5": "^1", - "url-join": "^5", "use-merge-value": "^1", "zustand": "^4.4.1", "zustand-utils": "^1.3.1" diff --git a/src/ProChat/utils/tokenizer.ts b/src/ProChat/utils/tokenizer.ts deleted file mode 100644 index ecd43c24..00000000 --- a/src/ProChat/utils/tokenizer.ts +++ /dev/null @@ -1,5 +0,0 @@ -export const encodeAsync = async (str: string) => { - const { encode } = await import('gpt-tokenizer'); - - return encode(str).length; -};