@mastra/lance 0.0.0-scorers-ui-refactored-20250916094952 → 0.0.0-scorers-logs-20251208093427

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/README.md CHANGED
@@ -114,7 +114,7 @@ const message = await storage.load({
114
114
  });
115
115
 
116
116
  // Load messages from a thread
117
- const messages = await storage.getMessages({
117
+ const messages = await storage.listMessages({
118
118
  threadId: '123e4567-e89b-12d3-a456-426614174001',
119
119
  });
120
120
  ```
@@ -175,10 +175,12 @@ const messages: MessageType[] = [
175
175
  // Save messages
176
176
  await storage.saveMessages({ messages });
177
177
 
178
- // Retrieve messages with context
179
- const retrievedMessages = await storage.getMessages({
178
+ // Retrieve messages with pagination and context
179
+ const retrievedMessages = await storage.listMessages({
180
180
  threadId: '123e4567-e89b-12d3-a456-426614174010',
181
- selectBy: [
181
+ perPage: 10,
182
+ page: 0,
183
+ include: [
182
184
  {
183
185
  id: 'msg-001',
184
186
  withPreviousMessages: 5, // Include up to 5 messages before this one
@@ -261,3 +263,58 @@ await storage.clearTable({ tableName: TABLE_MESSAGES });
261
263
  // Get table schema
262
264
  const schema = await storage.getTableSchema(TABLE_MESSAGES);
263
265
  ```
266
+
267
+ ## Storage Methods
268
+
269
+ ### Thread Operations
270
+
271
+ - `saveThread({ thread })`: Create or update a thread
272
+ - `getThreadById({ threadId })`: Get a thread by ID
273
+ - `listThreadsByResourceId({ resourceId, offset, limit, orderBy? })`: List paginated threads for a resource
274
+ - `updateThread({ id, title, metadata })`: Update thread title and/or metadata
275
+ - `deleteThread({ threadId })`: Delete a thread and its messages
276
+
277
+ ### Message Operations
278
+
279
+ - `saveMessages({ messages })`: Save multiple messages in a transaction
280
+ - `listMessages({ threadId, resourceId?, perPage?, page?, orderBy?, filter?, include? })`: Get messages for a thread with pagination and optional context inclusion
281
+ - `listMessagesById({ messageIds })`: Get specific messages by their IDs
282
+ - `updateMessages({ messages })`: Update existing messages
283
+
284
+ ### Resource Operations
285
+
286
+ - `getResourceById({ resourceId })`: Get a resource by ID
287
+ - `saveResource({ resource })`: Create or save a resource
288
+ - `updateResource({ resourceId, workingMemory })`: Update resource working memory
289
+
290
+ ### Workflow Operations
291
+
292
+ - `persistWorkflowSnapshot({ workflowName, runId, snapshot })`: Save workflow state
293
+ - `loadWorkflowSnapshot({ workflowName, runId })`: Load workflow state
294
+ - `listWorkflowRuns({ workflowName?, pagination? })`: List workflow runs with pagination
295
+ - `getWorkflowRunById({ runId, workflowName? })`: Get a specific workflow run
296
+ - `updateWorkflowState({ workflowName, runId, state })`: Update workflow state
297
+ - `updateWorkflowResults({ workflowName, runId, results })`: Update workflow results
298
+
299
+ ### Evaluation/Scoring Operations
300
+
301
+ - `getScoreById({ id })`: Get a score by ID
302
+ - `saveScore(score)`: Save an evaluation score
303
+ - `listScoresByScorerId({ scorerId, pagination })`: List scores by scorer with pagination
304
+ - `listScoresByRunId({ runId, pagination })`: List scores by run with pagination
305
+ - `listScoresByEntityId({ entityId, entityType, pagination })`: List scores by entity with pagination
306
+ - `listScoresBySpan({ traceId, spanId, pagination })`: List scores by span with pagination
307
+
308
+ ### Low-Level Operations
309
+
310
+ - `createTable({ tableName, schema })`: Create a new table with schema
311
+ - `dropTable({ tableName })`: Drop a table
312
+ - `clearTable({ tableName })`: Clear all records from a table
313
+ - `insert({ tableName, record })`: Insert a single record
314
+ - `batchInsert({ tableName, records })`: Insert multiple records
315
+ - `load({ tableName, keys })`: Load a record by keys
316
+
317
+ ### Operations Not Currently Supported
318
+
319
+ - `deleteMessages(messageIds)`: Message deletion is not currently supported
320
+ - AI Observability (traces/spans): Not currently supported