scorecard-ai-mcp 1.0.0-alpha.8 → 1.0.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.
Files changed (274) hide show
  1. package/README.md +18 -14
  2. package/dynamic-tools.d.mts +1 -1
  3. package/dynamic-tools.d.mts.map +1 -1
  4. package/dynamic-tools.d.ts +1 -1
  5. package/dynamic-tools.d.ts.map +1 -1
  6. package/dynamic-tools.js +5 -4
  7. package/dynamic-tools.js.map +1 -1
  8. package/dynamic-tools.mjs +5 -4
  9. package/dynamic-tools.mjs.map +1 -1
  10. package/package.json +2 -2
  11. package/server.d.mts +1 -6
  12. package/server.d.mts.map +1 -1
  13. package/server.d.ts +1 -6
  14. package/server.d.ts.map +1 -1
  15. package/server.js +3 -11
  16. package/server.js.map +1 -1
  17. package/server.mjs +3 -11
  18. package/server.mjs.map +1 -1
  19. package/src/dynamic-tools.ts +13 -7
  20. package/src/server.ts +3 -11
  21. package/src/tools/index.ts +11 -22
  22. package/src/tools/metrics/create-metrics.ts +251 -0
  23. package/src/tools/projects/create-projects.ts +7 -2
  24. package/src/tools/projects/list-projects.ts +7 -2
  25. package/src/tools/records/create-records.ts +7 -2
  26. package/src/tools/runs/create-runs.ts +11 -6
  27. package/src/tools/scores/upsert-scores.ts +7 -2
  28. package/src/tools/systems/create-systems.ts +7 -2
  29. package/src/tools/systems/delete-systems.ts +8 -3
  30. package/src/tools/systems/get-systems.ts +7 -2
  31. package/src/tools/systems/list-systems.ts +7 -2
  32. package/src/tools/systems/update-systems.ts +7 -2
  33. package/src/tools/systems/versions/create-systems-versions.ts +45 -0
  34. package/src/tools/systems/versions/get-systems-versions.ts +36 -0
  35. package/src/tools/{system-configs/list-system-configs.ts → systems/versions/list-systems-versions.ts} +11 -6
  36. package/src/tools/testcases/create-testcases.ts +7 -2
  37. package/src/tools/testcases/delete-testcases.ts +7 -2
  38. package/src/tools/testcases/get-testcases.ts +7 -2
  39. package/src/tools/testcases/list-testcases.ts +7 -2
  40. package/src/tools/testcases/update-testcases.ts +7 -2
  41. package/src/tools/testsets/create-testsets.ts +7 -2
  42. package/src/tools/testsets/delete-testsets.ts +7 -2
  43. package/src/tools/testsets/get-testsets.ts +8 -3
  44. package/src/tools/testsets/list-testsets.ts +7 -2
  45. package/src/tools/testsets/update-testsets.ts +7 -2
  46. package/src/tools/types.ts +104 -0
  47. package/tools/index.d.mts +2 -13
  48. package/tools/index.d.mts.map +1 -1
  49. package/tools/index.d.ts +2 -13
  50. package/tools/index.d.ts.map +1 -1
  51. package/tools/index.js +8 -6
  52. package/tools/index.js.map +1 -1
  53. package/tools/index.mjs +8 -6
  54. package/tools/index.mjs.map +1 -1
  55. package/tools/{system-configs/get-system-configs.d.mts → metrics/create-metrics.d.mts} +3 -3
  56. package/tools/metrics/create-metrics.d.mts.map +1 -0
  57. package/tools/{system-configs/get-system-configs.d.ts → metrics/create-metrics.d.ts} +3 -3
  58. package/tools/metrics/create-metrics.d.ts.map +1 -0
  59. package/tools/metrics/create-metrics.js +245 -0
  60. package/tools/metrics/create-metrics.js.map +1 -0
  61. package/tools/metrics/create-metrics.mjs +241 -0
  62. package/tools/metrics/create-metrics.mjs.map +1 -0
  63. package/tools/projects/create-projects.d.mts +2 -2
  64. package/tools/projects/create-projects.d.mts.map +1 -1
  65. package/tools/projects/create-projects.d.ts +2 -2
  66. package/tools/projects/create-projects.d.ts.map +1 -1
  67. package/tools/projects/create-projects.js +6 -2
  68. package/tools/projects/create-projects.js.map +1 -1
  69. package/tools/projects/create-projects.mjs +6 -2
  70. package/tools/projects/create-projects.mjs.map +1 -1
  71. package/tools/projects/list-projects.d.mts +2 -2
  72. package/tools/projects/list-projects.d.mts.map +1 -1
  73. package/tools/projects/list-projects.d.ts +2 -2
  74. package/tools/projects/list-projects.d.ts.map +1 -1
  75. package/tools/projects/list-projects.js +6 -2
  76. package/tools/projects/list-projects.js.map +1 -1
  77. package/tools/projects/list-projects.mjs +6 -2
  78. package/tools/projects/list-projects.mjs.map +1 -1
  79. package/tools/records/create-records.d.mts +2 -2
  80. package/tools/records/create-records.d.mts.map +1 -1
  81. package/tools/records/create-records.d.ts +2 -2
  82. package/tools/records/create-records.d.ts.map +1 -1
  83. package/tools/records/create-records.js +6 -2
  84. package/tools/records/create-records.js.map +1 -1
  85. package/tools/records/create-records.mjs +6 -2
  86. package/tools/records/create-records.mjs.map +1 -1
  87. package/tools/runs/create-runs.d.mts +2 -2
  88. package/tools/runs/create-runs.d.mts.map +1 -1
  89. package/tools/runs/create-runs.d.ts +2 -2
  90. package/tools/runs/create-runs.d.ts.map +1 -1
  91. package/tools/runs/create-runs.js +10 -6
  92. package/tools/runs/create-runs.js.map +1 -1
  93. package/tools/runs/create-runs.mjs +10 -6
  94. package/tools/runs/create-runs.mjs.map +1 -1
  95. package/tools/scores/upsert-scores.d.mts +2 -2
  96. package/tools/scores/upsert-scores.d.mts.map +1 -1
  97. package/tools/scores/upsert-scores.d.ts +2 -2
  98. package/tools/scores/upsert-scores.d.ts.map +1 -1
  99. package/tools/scores/upsert-scores.js +6 -2
  100. package/tools/scores/upsert-scores.js.map +1 -1
  101. package/tools/scores/upsert-scores.mjs +6 -2
  102. package/tools/scores/upsert-scores.mjs.map +1 -1
  103. package/tools/systems/create-systems.d.mts +2 -2
  104. package/tools/systems/create-systems.d.mts.map +1 -1
  105. package/tools/systems/create-systems.d.ts +2 -2
  106. package/tools/systems/create-systems.d.ts.map +1 -1
  107. package/tools/systems/create-systems.js +6 -2
  108. package/tools/systems/create-systems.js.map +1 -1
  109. package/tools/systems/create-systems.mjs +6 -2
  110. package/tools/systems/create-systems.mjs.map +1 -1
  111. package/tools/systems/delete-systems.d.mts +2 -2
  112. package/tools/systems/delete-systems.d.mts.map +1 -1
  113. package/tools/systems/delete-systems.d.ts +2 -2
  114. package/tools/systems/delete-systems.d.ts.map +1 -1
  115. package/tools/systems/delete-systems.js +7 -3
  116. package/tools/systems/delete-systems.js.map +1 -1
  117. package/tools/systems/delete-systems.mjs +7 -3
  118. package/tools/systems/delete-systems.mjs.map +1 -1
  119. package/tools/systems/get-systems.d.mts +2 -2
  120. package/tools/systems/get-systems.d.mts.map +1 -1
  121. package/tools/systems/get-systems.d.ts +2 -2
  122. package/tools/systems/get-systems.d.ts.map +1 -1
  123. package/tools/systems/get-systems.js +6 -2
  124. package/tools/systems/get-systems.js.map +1 -1
  125. package/tools/systems/get-systems.mjs +6 -2
  126. package/tools/systems/get-systems.mjs.map +1 -1
  127. package/tools/systems/list-systems.d.mts +2 -2
  128. package/tools/systems/list-systems.d.mts.map +1 -1
  129. package/tools/systems/list-systems.d.ts +2 -2
  130. package/tools/systems/list-systems.d.ts.map +1 -1
  131. package/tools/systems/list-systems.js +6 -2
  132. package/tools/systems/list-systems.js.map +1 -1
  133. package/tools/systems/list-systems.mjs +6 -2
  134. package/tools/systems/list-systems.mjs.map +1 -1
  135. package/tools/systems/update-systems.d.mts +2 -2
  136. package/tools/systems/update-systems.d.mts.map +1 -1
  137. package/tools/systems/update-systems.d.ts +2 -2
  138. package/tools/systems/update-systems.d.ts.map +1 -1
  139. package/tools/systems/update-systems.js +6 -2
  140. package/tools/systems/update-systems.js.map +1 -1
  141. package/tools/systems/update-systems.mjs +6 -2
  142. package/tools/systems/update-systems.mjs.map +1 -1
  143. package/tools/{system-configs/create-system-configs.d.ts → systems/versions/create-systems-versions.d.mts} +4 -4
  144. package/tools/systems/versions/create-systems-versions.d.mts.map +1 -0
  145. package/tools/{system-configs/create-system-configs.d.mts → systems/versions/create-systems-versions.d.ts} +4 -4
  146. package/tools/systems/versions/create-systems-versions.d.ts.map +1 -0
  147. package/tools/systems/versions/create-systems-versions.js +40 -0
  148. package/tools/systems/versions/create-systems-versions.js.map +1 -0
  149. package/tools/systems/versions/create-systems-versions.mjs +36 -0
  150. package/tools/systems/versions/create-systems-versions.mjs.map +1 -0
  151. package/tools/systems/versions/get-systems-versions.d.mts +32 -0
  152. package/tools/systems/versions/get-systems-versions.d.mts.map +1 -0
  153. package/tools/systems/versions/get-systems-versions.d.ts +32 -0
  154. package/tools/systems/versions/get-systems-versions.d.ts.map +1 -0
  155. package/tools/systems/versions/get-systems-versions.js +32 -0
  156. package/tools/systems/versions/get-systems-versions.js.map +1 -0
  157. package/tools/systems/versions/get-systems-versions.mjs +28 -0
  158. package/tools/systems/versions/get-systems-versions.mjs.map +1 -0
  159. package/tools/systems/versions/list-systems-versions.d.mts +32 -0
  160. package/tools/systems/versions/list-systems-versions.d.mts.map +1 -0
  161. package/tools/systems/versions/list-systems-versions.d.ts +32 -0
  162. package/tools/systems/versions/list-systems-versions.d.ts.map +1 -0
  163. package/tools/{system-configs/list-system-configs.js → systems/versions/list-systems-versions.js} +10 -6
  164. package/tools/systems/versions/list-systems-versions.js.map +1 -0
  165. package/tools/{system-configs/list-system-configs.mjs → systems/versions/list-systems-versions.mjs} +10 -6
  166. package/tools/systems/versions/list-systems-versions.mjs.map +1 -0
  167. package/tools/testcases/create-testcases.d.mts +2 -2
  168. package/tools/testcases/create-testcases.d.mts.map +1 -1
  169. package/tools/testcases/create-testcases.d.ts +2 -2
  170. package/tools/testcases/create-testcases.d.ts.map +1 -1
  171. package/tools/testcases/create-testcases.js +6 -2
  172. package/tools/testcases/create-testcases.js.map +1 -1
  173. package/tools/testcases/create-testcases.mjs +6 -2
  174. package/tools/testcases/create-testcases.mjs.map +1 -1
  175. package/tools/testcases/delete-testcases.d.mts +2 -2
  176. package/tools/testcases/delete-testcases.d.mts.map +1 -1
  177. package/tools/testcases/delete-testcases.d.ts +2 -2
  178. package/tools/testcases/delete-testcases.d.ts.map +1 -1
  179. package/tools/testcases/delete-testcases.js +6 -2
  180. package/tools/testcases/delete-testcases.js.map +1 -1
  181. package/tools/testcases/delete-testcases.mjs +6 -2
  182. package/tools/testcases/delete-testcases.mjs.map +1 -1
  183. package/tools/testcases/get-testcases.d.mts +2 -2
  184. package/tools/testcases/get-testcases.d.mts.map +1 -1
  185. package/tools/testcases/get-testcases.d.ts +2 -2
  186. package/tools/testcases/get-testcases.d.ts.map +1 -1
  187. package/tools/testcases/get-testcases.js +6 -2
  188. package/tools/testcases/get-testcases.js.map +1 -1
  189. package/tools/testcases/get-testcases.mjs +6 -2
  190. package/tools/testcases/get-testcases.mjs.map +1 -1
  191. package/tools/testcases/list-testcases.d.mts +2 -2
  192. package/tools/testcases/list-testcases.d.mts.map +1 -1
  193. package/tools/testcases/list-testcases.d.ts +2 -2
  194. package/tools/testcases/list-testcases.d.ts.map +1 -1
  195. package/tools/testcases/list-testcases.js +6 -2
  196. package/tools/testcases/list-testcases.js.map +1 -1
  197. package/tools/testcases/list-testcases.mjs +6 -2
  198. package/tools/testcases/list-testcases.mjs.map +1 -1
  199. package/tools/testcases/update-testcases.d.mts +2 -2
  200. package/tools/testcases/update-testcases.d.mts.map +1 -1
  201. package/tools/testcases/update-testcases.d.ts +2 -2
  202. package/tools/testcases/update-testcases.d.ts.map +1 -1
  203. package/tools/testcases/update-testcases.js +6 -2
  204. package/tools/testcases/update-testcases.js.map +1 -1
  205. package/tools/testcases/update-testcases.mjs +6 -2
  206. package/tools/testcases/update-testcases.mjs.map +1 -1
  207. package/tools/testsets/create-testsets.d.mts +2 -2
  208. package/tools/testsets/create-testsets.d.mts.map +1 -1
  209. package/tools/testsets/create-testsets.d.ts +2 -2
  210. package/tools/testsets/create-testsets.d.ts.map +1 -1
  211. package/tools/testsets/create-testsets.js +6 -2
  212. package/tools/testsets/create-testsets.js.map +1 -1
  213. package/tools/testsets/create-testsets.mjs +6 -2
  214. package/tools/testsets/create-testsets.mjs.map +1 -1
  215. package/tools/testsets/delete-testsets.d.mts +2 -2
  216. package/tools/testsets/delete-testsets.d.mts.map +1 -1
  217. package/tools/testsets/delete-testsets.d.ts +2 -2
  218. package/tools/testsets/delete-testsets.d.ts.map +1 -1
  219. package/tools/testsets/delete-testsets.js +6 -2
  220. package/tools/testsets/delete-testsets.js.map +1 -1
  221. package/tools/testsets/delete-testsets.mjs +6 -2
  222. package/tools/testsets/delete-testsets.mjs.map +1 -1
  223. package/tools/testsets/get-testsets.d.mts +2 -2
  224. package/tools/testsets/get-testsets.d.mts.map +1 -1
  225. package/tools/testsets/get-testsets.d.ts +2 -2
  226. package/tools/testsets/get-testsets.d.ts.map +1 -1
  227. package/tools/testsets/get-testsets.js +7 -3
  228. package/tools/testsets/get-testsets.js.map +1 -1
  229. package/tools/testsets/get-testsets.mjs +7 -3
  230. package/tools/testsets/get-testsets.mjs.map +1 -1
  231. package/tools/testsets/list-testsets.d.mts +2 -2
  232. package/tools/testsets/list-testsets.d.mts.map +1 -1
  233. package/tools/testsets/list-testsets.d.ts +2 -2
  234. package/tools/testsets/list-testsets.d.ts.map +1 -1
  235. package/tools/testsets/list-testsets.js +6 -2
  236. package/tools/testsets/list-testsets.js.map +1 -1
  237. package/tools/testsets/list-testsets.mjs +6 -2
  238. package/tools/testsets/list-testsets.mjs.map +1 -1
  239. package/tools/testsets/update-testsets.d.mts +2 -2
  240. package/tools/testsets/update-testsets.d.mts.map +1 -1
  241. package/tools/testsets/update-testsets.d.ts +2 -2
  242. package/tools/testsets/update-testsets.d.ts.map +1 -1
  243. package/tools/testsets/update-testsets.js +6 -2
  244. package/tools/testsets/update-testsets.js.map +1 -1
  245. package/tools/testsets/update-testsets.mjs +6 -2
  246. package/tools/testsets/update-testsets.mjs.map +1 -1
  247. package/tools/types.d.mts +51 -0
  248. package/tools/types.d.mts.map +1 -0
  249. package/tools/types.d.ts +51 -0
  250. package/tools/types.d.ts.map +1 -0
  251. package/tools/types.js +46 -0
  252. package/tools/types.js.map +1 -0
  253. package/tools/types.mjs +42 -0
  254. package/tools/types.mjs.map +1 -0
  255. package/src/tools/system-configs/create-system-configs.ts +0 -59
  256. package/src/tools/system-configs/get-system-configs.ts +0 -34
  257. package/tools/system-configs/create-system-configs.d.mts.map +0 -1
  258. package/tools/system-configs/create-system-configs.d.ts.map +0 -1
  259. package/tools/system-configs/create-system-configs.js +0 -54
  260. package/tools/system-configs/create-system-configs.js.map +0 -1
  261. package/tools/system-configs/create-system-configs.mjs +0 -50
  262. package/tools/system-configs/create-system-configs.mjs.map +0 -1
  263. package/tools/system-configs/get-system-configs.d.mts.map +0 -1
  264. package/tools/system-configs/get-system-configs.d.ts.map +0 -1
  265. package/tools/system-configs/get-system-configs.js +0 -31
  266. package/tools/system-configs/get-system-configs.js.map +0 -1
  267. package/tools/system-configs/get-system-configs.mjs +0 -27
  268. package/tools/system-configs/get-system-configs.mjs.map +0 -1
  269. package/tools/system-configs/list-system-configs.d.mts +0 -32
  270. package/tools/system-configs/list-system-configs.d.mts.map +0 -1
  271. package/tools/system-configs/list-system-configs.d.ts +0 -32
  272. package/tools/system-configs/list-system-configs.d.ts.map +0 -1
  273. package/tools/system-configs/list-system-configs.js.map +0 -1
  274. package/tools/system-configs/list-system-configs.mjs.map +0 -1
