@wix/evalforge-types 0.77.0 → 0.79.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.
@@ -1,6 +1,5 @@
1
1
  import type { SkillWithLatestVersion } from '../target/skill.js';
2
2
  import type { TestScenario, TriggerPromptImage } from '../scenario/test-scenario.js';
3
- import type { ModelConfig } from '../common/models.js';
4
3
  import type { LLMTrace } from '../evaluation/metrics.js';
5
4
  import type { ConversationMessage } from '../evaluation/conversation.js';
6
5
  import type { MCPEntity } from '../common/mcp.js';
@@ -47,8 +46,11 @@ export interface AgentExecutionContext {
47
46
  scenario: TestScenario;
48
47
  /** Working directory for the execution */
49
48
  cwd: string;
50
- /** Optional model configuration override */
51
- modelConfig?: ModelConfig;
49
+ /**
50
+ * Unified agent config bag — model params + agent-specific settings.
51
+ * Adapters parse this with their typed Zod schema (e.g. ClaudeCodeConfigSchema).
52
+ */
53
+ config?: Record<string, unknown>;
52
54
  /** AI Gateway base URL for LLM calls */
53
55
  aiGatewayUrl?: string;
54
56
  /** Custom headers for AI Gateway requests */
@@ -0,0 +1,118 @@
1
+ import { z } from 'zod';
2
+ export declare const BaseAgentConfigSchema: z.ZodObject<{
3
+ model: z.ZodOptional<z.ZodEnum<{
4
+ [x: string]: string;
5
+ }>>;
6
+ temperature: z.ZodOptional<z.ZodNumber>;
7
+ maxTokens: z.ZodOptional<z.ZodNumber>;
8
+ maxTurns: z.ZodOptional<z.ZodNumber>;
9
+ maxDurationMs: z.ZodOptional<z.ZodNumber>;
10
+ }, z.core.$strip>;
11
+ export type BaseAgentConfig = z.infer<typeof BaseAgentConfigSchema>;
12
+ export declare const EffortLevelSchema: z.ZodEnum<{
13
+ low: "low";
14
+ medium: "medium";
15
+ high: "high";
16
+ max: "max";
17
+ }>;
18
+ export type EffortLevel = z.infer<typeof EffortLevelSchema>;
19
+ export declare const ClaudeCodeConfigSchema: z.ZodObject<{
20
+ model: z.ZodOptional<z.ZodEnum<{
21
+ [x: string]: string;
22
+ }>>;
23
+ temperature: z.ZodOptional<z.ZodNumber>;
24
+ maxTokens: z.ZodOptional<z.ZodNumber>;
25
+ maxTurns: z.ZodOptional<z.ZodNumber>;
26
+ maxDurationMs: z.ZodOptional<z.ZodNumber>;
27
+ maxThinkingTokens: z.ZodOptional<z.ZodNumber>;
28
+ allowedTools: z.ZodOptional<z.ZodArray<z.ZodString>>;
29
+ disallowedTools: z.ZodOptional<z.ZodArray<z.ZodString>>;
30
+ effort: z.ZodOptional<z.ZodEnum<{
31
+ low: "low";
32
+ medium: "medium";
33
+ high: "high";
34
+ max: "max";
35
+ }>>;
36
+ maxBudgetUsd: z.ZodOptional<z.ZodNumber>;
37
+ }, z.core.$strip>;
38
+ export type ClaudeCodeConfig = z.infer<typeof ClaudeCodeConfigSchema>;
39
+ /** Permission values: allow or deny. */
40
+ export declare const PermissionValueSchema: z.ZodEnum<{
41
+ allow: "allow";
42
+ deny: "deny";
43
+ }>;
44
+ export type PermissionValue = z.infer<typeof PermissionValueSchema>;
45
+ /**
46
+ * OpenCode permission object — mixed format matching the CLI's config schema.
47
+ *
48
+ * Category keys (`bash`, `edit`, `external_directory`) accept nested glob-pattern
49
+ * maps: `{ "git *": "allow", "*": "deny" }`.
50
+ *
51
+ * Tool-level keys (`task`, `skill`, `todowrite`, etc.) and the catch-all `*`
52
+ * accept a flat `"allow"` or `"deny"` string.
53
+ *
54
+ * @example { "*": "allow", task: "deny", bash: { "git *": "allow", "*": "deny" } }
55
+ */
56
+ export declare const OpenCodePermissionSchema: z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodEnum<{
57
+ allow: "allow";
58
+ deny: "deny";
59
+ }>, z.ZodRecord<z.ZodString, z.ZodEnum<{
60
+ allow: "allow";
61
+ deny: "deny";
62
+ }>>]>>;
63
+ export type OpenCodePermission = z.infer<typeof OpenCodePermissionSchema>;
64
+ export declare const ThinkingVariantSchema: z.ZodEnum<{
65
+ low: "low";
66
+ high: "high";
67
+ none: "none";
68
+ }>;
69
+ export type ThinkingVariant = z.infer<typeof ThinkingVariantSchema>;
70
+ export declare const OpenCodeConfigSchema: z.ZodObject<{
71
+ model: z.ZodOptional<z.ZodEnum<{
72
+ [x: string]: string;
73
+ }>>;
74
+ temperature: z.ZodOptional<z.ZodNumber>;
75
+ maxTurns: z.ZodOptional<z.ZodNumber>;
76
+ maxDurationMs: z.ZodOptional<z.ZodNumber>;
77
+ permission: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodEnum<{
78
+ allow: "allow";
79
+ deny: "deny";
80
+ }>, z.ZodRecord<z.ZodString, z.ZodEnum<{
81
+ allow: "allow";
82
+ deny: "deny";
83
+ }>>]>>>;
84
+ thinkingVariant: z.ZodOptional<z.ZodEnum<{
85
+ low: "low";
86
+ high: "high";
87
+ none: "none";
88
+ }>>;
89
+ topP: z.ZodOptional<z.ZodNumber>;
90
+ }, z.core.$strip>;
91
+ export type OpenCodeConfig = z.infer<typeof OpenCodeConfigSchema>;
92
+ export declare const ReasoningEffortSchema: z.ZodEnum<{
93
+ low: "low";
94
+ medium: "medium";
95
+ high: "high";
96
+ }>;
97
+ export type ReasoningEffort = z.infer<typeof ReasoningEffortSchema>;
98
+ export declare const SimpleAgentConfigSchema: z.ZodObject<{
99
+ model: z.ZodOptional<z.ZodEnum<{
100
+ [x: string]: string;
101
+ }>>;
102
+ temperature: z.ZodOptional<z.ZodNumber>;
103
+ maxTokens: z.ZodOptional<z.ZodNumber>;
104
+ maxTurns: z.ZodOptional<z.ZodNumber>;
105
+ maxDurationMs: z.ZodOptional<z.ZodNumber>;
106
+ thinkingBudgetTokens: z.ZodOptional<z.ZodNumber>;
107
+ topP: z.ZodOptional<z.ZodNumber>;
108
+ seed: z.ZodOptional<z.ZodNumber>;
109
+ stopSequences: z.ZodOptional<z.ZodArray<z.ZodString>>;
110
+ reasoningEffort: z.ZodOptional<z.ZodEnum<{
111
+ low: "low";
112
+ medium: "medium";
113
+ high: "high";
114
+ }>>;
115
+ frequencyPenalty: z.ZodOptional<z.ZodNumber>;
116
+ presencePenalty: z.ZodOptional<z.ZodNumber>;
117
+ }, z.core.$strip>;
118
+ export type SimpleAgentConfig = z.infer<typeof SimpleAgentConfigSchema>;
@@ -7,3 +7,5 @@
7
7
  * agent types (Claude Code, Cursor, Aider, etc.) through a unified interface.
