dsh-connect-madao 0.9.0 → 0.9.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/lib/index.js +1 -1
  2. package/package.json +1 -1
package/lib/index.js CHANGED
@@ -1999,7 +1999,7 @@ async function chatCompletion(res, client, rawBody, ctxModels) {
1999
1999
  const msgCount = Array.isArray(rawBody.messages) ? rawBody.messages.length : 0;
2000
2000
  chatLog(`chat REJECT body ${mb}MB (msgs ${msgCount} + tools ${toolCountForMsg}) > 9.5MB for ${model}`);
2001
2001
  const smaller = ctxModels.filter((m) => m.context <= 262144).slice(0, 4).map((m) => `${m.name}\uFF08${m.context}\uFF09`);
2002
- return json(res, 400, {
2002
+ return json(res, 413, {
2003
2003
  error: {
2004
2004
  message: `\u5F53\u524D\u4F1A\u8BDD\u7684\u8BF7\u6C42\u4F53 ${mb} MB\uFF0C\u8D85\u8FC7\u7801\u9053\u7F51\u5173\u7EA6 10 MB \u7684\u5355\u6B21\u4E0A\u9650\u3002
2005
2005
  \u8FD9\u4E0D\u662F\u914D\u7F6E\u95EE\u9898\uFF0C\u7F51\u5173\u4F1A\u8FD4\u56DE\u300C\u53C2\u6570\u65E0\u6548\u300D\u800C\u4E0D\u8BF4\u662F\u4F53\u79EF\u8D85\u4E86\u3002
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "dsh-connect-madao",
3
3
  "displayName": "DSH Connect 码道",
4
4
  "description": "把华为云码道(CodeArts Agent)的模型接入 DeepSeek Harness:自签 SDK-HMAC-SHA256、P-256 密钥协商与 SM4-GCM 载荷加密,对外提供 OpenAI 兼容接口,并带设置面板与状态胶囊。",
5
- "version": "0.9.0",
5
+ "version": "0.9.1",
6
6
  "license": "MIT",
7
7
  "type": "module",
8
8
  "engines": {