@@ -0,0 +1,251 @@
1
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ import { asTextContentResult } from 'scorecard-ai-mcp/tools/types';
4
+
5
+ import { Tool } from '@modelcontextprotocol/sdk/types.js';
6
+ import type { Metadata } from '../';
7
+ import Scorecard from 'scorecard-ai';
8
+
9
+ export const metadata: Metadata = {
10
+ resource: 'metrics',
11
+ operation: 'write',
12
+ tags: [],
13
+ httpMethod: 'post',
14
+ httpPath: '/projects/{projectId}/metrics',
15
+ operationId: 'createMetric',
16
+ };
17
+
18
+ export const tool: Tool = {
19
+ name: 'create_metrics',
20
+ description: 'Create a new Metric for evaluating system outputs.',
21
+ inputSchema: {
22
+ type: 'object',
23
+ anyOf: [
24
+ {
25
+ type: 'object',
26
+ properties: {
27
+ projectId: {
28
+ type: 'string',
29
+ },
30
+ evalType: {
31
+ type: 'string',
32
+ description: 'AI-based evaluation type.',
33
+ enum: ['ai'],
34
+ },
35
+ name: {
36
+ type: 'string',
37
+ description: 'The name of the Metric.',
38
+ },
39
+ outputType: {
40
+ type: 'string',
41
+ description: 'Integer output type.',
42
+ enum: ['int'],
43
+ },
44
+ promptTemplate: {
45
+ type: 'string',
46
+ description:
47
+ 'The complete prompt template for AI evaluation. Should include placeholders for dynamic content.',
48
+ },
49
+ description: {
50
+ type: 'string',
51
+ description: 'The description of the Metric.',
52
+ },
53
+ evalModelName: {
54
+ type: 'string',
55
+ description: 'The AI model to use for evaluation.',
56
+ },
57
+ guidelines: {
58
+ type: 'string',
59
+ description: 'Guidelines for AI evaluation on how to score the metric.',
60
+ },
61
+ passingThreshold: {
62
+ type: 'integer',
63
+ description: 'The threshold for determining pass/fail from integer scores (1-5).',
64
+ },
65
+ temperature: {
66
+ type: 'number',
67
+ description: 'The temperature for AI evaluation (0-2).',
68
+ },
69
+ },
70
+ },
71
+ {
72
+ type: 'object',
73
+ properties: {
74
+ projectId: {
75
+ type: 'string',
76
+ },
77
+ evalType: {
78
+ type: 'string',
79
+ description: 'Human-based evaluation type.',
80
+ enum: ['human'],
81
+ },
82
+ name: {
83
+ type: 'string',
84
+ description: 'The name of the Metric.',
85
+ },
86
+ outputType: {
87
+ type: 'string',
88
+ description: 'Integer output type.',
89
+ enum: ['int'],
90
+ },
91
+ description: {
92
+ type: 'string',
93
+ description: 'The description of the Metric.',
94
+ },
95
+ guidelines: {
96
+ type: 'string',
97
+ description: 'Guidelines for human evaluators.',
98
+ },
99
+ passingThreshold: {
100
+ type: 'integer',
101
+ description: 'The threshold for determining pass/fail from integer scores (1-5).',
102
+ },
103
+ },
104
+ },
105
+ {
106
+ type: 'object',
107
+ properties: {
108
+ projectId: {
109
+ type: 'string',
110
+ },
111
+ evalType: {
112
+ type: 'string',
113
+ description: 'Heuristic-based evaluation type.',
114
+ enum: ['heuristic'],
115
+ },
116
+ name: {
117
+ type: 'string',
118
+ description: 'The name of the Metric.',
119
+ },
120
+ outputType: {
121
+ type: 'string',
122
+ description: 'Integer output type.',
123
+ enum: ['int'],
124
+ },
125
+ description: {
126
+ type: 'string',
127
+ description: 'The description of the Metric.',
128
+ },
129
+ guidelines: {
130
+ type: 'string',
131
+ description: 'Optional guidelines for heuristic evaluation logic.',
132
+ },
133
+ passingThreshold: {
134
+ type: 'integer',
135
+ description: 'The threshold for determining pass/fail from integer scores (1-5).',
136
+ },
137
+ },
138
+ },
139
+ {
140
+ type: 'object',
141
+ properties: {
142
+ projectId: {
143
+ type: 'string',
144
+ },
145
+ evalType: {
146
+ type: 'string',
147
+ description: 'AI-based evaluation type.',
148
+ enum: ['ai'],
149
+ },
150
+ name: {
151
+ type: 'string',
152
+ description: 'The name of the Metric.',
153
+ },
154
+ outputType: {
155
+ type: 'string',
156
+ description: 'Boolean output type.',
157
+ enum: ['boolean'],
158
+ },
159
+ promptTemplate: {
160
+ type: 'string',
161
+ description:
162
+ 'The complete prompt template for AI evaluation. Should include placeholders for dynamic content.',
163
+ },
164
+ description: {
165
+ type: 'string',
166
+ description: 'The description of the Metric.',
167
+ },
168
+ evalModelName: {
169
+ type: 'string',
170
+ description: 'The AI model to use for evaluation.',
171
+ },
172
+ guidelines: {
173
+ type: 'string',
174
+ description: 'Guidelines for AI evaluation on how to score the metric.',
175
+ },
176
+ temperature: {
177
+ type: 'number',
178
+ description: 'The temperature for AI evaluation (0-2).',
179
+ },
180
+ },
181
+ },
182
+ {
183
+ type: 'object',
184
+ properties: {
185
+ projectId: {
186
+ type: 'string',
187
+ },
188
+ evalType: {
189
+ type: 'string',
190
+ description: 'Human-based evaluation type.',
191
+ enum: ['human'],
192
+ },
193
+ name: {
194
+ type: 'string',
195
+ description: 'The name of the Metric.',
196
+ },
197
+ outputType: {
198
+ type: 'string',
199
+ description: 'Boolean output type.',
200
+ enum: ['boolean'],
201
+ },
202
+ description: {
203
+ type: 'string',
204
+ description: 'The description of the Metric.',
205
+ },
206
+ guidelines: {
207
+ type: 'string',
208
+ description: 'Guidelines for human evaluators.',
209
+ },
210
+ },
211
+ },
212
+ {
213
+ type: 'object',
214
+ properties: {
215
+ projectId: {
216
+ type: 'string',
217
+ },
218
+ evalType: {
219
+ type: 'string',
220
+ description: 'Heuristic-based evaluation type.',
221
+ enum: ['heuristic'],
222
+ },
223
+ name: {
224
+ type: 'string',
225
+ description: 'The name of the Metric.',
226
+ },
227
+ outputType: {
228
+ type: 'string',
229
+ description: 'Boolean output type.',
230
+ enum: ['boolean'],
231
+ },
232
+ description: {
233
+ type: 'string',
234
+ description: 'The description of the Metric.',
235
+ },
236
+ guidelines: {
237
+ type: 'string',
238
+ description: 'Optional guidelines for heuristic evaluation logic.',
239
+ },
240
+ },
241
+ },
242
+ ],
243
+ },
244
+ };
245
+
246
+ export const handler = async (client: Scorecard, args: Record<string, unknown> | undefined) => {
247
+ const { projectId, ...body } = args as any;
248
+ return asTextContentResult(await client.metrics.create(projectId, body));
249
+ };
250
+
251
+ export default { metadata, tool, handler };
@@ -1,5 +1,7 @@
1
1
  // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
