@honcho-ai/core 1.7.0 → 1.8.0

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 (62) hide show
  1. package/CHANGELOG.md +18 -0
  2. package/index.d.mts +2 -2
  3. package/index.d.ts +2 -2
  4. package/index.d.ts.map +1 -1
  5. package/index.js.map +1 -1
  6. package/index.mjs.map +1 -1
  7. package/package.json +1 -1
  8. package/resources/index.d.ts +1 -1
  9. package/resources/index.d.ts.map +1 -1
  10. package/resources/index.js.map +1 -1
  11. package/resources/index.mjs.map +1 -1
  12. package/resources/workspaces/index.d.ts +2 -3
  13. package/resources/workspaces/index.d.ts.map +1 -1
  14. package/resources/workspaces/index.js +1 -4
  15. package/resources/workspaces/index.js.map +1 -1
  16. package/resources/workspaces/index.mjs +0 -1
  17. package/resources/workspaces/index.mjs.map +1 -1
  18. package/resources/workspaces/observations.d.ts +9 -19
  19. package/resources/workspaces/observations.d.ts.map +1 -1
  20. package/resources/workspaces/observations.js +0 -6
  21. package/resources/workspaces/observations.js.map +1 -1
  22. package/resources/workspaces/observations.mjs +0 -6
  23. package/resources/workspaces/observations.mjs.map +1 -1
  24. package/resources/workspaces/peers/index.d.ts +1 -1
  25. package/resources/workspaces/peers/index.d.ts.map +1 -1
  26. package/resources/workspaces/peers/index.js.map +1 -1
  27. package/resources/workspaces/peers/index.mjs.map +1 -1
  28. package/resources/workspaces/peers/peers.d.ts +64 -66
  29. package/resources/workspaces/peers/peers.d.ts.map +1 -1
  30. package/resources/workspaces/peers/peers.js.map +1 -1
  31. package/resources/workspaces/peers/peers.mjs.map +1 -1
  32. package/resources/workspaces/sessions/sessions.d.ts +5 -68
  33. package/resources/workspaces/sessions/sessions.d.ts.map +1 -1
  34. package/resources/workspaces/sessions/sessions.js +2 -2
  35. package/resources/workspaces/sessions/sessions.js.map +1 -1
  36. package/resources/workspaces/sessions/sessions.mjs +2 -2
  37. package/resources/workspaces/sessions/sessions.mjs.map +1 -1
  38. package/resources/workspaces/workspaces.d.ts +5 -90
  39. package/resources/workspaces/workspaces.d.ts.map +1 -1
  40. package/resources/workspaces/workspaces.js +0 -11
  41. package/resources/workspaces/workspaces.js.map +1 -1
  42. package/resources/workspaces/workspaces.mjs +0 -11
  43. package/resources/workspaces/workspaces.mjs.map +1 -1
  44. package/src/index.ts +0 -4
  45. package/src/resources/index.ts +0 -2
  46. package/src/resources/workspaces/index.ts +1 -17
  47. package/src/resources/workspaces/observations.ts +9 -20
  48. package/src/resources/workspaces/peers/index.ts +1 -0
  49. package/src/resources/workspaces/peers/peers.ts +75 -76
  50. package/src/resources/workspaces/sessions/sessions.ts +5 -79
  51. package/src/resources/workspaces/workspaces.ts +4 -146
  52. package/src/version.ts +1 -1
  53. package/version.d.ts +1 -1
  54. package/version.js +1 -1
  55. package/version.mjs +1 -1
  56. package/resources/workspaces/conclusions.d.ts +0 -142
  57. package/resources/workspaces/conclusions.d.ts.map +0 -1
  58. package/resources/workspaces/conclusions.js +0 -47
  59. package/resources/workspaces/conclusions.js.map +0 -1
  60. package/resources/workspaces/conclusions.mjs +0 -42
  61. package/resources/workspaces/conclusions.mjs.map +0 -1
  62. package/src/resources/workspaces/conclusions.ts +0 -220
