openmates 0.18.0-alpha.49 → 0.18.0-alpha.50
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.
|
@@ -5780,6 +5780,7 @@ function projectAssistantSpeech(content) {
|
|
|
5780
5780
|
(block) => FENCED_BLOCK.test(block.trim()) ? [block] : block.split(/\n\n+/)
|
|
5781
5781
|
);
|
|
5782
5782
|
const segments = [];
|
|
5783
|
+
const semanticSummaries = /* @__PURE__ */ new Set();
|
|
5783
5784
|
for (const paragraph of paragraphs.map((block) => block.trim()).filter(Boolean)) {
|
|
5784
5785
|
if (!FENCED_BLOCK.test(paragraph)) {
|
|
5785
5786
|
const heading = paragraph.split("\n").map((line) => line.match(/^#{1,6}\s+(.+?)\s*#*$/)?.[1]?.trim()).find(Boolean);
|
|
@@ -5787,6 +5788,11 @@ function projectAssistantSpeech(content) {
|
|
|
5787
5788
|
}
|
|
5788
5789
|
const projected = projectParagraph(paragraph);
|
|
5789
5790
|
for (const speakableText of splitLongParagraph(projected.speakableText)) {
|
|
5791
|
+
const semanticIdentity = `${projected.kind}:${speakableText}`;
|
|
5792
|
+
if (projected.kind === "embed_summary" && speakableText === "Search results are available.") {
|
|
5793
|
+
if (semanticSummaries.has(semanticIdentity)) continue;
|
|
5794
|
+
semanticSummaries.add(semanticIdentity);
|
|
5795
|
+
}
|
|
5790
5796
|
if (segments.length === MAX_SPEECH_SEGMENTS) return segments;
|
|
5791
5797
|
const sequence = segments.length;
|
|
5792
5798
|
segments.push({
|
package/dist/cli.js
CHANGED
package/dist/index.js
CHANGED