@arizeai/phoenix-client 6.1.0 → 6.2.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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@arizeai/phoenix-client",
3
- "version": "6.1.0",
3
+ "version": "6.2.0",
4
4
  "description": "A client for the Phoenix API",
5
5
  "keywords": [
6
6
  "arize",
@@ -1745,7 +1745,7 @@ export interface components {
1745
1745
  * ModelProvider
1746
1746
  * @enum {string}
1747
1747
  */
1748
- ModelProvider: "OPENAI" | "AZURE_OPENAI" | "ANTHROPIC" | "GOOGLE" | "DEEPSEEK" | "XAI" | "OLLAMA" | "AWS";
1748
+ ModelProvider: "OPENAI" | "AZURE_OPENAI" | "ANTHROPIC" | "GOOGLE" | "DEEPSEEK" | "XAI" | "OLLAMA" | "AWS" | "CEREBRAS" | "FIREWORKS" | "GROQ" | "MOONSHOT";
1749
1749
  /** OAuth2User */
1750
1750
  OAuth2User: {
1751
1751
  /** Id */
@@ -2122,6 +2122,37 @@ export interface components {
2122
2122
  */
2123
2123
  reasoning_effort?: "none" | "minimal" | "low" | "medium" | "high" | "xhigh";
2124
2124
  };
2125
+ /** PromptCerebrasInvocationParameters */
2126
+ PromptCerebrasInvocationParameters: {
2127
+ /**
2128
+ * @description discriminator enum property added by openapi-typescript
2129
+ * @enum {string}
2130
+ */
2131
+ type: "cerebras";
2132
+ cerebras: components["schemas"]["PromptCerebrasInvocationParametersContent"];
2133
+ };
2134
+ /** PromptCerebrasInvocationParametersContent */
2135
+ PromptCerebrasInvocationParametersContent: {
2136
+ /** Temperature */
2137
+ temperature?: number;
2138
+ /** Max Tokens */
2139
+ max_tokens?: number;
2140
+ /** Max Completion Tokens */
2141
+ max_completion_tokens?: number;
2142
+ /** Frequency Penalty */
2143
+ frequency_penalty?: number;
2144
+ /** Presence Penalty */
2145
+ presence_penalty?: number;
2146
+ /** Top P */
2147
+ top_p?: number;
2148
+ /** Seed */
2149
+ seed?: number;
2150
+ /**
2151
+ * Reasoning Effort
2152
+ * @enum {string}
2153
+ */
2154
+ reasoning_effort?: "none" | "minimal" | "low" | "medium" | "high" | "xhigh";
2155
+ };
2125
2156
  /** PromptChatTemplate */
2126
2157
  PromptChatTemplate: {
2127
2158
  /**
@@ -2175,6 +2206,37 @@ export interface components {
2175
2206
  */
2176
2207
  reasoning_effort?: "none" | "minimal" | "low" | "medium" | "high" | "xhigh";
2177
2208
  };
2209
+ /** PromptFireworksInvocationParameters */
2210
+ PromptFireworksInvocationParameters: {
2211
+ /**
2212
+ * @description discriminator enum property added by openapi-typescript
2213
+ * @enum {string}
2214
+ */
2215
+ type: "fireworks";
2216
+ fireworks: components["schemas"]["PromptFireworksInvocationParametersContent"];
2217
+ };
2218
+ /** PromptFireworksInvocationParametersContent */
2219
+ PromptFireworksInvocationParametersContent: {
2220
+ /** Temperature */
2221
+ temperature?: number;
2222
+ /** Max Tokens */
2223
+ max_tokens?: number;
2224
+ /** Max Completion Tokens */
2225
+ max_completion_tokens?: number;
2226
+ /** Frequency Penalty */
2227
+ frequency_penalty?: number;
2228
+ /** Presence Penalty */
2229
+ presence_penalty?: number;
2230
+ /** Top P */
2231
+ top_p?: number;
2232
+ /** Seed */
2233
+ seed?: number;
2234
+ /**
2235
+ * Reasoning Effort
2236
+ * @enum {string}
2237
+ */
2238
+ reasoning_effort?: "none" | "minimal" | "low" | "medium" | "high" | "xhigh";
2239
+ };
2178
2240
  /** PromptGoogleInvocationParameters */
2179
2241
  PromptGoogleInvocationParameters: {
2180
2242
  /**
@@ -2201,6 +2263,37 @@ export interface components {
2201
2263
  /** Top K */
2202
2264
  top_k?: number;
2203
2265
  };
2266
+ /** PromptGroqInvocationParameters */
2267
+ PromptGroqInvocationParameters: {
2268
+ /**
2269
+ * @description discriminator enum property added by openapi-typescript
2270
+ * @enum {string}
2271
+ */
2272
+ type: "groq";
2273
+ groq: components["schemas"]["PromptGroqInvocationParametersContent"];
2274
+ };
2275
+ /** PromptGroqInvocationParametersContent */
2276
+ PromptGroqInvocationParametersContent: {
2277
+ /** Temperature */
2278
+ temperature?: number;
2279
+ /** Max Tokens */
2280
+ max_tokens?: number;
2281
+ /** Max Completion Tokens */
2282
+ max_completion_tokens?: number;
2283
+ /** Frequency Penalty */
2284
+ frequency_penalty?: number;
2285
+ /** Presence Penalty */
2286
+ presence_penalty?: number;
2287
+ /** Top P */
2288
+ top_p?: number;
2289
+ /** Seed */
2290
+ seed?: number;
2291
+ /**
2292
+ * Reasoning Effort
2293
+ * @enum {string}
2294
+ */
2295
+ reasoning_effort?: "none" | "minimal" | "low" | "medium" | "high" | "xhigh";
2296
+ };
2204
2297
  /** PromptMessage */
2205
2298
  PromptMessage: {
2206
2299
  /**
@@ -2211,6 +2304,37 @@ export interface components {
2211
2304
  /** Content */
2212
2305
  content: string | (components["schemas"]["TextContentPart"] | components["schemas"]["ToolCallContentPart"] | components["schemas"]["ToolResultContentPart"])[];
2213
2306
  };
2307
+ /** PromptMoonshotInvocationParameters */
2308
+ PromptMoonshotInvocationParameters: {
2309
+ /**
2310
+ * @description discriminator enum property added by openapi-typescript
2311
+ * @enum {string}
2312
+ */
2313
+ type: "moonshot";
2314
+ moonshot: components["schemas"]["PromptMoonshotInvocationParametersContent"];
2315
+ };
2316
+ /** PromptMoonshotInvocationParametersContent */
2317
+ PromptMoonshotInvocationParametersContent: {
2318
+ /** Temperature */
2319
+ temperature?: number;
2320
+ /** Max Tokens */
2321
+ max_tokens?: number;
2322
+ /** Max Completion Tokens */
2323
+ max_completion_tokens?: number;
2324
+ /** Frequency Penalty */
2325
+ frequency_penalty?: number;
2326
+ /** Presence Penalty */
2327
+ presence_penalty?: number;
2328
+ /** Top P */
2329
+ top_p?: number;
2330
+ /** Seed */
2331
+ seed?: number;
2332
+ /**
2333
+ * Reasoning Effort
2334
+ * @enum {string}
2335
+ */
2336
+ reasoning_effort?: "none" | "minimal" | "low" | "medium" | "high" | "xhigh";
2337
+ };
2214
2338
  /** PromptOllamaInvocationParameters */
2215
2339
  PromptOllamaInvocationParameters: {
2216
2340
  /**
@@ -2397,7 +2521,7 @@ export interface components {
2397
2521
  template_type: components["schemas"]["PromptTemplateType"];
2398
2522
  template_format: components["schemas"]["PromptTemplateFormat"];
2399
2523
  /** Invocation Parameters */
2400
- invocation_parameters: components["schemas"]["PromptOpenAIInvocationParameters"] | components["schemas"]["PromptAzureOpenAIInvocationParameters"] | components["schemas"]["PromptAnthropicInvocationParameters"] | components["schemas"]["PromptGoogleInvocationParameters"] | components["schemas"]["PromptDeepSeekInvocationParameters"] | components["schemas"]["PromptXAIInvocationParameters"] | components["schemas"]["PromptOllamaInvocationParameters"] | components["schemas"]["PromptAwsInvocationParameters"];
2524
+ invocation_parameters: components["schemas"]["PromptOpenAIInvocationParameters"] | components["schemas"]["PromptAzureOpenAIInvocationParameters"] | components["schemas"]["PromptAnthropicInvocationParameters"] | components["schemas"]["PromptGoogleInvocationParameters"] | components["schemas"]["PromptDeepSeekInvocationParameters"] | components["schemas"]["PromptXAIInvocationParameters"] | components["schemas"]["PromptOllamaInvocationParameters"] | components["schemas"]["PromptAwsInvocationParameters"] | components["schemas"]["PromptCerebrasInvocationParameters"] | components["schemas"]["PromptFireworksInvocationParameters"] | components["schemas"]["PromptGroqInvocationParameters"] | components["schemas"]["PromptMoonshotInvocationParameters"];
2401
2525
  tools?: components["schemas"]["PromptTools"] | null;
2402
2526
  /** Response Format */
2403
2527
  response_format?: components["schemas"]["PromptResponseFormatJSONSchema"] | null;
@@ -2416,7 +2540,7 @@ export interface components {
2416
2540
  template_type: components["schemas"]["PromptTemplateType"];
2417
2541
  template_format: components["schemas"]["PromptTemplateFormat"];
2418
2542
  /** Invocation Parameters */
2419
- invocation_parameters: components["schemas"]["PromptOpenAIInvocationParameters"] | components["schemas"]["PromptAzureOpenAIInvocationParameters"] | components["schemas"]["PromptAnthropicInvocationParameters"] | components["schemas"]["PromptGoogleInvocationParameters"] | components["schemas"]["PromptDeepSeekInvocationParameters"] | components["schemas"]["PromptXAIInvocationParameters"] | components["schemas"]["PromptOllamaInvocationParameters"] | components["schemas"]["PromptAwsInvocationParameters"];
2543
+ invocation_parameters: components["schemas"]["PromptOpenAIInvocationParameters"] | components["schemas"]["PromptAzureOpenAIInvocationParameters"] | components["schemas"]["PromptAnthropicInvocationParameters"] | components["schemas"]["PromptGoogleInvocationParameters"] | components["schemas"]["PromptDeepSeekInvocationParameters"] | components["schemas"]["PromptXAIInvocationParameters"] | components["schemas"]["PromptOllamaInvocationParameters"] | components["schemas"]["PromptAwsInvocationParameters"] | components["schemas"]["PromptCerebrasInvocationParameters"] | components["schemas"]["PromptFireworksInvocationParameters"] | components["schemas"]["PromptGroqInvocationParameters"] | components["schemas"]["PromptMoonshotInvocationParameters"];
2420
2544
  tools?: components["schemas"]["PromptTools"] | null;
2421
2545
  /** Response Format */
2422
2546
  response_format?: components["schemas"]["PromptResponseFormatJSONSchema"] | null;
@@ -4635,6 +4759,8 @@ export interface operations {
4635
4759
  start_time?: string | null;
4636
4760
  /** @description Exclusive upper bound time */
4637
4761
  end_time?: string | null;
4762
+ /** @description Filter by one or more trace IDs */
4763
+ trace_id?: string[] | null;
4638
4764
  };
4639
4765
  header?: never;
4640
4766
  path: {
@@ -4694,6 +4820,8 @@ export interface operations {
4694
4820
  start_time?: string | null;
4695
4821
  /** @description Exclusive upper bound time */
4696
4822
  end_time?: string | null;
4823
+ /** @description Filter by one or more trace IDs */
4824
+ trace_id?: string[] | null;
4697
4825
  };
4698
4826
  header?: never;
4699
4827
  path: {
@@ -18,6 +18,8 @@ export interface GetSpansParams extends ClientFn {
18
18
  cursor?: string | null;
19
19
  /** Maximum number of spans to return */
20
20
  limit?: number;
21
+ /** Filter spans by one or more trace IDs */
22
+ traceIds?: string[] | null;
21
23
  }
22
24
 
23
25
  export type GetSpansResponse = operations["getSpans"]["responses"]["200"];
@@ -59,6 +61,13 @@ export type GetSpansResult = {
59
61
  * limit: 100
60
62
  * });
61
63
 
64
+ *
65
+ * // Get all spans for specific traces (requires Phoenix server >= 13.9.0)
66
+ * const result = await getSpans({
67
+ * client,
68
+ * project: { projectName: "my-project" },
69
+ * traceIds: ["trace-abc-123", "trace-def-456"],
70
+ * });
62
71
  *
63
72
  * // Paginate through results
64
73
  * let cursor: string | undefined;
@@ -86,6 +95,7 @@ export async function getSpans({
86
95
  limit = 100,
87
96
  startTime,
88
97
  endTime,
98
+ traceIds,
89
99
  }: GetSpansParams): Promise<GetSpansResult> {
90
100
  const client = _client ?? createClient();
91
101
  const projectIdentifier = resolveProjectIdentifier(project);
@@ -107,6 +117,10 @@ export async function getSpans({
107
117
  params.end_time = endTime instanceof Date ? endTime.toISOString() : endTime;
108
118
  }
109
119
 
120
+ if (traceIds) {
121
+ params.trace_id = traceIds;
122
+ }
123
+
110
124
  const { data, error } = await client.GET(
111
125
  "/v1/projects/{project_identifier}/spans",
112
126
  {