@elizaos/core 1.0.0-beta.25 → 1.0.0-beta.27

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.
Files changed (2) hide show
  1. package/dist/index.js +7 -15
  2. package/package.json +2 -2
package/dist/index.js CHANGED
@@ -1479,23 +1479,15 @@ var AgentRuntime = class {
1479
1479
  count: 5,
1480
1480
  match_threshold: 0.1
1481
1481
  });
1482
- const uniqueSources = [
1483
- ...new Set(
1484
- fragments.map((memory) => {
1485
- this.runtimeLogger.debug(
1486
- `Matched fragment: ${memory.content.text} with similarity: ${memory.similarity}`
1487
- );
1488
- return memory?.metadata?.type === "fragment" /* FRAGMENT */ ? memory?.metadata?.documentId : void 0;
1489
- }).filter(Boolean)
1490
- )
1491
- ];
1492
- const knowledgeDocuments = await Promise.all(
1493
- uniqueSources.map((source) => this.getMemoryById(source))
1494
- );
1495
- return knowledgeDocuments.filter((memory) => memory !== null).map((memory) => ({ id: memory.id, content: memory.content }));
1482
+ return fragments.map((fragment) => ({
1483
+ id: fragment.id,
1484
+ content: fragment.content,
1485
+ similarity: fragment.similarity,
1486
+ metadata: fragment.metadata
1487
+ }));
1496
1488
  }
1497
1489
  async addKnowledge(item, options2 = {
1498
- targetTokens: 3e3,
1490
+ targetTokens: 1500,
1499
1491
  overlap: 200,
1500
1492
  modelContextSize: 4096
1501
1493
  }) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@elizaos/core",
3
- "version": "1.0.0-beta.25",
3
+ "version": "1.0.0-beta.27",
4
4
  "description": "",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",
@@ -76,5 +76,5 @@
76
76
  "publishConfig": {
77
77
  "access": "public"
78
78
  },
79
- "gitHead": "4175c737436302188e5972030f2a698bd6fb9f71"
79
+ "gitHead": "2d8cc230c67ecbb23e653e2133bc1fdab9c6fbf4"
80
80
  }