8
8
  */
9
9
  export type { TraceContext, AgentExecutionContext, AgentTokenUsage, AgentExecutionResult, AgentAdapter } from './adapter.js';
10
+ export { BaseAgentConfigSchema, ClaudeCodeConfigSchema, EffortLevelSchema, OpenCodeConfigSchema, OpenCodePermissionSchema, PermissionValueSchema, ThinkingVariantSchema, SimpleAgentConfigSchema, ReasoningEffortSchema } from './agent-config.js';
11
+ export type { BaseAgentConfig, ClaudeCodeConfig, EffortLevel, OpenCodeConfig, OpenCodePermission, PermissionValue, ThinkingVariant, SimpleAgentConfig, ReasoningEffort } from './agent-config.js';
@@ -44,6 +44,26 @@ export declare const OPENAI_RESPONSES_MODEL_IDS: ReadonlySet<string>;
44
44
  export declare const OpenAIModelSchema: z.ZodEnum<{
45
45
  [x: string]: string;
46
46
  }>;
47
+ export declare const GeminiModel: {
48
+ readonly GEMINI_2_0_FLASH: "gemini-2.0-flash";
49
+ readonly GEMINI_2_0_FLASH_LITE: "gemini-2.0-flash-lite";
50
+ readonly GEMINI_2_5_PRO: "gemini-2.5-pro";
51
+ readonly GEMINI_2_5_FLASH: "gemini-2.5-flash";
52
+ readonly GEMINI_2_5_FLASH_LITE: "gemini-2.5-flash-lite";
53
+ readonly GEMINI_3_0_PRO: "gemini-3-pro-preview";
54
+ readonly GEMINI_3_0_FLASH: "gemini-3-flash-preview";
55
+ readonly GEMINI_3_1_PRO: "gemini-3.1-pro-preview";
56
+ };
57
+ export type GeminiModel = (typeof GeminiModel)[keyof typeof GeminiModel];
58
+ export declare const AVAILABLE_GEMINI_MODEL_IDS: GeminiModel[];
59
+ /**
60
+ * Gemini models that support extended reasoning (thinking).
61
+ * These models accept a `thinkingConfig` in the generation config.
62
+ */
63
+ export declare const GEMINI_THINKING_MODEL_IDS: ReadonlySet<string>;
64
+ export declare const GeminiModelSchema: z.ZodEnum<{
65
+ [x: string]: string;
66
+ }>;
47
67
  export declare const ALL_AVAILABLE_MODEL_IDS: string[];