2
 
3
+ import { asTextContentResult } from 'scorecard-ai-mcp/tools/types';
4
+
3
5
  import { Tool } from '@modelcontextprotocol/sdk/types.js';
4
6
  import type { Metadata } from '../';
5
7
  import Scorecard from 'scorecard-ai';
@@ -8,6 +10,9 @@ export const metadata: Metadata = {
8
10
  resource: 'projects',
9
11
  operation: 'write',
10
12
  tags: [],
13
+ httpMethod: 'post',
14
+ httpPath: '/projects',
15
+ operationId: 'createProject',
11
16
  };
12
17
 
13
18
  export const tool: Tool = {
@@ -28,9 +33,9 @@ export const tool: Tool = {
28
33
  },
29
34
  };
30
35
 
31
- export const handler = (client: Scorecard, args: Record<string, unknown> | undefined) => {
36
+ export const handler = async (client: Scorecard, args: Record<string, unknown> | undefined) => {
32
37
  const body = args as any;
33
- return client.projects.create(body);
38
+ return asTextContentResult(await client.projects.create(body));
34
39
  };
35
40
 
36
41
  export default { metadata, tool, handler };
@@ -1,5 +1,7 @@
1
1
  // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
2
 
3
+ import { asTextContentResult } from 'scorecard-ai-mcp/tools/types';
4
+
3
5
  import { Tool } from '@modelcontextprotocol/sdk/types.js';
4
6
  import type { Metadata } from '../';
5
7
  import Scorecard from 'scorecard-ai';
@@ -8,6 +10,9 @@ export const metadata: Metadata = {
8
10
  resource: 'projects',
9
11
  operation: 'read',
10
12
  tags: [],
13
+ httpMethod: 'get',
14
+ httpPath: '/projects',
15
+ operationId: 'listProjects',
11
16
  };
12
17
 
13
18
  export const tool: Tool = {
@@ -31,9 +36,9 @@ export const tool: Tool = {
31
36
  },
32
37
  };
33
38
 
34
- export const handler = (client: Scorecard, args: Record<string, unknown> | undefined) => {
39
+ export const handler = async (client: Scorecard, args: Record<string, unknown> | undefined) => {
35
40
  const body = args as any;
36
- return client.projects.list(body);
41
+ return asTextContentResult(await client.projects.list(body));
37
42
  };
38
43
 
39
44
  export default { metadata, tool, handler };
@@ -1,5 +1,7 @@
1
1
  // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
2
 
3
+ import { asTextContentResult } from 'scorecard-ai-mcp/tools/types';
4
+
3
5
  import { Tool } from '@modelcontextprotocol/sdk/types.js';
4
6
  import type { Metadata } from '../';
5
7
  import Scorecard from 'scorecard-ai';
@@ -8,6 +10,9 @@ export const metadata: Metadata = {
8
10
  resource: 'records',
9
11
  operation: 'write',
10
12
  tags: [],
13
+ httpMethod: 'post',
14
+ httpPath: '/runs/{runId}/records',
15
+ operationId: 'createRecord',
11
16
  };
12
17
 
13
18
  export const tool: Tool = {
@@ -39,9 +44,9 @@ export const tool: Tool = {
39
44
  },
40
45
  };
41
46
 
42
- export const handler = (client: Scorecard, args: Record<string, unknown> | undefined) => {
47
+ export const handler = async (client: Scorecard, args: Record<string, unknown> | undefined) => {
43
48
  const { runId, ...body } = args as any;
44
- return client.records.create(runId, body);
49
+ return asTextContentResult(await client.records.create(runId, body));
45
50
  };
46
51
 
47
52
  export default { metadata, tool, handler };
@@ -1,5 +1,7 @@
1
1
  // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
2
 
3
+ import { asTextContentResult } from 'scorecard-ai-mcp/tools/types';
4
+
3
5
  import { Tool } from '@modelcontextprotocol/sdk/types.js';
4
6
  import type { Metadata } from '../';
5
7
  import Scorecard from 'scorecard-ai';
@@ -8,6 +10,9 @@ export const metadata: Metadata = {
8
10
  resource: 'runs',
9
11
  operation: 'write',
10
12
  tags: [],
13
+ httpMethod: 'post',
14
+ httpPath: '/projects/{projectId}/runs',
15
+ operationId: 'createRun',
11
16
  };
12
17
 
13
18
  export const tool: Tool = {
@@ -26,21 +31,21 @@ export const tool: Tool = {
26
31
  type: 'string',
27
32
  },
28
33
  },
29
- testsetId: {
34
+ systemVersionId: {
30
35
  type: 'string',
31
- description: 'The ID of the Testset this Run is testing.',
36
+ description: 'The ID of the system version this Run is using.',
32
37
  },
33
- systemConfigId: {
38
+ testsetId: {
34
39
  type: 'string',
35
- description: 'The ID of the system configuration this Run is using.',
40
+ description: 'The ID of the Testset this Run is testing.',
36
41
  },
37
42
  },
38
43
  },
39
44
  };
40
45
 
41
- export const handler = (client: Scorecard, args: Record<string, unknown> | undefined) => {
46
+ export const handler = async (client: Scorecard, args: Record<string, unknown> | undefined) => {
42
47
  const { projectId, ...body } = args as any;
43
- return client.runs.create(projectId, body);
48
+ return asTextContentResult(await client.runs.create(projectId, body));
44
49
  };
45
50
 
46
51
  export default { metadata, tool, handler };
@@ -1,5 +1,7 @@
1
1
  // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
2
 
3
+ import { asTextContentResult } from 'scorecard-ai-mcp/tools/types';
4
+
3
5
  import { Tool } from '@modelcontextprotocol/sdk/types.js';
4
6
  import type { Metadata } from '../';
5
7
  import Scorecard from 'scorecard-ai';
@@ -8,6 +10,9 @@ export const metadata: Metadata = {
8
10
  resource: 'scores',
9
11
  operation: 'write',
10
12
  tags: [],
13
+ httpMethod: 'put',
14
+ httpPath: '/records/{recordId}/scores/{metricConfigId}',
15
+ operationId: 'upsertScore',
11
16
  };
12
17
 
13
18
  export const tool: Tool = {
@@ -32,9 +37,9 @@ export const tool: Tool = {
32
37
  },
33
38
  };
34
39
 
35
- export const handler = (client: Scorecard, args: Record<string, unknown> | undefined) => {
40
+ export const handler = async (client: Scorecard, args: Record<string, unknown> | undefined) => {
36
41
  const { metricConfigId, ...body } = args as any;
37
- return client.scores.upsert(metricConfigId, body);
42
+ return asTextContentResult(await client.scores.upsert(metricConfigId, body));
38
43
  };
39
44
 
40
45
  export default { metadata, tool, handler };
@@ -1,5 +1,7 @@
1
1
  // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
2
 
3
+ import { asTextContentResult } from 'scorecard-ai-mcp/tools/types';
4
+
3
5
  import { Tool } from '@modelcontextprotocol/sdk/types.js';
4
6
  import type { Metadata } from '../';
5
7
  import Scorecard from 'scorecard-ai';
@@ -8,6 +10,9 @@ export const metadata: Metadata = {
8
10
  resource: 'systems',
9
11
  operation: 'write',
10
12
  tags: [],
13
+ httpMethod: 'post',
14
+ httpPath: '/projects/{projectId}/systems',
15
+ operationId: 'createSystem',
11
16
  };
12
17
 
13
18
  export const tool: Tool = {
@@ -44,9 +49,9 @@ export const tool: Tool = {
44
49
  },
45
50
  };
46
51
 
47
- export const handler = (client: Scorecard, args: Record<string, unknown> | undefined) => {
52
+ export const handler = async (client: Scorecard, args: Record<string, unknown> | undefined) => {
48
53
  const { projectId, ...body } = args as any;
49
- return client.systems.create(projectId, body);
54
+ return asTextContentResult(await client.systems.create(projectId, body));
50
55
  };
51
56
 
52
57
  export default { metadata, tool, handler };
@@ -1,5 +1,7 @@
1
1
  // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
2
 
3
+ import { asTextContentResult } from 'scorecard-ai-mcp/tools/types';
4
+
3
5
  import { Tool } from '@modelcontextprotocol/sdk/types.js';
4
6
  import type { Metadata } from '../';
5
7
  import Scorecard from 'scorecard-ai';
@@ -8,11 +10,14 @@ export const metadata: Metadata = {
8
10
  resource: 'systems',
9
11
  operation: 'write',
10
12
  tags: [],
13
+ httpMethod: 'delete',
14
+ httpPath: '/systems/{systemId}',
15
+ operationId: 'deleteSystem',
11
16
  };
12
17
 
13
18
  export const tool: Tool = {
14
19
  name: 'delete_systems',
15
- description: 'Delete a system definition by ID. This will not delete associated system configurations.',
20
+ description: 'Delete a system definition by ID. This will not delete associated system versions.',
16
21
  inputSchema: {
17
22
  type: 'object',
18
23
  properties: {
@@ -23,9 +28,9 @@ export const tool: Tool = {
23
28
  },
24
29
  };
25
30
 
26
- export const handler = (client: Scorecard, args: Record<string, unknown> | undefined) => {
31
+ export const handler = async (client: Scorecard, args: Record<string, unknown> | undefined) => {
27
32
  const { systemId, ...body } = args as any;
28
- return client.systems.delete(systemId);
33
+ return asTextContentResult(await client.systems.delete(systemId));
29
34
  };
30
35
 
31
36
  export default { metadata, tool, handler };
@@ -1,5 +1,7 @@
1
1
  // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
2
 
3
+ import { asTextContentResult } from 'scorecard-ai-mcp/tools/types';
4
+
3
5
  import { Tool } from '@modelcontextprotocol/sdk/types.js';
4
6
  import type { Metadata } from '../';
5
7
  import Scorecard from 'scorecard-ai';
@@ -8,6 +10,9 @@ export const metadata: Metadata = {
8
10
  resource: 'systems',
9
11
  operation: 'read',
10
12
  tags: [],
13
+ httpMethod: 'get',
14
+ httpPath: '/systems/{systemId}',
15
+ operationId: 'getSystem',
11
16
  };
12
17
 
13
18
  export const tool: Tool = {
@@ -23,9 +28,9 @@ export const tool: Tool = {
23
28
  },
24
29
  };
25
30
 
26
- export const handler = (client: Scorecard, args: Record<string, unknown> | undefined) => {
31
+ export const handler = async (client: Scorecard, args: Record<string, unknown> | undefined) => {
27
32
  const { systemId, ...body } = args as any;
28
- return client.systems.get(systemId);
33
+ return asTextContentResult(await client.systems.get(systemId));
29
34
  };
30
35
 
31
36
  export default { metadata, tool, handler };
@@ -1,5 +1,7 @@
1
1
  // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
2
 
3
+ import { asTextContentResult } from 'scorecard-ai-mcp/tools/types';
4
+
3
5
  import { Tool } from '@modelcontextprotocol/sdk/types.js';
4
6
  import type { Metadata } from '../';
5
7
  import Scorecard from 'scorecard-ai';
@@ -8,6 +10,9 @@ export const metadata: Metadata = {
8
10
  resource: 'systems',
9
11
  operation: 'read',
10
12
  tags: [],
13
+ httpMethod: 'get',
14
+ httpPath: '/projects/{projectId}/systems',
15
+ operationId: 'listSystems',
11
16
  };
12
17
 
13
18
  export const tool: Tool = {
@@ -33,9 +38,9 @@ export const tool: Tool = {
33
38
  },
34
39
  };
35
40
 
36
- export const handler = (client: Scorecard, args: Record<string, unknown> | undefined) => {
41
+ export const handler = async (client: Scorecard, args: Record<string, unknown> | undefined) => {
37
42
  const { projectId, ...body } = args as any;
38
- return client.systems.list(projectId, body);
43
+ return asTextContentResult(await client.systems.list(projectId, body));
39
44
  };
40
45
 
41
46
  export default { metadata, tool, handler };
@@ -1,5 +1,7 @@
1
1
  // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
2
 
3
+ import { asTextContentResult } from 'scorecard-ai-mcp/tools/types';
4
+
3
5
  import { Tool } from '@modelcontextprotocol/sdk/types.js';
4
6
  import type { Metadata } from '../';
5
7
  import Scorecard from 'scorecard-ai';
@@ -8,6 +10,9 @@ export const metadata: Metadata = {
8
10
  resource: 'systems',
9
11
  operation: 'write',
10
12
  tags: [],
13
+ httpMethod: 'patch',
14
+ httpPath: '/systems/{systemId}',
15
+ operationId: 'updateSystem',
11
16
  };
12
17
 
13
18
  export const tool: Tool = {
@@ -44,9 +49,9 @@ export const tool: Tool = {
44
49
  },
45
50
  };
46
51
 
47
- export const handler = (client: Scorecard, args: Record<string, unknown> | undefined) => {
52
+ export const handler = async (client: Scorecard, args: Record<string, unknown> | undefined) => {
48
53
  const { systemId, ...body } = args as any;
49
- return client.systems.update(systemId, body);
54
+ return asTextContentResult(await client.systems.update(systemId, body));
50
55
  };
51
56
 
52
57
  export default { metadata, tool, handler };
@@ -0,0 +1,45 @@
1
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ import { asTextContentResult } from 'scorecard-ai-mcp/tools/types';
4
+
5
+ import { Tool } from '@modelcontextprotocol/sdk/types.js';
6
+ import type { Metadata } from '../../';
7
+ import Scorecard from 'scorecard-ai';
8
+
9
+ export const metadata: Metadata = {
10
+ resource: 'systems.versions',
11
+ operation: 'write',
12
+ tags: [],
13
+ httpMethod: 'post',
14
+ httpPath: '/systems/{systemId}/configs',
15
+ operationId: 'createSystemVersion',
16
+ };
17
+
18
+ export const tool: Tool = {
19
+ name: 'create_systems_versions',
20
+ description:
21
+ "Create a new version for a system.\n\nEach version contains specific parameter values that match the system's `configSchema` - things like model parameters, thresholds, or processing options.\nOnce created, versions cannot be modified, ensuring stable reference points for evaluations.\n\nWhen creating a system version:\n- The `config` object is validated against the parent system's `configSchema`.\n- System versions with validation errors are still stored, with errors included in the response.\n- Validation errors indicate fields that don't match the schema but don't prevent creation.\n- Having validation errors may affect how some evaluation metrics are calculated.",
22
+ inputSchema: {
23
+ type: 'object',
24
+ properties: {
25
+ systemId: {
26
+ type: 'string',
27
+ },
28
+ config: {
29
+ type: 'object',
30
+ description: 'The configuration of the system version.',
31
+ },
32
+ name: {
33
+ type: 'string',
34
+ description: 'The name of the system version.',
35
+ },
36
+ },
37
+ },
38
+ };
39
+
40
+ export const handler = async (client: Scorecard, args: Record<string, unknown> | undefined) => {
41
+ const { systemId, ...body } = args as any;
42
+ return asTextContentResult(await client.systems.versions.create(systemId, body));
43
+ };
44
+
45
+ export default { metadata, tool, handler };
@@ -0,0 +1,36 @@
1
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ import { asTextContentResult } from 'scorecard-ai-mcp/tools/types';
4
+
5
+ import { Tool } from '@modelcontextprotocol/sdk/types.js';
6
+ import type { Metadata } from '../../';
7
+ import Scorecard from 'scorecard-ai';
8
+
9
+ export const metadata: Metadata = {
10
+ resource: 'systems.versions',
11
+ operation: 'read',
12
+ tags: [],
13
+ httpMethod: 'get',
14
+ httpPath: '/systems/configs/{systemVersionId}',
15
+ operationId: 'getSystemVersion',
16
+ };
17
+
18
+ export const tool: Tool = {
19
+ name: 'get_systems_versions',
20
+ description: 'Retrieve a specific system version by ID.',
21
+ inputSchema: {
22
+ type: 'object',
23
+ properties: {
24
+ systemVersionId: {
25
+ type: 'string',
26
+ },
27
+ },
28
+ },
29
+ };
30
+
31
+ export const handler = async (client: Scorecard, args: Record<string, unknown> | undefined) => {
32
+ const { systemVersionId, ...body } = args as any;
33
+ return asTextContentResult(await client.systems.versions.get(systemVersionId));
34
+ };
35
+
36
+ export default { metadata, tool, handler };