@@ -1,220 +0,0 @@
1
- // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
-
3
- import { APIResource } from "../../resource.js";
4
- import { isRequestOptions } from "../../core.js";
5
- import * as Core from "../../core.js";
6
- import { Page, type PageParams } from "../../pagination.js";
7
-
8
- export class Conclusions extends APIResource {
9
- /**
10
- * Create one or more conclusions.
11
- *
12
- * Conclusions are theory-of-mind facts derived from interactions between peers.
13
- */
14
- create(
15
- workspaceId: string,
16
- body: ConclusionCreateParams,
17
- options?: Core.RequestOptions,
18
- ): Core.APIPromise<ConclusionCreateResponse> {
19
- return this._client.post(`/v2/workspaces/${workspaceId}/conclusions`, { body, ...options });
20
- }
21
-
22
- /**
23
- * List conclusions using custom filters, ordered by recency unless `reverse` is
24
- * true.
25
- */
26
- list(
27
- workspaceId: string,
28
- params?: ConclusionListParams,
29
- options?: Core.RequestOptions,
30
- ): Core.PagePromise<ConclusionsPage, Conclusion>;
31
- list(workspaceId: string, options?: Core.RequestOptions): Core.PagePromise<ConclusionsPage, Conclusion>;
32
- list(
33
- workspaceId: string,
34
- params: ConclusionListParams | Core.RequestOptions = {},
35
- options?: Core.RequestOptions,
36
- ): Core.PagePromise<ConclusionsPage, Conclusion> {
37
- if (isRequestOptions(params)) {
38
- return this.list(workspaceId, {}, params);
39
- }
40
- const { page, reverse, size, ...body } = params;
41
- return this._client.getAPIList(`/v2/workspaces/${workspaceId}/conclusions/list`, ConclusionsPage, {
42
- query: { page, reverse, size },
43
- body,
44
- method: 'post',
45
- ...options,
46
- });
47
- }
48
-
49
- /**
50
- * Delete a specific conclusion (document).
51
- */
52
- delete(workspaceId: string, conclusionId: string, options?: Core.RequestOptions): Core.APIPromise<unknown> {
53
- return this._client.delete(`/v2/workspaces/${workspaceId}/conclusions/${conclusionId}`, options);
54
- }
55
-
56
- /**
57
- * Query conclusions using semantic search.
58
- */
59
- query(
60
- workspaceId: string,
61
- body: ConclusionQueryParams,
62
- options?: Core.RequestOptions,
63
- ): Core.APIPromise<ConclusionQueryResponse> {
64
- return this._client.post(`/v2/workspaces/${workspaceId}/conclusions/query`, { body, ...options });
65
- }
66
- }
67
-
68
- export class ConclusionsPage extends Page<Conclusion> {}
69
-
70
- /**
71
- * Conclusion response - external view of a document.
72
- */
73
- export interface Conclusion {
74
- id: string;
75
-
76
- content: string;
77
-
78
- created_at: string;
79
-
80
- /**
81
- * The peer the conclusion is about
82
- */
83
- observed_id: string;
84
-
85
- /**
86
- * The peer who made the conclusion
87
- */
88
- observer_id: string;
89
-
90
- session_id: string;
91
- }
92
-
93
- /**
94
- * Schema for creating a single conclusion.
95
- */
96
- export interface ConclusionCreate {
97
- content: string;
98
-
99
- /**
100
- * The peer the conclusion is about
101
- */
102
- observed_id: string;
103
-
104
- /**
105
- * The peer making the conclusion
106
- */
107
- observer_id: string;
108
-
109
- /**
110
- * The session this conclusion relates to
111
- */
112
- session_id: string;
113
- }
114
-
115
- /**
116
- * Schema for listing conclusions with optional filters.
117
- */
118
- export interface ConclusionGet {
119
- filters?: { [key: string]: unknown } | null;
120
- }
121
-
122
- /**
123
- * Query parameters for semantic search of conclusions.
124
- */
125
- export interface ConclusionQuery {
126
- /**
127
- * Semantic search query
128
- */
129
- query: string;
130
-
131
- /**
132
- * Maximum cosine distance threshold for results
133
- */
134
- distance?: number | null;
135
-
136
- /**
137
- * Additional filters to apply
138
- */
139
- filters?: { [key: string]: unknown } | null;
140
-
141
- /**
142
- * Number of results to return
143
- */
144
- top_k?: number;
145
- }
146
-
147
- export interface PageConclusion {
148
- items: Array<Conclusion>;
149
-
150
- page: number;
151
-
152
- size: number;
153
-
154
- pages?: number;
155
-
156
- total?: number;
157
- }
158
-
159
- export type ConclusionCreateResponse = Array<Conclusion>;
160
-
161
- export type ConclusionDeleteResponse = unknown;
162
-
163
- export type ConclusionQueryResponse = Array<Conclusion>;
164
-
165
- export interface ConclusionCreateParams {
166
- conclusions: Array<ConclusionCreate>;
167
- }
168
-
169
- export interface ConclusionListParams extends PageParams {
170
- /**
171
- * Query param: Whether to reverse the order of results
172
- */
173
- reverse?: boolean | null;
174
-
175
- /**
176
- * Body param:
177
- */
178
- filters?: { [key: string]: unknown } | null;
179
- }
180
-
181
- export interface ConclusionQueryParams {
182
- /**
183
- * Semantic search query
184
- */
185
- query: string;
186
-
187
- /**
188
- * Maximum cosine distance threshold for results
189
- */
190
- distance?: number | null;
191
-
192
- /**
193
- * Additional filters to apply
194
- */
195
- filters?: { [key: string]: unknown } | null;
196
-
197
- /**
198
- * Number of results to return
199
- */
200
- top_k?: number;
201
- }
202
-
203
- Conclusions.ConclusionsPage = ConclusionsPage;
204
-
205
- export declare namespace Conclusions {
206
- export {
207
- type Conclusion as Conclusion,
208
- type ConclusionCreate as ConclusionCreate,
209
- type ConclusionGet as ConclusionGet,
210
- type ConclusionQuery as ConclusionQuery,
211
- type PageConclusion as PageConclusion,
212
- type ConclusionCreateResponse as ConclusionCreateResponse,
213
- type ConclusionDeleteResponse as ConclusionDeleteResponse,
214
- type ConclusionQueryResponse as ConclusionQueryResponse,
215
- ConclusionsPage as ConclusionsPage,
216
- type ConclusionCreateParams as ConclusionCreateParams,
217
- type ConclusionListParams as ConclusionListParams,
218
- type ConclusionQueryParams as ConclusionQueryParams,
219
- };
220
- }