@honcho-ai/core 1.8.0 → 2.0.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 (112) hide show
  1. package/CHANGELOG.md +40 -0
  2. package/LICENSE +1 -1
  3. package/README.md +12 -1
  4. package/index.d.mts +2 -5
  5. package/index.d.ts +2 -5
  6. package/index.d.ts.map +1 -1
  7. package/index.js +0 -3
  8. package/index.js.map +1 -1
  9. package/index.mjs +0 -3
  10. package/index.mjs.map +1 -1
  11. package/package.json +1 -1
  12. package/resources/index.d.ts +1 -2
  13. package/resources/index.d.ts.map +1 -1
  14. package/resources/index.js +1 -3
  15. package/resources/index.js.map +1 -1
  16. package/resources/index.mjs +0 -1
  17. package/resources/index.mjs.map +1 -1
  18. package/resources/workspaces/conclusions.d.ts +109 -0
  19. package/resources/workspaces/conclusions.d.ts.map +1 -0
  20. package/resources/workspaces/conclusions.js +54 -0
  21. package/resources/workspaces/conclusions.js.map +1 -0
  22. package/resources/workspaces/conclusions.mjs +49 -0
  23. package/resources/workspaces/conclusions.mjs.map +1 -0
  24. package/resources/workspaces/index.d.ts +6 -5
  25. package/resources/workspaces/index.d.ts.map +1 -1
  26. package/resources/workspaces/index.js +6 -4
  27. package/resources/workspaces/index.js.map +1 -1
  28. package/resources/workspaces/index.mjs +2 -1
  29. package/resources/workspaces/index.mjs.map +1 -1
  30. package/resources/workspaces/peers/index.d.ts +1 -1
  31. package/resources/workspaces/peers/index.d.ts.map +1 -1
  32. package/resources/workspaces/peers/index.js.map +1 -1
  33. package/resources/workspaces/peers/index.mjs.map +1 -1
  34. package/resources/workspaces/peers/peers.d.ts +83 -152
  35. package/resources/workspaces/peers/peers.d.ts.map +1 -1
  36. package/resources/workspaces/peers/peers.js +24 -20
  37. package/resources/workspaces/peers/peers.js.map +1 -1
  38. package/resources/workspaces/peers/peers.mjs +24 -20
  39. package/resources/workspaces/peers/peers.mjs.map +1 -1
  40. package/resources/workspaces/peers/sessions.d.ts +1 -1
  41. package/resources/workspaces/queue.d.ts +82 -0
  42. package/resources/workspaces/queue.d.ts.map +1 -0
  43. package/resources/workspaces/queue.js +16 -0
  44. package/resources/workspaces/queue.js.map +1 -0
  45. package/resources/workspaces/queue.mjs +12 -0
  46. package/resources/workspaces/queue.mjs.map +1 -0
  47. package/resources/workspaces/sessions/index.d.ts +2 -2
  48. package/resources/workspaces/sessions/index.d.ts.map +1 -1
  49. package/resources/workspaces/sessions/index.js.map +1 -1
  50. package/resources/workspaces/sessions/index.mjs.map +1 -1
  51. package/resources/workspaces/sessions/messages.d.ts +13 -11
  52. package/resources/workspaces/sessions/messages.d.ts.map +1 -1
  53. package/resources/workspaces/sessions/messages.js +10 -8
  54. package/resources/workspaces/sessions/messages.js.map +1 -1
  55. package/resources/workspaces/sessions/messages.mjs +10 -8
  56. package/resources/workspaces/sessions/messages.mjs.map +1 -1
  57. package/resources/workspaces/sessions/peers.d.ts +15 -12
  58. package/resources/workspaces/sessions/peers.d.ts.map +1 -1
  59. package/resources/workspaces/sessions/peers.js +12 -7
  60. package/resources/workspaces/sessions/peers.js.map +1 -1
  61. package/resources/workspaces/sessions/peers.mjs +12 -7
  62. package/resources/workspaces/sessions/peers.mjs.map +1 -1
  63. package/resources/workspaces/sessions/sessions.d.ts +43 -58
  64. package/resources/workspaces/sessions/sessions.d.ts.map +1 -1
  65. package/resources/workspaces/sessions/sessions.js +21 -19
  66. package/resources/workspaces/sessions/sessions.js.map +1 -1
  67. package/resources/workspaces/sessions/sessions.mjs +21 -19
  68. package/resources/workspaces/sessions/sessions.mjs.map +1 -1
  69. package/resources/workspaces/webhooks.d.ts +2 -3
  70. package/resources/workspaces/webhooks.d.ts.map +1 -1
  71. package/resources/workspaces/webhooks.js +4 -1
  72. package/resources/workspaces/webhooks.js.map +1 -1
  73. package/resources/workspaces/webhooks.mjs +4 -1
  74. package/resources/workspaces/webhooks.mjs.map +1 -1
  75. package/resources/workspaces/workspaces.d.ts +73 -125
  76. package/resources/workspaces/workspaces.d.ts.map +1 -1
  77. package/resources/workspaces/workspaces.js +34 -25
  78. package/resources/workspaces/workspaces.js.map +1 -1
  79. package/resources/workspaces/workspaces.mjs +36 -27
  80. package/resources/workspaces/workspaces.mjs.map +1 -1
  81. package/src/index.ts +4 -17
  82. package/src/resources/index.ts +2 -5
  83. package/src/resources/workspaces/conclusions.ts +178 -0
  84. package/src/resources/workspaces/index.ts +18 -26
  85. package/src/resources/workspaces/peers/index.ts +4 -5
  86. package/src/resources/workspaces/peers/peers.ts +104 -182
  87. package/src/resources/workspaces/peers/sessions.ts +1 -1
  88. package/src/resources/workspaces/queue.ts +111 -0
  89. package/src/resources/workspaces/sessions/index.ts +2 -3
  90. package/src/resources/workspaces/sessions/messages.ts +25 -23
  91. package/src/resources/workspaces/sessions/peers.ts +16 -14
  92. package/src/resources/workspaces/sessions/sessions.ts +56 -72
  93. package/src/resources/workspaces/webhooks.ts +5 -5
  94. package/src/resources/workspaces/workspaces.ts +125 -209
  95. package/src/version.ts +1 -1
  96. package/version.d.ts +1 -1
  97. package/version.js +1 -1
  98. package/version.mjs +1 -1
  99. package/resources/keys.d.ts +0 -29
  100. package/resources/keys.d.ts.map +0 -1
  101. package/resources/keys.js +0 -20
  102. package/resources/keys.js.map +0 -1
  103. package/resources/keys.mjs +0 -16
  104. package/resources/keys.mjs.map +0 -1
  105. package/resources/workspaces/observations.d.ts +0 -156
  106. package/resources/workspaces/observations.d.ts.map +0 -1
  107. package/resources/workspaces/observations.js +0 -58
  108. package/resources/workspaces/observations.js.map +0 -1
  109. package/resources/workspaces/observations.mjs +0 -53
  110. package/resources/workspaces/observations.mjs.map +0 -1
  111. package/src/resources/keys.ts +0 -51
  112. package/src/resources/workspaces/observations.ts +0 -238
