qwen-alpha 1.0.17 → 1.0.18
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/README.md +1 -1
- package/package.json +1 -1
- package/src/services/qwenService.js +6 -3
package/README.md
CHANGED
package/package.json
CHANGED
|
@@ -169,11 +169,14 @@ class QwenService {
|
|
|
169
169
|
|
|
170
170
|
for (const msg of messages) {
|
|
171
171
|
// Сначала проверяем result сообщение (оно содержит финальный ответ)
|
|
172
|
-
if (msg.type === 'result'
|
|
173
|
-
|
|
174
|
-
|
|
172
|
+
if (msg.type === 'result') {
|
|
173
|
+
logger.debug({ resultType: typeof msg.result, resultLength: msg.result?.length, result: msg.result?.substring?.(0, 100) }, 'Checking result message');
|
|
174
|
+
|
|
175
|
+
// result должен быть строкой
|
|
176
|
+
if (typeof msg.result === 'string') {
|
|
175
177
|
textContents.push(msg.result);
|
|
176
178
|
hasResult = true;
|
|
179
|
+
logger.info({ resultLength: msg.result.length }, 'Found result text');
|
|
177
180
|
break;
|
|
178
181
|
}
|
|
179
182
|
}
|