@gammatech/aijsx 0.2.0-beta.2 → 0.2.0-beta.4
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/dist/index.js +2 -2
- package/dist/index.mjs +2 -2
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -392,7 +392,7 @@ function parseXml(input) {
|
|
|
392
392
|
return constructNode(null, parsed[0]);
|
|
393
393
|
}
|
|
394
394
|
function escape(html) {
|
|
395
|
-
return html.replace(/&/g, "&").replace(/</g, "<").replace(/>/g, ">").replace(/"/g, """)
|
|
395
|
+
return html.replace(/&/g, "&").replace(/</g, "<").replace(/>/g, ">").replace(/"/g, """);
|
|
396
396
|
}
|
|
397
397
|
|
|
398
398
|
// src/context.ts
|
|
@@ -987,7 +987,7 @@ async function* OpenAIVisionChatCompletion(props, { logger, render, getContext }
|
|
|
987
987
|
return `<ContentTypeImage url="${part.image_url.url}" detail="${part.image_url.detail || "auto"}" />`;
|
|
988
988
|
}
|
|
989
989
|
throw new Error("Invalid ChatCompletionContentPart type");
|
|
990
|
-
}).join("
|
|
990
|
+
}).join("\n\n");
|
|
991
991
|
};
|
|
992
992
|
return {
|
|
993
993
|
role: message.role,
|
package/dist/index.mjs
CHANGED
|
@@ -309,7 +309,7 @@ function parseXml(input) {
|
|
|
309
309
|
return constructNode(null, parsed[0]);
|
|
310
310
|
}
|
|
311
311
|
function escape(html) {
|
|
312
|
-
return html.replace(/&/g, "&").replace(/</g, "<").replace(/>/g, ">").replace(/"/g, """)
|
|
312
|
+
return html.replace(/&/g, "&").replace(/</g, "<").replace(/>/g, ">").replace(/"/g, """);
|
|
313
313
|
}
|
|
314
314
|
|
|
315
315
|
// src/context.ts
|
|
@@ -904,7 +904,7 @@ async function* OpenAIVisionChatCompletion(props, { logger, render, getContext }
|
|
|
904
904
|
return `<ContentTypeImage url="${part.image_url.url}" detail="${part.image_url.detail || "auto"}" />`;
|
|
905
905
|
}
|
|
906
906
|
throw new Error("Invalid ChatCompletionContentPart type");
|
|
907
|
-
}).join("
|
|
907
|
+
}).join("\n\n");
|
|
908
908
|
};
|
|
909
909
|
return {
|
|
910
910
|
role: message.role,
|