@mastra/mongodb 1.7.0 → 1.7.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.js CHANGED
@@ -12,7 +12,7 @@ import { saveScorePayloadSchema } from '@mastra/core/evals';
12
12
 
13
13
  // package.json
14
14
  var package_default = {
15
- version: "1.7.0"};
15
+ version: "1.7.1"};
16
16
  var MongoDBFilterTranslator = class extends BaseFilterTranslator {
17
17
  getSupportedOperators() {
18
18
  return {
@@ -2827,6 +2827,18 @@ var MongoDBExperimentsStorage = class _MongoDBExperimentsStorage extends Experim
2827
2827
  if (args.datasetId) {
2828
2828
  filter.datasetId = args.datasetId;
2829
2829
  }
2830
+ if (args.targetType) {
2831
+ filter.targetType = args.targetType;
2832
+ }
2833
+ if (args.targetId) {
2834
+ filter.targetId = args.targetId;
2835
+ }
2836
+ if (args.agentVersion) {
2837
+ filter.agentVersion = args.agentVersion;
2838
+ }
2839
+ if (args.status) {
2840
+ filter.status = args.status;
2841
+ }
2830
2842
  const total = await collection.countDocuments(filter);
2831
2843
  if (total === 0) {
2832
2844
  return { experiments: [], pagination: { total: 0, page, perPage: perPageInput, hasMore: false } };
@@ -2999,6 +3011,12 @@ var MongoDBExperimentsStorage = class _MongoDBExperimentsStorage extends Experim
2999
3011
  const collection = await this.getCollection(TABLE_EXPERIMENT_RESULTS);
3000
3012
  const { page, perPage: perPageInput } = args.pagination;
3001
3013
  const filter = { experimentId: args.experimentId };
3014
+ if (args.traceId) {
3015
+ filter.traceId = args.traceId;
3016
+ }
3017
+ if (args.status) {
3018
+ filter.status = args.status;
3019
+ }
3002
3020
  const total = await collection.countDocuments(filter);
3003
3021
  if (total === 0) {
3004
3022
  return { results: [], pagination: { total: 0, page, perPage: perPageInput, hasMore: false } };