@getzep/zep-cloud 1.0.7 → 1.0.8
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/api/resources/document/client/Client.js +13 -13
- package/api/resources/memory/client/Client.d.ts +40 -0
- package/api/resources/memory/client/Client.js +249 -20
- package/api/resources/memory/client/requests/CreateSessionRequest.d.ts +3 -0
- package/api/resources/memory/client/requests/MemoryGetRequest.d.ts +4 -0
- package/api/resources/memory/client/requests/MemoryGetSessionFactsRequest.d.ts +13 -0
- package/api/resources/memory/client/requests/MemoryGetSessionFactsRequest.js +5 -0
- package/api/resources/memory/client/requests/MemorySearchPayload.d.ts +1 -0
- package/api/resources/memory/client/requests/SessionSearchQuery.d.ts +1 -0
- package/api/resources/memory/client/requests/UpdateSessionRequest.d.ts +6 -0
- package/api/resources/memory/client/requests/index.d.ts +1 -0
- package/api/resources/user/client/Client.js +6 -6
- package/api/types/Fact.d.ts +1 -0
- package/api/types/FactRatingExamples.d.ts +8 -0
- package/api/types/FactRatingExamples.js +5 -0
- package/api/types/FactRatingInstruction.d.ts +21 -0
- package/api/types/FactRatingInstruction.js +5 -0
- package/api/types/FactResponse.d.ts +7 -0
- package/api/types/FactResponse.js +5 -0
- package/api/types/FactsResponse.d.ts +7 -0
- package/api/types/FactsResponse.js +5 -0
- package/api/types/Session.d.ts +2 -0
- package/api/types/index.d.ts +4 -0
- package/api/types/index.js +4 -0
- package/dist/api/resources/document/client/Client.js +13 -13
- package/dist/api/resources/memory/client/Client.d.ts +40 -0
- package/dist/api/resources/memory/client/Client.js +249 -20
- package/dist/api/resources/memory/client/requests/CreateSessionRequest.d.ts +3 -0
- package/dist/api/resources/memory/client/requests/MemoryGetRequest.d.ts +4 -0
- package/dist/api/resources/memory/client/requests/MemoryGetSessionFactsRequest.d.ts +13 -0
- package/dist/api/resources/memory/client/requests/MemoryGetSessionFactsRequest.js +5 -0
- package/dist/api/resources/memory/client/requests/MemorySearchPayload.d.ts +1 -0
- package/dist/api/resources/memory/client/requests/SessionSearchQuery.d.ts +1 -0
- package/dist/api/resources/memory/client/requests/UpdateSessionRequest.d.ts +6 -0
- package/dist/api/resources/memory/client/requests/index.d.ts +1 -0
- package/dist/api/resources/user/client/Client.js +6 -6
- package/dist/api/types/Fact.d.ts +1 -0
- package/dist/api/types/FactRatingExamples.d.ts +8 -0
- package/dist/api/types/FactRatingExamples.js +5 -0
- package/dist/api/types/FactRatingInstruction.d.ts +21 -0
- package/dist/api/types/FactRatingInstruction.js +5 -0
- package/dist/api/types/FactResponse.d.ts +7 -0
- package/dist/api/types/FactResponse.js +5 -0
- package/dist/api/types/FactsResponse.d.ts +7 -0
- package/dist/api/types/FactsResponse.js +5 -0
- package/dist/api/types/Session.d.ts +2 -0
- package/dist/api/types/index.d.ts +4 -0
- package/dist/api/types/index.js +4 -0
- package/dist/serialization/resources/memory/client/deleteFact.d.ts +9 -0
- package/dist/serialization/resources/memory/client/deleteFact.js +31 -0
- package/dist/serialization/resources/memory/client/index.d.ts +1 -0
- package/dist/serialization/resources/memory/client/index.js +2 -1
- package/dist/serialization/resources/memory/client/requests/CreateSessionRequest.d.ts +2 -0
- package/dist/serialization/resources/memory/client/requests/CreateSessionRequest.js +2 -0
- package/dist/serialization/resources/memory/client/requests/MemorySearchPayload.d.ts +1 -0
- package/dist/serialization/resources/memory/client/requests/MemorySearchPayload.js +1 -0
- package/dist/serialization/resources/memory/client/requests/SessionSearchQuery.d.ts +1 -0
- package/dist/serialization/resources/memory/client/requests/SessionSearchQuery.js +1 -0
- package/dist/serialization/resources/memory/client/requests/UpdateSessionRequest.d.ts +2 -0
- package/dist/serialization/resources/memory/client/requests/UpdateSessionRequest.js +2 -0
- package/dist/serialization/types/Fact.d.ts +1 -0
- package/dist/serialization/types/Fact.js +1 -0
- package/dist/serialization/types/FactRatingExamples.d.ts +14 -0
- package/dist/serialization/types/FactRatingExamples.js +35 -0
- package/dist/serialization/types/FactRatingInstruction.d.ts +14 -0
- package/dist/serialization/types/FactRatingInstruction.js +35 -0
- package/dist/serialization/types/FactResponse.d.ts +13 -0
- package/dist/serialization/types/FactResponse.js +34 -0
- package/dist/serialization/types/FactsResponse.d.ts +13 -0
- package/dist/serialization/types/FactsResponse.js +34 -0
- package/dist/serialization/types/Session.d.ts +2 -0
- package/dist/serialization/types/Session.js +2 -0
- package/dist/serialization/types/index.d.ts +4 -0
- package/dist/serialization/types/index.js +4 -0
- package/package.json +1 -1
- package/serialization/resources/memory/client/deleteFact.d.ts +9 -0
- package/serialization/resources/memory/client/deleteFact.js +31 -0
- package/serialization/resources/memory/client/index.d.ts +1 -0
- package/serialization/resources/memory/client/index.js +2 -1
- package/serialization/resources/memory/client/requests/CreateSessionRequest.d.ts +2 -0
- package/serialization/resources/memory/client/requests/CreateSessionRequest.js +2 -0
- package/serialization/resources/memory/client/requests/MemorySearchPayload.d.ts +1 -0
- package/serialization/resources/memory/client/requests/MemorySearchPayload.js +1 -0
- package/serialization/resources/memory/client/requests/SessionSearchQuery.d.ts +1 -0
- package/serialization/resources/memory/client/requests/SessionSearchQuery.js +1 -0
- package/serialization/resources/memory/client/requests/UpdateSessionRequest.d.ts +2 -0
- package/serialization/resources/memory/client/requests/UpdateSessionRequest.js +2 -0
- package/serialization/types/Fact.d.ts +1 -0
- package/serialization/types/Fact.js +1 -0
- package/serialization/types/FactRatingExamples.d.ts +14 -0
- package/serialization/types/FactRatingExamples.js +35 -0
- package/serialization/types/FactRatingInstruction.d.ts +14 -0
- package/serialization/types/FactRatingInstruction.js +35 -0
- package/serialization/types/FactResponse.d.ts +13 -0
- package/serialization/types/FactResponse.js +34 -0
- package/serialization/types/FactsResponse.d.ts +13 -0
- package/serialization/types/FactsResponse.js +34 -0
- package/serialization/types/Session.d.ts +2 -0
- package/serialization/types/Session.js +2 -0
- package/serialization/types/index.d.ts +4 -0
- package/serialization/types/index.js +4 -0
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* This file was auto-generated by Fern from our API Definition.
|
|
3
3
|
*/
|
|
4
|
+
import * as Zep from "../../../../index";
|
|
4
5
|
/**
|
|
5
6
|
* @example
|
|
6
7
|
* {
|
|
@@ -8,6 +9,8 @@
|
|
|
8
9
|
* }
|
|
9
10
|
*/
|
|
10
11
|
export interface CreateSessionRequest {
|
|
12
|
+
/** Optional instruction to use for fact rating. */
|
|
13
|
+
factRatingInstruction?: Zep.FactRatingInstruction;
|
|
11
14
|
/** The metadata associated with the session. */
|
|
12
15
|
metadata?: Record<string, unknown>;
|
|
13
16
|
/** The unique identifier of the session. */
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* This file was auto-generated by Fern from our API Definition.
|
|
3
3
|
*/
|
|
4
|
+
import * as Zep from "../../../../index";
|
|
4
5
|
/**
|
|
5
6
|
* @example
|
|
6
7
|
* {
|
|
@@ -8,6 +9,11 @@
|
|
|
8
9
|
* }
|
|
9
10
|
*/
|
|
10
11
|
export interface UpdateSessionRequest {
|
|
12
|
+
/**
|
|
13
|
+
* Optional instruction to use for fact rating.
|
|
14
|
+
* Fact rating instructions can not be unset.
|
|
15
|
+
*/
|
|
16
|
+
factRatingInstruction?: Zep.FactRatingInstruction;
|
|
11
17
|
/** The metadata to update */
|
|
12
18
|
metadata: Record<string, unknown>;
|
|
13
19
|
}
|
|
@@ -5,6 +5,7 @@ export { type SessionSearchQuery } from "./SessionSearchQuery";
|
|
|
5
5
|
export { type UpdateSessionRequest } from "./UpdateSessionRequest";
|
|
6
6
|
export { type EndSessionRequest } from "./EndSessionRequest";
|
|
7
7
|
export { type ExtractDataRequest } from "./ExtractDataRequest";
|
|
8
|
+
export { type MemoryGetSessionFactsRequest } from "./MemoryGetSessionFactsRequest";
|
|
8
9
|
export { type MemoryGetRequest } from "./MemoryGetRequest";
|
|
9
10
|
export { type AddMemoryRequest } from "./AddMemoryRequest";
|
|
10
11
|
export { type MemoryGetSessionMessagesRequest } from "./MemoryGetSessionMessagesRequest";
|
|
@@ -67,7 +67,7 @@ class User {
|
|
|
67
67
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
68
68
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ZepEnvironment.Default, "users"),
|
|
69
69
|
method: "POST",
|
|
70
|
-
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "1.0.
|
|
70
|
+
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "1.0.8", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
|
|
71
71
|
contentType: "application/json",
|
|
72
72
|
body: yield serializers.CreateUserRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
|
73
73
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -149,7 +149,7 @@ class User {
|
|
|
149
149
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
150
150
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ZepEnvironment.Default, "users-ordered"),
|
|
151
151
|
method: "GET",
|
|
152
|
-
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "1.0.
|
|
152
|
+
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "1.0.8", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
|
|
153
153
|
contentType: "application/json",
|
|
154
154
|
queryParameters: _queryParams,
|
|
155
155
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -223,7 +223,7 @@ class User {
|
|
|
223
223
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
224
224
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ZepEnvironment.Default, `users/${encodeURIComponent(userId)}`),
|
|
225
225
|
method: "GET",
|
|
226
|
-
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "1.0.
|
|
226
|
+
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "1.0.8", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
|
|
227
227
|
contentType: "application/json",
|
|
228
228
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
229
229
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
@@ -296,7 +296,7 @@ class User {
|
|
|
296
296
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
297
297
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ZepEnvironment.Default, `users/${encodeURIComponent(userId)}`),
|
|
298
298
|
method: "DELETE",
|
|
299
|
-
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "1.0.
|
|
299
|
+
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "1.0.8", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
|
|
300
300
|
contentType: "application/json",
|
|
301
301
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
302
302
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
@@ -371,7 +371,7 @@ class User {
|
|
|
371
371
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
372
372
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ZepEnvironment.Default, `users/${encodeURIComponent(userId)}`),
|
|
373
373
|
method: "PATCH",
|
|
374
|
-
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "1.0.
|
|
374
|
+
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "1.0.8", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
|
|
375
375
|
contentType: "application/json",
|
|
376
376
|
body: yield serializers.UpdateUserRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
|
377
377
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -452,7 +452,7 @@ class User {
|
|
|
452
452
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
453
453
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ZepEnvironment.Default, `users/${encodeURIComponent(userId)}/sessions`),
|
|
454
454
|
method: "GET",
|
|
455
|
-
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "1.0.
|
|
455
|
+
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "1.0.8", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
|
|
456
456
|
contentType: "application/json",
|
|
457
457
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
458
458
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
package/api/types/Fact.d.ts
CHANGED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This file was auto-generated by Fern from our API Definition.
|
|
3
|
+
*/
|
|
4
|
+
import * as Zep from "../index";
|
|
5
|
+
export interface FactRatingInstruction {
|
|
6
|
+
/**
|
|
7
|
+
* Examples is a list of examples that demonstrate how facts might be rated based on your instruction. You should provide
|
|
8
|
+
* an example of a highly rated example, a low rated example, and a medium (or in between example). For example, if you are rating
|
|
9
|
+
* based on relevance to a trip planning application, your examples might be:
|
|
10
|
+
* High: "Joe's dream vacation is Bali"
|
|
11
|
+
* Medium: "Joe has a fear of flying",
|
|
12
|
+
* Low: "Joe's favorite food is Japanese",
|
|
13
|
+
*/
|
|
14
|
+
examples?: Zep.FactRatingExamples;
|
|
15
|
+
/**
|
|
16
|
+
* A string describing how to rate facts as they apply to your application. A trip planning application may
|
|
17
|
+
* use something like "relevancy to planning a trip, the user's preferences when traveling,
|
|
18
|
+
* or the user's travel history."
|
|
19
|
+
*/
|
|
20
|
+
instruction?: string;
|
|
21
|
+
}
|
package/api/types/Session.d.ts
CHANGED
|
@@ -1,11 +1,13 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* This file was auto-generated by Fern from our API Definition.
|
|
3
3
|
*/
|
|
4
|
+
import * as Zep from "../index";
|
|
4
5
|
export interface Session {
|
|
5
6
|
classifications?: Record<string, string>;
|
|
6
7
|
createdAt?: string;
|
|
7
8
|
deletedAt?: string;
|
|
8
9
|
endedAt?: string;
|
|
10
|
+
factRatingInstruction?: Zep.FactRatingInstruction;
|
|
9
11
|
factVersionUuid?: string;
|
|
10
12
|
facts?: string[];
|
|
11
13
|
id?: number;
|
package/api/types/index.d.ts
CHANGED
|
@@ -9,6 +9,10 @@ export * from "./DocumentSearchResultPage";
|
|
|
9
9
|
export * from "./EndSessionResponse";
|
|
10
10
|
export * from "./EndSessionsResponse";
|
|
11
11
|
export * from "./Fact";
|
|
12
|
+
export * from "./FactRatingExamples";
|
|
13
|
+
export * from "./FactRatingInstruction";
|
|
14
|
+
export * from "./FactResponse";
|
|
15
|
+
export * from "./FactsResponse";
|
|
12
16
|
export * from "./Memory";
|
|
13
17
|
export * from "./MemorySearchResult";
|
|
14
18
|
export * from "./Message";
|
package/api/types/index.js
CHANGED
|
@@ -25,6 +25,10 @@ __exportStar(require("./DocumentSearchResultPage"), exports);
|
|
|
25
25
|
__exportStar(require("./EndSessionResponse"), exports);
|
|
26
26
|
__exportStar(require("./EndSessionsResponse"), exports);
|
|
27
27
|
__exportStar(require("./Fact"), exports);
|
|
28
|
+
__exportStar(require("./FactRatingExamples"), exports);
|
|
29
|
+
__exportStar(require("./FactRatingInstruction"), exports);
|
|
30
|
+
__exportStar(require("./FactResponse"), exports);
|
|
31
|
+
__exportStar(require("./FactsResponse"), exports);
|
|
28
32
|
__exportStar(require("./Memory"), exports);
|
|
29
33
|
__exportStar(require("./MemorySearchResult"), exports);
|
|
30
34
|
__exportStar(require("./Message"), exports);
|
|
@@ -77,7 +77,7 @@ class Document {
|
|
|
77
77
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
78
78
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ZepEnvironment.Default, "collections"),
|
|
79
79
|
method: "GET",
|
|
80
|
-
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "1.0.
|
|
80
|
+
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "1.0.8", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
|
|
81
81
|
contentType: "application/json",
|
|
82
82
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
83
83
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
@@ -152,7 +152,7 @@ class Document {
|
|
|
152
152
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
153
153
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ZepEnvironment.Default, `collections/${encodeURIComponent(collectionName)}`),
|
|
154
154
|
method: "GET",
|
|
155
|
-
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "1.0.
|
|
155
|
+
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "1.0.8", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
|
|
156
156
|
contentType: "application/json",
|
|
157
157
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
158
158
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
@@ -244,7 +244,7 @@ class Document {
|
|
|
244
244
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
245
245
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ZepEnvironment.Default, `collections/${encodeURIComponent(collectionName)}`),
|
|
246
246
|
method: "POST",
|
|
247
|
-
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "1.0.
|
|
247
|
+
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "1.0.8", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
|
|
248
248
|
contentType: "application/json",
|
|
249
249
|
body: yield serializers.CreateDocumentCollectionRequest.jsonOrThrow(request, {
|
|
250
250
|
unrecognizedObjectKeys: "strip",
|
|
@@ -338,7 +338,7 @@ class Document {
|
|
|
338
338
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
339
339
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ZepEnvironment.Default, `collections/${encodeURIComponent(collectionName)}`),
|
|
340
340
|
method: "DELETE",
|
|
341
|
-
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "1.0.
|
|
341
|
+
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "1.0.8", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
|
|
342
342
|
contentType: "application/json",
|
|
343
343
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
344
344
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
@@ -430,7 +430,7 @@ class Document {
|
|
|
430
430
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
431
431
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ZepEnvironment.Default, `collections/${encodeURIComponent(collectionName)}`),
|
|
432
432
|
method: "PATCH",
|
|
433
|
-
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "1.0.
|
|
433
|
+
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "1.0.8", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
|
|
434
434
|
contentType: "application/json",
|
|
435
435
|
body: yield serializers.UpdateDocumentCollectionRequest.jsonOrThrow(request, {
|
|
436
436
|
unrecognizedObjectKeys: "strip",
|
|
@@ -526,7 +526,7 @@ class Document {
|
|
|
526
526
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
527
527
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ZepEnvironment.Default, `collections/${encodeURIComponent(collectionName)}/documents`),
|
|
528
528
|
method: "POST",
|
|
529
|
-
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "1.0.
|
|
529
|
+
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "1.0.8", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
|
|
530
530
|
contentType: "application/json",
|
|
531
531
|
body: yield serializers.document.addDocuments.Request.jsonOrThrow(request, {
|
|
532
532
|
unrecognizedObjectKeys: "strip",
|
|
@@ -612,7 +612,7 @@ class Document {
|
|
|
612
612
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
613
613
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ZepEnvironment.Default, `collections/${encodeURIComponent(collectionName)}/documents/batchDelete`),
|
|
614
614
|
method: "POST",
|
|
615
|
-
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "1.0.
|
|
615
|
+
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "1.0.8", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
|
|
616
616
|
contentType: "application/json",
|
|
617
617
|
body: yield serializers.document.batchDeleteDocuments.Request.jsonOrThrow(request, {
|
|
618
618
|
unrecognizedObjectKeys: "strip",
|
|
@@ -698,7 +698,7 @@ class Document {
|
|
|
698
698
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
699
699
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ZepEnvironment.Default, `collections/${encodeURIComponent(collectionName)}/documents/batchGet`),
|
|
700
700
|
method: "POST",
|
|
701
|
-
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "1.0.
|
|
701
|
+
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "1.0.8", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
|
|
702
702
|
contentType: "application/json",
|
|
703
703
|
body: yield serializers.GetDocumentListRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
|
704
704
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -784,7 +784,7 @@ class Document {
|
|
|
784
784
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
785
785
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ZepEnvironment.Default, `collections/${encodeURIComponent(collectionName)}/documents/batchUpdate`),
|
|
786
786
|
method: "PATCH",
|
|
787
|
-
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "1.0.
|
|
787
|
+
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "1.0.8", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
|
|
788
788
|
contentType: "application/json",
|
|
789
789
|
body: yield serializers.document.batchUpdateDocuments.Request.jsonOrThrow(request, {
|
|
790
790
|
unrecognizedObjectKeys: "strip",
|
|
@@ -870,7 +870,7 @@ class Document {
|
|
|
870
870
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
871
871
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ZepEnvironment.Default, `collections/${encodeURIComponent(collectionName)}/documents/uuid/${encodeURIComponent(documentUuid)}`),
|
|
872
872
|
method: "GET",
|
|
873
|
-
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "1.0.
|
|
873
|
+
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "1.0.8", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
|
|
874
874
|
contentType: "application/json",
|
|
875
875
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
876
876
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
@@ -954,7 +954,7 @@ class Document {
|
|
|
954
954
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
955
955
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ZepEnvironment.Default, `collections/${encodeURIComponent(collectionName)}/documents/uuid/${encodeURIComponent(documentUuid)}`),
|
|
956
956
|
method: "DELETE",
|
|
957
|
-
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "1.0.
|
|
957
|
+
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "1.0.8", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
|
|
958
958
|
contentType: "application/json",
|
|
959
959
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
960
960
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
@@ -1047,7 +1047,7 @@ class Document {
|
|
|
1047
1047
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
1048
1048
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ZepEnvironment.Default, `collections/${encodeURIComponent(collectionName)}/documents/uuid/${encodeURIComponent(documentUuid)}`),
|
|
1049
1049
|
method: "PATCH",
|
|
1050
|
-
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "1.0.
|
|
1050
|
+
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "1.0.8", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
|
|
1051
1051
|
contentType: "application/json",
|
|
1052
1052
|
body: yield serializers.UpdateDocumentRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
|
1053
1053
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -1144,7 +1144,7 @@ class Document {
|
|
|
1144
1144
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
1145
1145
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ZepEnvironment.Default, `collections/${encodeURIComponent(collectionName)}/search`),
|
|
1146
1146
|
method: "POST",
|
|
1147
|
-
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "1.0.
|
|
1147
|
+
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "1.0.8", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
|
|
1148
1148
|
contentType: "application/json",
|
|
1149
1149
|
queryParameters: _queryParams,
|
|
1150
1150
|
body: yield serializers.DocumentSearchPayload.jsonOrThrow(_body, { unrecognizedObjectKeys: "strip" }),
|
|
@@ -19,6 +19,32 @@ export declare namespace Memory {
|
|
|
19
19
|
export declare class Memory {
|
|
20
20
|
protected readonly _options: Memory.Options;
|
|
21
21
|
constructor(_options?: Memory.Options);
|
|
22
|
+
/**
|
|
23
|
+
* get fact by uuid
|
|
24
|
+
*
|
|
25
|
+
* @param {string} factUuid - Fact UUID
|
|
26
|
+
* @param {Memory.RequestOptions} requestOptions - Request-specific configuration.
|
|
27
|
+
*
|
|
28
|
+
* @throws {@link Zep.NotFoundError}
|
|
29
|
+
* @throws {@link Zep.InternalServerError}
|
|
30
|
+
*
|
|
31
|
+
* @example
|
|
32
|
+
* await zep.memory.getFact("factUUID")
|
|
33
|
+
*/
|
|
34
|
+
getFact(factUuid: string, requestOptions?: Memory.RequestOptions): Promise<Zep.FactResponse>;
|
|
35
|
+
/**
|
|
36
|
+
* delete a fact
|
|
37
|
+
*
|
|
38
|
+
* @param {string} factUuid - Fact UUID
|
|
39
|
+
* @param {Memory.RequestOptions} requestOptions - Request-specific configuration.
|
|
40
|
+
*
|
|
41
|
+
* @throws {@link Zep.NotFoundError}
|
|
42
|
+
* @throws {@link Zep.InternalServerError}
|
|
43
|
+
*
|
|
44
|
+
* @example
|
|
45
|
+
* await zep.memory.deleteFact("factUUID")
|
|
46
|
+
*/
|
|
47
|
+
deleteFact(factUuid: string, requestOptions?: Memory.RequestOptions): Promise<string>;
|
|
22
48
|
/**
|
|
23
49
|
* Create New Session
|
|
24
50
|
*
|
|
@@ -156,6 +182,20 @@ export declare class Memory {
|
|
|
156
182
|
* })
|
|
157
183
|
*/
|
|
158
184
|
extractData(sessionId: string, request: Zep.ExtractDataRequest, requestOptions?: Memory.RequestOptions): Promise<Record<string, string>>;
|
|
185
|
+
/**
|
|
186
|
+
* get facts for a session
|
|
187
|
+
*
|
|
188
|
+
* @param {string} sessionId - Session ID
|
|
189
|
+
* @param {Zep.MemoryGetSessionFactsRequest} request
|
|
190
|
+
* @param {Memory.RequestOptions} requestOptions - Request-specific configuration.
|
|
191
|
+
*
|
|
192
|
+
* @throws {@link Zep.NotFoundError}
|
|
193
|
+
* @throws {@link Zep.InternalServerError}
|
|
194
|
+
*
|
|
195
|
+
* @example
|
|
196
|
+
* await zep.memory.getSessionFacts("sessionId")
|
|
197
|
+
*/
|
|
198
|
+
getSessionFacts(sessionId: string, request?: Zep.MemoryGetSessionFactsRequest, requestOptions?: Memory.RequestOptions): Promise<Zep.FactsResponse>;
|
|
159
199
|
/**
|
|
160
200
|
* Returns a memory (latest summary, list of messages and facts for models.MemoryTypePerpetual) for a given session
|
|
161
201
|
*
|