Skip to content

Commit 3694b37

Browse files
committed
fix: Address security issue with eval() by converting model cost data from CSV to JSON format
- Update merbench_ui.py to use the new JSON format
1 parent cda1273 commit 3694b37

File tree

3 files changed

+191
-188
lines changed

3 files changed

+191
-188
lines changed

agents_mcp_usage/multi_mcp/eval_multi_mcp/costs.csv

Lines changed: 0 additions & 155 deletions
This file was deleted.
Lines changed: 158 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,158 @@
1+
{
2+
"_comment": "Prices are per 1 million tokens",
3+
"_sources": {
4+
"gemini": "https://ai.google.dev/gemini-api/docs/pricing",
5+
"openai": "https://openai.com/api/pricing/"
6+
},
7+
"model_costs": {
8+
"gemini-2.5-pro-preview-03-25": {
9+
"friendly_name": "Gemini 2.5 Pro Preview (Mar)",
10+
"input": [
11+
{"up_to": 200000, "price": 1.25},
12+
{"up_to": "inf", "price": 2.50}
13+
],
14+
"output": {
15+
"default": [
16+
{"up_to": 200000, "price": 10.00},
17+
{"up_to": "inf", "price": 15.00}
18+
]
19+
}
20+
},
21+
"gemini-2.5-pro-preview-05-06": {
22+
"friendly_name": "Gemini 2.5 Pro Preview (May)",
23+
"input": [
24+
{"up_to": 200000, "price": 1.25},
25+
{"up_to": "inf", "price": 2.50}
26+
],
27+
"output": {
28+
"default": [
29+
{"up_to": 200000, "price": 10.00},
30+
{"up_to": "inf", "price": 15.00}
31+
]
32+
}
33+
},
34+
"gemini-2.5-pro-preview-06-05": {
35+
"friendly_name": "Gemini 2.5 Pro Preview (Jun)",
36+
"input": [
37+
{"up_to": 200000, "price": 1.25},
38+
{"up_to": "inf", "price": 2.50}
39+
],
40+
"output": {
41+
"default": [
42+
{"up_to": 200000, "price": 10.00},
43+
{"up_to": "inf", "price": 15.00}
44+
]
45+
}
46+
},
47+
"gemini-2.5-pro-preview": {
48+
"friendly_name": "Gemini 2.5 Pro Preview",
49+
"input": [
50+
{"up_to": 200000, "price": 1.25},
51+
{"up_to": "inf", "price": 2.50}
52+
],
53+
"output": {
54+
"default": [
55+
{"up_to": 200000, "price": 10.00},
56+
{"up_to": "inf", "price": 15.00}
57+
]
58+
}
59+
},
60+
"gemini-1.5-pro": {
61+
"friendly_name": "Gemini 1.5 Pro",
62+
"input": [
63+
{"up_to": 128000, "price": 1.25},
64+
{"up_to": "inf", "price": 2.50}
65+
],
66+
"output": {
67+
"default": [
68+
{"up_to": 128000, "price": 5.00},
69+
{"up_to": "inf", "price": 10.00}
70+
]
71+
}
72+
},
73+
"gemini-1.5-flash": {
74+
"friendly_name": "Gemini 1.5 Flash",
75+
"input": [
76+
{"up_to": 128000, "price": 0.075},
77+
{"up_to": "inf", "price": 0.15}
78+
],
79+
"output": {
80+
"default": [
81+
{"up_to": 128000, "price": 0.30},
82+
{"up_to": "inf", "price": 0.60}
83+
]
84+
}
85+
},
86+
"gemini-2.0-flash": {
87+
"friendly_name": "Gemini 2.0 Flash",
88+
"input": [{"up_to": "inf", "price": 0.10}],
89+
"output": {"default": [{"up_to": "inf", "price": 0.40}]}
90+
},
91+
"gemini-2.5-flash-preview-04-17": {
92+
"friendly_name": "Gemini 2.5 Flash Preview (Apr)",
93+
"input": [{"up_to": "inf", "price": 0.15}],
94+
"output": {
95+
"non_thinking": [{"up_to": "inf", "price": 0.60}],
96+
"thinking": [{"up_to": "inf", "price": 3.50}]
97+
}
98+
},
99+
"gemini-2.5-flash-preview": {
100+
"friendly_name": "Gemini 2.5 Flash Preview",
101+
"input": [{"up_to": "inf", "price": 0.15}],
102+
"output": {
103+
"non_thinking": [{"up_to": "inf", "price": 0.60}],
104+
"thinking": [{"up_to": "inf", "price": 3.50}]
105+
}
106+
},
107+
"openai:o4-mini": {
108+
"friendly_name": "OpenAI o4-mini",
109+
"input": [{"up_to": "inf", "price": 1.10}],
110+
"output": {"default": [{"up_to": "inf", "price": 4.40}]}
111+
},
112+
"openai:o3": {
113+
"friendly_name": "OpenAI o3",
114+
"input": [{"up_to": "inf", "price": 10.00}],
115+
"output": {"default": [{"up_to": "inf", "price": 40.00}]}
116+
},
117+
"openai:gpt-4.1": {
118+
"friendly_name": "GPT-4.1",
119+
"input": [{"up_to": "inf", "price": 2.00}],
120+
"output": {"default": [{"up_to": "inf", "price": 8.00}]}
121+
},
122+
"openai:gpt-4.1-mini": {
123+
"friendly_name": "GPT-4.1 Mini",
124+
"input": [{"up_to": "inf", "price": 0.40}],
125+
"output": {"default": [{"up_to": "inf", "price": 1.60}]}
126+
},
127+
"openai:gpt-4.1-nano": {
128+
"friendly_name": "GPT-4.1 Nano",
129+
"input": [{"up_to": "inf", "price": 0.10}],
130+
"output": {"default": [{"up_to": "inf", "price": 0.40}]}
131+
},
132+
"bedrock:us.anthropic.claude-sonnet-4-20250514-v1:0": {
133+
"friendly_name": "Claude 4 Sonnet",
134+
"input": [{"up_to": "inf", "price": 3.00}],
135+
"output": {"default": [{"up_to": "inf", "price": 15.00}]}
136+
},
137+
"bedrock:us.anthropic.claude-opus-4-20250514-v1:0": {
138+
"friendly_name": "Claude 4 Opus",
139+
"input": [{"up_to": "inf", "price": 15.00}],
140+
"output": {"default": [{"up_to": "inf", "price": 75.00}]}
141+
},
142+
"bedrock:us.anthropic.claude-3-7-sonnet-20250219-v1:0": {
143+
"friendly_name": "Claude 3.7 Sonnet",
144+
"input": [{"up_to": "inf", "price": 3.00}],
145+
"output": {"default": [{"up_to": "inf", "price": 15.00}]}
146+
},
147+
"bedrock:us.anthropic.claude-3-5-sonnet-20240620-v1:0": {
148+
"friendly_name": "Claude 3.5 Sonnet",
149+
"input": [{"up_to": "inf", "price": 3.00}],
150+
"output": {"default": [{"up_to": "inf", "price": 15.00}]}
151+
},
152+
"bedrock:us.anthropic.claude-3-5-haiku-20241022-v1:0": {
153+
"friendly_name": "Claude 3.5 Haiku",
154+
"input": [{"up_to": "inf", "price": 1.00}],
155+
"output": {"default": [{"up_to": "inf", "price": 4.00}]}
156+
}
157+
}
158+
}

0 commit comments

Comments
 (0)