nothumanallowed 14.1.53 → 14.1.55
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.
- package/package.json +1 -1
- package/src/constants.mjs +1 -1
- package/src/services/llm.mjs +1 -48
- package/src/ui-dist/assets/index-CPFuKqv_.js +684 -0
- package/src/ui-dist/assets/index-Cjij9TME.css +1 -0
- package/src/ui-dist/index.html +2 -2
- package/src/ui-dist/assets/index-CjcT4Ajd.css +0 -1
- package/src/ui-dist/assets/index-Dj5STkBr.js +0 -684
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "nothumanallowed",
|
|
3
|
-
"version": "14.1.
|
|
3
|
+
"version": "14.1.55",
|
|
4
4
|
"description": "NotHumanAllowed — 38 AI agents, 80 tools, Studio (visual agentic workflows). Email, calendar, browser automation, screen capture, canvas, cron/heartbeat, Alexandria E2E messaging, GitHub, Notion, Slack, voice chat, free AI (Liara), 28 languages. Zero-dependency CLI.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|
package/src/constants.mjs
CHANGED
|
@@ -5,7 +5,7 @@ import { fileURLToPath } from 'url';
|
|
|
5
5
|
const __filename = fileURLToPath(import.meta.url);
|
|
6
6
|
const __dirname = path.dirname(__filename);
|
|
7
7
|
|
|
8
|
-
export const VERSION = '14.1.
|
|
8
|
+
export const VERSION = '14.1.55';
|
|
9
9
|
export const BASE_URL = 'https://nothumanallowed.com/cli';
|
|
10
10
|
export const API_BASE = 'https://nothumanallowed.com/api/v1';
|
|
11
11
|
|
package/src/services/llm.mjs
CHANGED
|
@@ -1112,26 +1112,12 @@ function parseSSEText(text, format, onToken) {
|
|
|
1112
1112
|
}
|
|
1113
1113
|
}
|
|
1114
1114
|
if (out) {
|
|
1115
|
-
chunkCount++;
|
|
1116
|
-
if (chunkCount <= 3) process.stderr.write(`[QWEN3 CHUNK ${chunkCount}] len=${out.length} repr=${JSON.stringify(out.slice(0,60))}\n`);
|
|
1117
|
-
// Detect HTML output on first meaningful token
|
|
1118
|
-
if (!isHtmlOutput && (out.includes('<div') || out.includes('<!DOCTYPE') || out.includes('<html'))) {
|
|
1119
|
-
isHtmlOutput = true;
|
|
1120
|
-
}
|
|
1121
|
-
if (!isHtmlOutput) {
|
|
1122
|
-
out = fixQwen3Markdown(out);
|
|
1123
|
-
const insideTag = fullText.lastIndexOf('<') > fullText.lastIndexOf('>');
|
|
1124
|
-
if (fullText && out && !insideTag && !/[\s\n]$/.test(fullText) && !/^[\s\n.,;:!?)\]}'">]/.test(out)) {
|
|
1125
|
-
out = ' ' + out;
|
|
1126
|
-
}
|
|
1127
|
-
}
|
|
1128
1115
|
fullText += out;
|
|
1129
1116
|
if (onToken) onToken(out);
|
|
1130
1117
|
}
|
|
1131
1118
|
}
|
|
1132
1119
|
} catch {}
|
|
1133
1120
|
}
|
|
1134
|
-
process.stderr.write(`[QWEN3 TOTAL CHUNKS] ${chunkCount}, fullText len=${fullText.length}\n`);
|
|
1135
1121
|
return fullText;
|
|
1136
1122
|
}
|
|
1137
1123
|
|
|
@@ -1143,11 +1129,6 @@ async function streamSSEWithCallback(res, format, onToken) {
|
|
|
1143
1129
|
let fullText = '';
|
|
1144
1130
|
let thinkBuf = ''; // accumulates <think>...</think> content to suppress
|
|
1145
1131
|
let inThink = false;
|
|
1146
|
-
let isHtmlOutput = false;
|
|
1147
|
-
|
|
1148
|
-
// BPE REPAIR STREAMING: accumula parole fino a punctuation, ripara, e invia token per token
|
|
1149
|
-
let bpeBuffer = '';
|
|
1150
|
-
let lastSentPos = 0;
|
|
1151
1132
|
|
|
1152
1133
|
while (true) {
|
|
1153
1134
|
const { done, value } = await reader.read();
|
|
@@ -1193,36 +1174,8 @@ async function streamSSEWithCallback(res, format, onToken) {
|
|
|
1193
1174
|
}
|
|
1194
1175
|
}
|
|
1195
1176
|
if (out) {
|
|
1196
|
-
if (!isHtmlOutput && (out.includes('<div') || out.includes('<!DOCTYPE') || out.includes('<html'))) {
|
|
1197
|
-
isHtmlOutput = true;
|
|
1198
|
-
}
|
|
1199
|
-
if (!isHtmlOutput) {
|
|
1200
|
-
out = fixQwen3Markdown(out);
|
|
1201
|
-
const insideTag2 = fullText.lastIndexOf('<') > fullText.lastIndexOf('>');
|
|
1202
|
-
if (fullText && out && !insideTag2 && !/[\s\n]$/.test(fullText) && !/^[\s\n.,;:!?)\]}'">]/.test(out)) {
|
|
1203
|
-
out = ' ' + out;
|
|
1204
|
-
}
|
|
1205
|
-
}
|
|
1206
1177
|
fullText += out;
|
|
1207
|
-
|
|
1208
|
-
// BPE REPAIR STREAMING: accumula nel buffer e invia token riparati progressivamente
|
|
1209
|
-
bpeBuffer += out;
|
|
1210
|
-
|
|
1211
|
-
// Quando raggiungiamo un punto di stop naturale (punteggiatura), ripara il buffer
|
|
1212
|
-
if (/[.!?;:\n]/.test(out)) {
|
|
1213
|
-
const repairedBuffer = fixQwen3BPE(bpeBuffer);
|
|
1214
|
-
|
|
1215
|
-
// Invia solo la parte nuova (dalla posizione precedente)
|
|
1216
|
-
const newPart = repairedBuffer.slice(lastSentPos);
|
|
1217
|
-
if (newPart && onToken) {
|
|
1218
|
-
onToken(newPart);
|
|
1219
|
-
}
|
|
1220
|
-
|
|
1221
|
-
lastSentPos = repairedBuffer.length;
|
|
1222
|
-
} else {
|
|
1223
|
-
// Per output senza punteggiatura, invia token originali
|
|
1224
|
-
if (onToken) onToken(out);
|
|
1225
|
-
}
|
|
1178
|
+
if (onToken) onToken(out);
|
|
1226
1179
|
}
|
|
1227
1180
|
}
|
|
1228
1181
|
} catch {}
|