Commit 84d91f3f by archer

perf: 接口大小

parent 7811f748
...@@ -100,8 +100,8 @@ export default async function handler(req: NextApiRequest, res: NextApiResponse) ...@@ -100,8 +100,8 @@ export default async function handler(req: NextApiRequest, res: NextApiResponse)
throw new Error('对不起,我没有找到你的问题'); throw new Error('对不起,我没有找到你的问题');
} }
// textArr 筛选,最多 3000 tokens // textArr 筛选,最多 2800 tokens
const systemPrompt = systemPromptFilter(formatRedisPrompt, 3000); const systemPrompt = systemPromptFilter(formatRedisPrompt, 2800);
prompts.unshift({ prompts.unshift({
obj: 'SYSTEM', obj: 'SYSTEM',
......
...@@ -76,3 +76,11 @@ export default async function handler(req: NextApiRequest, res: NextApiResponse) ...@@ -76,3 +76,11 @@ export default async function handler(req: NextApiRequest, res: NextApiResponse)
}); });
} }
} }
export const config = {
api: {
bodyParser: {
sizeLimit: '10mb'
}
}
};
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment