@memnexus-ai/typescript-sdk 1.52.22 → 1.53.1
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.cjs +26 -0
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +12 -0
- package/dist/index.d.ts +12 -0
- package/dist/index.js +26 -0
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -2797,6 +2797,32 @@ var MemoriesService = class extends BaseService {
|
|
|
2797
2797
|
}
|
|
2798
2798
|
return this.client.call(request);
|
|
2799
2799
|
}
|
|
2800
|
+
/**
|
|
2801
|
+
* Record behavioral feedback on a search result
|
|
2802
|
+
* Record whether a search result was selected or ignored by the user.
|
|
2803
|
+
Used to build behavioral signals for retrieval quality measurement.
|
|
2804
|
+
|
|
2805
|
+
* @param body - Request body
|
|
2806
|
+
*/
|
|
2807
|
+
async recordSearchResultFeedback(body) {
|
|
2808
|
+
const request = new Request({
|
|
2809
|
+
baseUrl: this.config.baseUrl || "http://localhost:3000",
|
|
2810
|
+
method: "POST",
|
|
2811
|
+
path: "/api/memories/search/feedback",
|
|
2812
|
+
config: this.config,
|
|
2813
|
+
retry: {
|
|
2814
|
+
attempts: 3,
|
|
2815
|
+
delayMs: 150,
|
|
2816
|
+
maxDelayMs: 5e3,
|
|
2817
|
+
jitterMs: 50,
|
|
2818
|
+
backoffFactor: 2
|
|
2819
|
+
}
|
|
2820
|
+
});
|
|
2821
|
+
if (body !== void 0) {
|
|
2822
|
+
request.addBody(body);
|
|
2823
|
+
}
|
|
2824
|
+
return this.client.call(request);
|
|
2825
|
+
}
|
|
2800
2826
|
/**
|
|
2801
2827
|
* Find similar memories
|
|
2802
2828
|
* Find memories that are semantically similar to the given memory.
|