@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 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, "&amp;").replace(/</g, "&lt;").replace(/>/g, "&gt;").replace(/"/g, "&quot;").replace(/'/g, "&#039;");
395
+ return html.replace(/&/g, "&amp;").replace(/</g, "&lt;").replace(/>/g, "&gt;").replace(/"/g, "&quot;");
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, "&amp;").replace(/</g, "&lt;").replace(/>/g, "&gt;").replace(/"/g, "&quot;").replace(/'/g, "&#039;");
312
+ return html.replace(/&/g, "&amp;").replace(/</g, "&lt;").replace(/>/g, "&gt;").replace(/"/g, "&quot;");
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,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@gammatech/aijsx",
3
- "version": "0.2.0-beta.2",
3
+ "version": "0.2.0-beta.4",
4
4
  "description": "Rewrite of aijsx",
5
5
  "author": "Jordan Garcia",
6
6
  "license": "MIT",