48
68
  export declare const AnyModelSchema: z.ZodEnum<{
49
69
  [x: string]: string;
@@ -64,6 +64,7 @@ export declare const AgentSchema: z.ZodObject<{
64
64
  maxTurns: z.ZodPipe<z.ZodTransform<{} | undefined, unknown>, z.ZodOptional<z.ZodNumber>>;
65
65
  }, z.core.$strip>>;
66
66
  systemPrompt: z.ZodOptional<z.ZodNullable<z.ZodString>>;
67
+ config: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
67
68
  }, z.core.$strip>;
68
69
  export type Agent = z.infer<typeof AgentSchema>;
69
70
  /**
@@ -73,6 +74,7 @@ export declare const CreateAgentInputSchema: z.ZodObject<{
73
74
  name: z.ZodString;
74
75
  description: z.ZodString;
75
76
  projectId: z.ZodString;
77
+ config: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
76
78
  agentType: z.ZodDefault<z.ZodEnum<{
77
79
  cli: "cli";
78
80
  sdk: "sdk";
@@ -111,5 +113,6 @@ export declare const UpdateAgentInputSchema: z.ZodObject<{
111
113
  maxTurns: z.ZodPipe<z.ZodTransform<{} | undefined, unknown>, z.ZodOptional<z.ZodNumber>>;
112
114
  }, z.core.$strip>>>;
113
115
  systemPrompt: z.ZodNullable<z.ZodOptional<z.ZodString>>;
116
+ config: z.ZodNullable<z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
114
117
  }, z.core.$strip>;
115
118
  export type UpdateAgentInput = z.infer<typeof UpdateAgentInputSchema>;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wix/evalforge-types",
3
- "version": "0.77.0",
3
+ "version": "0.79.0",
4
4
  "description": "Unified types for EvalForge agent evaluation system",
5
5
  "files": [
6
6
  "build"
@@ -46,5 +46,5 @@
46
46
  "artifactId": "evalforge-types"
47
47
  }
48
48
  },
49
- "falconPackageHash": "4e3cc484177d8c60cfd9b5eabfeb9ad1906d658be6f4b6ad6ec299bf"
49
+ "falconPackageHash": "82a6c5416397fb3ba2514dfad7a5b75ae0c4394fe76025ee76179076"
50
50
  }