Skip to main content
Glama
Arize-ai

@arizeai/phoenix-mcp

Official
by Arize-ai

get-dataset-experiments

Retrieve all experiments conducted on a specific dataset to analyze testing history and metadata.

Instructions

List experiments run on a dataset.

Example usage: Show me all experiments run on dataset RGF0YXNldDox

Expected return: Array of experiment objects with metadata. Example: [ { "id": "experimentid1234", "dataset_id": "datasetid1234", "dataset_version_id": "datasetversionid1234", "repetitions": 1, "metadata": {}, "project_name": "Experiment-abc123", "created_at": "YYYY-MM-DDTHH:mm:ssZ", "updated_at": "YYYY-MM-DDTHH:mm:ssZ" } ]

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
datasetIdYes

Implementation Reference

  • The core handler function for the "get-dataset-experiments" tool. It fetches experiments for the given datasetId via the PhoenixClient API and returns a text content block with the JSON-stringified response data.
    async ({ datasetId }) => { const response = await client.GET( "/v1/datasets/{dataset_id}/experiments", { params: { path: { dataset_id: datasetId }, }, } ); return { content: [ { type: "text", text: JSON.stringify(response.data, null, 2), }, ], }; }
  • Zod input schema for the tool, defining 'datasetId' as a required string parameter.
    { datasetId: z.string(), },
  • Registration of the "get-dataset-experiments" MCP tool using McpServer.tool(), including the tool name, description reference, input schema, and inline handler function.
    server.tool( "get-dataset-experiments", GET_DATASET_EXPERIMENTS_DESCRIPTION, { datasetId: z.string(), }, async ({ datasetId }) => { const response = await client.GET( "/v1/datasets/{dataset_id}/experiments", { params: { path: { dataset_id: datasetId }, }, } ); return { content: [ { type: "text", text: JSON.stringify(response.data, null, 2), }, ], }; } );
  • Description constant for the "get-dataset-experiments" tool, providing usage examples and expected return format.
    const GET_DATASET_EXPERIMENTS_DESCRIPTION = `List experiments run on a dataset. Example usage: Show me all experiments run on dataset RGF0YXNldDox Expected return: Array of experiment objects with metadata. Example: [ { "id": "experimentid1234", "dataset_id": "datasetid1234", "dataset_version_id": "datasetversionid1234", "repetitions": 1, "metadata": {}, "project_name": "Experiment-abc123", "created_at": "YYYY-MM-DDTHH:mm:ssZ", "updated_at": "YYYY-MM-DDTHH:mm:ssZ" } ]`;
  • Invocation of initializeDatasetTools function during MCP server setup, which registers the dataset tools including "get-dataset-experiments".
    initializeDatasetTools({ client, server });

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/Arize-ai/phoenix'

If you have feedback or need assistance with the MCP directory API, please join our Discord server