@snap-agent/rag-web 0.1.2 → 0.1.3
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 -0
- package/dist/index.mjs +2 -0
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1668,6 +1668,7 @@ var WebRAGPlugin = class _WebRAGPlugin {
|
|
|
1668
1668
|
imageUrl = image;
|
|
1669
1669
|
}
|
|
1670
1670
|
}
|
|
1671
|
+
const description = $('meta[property="og:description"]').attr("content") || $('meta[name="description"]').attr("content") || void 0;
|
|
1671
1672
|
let type = config.defaultType || "page";
|
|
1672
1673
|
if (config.typeFromUrl) {
|
|
1673
1674
|
for (const [pattern, typeName] of Object.entries(config.typeFromUrl)) {
|
|
@@ -1686,6 +1687,7 @@ var WebRAGPlugin = class _WebRAGPlugin {
|
|
|
1686
1687
|
title,
|
|
1687
1688
|
url,
|
|
1688
1689
|
...imageUrl ? { imageUrl } : {},
|
|
1690
|
+
...description ? { description } : {},
|
|
1689
1691
|
...config.metadata
|
|
1690
1692
|
}
|
|
1691
1693
|
};
|
package/dist/index.mjs
CHANGED
|
@@ -1632,6 +1632,7 @@ var WebRAGPlugin = class _WebRAGPlugin {
|
|
|
1632
1632
|
imageUrl = image;
|
|
1633
1633
|
}
|
|
1634
1634
|
}
|
|
1635
|
+
const description = $('meta[property="og:description"]').attr("content") || $('meta[name="description"]').attr("content") || void 0;
|
|
1635
1636
|
let type = config.defaultType || "page";
|
|
1636
1637
|
if (config.typeFromUrl) {
|
|
1637
1638
|
for (const [pattern, typeName] of Object.entries(config.typeFromUrl)) {
|
|
@@ -1650,6 +1651,7 @@ var WebRAGPlugin = class _WebRAGPlugin {
|
|
|
1650
1651
|
title,
|
|
1651
1652
|
url,
|
|
1652
1653
|
...imageUrl ? { imageUrl } : {},
|
|
1654
|
+
...description ? { description } : {},
|
|
1653
1655
|
...config.metadata
|
|
1654
1656
|
}
|
|
1655
1657
|
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@snap-agent/rag-web",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.3",
|
|
4
4
|
"description": "Web RAG plugin for SnapAgent SDK - Schema-agnostic content search via web crawling, CMS APIs, sitemaps, and RSS feeds",
|
|
5
5
|
"main": "./dist/index.js",
|
|
6
6
|
"module": "./dist/index.mjs",
|