@@ -1,3 +1,3 @@
1
- export { PeersPage, Peers, type PagePeer, type PageSession, type Peer, type PeerCardResponse, type Representation, type SessionGet, type PeerChatResponse, type PeerGetContextResponse, type PeerSearchResponse, type PeerWorkingRepresentationResponse, type PeerUpdateParams, type PeerListParams, type PeerCardParams, type PeerChatParams, type PeerGetContextParams, type PeerGetOrCreateParams, type PeerSearchParams, type PeerSetCardParams, type PeerWorkingRepresentationParams, } from "./peers.js";
1
+ export { PeersPage, Peers, type PagePeer, type PageSession, type Peer, type PeerCardResponse, type SessionGet, type PeerChatResponse, type PeerContextResponse, type PeerRepresentationResponse, type PeerSearchResponse, type PeerUpdateParams, type PeerListParams, type PeerCardParams, type PeerChatParams, type PeerContextParams, type PeerGetOrCreateParams, type PeerRepresentationParams, type PeerSearchParams, type PeerSetCardParams, } from "./peers.js";
2
2
  export { Sessions, type SessionListParams } from "./sessions.js";
3
3
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/resources/workspaces/peers/index.ts"],"names":[],"mappings":"AAEA,OAAO,EACL,SAAS,EACT,KAAK,EACL,KAAK,QAAQ,EACb,KAAK,WAAW,EAChB,KAAK,IAAI,EACT,KAAK,gBAAgB,EACrB,KAAK,cAAc,EACnB,KAAK,UAAU,EACf,KAAK,gBAAgB,EACrB,KAAK,sBAAsB,EAC3B,KAAK,kBAAkB,EACvB,KAAK,iCAAiC,EACtC,KAAK,gBAAgB,EACrB,KAAK,cAAc,EACnB,KAAK,cAAc,EACnB,KAAK,cAAc,EACnB,KAAK,oBAAoB,EACzB,KAAK,qBAAqB,EAC1B,KAAK,gBAAgB,EACrB,KAAK,iBAAiB,EACtB,KAAK,+BAA+B,GACrC,MAAM,SAAS,CAAC;AACjB,OAAO,EAAE,QAAQ,EAAE,KAAK,iBAAiB,EAAE,MAAM,YAAY,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/resources/workspaces/peers/index.ts"],"names":[],"mappings":"AAEA,OAAO,EACL,SAAS,EACT,KAAK,EACL,KAAK,QAAQ,EACb,KAAK,WAAW,EAChB,KAAK,IAAI,EACT,KAAK,gBAAgB,EACrB,KAAK,UAAU,EACf,KAAK,gBAAgB,EACrB,KAAK,mBAAmB,EACxB,KAAK,0BAA0B,EAC/B,KAAK,kBAAkB,EACvB,KAAK,gBAAgB,EACrB,KAAK,cAAc,EACnB,KAAK,cAAc,EACnB,KAAK,cAAc,EACnB,KAAK,iBAAiB,EACtB,KAAK,qBAAqB,EAC1B,KAAK,wBAAwB,EAC7B,KAAK,gBAAgB,EACrB,KAAK,iBAAiB,GACvB,MAAM,SAAS,CAAC;AACjB,OAAO,EAAE,QAAQ,EAAE,KAAK,iBAAiB,EAAE,MAAM,YAAY,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/resources/workspaces/peers/index.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,oCAsBiB;AArBf,kGAAA,SAAS,OAAA;AACT,8FAAA,KAAK,OAAA;AAqBP,0CAA8D;AAArD,oGAAA,QAAQ,OAAA"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/resources/workspaces/peers/index.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,oCAqBiB;AApBf,kGAAA,SAAS,OAAA;AACT,8FAAA,KAAK,OAAA;AAoBP,0CAA8D;AAArD,oGAAA,QAAQ,OAAA"}
@@ -1 +1 @@
1
- {"version":3,"file":"index.mjs","sourceRoot":"","sources":["../../../src/resources/workspaces/peers/index.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EACL,SAAS,EACT,KAAK,GAoBN;OACM,EAAE,QAAQ,EAA0B"}
1
+ {"version":3,"file":"index.mjs","sourceRoot":"","sources":["../../../src/resources/workspaces/peers/index.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EACL,SAAS,EACT,KAAK,GAmBN;OACM,EAAE,QAAQ,EAA0B"}
@@ -8,11 +8,11 @@ import { Page, type PageParams } from "../../../pagination.js";
8
8
  export declare class Peers extends APIResource {
9
9
  sessions: SessionsAPI.Sessions;
10
10
  /**
11
- * Update a Peer's name and/or metadata
11
+ * Update a Peer's metadata and/or configuration.
12
12
  */
13
13
  update(workspaceId: string, peerId: string, body: PeerUpdateParams, options?: Core.RequestOptions): Core.APIPromise<Peer>;
14
14
  /**
15
- * Get All Peers for a Workspace
15
+ * Get all Peers for a Workspace, paginated with optional filters.
16
16
  */
17
17
  list(workspaceId: string, params?: PeerListParams, options?: Core.RequestOptions): Core.PagePromise<PeersPage, Peer>;
18
18
  list(workspaceId: string, options?: Core.RequestOptions): Core.PagePromise<PeersPage, Peer>;
@@ -25,31 +25,44 @@ export declare class Peers extends APIResource {
25
25
  card(workspaceId: string, peerId: string, query?: PeerCardParams, options?: Core.RequestOptions): Core.APIPromise<PeerCardResponse>;
26
26
  card(workspaceId: string, peerId: string, options?: Core.RequestOptions): Core.APIPromise<PeerCardResponse>;
27
27
  /**
28
- * Chat
28
+ * Query a Peer's representation using natural language. Performs agentic search
29
+ * and reasoning to comprehensively answer the query based on all latent knowledge
30
+ * gathered about the peer from their messages and conclusions.
29
31
  */
30
32
  chat(workspaceId: string, peerId: string, body: PeerChatParams, options?: Core.RequestOptions): Core.APIPromise<PeerChatResponse>;
31
33
  /**
32
34
  * Get context for a peer, including their representation and peer card.
33
35
  *
34
- * This endpoint returns the working representation and peer card for a peer. If a
35
- * target is specified, returns the context for the target from the observer peer's
36
- * perspective. If no target is specified, returns the peer's own context
37
- * (self-observation).
36
+ * This endpoint returns a curated subset of the representation and peer card for a
37
+ * peer. If a target is specified, returns the context for the target from the
38
+ * observer peer's perspective. If no target is specified, returns the peer's own
39
+ * context (self-observation).
38
40
  *
39
41
  * This is useful for getting all the context needed about a peer without making
40
42
  * multiple API calls.
41
43
  */
42
- getContext(workspaceId: string, peerId: string, query?: PeerGetContextParams, options?: Core.RequestOptions): Core.APIPromise<PeerGetContextResponse>;
43
- getContext(workspaceId: string, peerId: string, options?: Core.RequestOptions): Core.APIPromise<PeerGetContextResponse>;
44
+ context(workspaceId: string, peerId: string, query?: PeerContextParams, options?: Core.RequestOptions): Core.APIPromise<PeerContextResponse>;
45
+ context(workspaceId: string, peerId: string, options?: Core.RequestOptions): Core.APIPromise<PeerContextResponse>;
44
46
  /**
45
- * Get a Peer by ID
47
+ * Get a Peer by ID or create a new Peer with the given ID.
46
48
  *
47
49
  * If peer_id is provided as a query parameter, it uses that (must match JWT
48
50
  * workspace_id). Otherwise, it uses the peer_id from the JWT.
49
51
  */
50
52
  getOrCreate(workspaceId: string, body: PeerGetOrCreateParams, options?: Core.RequestOptions): Core.APIPromise<Peer>;
51
53
  /**
52
- * Search a Peer
54
+ * Get a curated subset of a Peer's Representation. A Representation is always a
55
+ * subset of the total knowledge about the Peer. The subset can be scoped and
56
+ * filtered in various ways.
57
+ *
58
+ * If a session_id is provided in the body, we get the Representation of the Peer
59
+ * scoped to that Session. If a target is provided, we get the Representation of
60
+ * the target from the perspective of the Peer. If no target is provided, we get
61
+ * the omniscient Honcho Representation of the Peer.
62
+ */
63
+ representation(workspaceId: string, peerId: string, body: PeerRepresentationParams, options?: Core.RequestOptions): Core.APIPromise<PeerRepresentationResponse>;
64
+ /**
65
+ * Search a Peer's messages, optionally filtered by various criteria.
53
66
  */
54
67
  search(workspaceId: string, peerId: string, body: PeerSearchParams, options?: Core.RequestOptions): Core.APIPromise<PeerSearchResponse>;
55
68
  /**
@@ -59,15 +72,6 @@ export declare class Peers extends APIResource {
59
72
  * is specified, sets the observer's own peer card.
60
73
  */
61
74
  setCard(workspaceId: string, peerId: string, params: PeerSetCardParams, options?: Core.RequestOptions): Core.APIPromise<PeerCardResponse>;
62
- /**
63
- * Get a peer's working representation for a session.
64
- *
65
- * If a session_id is provided in the body, we get the working representation of
66
- * the peer in that session. If a target is provided, we get the representation of
67
- * the target from the perspective of the peer. If no target is provided, we get
68
- * the omniscient Honcho representation of the peer.
69
- */
70
- workingRepresentation(workspaceId: string, peerId: string, body: PeerWorkingRepresentationParams, options?: Core.RequestOptions): Core.APIPromise<PeerWorkingRepresentationResponse>;
71
75
  }
72
76
  export declare class PeersPage extends Page<Peer> {
73
77
  }
@@ -102,68 +106,6 @@ export interface PeerCardResponse {
102
106
  */
103
107
  peer_card?: Array<string> | null;
104
108
  }
105
- /**
106
- * A Representation is a traversable and diffable map of observations. At the base,
107
- * we have a list of explicit observations, derived from a peer's messages.
108
- *
109
- * From there, deductive observations can be made by establishing logical
110
- * relationships between explicit observations.
111
- *
112
- * In the future, we can add more levels of reasoning on top of these.
113
- *
114
- * All of a peer's observations are stored as documents in a collection. These
115
- * documents can be queried in various ways to produce this Representation object.
116
- *
117
- * Additionally, a "working representation" is a version of this data structure
118
- * representing the most recent observations within a single session.
119
- *
120
- * A representation can have a maximum number of observations, which is applied
121
- * individually to each level of reasoning. If a maximum is set, observations are
122
- * added and removed in FIFO order.
123
- */
124
- export interface Representation {
125
- /**
126
- * Conclusions that MUST be true given explicit facts and premises - strict logical
127
- * necessities. Each deduction should have premises and a single conclusion.
128
- */
129
- deductive?: Array<Representation.Deductive>;
130
- /**
131
- * Facts LITERALLY stated by the user - direct quotes or clear paraphrases only, no
132
- * interpretation or inference. Example: ['The user is 25 years old', 'The user has
133
- * a dog']
134
- */
135
- explicit?: Array<Representation.Explicit>;
136
- }
137
- export declare namespace Representation {
138
- /**
139
- * Deductive observation with multiple premises and one conclusion, plus metadata.
140
- */
141
- interface Deductive {
142
- /**
143
- * The deductive conclusion
144
- */
145
- conclusion: string;
146
- created_at: string;
147
- message_ids: Array<number>;
148
- session_name: string;
149
- /**
150
- * Supporting premises or evidence for this conclusion
151
- */
152
- premises?: Array<string>;
153
- }
154
- /**
155
- * Explicit observation with content and metadata.
156
- */
157
- interface Explicit {
158
- /**
159
- * The explicit observation
160
- */
161
- content: string;
162
- created_at: string;
163
- message_ids: Array<number>;
164
- session_name: string;
165
- }
166
- }
167
109
  export interface SessionGet {
168
110
  filters?: {
169
111
  [key: string]: unknown;
@@ -175,7 +117,7 @@ export interface PeerChatResponse {
175
117
  /**
176
118
  * Context for a peer, including representation and peer card.
177
119
  */
178
- export interface PeerGetContextResponse {
120
+ export interface PeerContextResponse {
179
121
  /**
180
122
  * The ID of the peer
181
123
  */
@@ -189,30 +131,15 @@ export interface PeerGetContextResponse {
189
131
  */
190
132
  peer_card?: Array<string> | null;
191
133
  /**
192
- * A Representation is a traversable and diffable map of observations. At the base,
193
- * we have a list of explicit observations, derived from a peer's messages.
194
- *
195
- * From there, deductive observations can be made by establishing logical
196
- * relationships between explicit observations.
197
- *
198
- * In the future, we can add more levels of reasoning on top of these.
199
- *
200
- * All of a peer's observations are stored as documents in a collection. These
201
- * documents can be queried in various ways to produce this Representation object.
202
- *
203
- * Additionally, a "working representation" is a version of this data structure
204
- * representing the most recent observations within a single session.
205
- *
206
- * A representation can have a maximum number of observations, which is applied
207
- * individually to each level of reasoning. If a maximum is set, observations are
208
- * added and removed in FIFO order.
134
+ * A curated subset of the representation of the target peer from the observer's
135
+ * perspective
209
136
  */
210
- representation?: Representation | null;
137
+ representation?: string | null;
138
+ }
139
+ export interface PeerRepresentationResponse {
140
+ representation: string;
211
141
  }
212
142
  export type PeerSearchResponse = Array<MessagesAPI.Message>;
213
- export type PeerWorkingRepresentationResponse = {
214
- [key: string]: unknown;
215
- };
216
143
  export interface PeerUpdateParams {
217
144
  configuration?: {
218
145
  [key: string]: unknown;
@@ -231,8 +158,8 @@ export interface PeerListParams extends PageParams {
231
158
  }
232
159
  export interface PeerCardParams {
233
160
  /**
234
- * The peer whose card to retrieve. If not provided, returns the observer's own
235
- * card
161
+ * Optional target peer to retrieve a card for, from the observer's perspective. If
162
+ * not provided, returns the observer's own card
236
163
  */
237
164
  target?: string | null;
238
165
  }
@@ -241,6 +168,10 @@ export interface PeerChatParams {
241
168
  * Dialectic API Prompt
242
169
  */
243
170
  query: string;
171
+ /**
172
+ * Level of reasoning to apply: minimal, low, medium, high, or extra-high
173
+ */
174
+ reasoning_level?: 'minimal' | 'low' | 'medium' | 'high' | 'extra-high';
244
175
  /**
245
176
  * ID of the session to scope the representation to
246
177
  */
@@ -251,18 +182,18 @@ export interface PeerChatParams {
251
182
  */
252
183
  target?: string | null;
253
184
  }
254
- export interface PeerGetContextParams {
185
+ export interface PeerContextParams {
255
186
  /**
256
- * Whether to include the most derived observations in the representation
187
+ * Whether to include the most frequent conclusions in the representation
257
188
  */
258
- include_most_derived?: boolean;
189
+ include_most_frequent?: boolean;
259
190
  /**
260
- * Maximum number of observations to include in the representation
191
+ * Maximum number of conclusions to include in the representation
261
192
  */
262
- max_observations?: number | null;
193
+ max_conclusions?: number | null;
263
194
  /**
264
195
  * Only used if `search_query` is provided. Maximum distance for semantically
265
- * relevant observations
196
+ * relevant conclusions
266
197
  */
267
198
  search_max_distance?: number | null;
268
199
  /**
@@ -271,12 +202,12 @@ export interface PeerGetContextParams {
271
202
  search_query?: string | null;
272
203
  /**
273
204
  * Only used if `search_query` is provided. Number of semantic-search-retrieved
274
- * observations to include
205
+ * conclusions to include
275
206
  */
276
207
  search_top_k?: number | null;
277
208
  /**
278
- * The target peer to get context for. If not provided, returns the peer's own
279
- * context (self-observation)
209
+ * Optional target peer to get context for, from the observer's perspective. If not
210
+ * provided, returns the observer's own context (self-observation)
280
211
  */
281
212
  target?: string | null;
282
213
  }
@@ -289,47 +220,20 @@ export interface PeerGetOrCreateParams {
289
220
  [key: string]: unknown;
290
221
  } | null;
291
222
  }
292
- export interface PeerSearchParams {
293
- /**
294
- * Search query
295
- */
296
- query: string;
297
- /**
298
- * Filters to scope the search
299
- */
300
- filters?: {
301
- [key: string]: unknown;
302
- } | null;
303
- /**
304
- * Number of results to return
305
- */
306
- limit?: number;
307
- }
308
- export interface PeerSetCardParams {
309
- /**
310
- * Body param: The peer card content to set
311
- */
312
- peer_card: Array<string>;
313
- /**
314
- * Query param: The peer whose card to set. If not provided, sets the observer's
315
- * own card
316
- */
317
- target?: string | null;
318
- }
319
- export interface PeerWorkingRepresentationParams {
223
+ export interface PeerRepresentationParams {
320
224
  /**
321
- * Only used if `search_query` is provided. Whether to include the most derived
322
- * observations in the representation
225
+ * Only used if `search_query` is provided. Whether to include the most frequent
226
+ * conclusions in the representation
323
227
  */
324
- include_most_derived?: boolean | null;
228
+ include_most_frequent?: boolean | null;
325
229
  /**
326
- * Only used if `search_query` is provided. Maximum number of observations to
230
+ * Only used if `search_query` is provided. Maximum number of conclusions to
327
231
  * include in the representation
328
232
  */
329
- max_observations?: number | null;
233
+ max_conclusions?: number | null;
330
234
  /**
331
235
  * Only used if `search_query` is provided. Maximum distance to search for
332
- * semantically relevant observations
236
+ * semantically relevant conclusions
333
237
  */
334
238
  search_max_distance?: number | null;
335
239
  /**
@@ -338,11 +242,11 @@ export interface PeerWorkingRepresentationParams {
338
242
  search_query?: string | null;
339
243
  /**
340
244
  * Only used if `search_query` is provided. Number of semantic-search-retrieved
341
- * observations to include in the representation
245
+ * conclusions to include in the representation
342
246
  */
343
247
  search_top_k?: number | null;
344
248
  /**
345
- * Get the working representation within this session
249
+ * Optional session ID within which to scope the representation
346
250
  */
347
251
  session_id?: string | null;
348
252
  /**
@@ -351,8 +255,35 @@ export interface PeerWorkingRepresentationParams {
351
255
  */
352
256
  target?: string | null;
353
257
  }
258
+ export interface PeerSearchParams {
259
+ /**
260
+ * Search query
261
+ */
262
+ query: string;
263
+ /**
264
+ * Filters to scope the search
265
+ */
266
+ filters?: {
267
+ [key: string]: unknown;
268
+ } | null;
269
+ /**
270
+ * Number of results to return
271
+ */
272
+ limit?: number;
273
+ }
274
+ export interface PeerSetCardParams {
275
+ /**
276
+ * Body param: The peer card content to set
277
+ */
278
+ peer_card: Array<string>;
279
+ /**
280
+ * Query param: Optional target peer to set a card for, from the observer's
281
+ * perspective. If not provided, sets the observer's own card
282
+ */
283
+ target?: string | null;
284
+ }
354
285
  export declare namespace Peers {
355
- export { type PagePeer as PagePeer, type PageSession as PageSession, type Peer as Peer, type PeerCardResponse as PeerCardResponse, type Representation as Representation, type SessionGet as SessionGet, type PeerChatResponse as PeerChatResponse, type PeerGetContextResponse as PeerGetContextResponse, type PeerSearchResponse as PeerSearchResponse, type PeerWorkingRepresentationResponse as PeerWorkingRepresentationResponse, PeersPage as PeersPage, type PeerUpdateParams as PeerUpdateParams, type PeerListParams as PeerListParams, type PeerCardParams as PeerCardParams, type PeerChatParams as PeerChatParams, type PeerGetContextParams as PeerGetContextParams, type PeerGetOrCreateParams as PeerGetOrCreateParams, type PeerSearchParams as PeerSearchParams, type PeerSetCardParams as PeerSetCardParams, type PeerWorkingRepresentationParams as PeerWorkingRepresentationParams, };
286
+ export { type PagePeer as PagePeer, type PageSession as PageSession, type Peer as Peer, type PeerCardResponse as PeerCardResponse, type SessionGet as SessionGet, type PeerChatResponse as PeerChatResponse, type PeerContextResponse as PeerContextResponse, type PeerRepresentationResponse as PeerRepresentationResponse, type PeerSearchResponse as PeerSearchResponse, PeersPage as PeersPage, type PeerUpdateParams as PeerUpdateParams, type PeerListParams as PeerListParams, type PeerCardParams as PeerCardParams, type PeerChatParams as PeerChatParams, type PeerContextParams as PeerContextParams, type PeerGetOrCreateParams as PeerGetOrCreateParams, type PeerRepresentationParams as PeerRepresentationParams, type PeerSearchParams as PeerSearchParams, type PeerSetCardParams as PeerSetCardParams, };
356
287
  export { Sessions as Sessions, type SessionListParams as SessionListParams };
357
288
  }
358
289
  //# sourceMappingURL=peers.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"peers.d.ts","sourceRoot":"","sources":["../../../src/resources/workspaces/peers/peers.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAC;AAEhD,OAAO,KAAK,IAAI,MAAM,eAAe,CAAC;AACtC,OAAO,KAAK,WAAW,MAAM,YAAY,CAAC;AAC1C,OAAO,EAAE,iBAAiB,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AACzD,OAAO,KAAK,WAAW,MAAM,sBAAsB,CAAC;AACpD,OAAO,KAAK,mBAAmB,MAAM,sBAAsB,CAAC;AAC5D,OAAO,EAAE,IAAI,EAAE,KAAK,UAAU,EAAE,MAAM,qBAAqB,CAA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
39
- * Update a Peer's name and/or metadata
39
+ * Update a Peer's metadata and/or configuration.
40
40
  */
41
41
  update(workspaceId, peerId, body, options) {
42
42
  return this._client.put(`/v2/workspaces/${workspaceId}/peers/${peerId}`, { body, ...options });
@@ -60,19 +60,21 @@ class Peers extends resource_1.APIResource {
60
60
  return this._client.get(`/v2/workspaces/${workspaceId}/peers/${peerId}/card`, { query, ...options });
61
61
  }
62
62
  /**
63
- * Chat
63
+ * Query a Peer's representation using natural language. Performs agentic search
64
+ * and reasoning to comprehensively answer the query based on all latent knowledge
65
+ * gathered about the peer from their messages and conclusions.
64
66
  */
65
67
  chat(workspaceId, peerId, body, options) {
66
68
  return this._client.post(`/v2/workspaces/${workspaceId}/peers/${peerId}/chat`, { body, ...options });
67
69
  }
68
- getContext(workspaceId, peerId, query = {}, options) {
70
+ context(workspaceId, peerId, query = {}, options) {
69
71
  if ((0, core_1.isRequestOptions)(query)) {
70
- return this.getContext(workspaceId, peerId, {}, query);
72
+ return this.context(workspaceId, peerId, {}, query);
71
73
  }
72
74
  return this._client.get(`/v2/workspaces/${workspaceId}/peers/${peerId}/context`, { query, ...options });
73
75
  }
74
76
  /**
75
- * Get a Peer by ID
77
+ * Get a Peer by ID or create a new Peer with the given ID.
76
78
  *
77
79
  * If peer_id is provided as a query parameter, it uses that (must match JWT
78
80
  * workspace_id). Otherwise, it uses the peer_id from the JWT.
@@ -81,7 +83,23 @@ class Peers extends resource_1.APIResource {
81
83
  return this._client.post(`/v2/workspaces/${workspaceId}/peers`, { body, ...options });
82
84
  }
83
85
  /**
84
- * Search a Peer
86
+ * Get a curated subset of a Peer's Representation. A Representation is always a
87
+ * subset of the total knowledge about the Peer. The subset can be scoped and
88
+ * filtered in various ways.
89
+ *
90
+ * If a session_id is provided in the body, we get the Representation of the Peer
91
+ * scoped to that Session. If a target is provided, we get the Representation of
92
+ * the target from the perspective of the Peer. If no target is provided, we get
93
+ * the omniscient Honcho Representation of the Peer.
94
+ */
95
+ representation(workspaceId, peerId, body, options) {
96
+ return this._client.post(`/v2/workspaces/${workspaceId}/peers/${peerId}/representation`, {
97
+ body,
98
+ ...options,
99
+ });
100
+ }
101
+ /**
102
+ * Search a Peer's messages, optionally filtered by various criteria.
85
103
  */
86
104
  search(workspaceId, peerId, body, options) {
87
105
  return this._client.post(`/v2/workspaces/${workspaceId}/peers/${peerId}/search`, { body, ...options });
@@ -100,20 +118,6 @@ class Peers extends resource_1.APIResource {
100
118
  ...options,
101
119
  });
102
120
  }
103
- /**
104
- * Get a peer's working representation for a session.
105
- *
106
- * If a session_id is provided in the body, we get the working representation of
107
- * the peer in that session. If a target is provided, we get the representation of
108
- * the target from the perspective of the peer. If no target is provided, we get
109
- * the omniscient Honcho representation of the peer.
110
- */
111
- workingRepresentation(workspaceId, peerId, body, options) {
112
- return this._client.post(`/v2/workspaces/${workspaceId}/peers/${peerId}/representation`, {
113
- body,
114
- ...options,
115
- });
116
- }
117
121
  }
118
122
  exports.Peers = Peers;
119
123
  class PeersPage extends pagination_1.Page {
@@ -1 +1 @@
1
- {"version":3,"file":"peers.js","sourceRoot":"","sources":["../../../src/resources/workspaces/peers/peers.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;;;;;;;;;;;;;;;;;;;;;;;;AAEtF,mDAAgD;AAChD,2CAAiD;AAEjD,2DAA0C;AAC1C,4CAAyD;AAGzD,uDAA4D;AAE5D,MAAa,KAAM,SAAQ,sBAAW;IAAtC;;QACE,aAAQ,GAAyB,IAAI,WAAW,CAAC,QAAQ,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;IAgL1E,CAAC;IA9KC;;OAEG;IACH,MAAM,CACJ,WAAmB,EACnB,MAAc,EACd,IAAsB,EACtB,OAA6B;QAE7B,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,kBAAkB,WAAW,UAAU,MAAM,EAAE,EAAE,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACjG,CAAC;IAWD,IAAI,CACF,WAAmB,EACnB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vF,IAAI;YACJ,GAAG,OAAO;SACX,CAAC,CAAC;IACL,CAAC;IAED;;OAEG;IACH,MAAM,CACJ,WAAmB,EACnB,MAAc,EACd,IAAsB,EACtB,OAA6B;QAE7B,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,kBAAkB,WAAW,UAAU,MAAM,SAAS,EAAE,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACzG,CAAC;IAED;;;;;OAKG;IACH,OAAO,CACL,WAAmB,EACnB,MAAc,EACd,MAAyB,EACzB,OAA6B;QAE7B,MAAM,EAAE,MAAM,EAAE,GAAG,IAAI,EAAE,GAAG,MAAM,CAAC;QACnC,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,kBAAkB,WAAW,UAAU,MAAM,OAAO,EAAE;YAC5E,KAAK,EAAE,EAAE,MAAM,EAAE;YACjB,IAAI;YACJ,GAAG,OAAO;SACX,CAAC,CAAC;IACL,CAAC;CACF;AArLD,sBAqLC;AAED,MAAa,SAAU,SAAQ,iBAAU;CAAG;AAA5C,8BAA4C;AAqP5C,KAAK,CAAC,SAAS,GAAG,SAAS,CAAC;AAC5B,KAAK,CAAC,QAAQ,GAAG,mBAAQ,CAAC"}
@@ -10,7 +10,7 @@ export class Peers extends APIResource {
10
10
  this.sessions = new SessionsAPI.Sessions(this._client);
11
11
  }
12
12
  /**
13
- * Update a Peer's name and/or metadata
13
+ * Update a Peer's metadata and/or configuration.
14
14
  */
15
15
  update(workspaceId, peerId, body, options) {
16
16
  return this._client.put(`/v2/workspaces/${workspaceId}/peers/${peerId}`, { body, ...options });
@@ -34,19 +34,21 @@ export class Peers extends APIResource {
34
34
  return this._client.get(`/v2/workspaces/${workspaceId}/peers/${peerId}/card`, { query, ...options });
35
35
  }
36
36
  /**
37
- * Chat
37
+ * Query a Peer's representation using natural language. Performs agentic search
38
+ * and reasoning to comprehensively answer the query based on all latent knowledge
39
+ * gathered about the peer from their messages and conclusions.
38
40
  */
39
41
  chat(workspaceId, peerId, body, options) {
40
42
  return this._client.post(`/v2/workspaces/${workspaceId}/peers/${peerId}/chat`, { body, ...options });
41
43
  }
42
- getContext(workspaceId, peerId, query = {}, options) {
44
+ context(workspaceId, peerId, query = {}, options) {
43
45
  if (isRequestOptions(query)) {
44
- return this.getContext(workspaceId, peerId, {}, query);
46
+ return this.context(workspaceId, peerId, {}, query);
45
47
  }
46
48
  return this._client.get(`/v2/workspaces/${workspaceId}/peers/${peerId}/context`, { query, ...options });
47
49
  }
48
50
  /**
49
- * Get a Peer by ID
51
+ * Get a Peer by ID or create a new Peer with the given ID.
50
52
  *
51
53
  * If peer_id is provided as a query parameter, it uses that (must match JWT
52
54
  * workspace_id). Otherwise, it uses the peer_id from the JWT.
@@ -55,7 +57,23 @@ export class Peers extends APIResource {
55
57
  return this._client.post(`/v2/workspaces/${workspaceId}/peers`, { body, ...options });
56
58
  }
57
59
  /**
58
- * Search a Peer
60
+ * Get a curated subset of a Peer's Representation. A Representation is always a
61
+ * subset of the total knowledge about the Peer. The subset can be scoped and
62
+ * filtered in various ways.
63
+ *
64
+ * If a session_id is provided in the body, we get the Representation of the Peer
65
+ * scoped to that Session. If a target is provided, we get the Representation of
66
+ * the target from the perspective of the Peer. If no target is provided, we get
67
+ * the omniscient Honcho Representation of the Peer.
68
+ */
69
+ representation(workspaceId, peerId, body, options) {
70
+ return this._client.post(`/v2/workspaces/${workspaceId}/peers/${peerId}/representation`, {
71
+ body,
72
+ ...options,
73
+ });
74
+ }
75
+ /**
76
+ * Search a Peer's messages, optionally filtered by various criteria.
59
77
  */
60
78
  search(workspaceId, peerId, body, options) {
61
79
  return this._client.post(`/v2/workspaces/${workspaceId}/peers/${peerId}/search`, { body, ...options });
@@ -74,20 +92,6 @@ export class Peers extends APIResource {
74
92
  ...options,
75
93
  });
76
94
  }
77
- /**
78
- * Get a peer's working representation for a session.
79
- *
80
- * If a session_id is provided in the body, we get the working representation of
81
- * the peer in that session. If a target is provided, we get the representation of
82
- * the target from the perspective of the peer. If no target is provided, we get
83
- * the omniscient Honcho representation of the peer.
84
- */
85
- workingRepresentation(workspaceId, peerId, body, options) {
86
- return this._client.post(`/v2/workspaces/${workspaceId}/peers/${peerId}/representation`, {
87
- body,
88
- ...options,
89
- });
90
- }
91
95
  }
92
96
  export class PeersPage extends Page {
93
97
  }
@@ -1 +1 @@
1
- {"version":3,"file":"peers.mjs","sourceRoot":"","sources":["../../../src/resources/workspaces/peers/peers.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAE;OACf,EAAE,gBAAgB,EAAE;OAEpB,KAAK,WAAW;OAChB,EAAqB,QAAQ,EAAE;OAG/B,EAAE,IAAI,EAAmB;AAEhC,MAAM,OAAO,KAAM,SAAQ,WAAW;IAAtC;;QACE,aAAQ,GAAyB,IAAI,WAAW,CAAC,QAAQ,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;IAgL1E,CAAC;IA9KC;;OAEG;IACH,MAAM,CACJ,WAAmB,EACnB,MAAc,EACd,IAAsB,EACtB,OAA6B;QAE7B,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,kBAAkB,WAAW,UAAU,MAAM,EAAE,EAAE,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACjG,CAAC;IAWD,IAAI,CACF,WAAmB,EACnB,SAA+C,EAAE,EACjD,OAA6B;QAE7B,IAAI,gBAAgB,CAAC,MAAM,CAAC,EAAE;YAC5B,OAAO,IAAI,CAAC,IAAI,CAAC,WAAW,EAAE,EAAE,EAAE,MAAM,CAAC,CAAC;SAC3C;QACD,MAAM,EAAE,IAAI,EAAE,IAAI,EAAE,GAAG,IAAI,EAAE,GAAG,MAAM,CAAC;QACvC,OAAO,IAAI,CAAC,OAAO,CAAC,UAAU,CAAC,kBAAkB,WAAW,aAAa,EAAE,SAAS,EAAE;YACpF,KAAK,EAAE,EAAE,IAAI,EAAE,IAAI,EAAE;YACrB,IAAI;YACJ,MAAM,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,CAAC,OAAO,CAAC,GAAG,CAAC,kBAAkB,WAAW,UAAU,MAAM,OAAO,EAAE;YAC5E,KAAK,EAAE,EAAE,MAAM,EAAE;YACjB,IAAI;YACJ,GAAG,OAAO;SACX,CAAC,CAAC;IACL,CAAC;CACF;AAED,MAAM,OAAO,SAAU,SAAQ,IAAU;CAAG;AAqP5C,KAAK,CAAC,SAAS,GAAG,SAAS,CAAC;AAC5B,KAAK,CAAC,QAAQ,GAAG,QAAQ,CAAC"}
@@ -5,7 +5,7 @@ import { SessionsPage } from "../sessions/sessions.js";
5
5
  import { type PageParams } from "../../../pagination.js";
6
6
  export declare class Sessions extends APIResource {
7
7
  /**
8
- * Get All Sessions for a Peer
8
+ * Get all Sessions for a Peer, paginated with optional filters.
9
9
  */
10
10
  list(workspaceId: string, peerId: string, params?: SessionListParams, options?: Core.RequestOptions): Core.PagePromise<SessionsPage, SessionsSessionsAPI.Session>;
11
11
  list(workspaceId: string, peerId: string, options?: Core.RequestOptions): Core.PagePromise<SessionsPage, SessionsSessionsAPI.Session>;