go/resources/graders/subresources/grader_models/index.md +0 −1066 deleted
File Deleted View Diff
1# Grader Models
2
3## Domain Types
4
5### Grader Inputs
6
7- `type GraderInputs []GraderInputUnion`
8
9 A list of inputs, each of which may be either an input text, output text, input
10 image, or input audio object.
11
12 - `string`
13
14 - `type ResponseInputText struct{…}`
15
16 A text input to the model.
17
18 - `Text string`
19
20 The text input to the model.
21
22 - `Type InputText`
23
24 The type of the input item. Always `input_text`.
25
26 - `const InputTextInputText InputText = "input_text"`
27
28 - `PromptCacheBreakpoint ResponseInputTextPromptCacheBreakpoint`
29
30 Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
31
32 - `Mode Explicit`
33
34 The breakpoint mode. Always `explicit`.
35
36 - `const ExplicitExplicit Explicit = "explicit"`
37
38 - `type GraderInputOutputText struct{…}`
39
40 A text output from the model.
41
42 - `Text string`
43
44 The text output from the model.
45
46 - `Type OutputText`
47
48 The type of the output text. Always `output_text`.
49
50 - `const OutputTextOutputText OutputText = "output_text"`
51
52 - `type GraderInputInputImage struct{…}`
53
54 An image input block used within EvalItem content arrays.
55
56 - `ImageURL string`
57
58 The URL of the image input.
59
60 - `Type InputImage`
61
62 The type of the image input. Always `input_image`.
63
64 - `const InputImageInputImage InputImage = "input_image"`
65
66 - `Detail string`
67
68 The detail level of the image to be sent to the model. One of `high`, `low`, or `auto`. Defaults to `auto`.
69
70 - `type ResponseInputAudio struct{…}`
71
72 An audio input to the model.
73
74 - `InputAudio ResponseInputAudioInputAudio`
75
76 - `Data string`
77
78 Base64-encoded audio data.
79
80 - `Format string`
81
82 The format of the audio data. Currently supported formats are `mp3` and
83 `wav`.
84
85 - `const ResponseInputAudioInputAudioFormatMP3 ResponseInputAudioInputAudioFormat = "mp3"`
86
87 - `const ResponseInputAudioInputAudioFormatWAV ResponseInputAudioInputAudioFormat = "wav"`
88
89 - `Type InputAudio`
90
91 The type of the input item. Always `input_audio`.
92
93 - `const InputAudioInputAudio InputAudio = "input_audio"`
94
95### Label Model Grader
96
97- `type LabelModelGrader struct{…}`
98
99 A LabelModelGrader object which uses a model to assign labels to each item
100 in the evaluation.
101
102 - `Input []LabelModelGraderInput`
103
104 - `Content LabelModelGraderInputContentUnion`
105
106 Inputs to the model - can contain template strings. Supports text, output text, input images, and input audio, either as a single item or an array of items.
107
108 - `string`
109
110 - `type ResponseInputText struct{…}`
111
112 A text input to the model.
113
114 - `Text string`
115
116 The text input to the model.
117
118 - `Type InputText`
119
120 The type of the input item. Always `input_text`.
121
122 - `const InputTextInputText InputText = "input_text"`
123
124 - `PromptCacheBreakpoint ResponseInputTextPromptCacheBreakpoint`
125
126 Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
127
128 - `Mode Explicit`
129
130 The breakpoint mode. Always `explicit`.
131
132 - `const ExplicitExplicit Explicit = "explicit"`
133
134 - `type LabelModelGraderInputContentOutputText struct{…}`
135
136 A text output from the model.
137
138 - `Text string`
139
140 The text output from the model.
141
142 - `Type OutputText`
143
144 The type of the output text. Always `output_text`.
145
146 - `const OutputTextOutputText OutputText = "output_text"`
147
148 - `type LabelModelGraderInputContentInputImage struct{…}`
149
150 An image input block used within EvalItem content arrays.
151
152 - `ImageURL string`
153
154 The URL of the image input.
155
156 - `Type InputImage`
157
158 The type of the image input. Always `input_image`.
159
160 - `const InputImageInputImage InputImage = "input_image"`
161
162 - `Detail string`
163
164 The detail level of the image to be sent to the model. One of `high`, `low`, or `auto`. Defaults to `auto`.
165
166 - `type ResponseInputAudio struct{…}`
167
168 An audio input to the model.
169
170 - `InputAudio ResponseInputAudioInputAudio`
171
172 - `Data string`
173
174 Base64-encoded audio data.
175
176 - `Format string`
177
178 The format of the audio data. Currently supported formats are `mp3` and
179 `wav`.
180
181 - `const ResponseInputAudioInputAudioFormatMP3 ResponseInputAudioInputAudioFormat = "mp3"`
182
183 - `const ResponseInputAudioInputAudioFormatWAV ResponseInputAudioInputAudioFormat = "wav"`
184
185 - `Type InputAudio`
186
187 The type of the input item. Always `input_audio`.
188
189 - `const InputAudioInputAudio InputAudio = "input_audio"`
190
191 - `type GraderInputs []GraderInputUnion`
192
193 A list of inputs, each of which may be either an input text, output text, input
194 image, or input audio object.
195
196 - `string`
197
198 - `type ResponseInputText struct{…}`
199
200 A text input to the model.
201
202 - `type GraderInputOutputText struct{…}`
203
204 A text output from the model.
205
206 - `Text string`
207
208 The text output from the model.
209
210 - `Type OutputText`
211
212 The type of the output text. Always `output_text`.
213
214 - `const OutputTextOutputText OutputText = "output_text"`
215
216 - `type GraderInputInputImage struct{…}`
217
218 An image input block used within EvalItem content arrays.
219
220 - `ImageURL string`
221
222 The URL of the image input.
223
224 - `Type InputImage`
225
226 The type of the image input. Always `input_image`.
227
228 - `const InputImageInputImage InputImage = "input_image"`
229
230 - `Detail string`
231
232 The detail level of the image to be sent to the model. One of `high`, `low`, or `auto`. Defaults to `auto`.
233
234 - `type ResponseInputAudio struct{…}`
235
236 An audio input to the model.
237
238 - `Role string`
239
240 The role of the message input. One of `user`, `assistant`, `system`, or
241 `developer`.
242
243 - `const LabelModelGraderInputRoleUser LabelModelGraderInputRole = "user"`
244
245 - `const LabelModelGraderInputRoleAssistant LabelModelGraderInputRole = "assistant"`
246
247 - `const LabelModelGraderInputRoleSystem LabelModelGraderInputRole = "system"`
248
249 - `const LabelModelGraderInputRoleDeveloper LabelModelGraderInputRole = "developer"`
250
251 - `Type string`
252
253 The type of the message input. Always `message`.
254
255 - `const LabelModelGraderInputTypeMessage LabelModelGraderInputType = "message"`
256
257 - `Labels []string`
258
259 The labels to assign to each item in the evaluation.
260
261 - `Model string`
262
263 The model to use for the evaluation. Must support structured outputs.
264
265 - `Name string`
266
267 The name of the grader.
268
269 - `PassingLabels []string`
270
271 The labels that indicate a passing result. Must be a subset of labels.
272
273 - `Type LabelModel`
274
275 The object type, which is always `label_model`.
276
277 - `const LabelModelLabelModel LabelModel = "label_model"`
278
279### Multi Grader
280
281- `type MultiGrader struct{…}`
282
283 A MultiGrader object combines the output of multiple graders to produce a single score.
284
285 - `CalculateOutput string`
286
287 A formula to calculate the output based on grader results.
288
289 - `Graders MultiGraderGradersUnion`
290
291 A StringCheckGrader object that performs a string comparison between input and reference using a specified operation.
292
293 - `type StringCheckGrader struct{…}`
294
295 A StringCheckGrader object that performs a string comparison between input and reference using a specified operation.
296
297 - `Input string`
298
299 The input text. This may include template strings.
300
301 - `Name string`
302
303 The name of the grader.
304
305 - `Operation StringCheckGraderOperation`
306
307 The string check operation to perform. One of `eq`, `ne`, `like`, or `ilike`.
308
309 - `const StringCheckGraderOperationEq StringCheckGraderOperation = "eq"`
310
311 - `const StringCheckGraderOperationNe StringCheckGraderOperation = "ne"`
312
313 - `const StringCheckGraderOperationLike StringCheckGraderOperation = "like"`
314
315 - `const StringCheckGraderOperationIlike StringCheckGraderOperation = "ilike"`
316
317 - `Reference string`
318
319 The reference text. This may include template strings.
320
321 - `Type StringCheck`
322
323 The object type, which is always `string_check`.
324
325 - `const StringCheckStringCheck StringCheck = "string_check"`
326
327 - `type TextSimilarityGrader struct{…}`
328
329 A TextSimilarityGrader object which grades text based on similarity metrics.
330
331 - `EvaluationMetric TextSimilarityGraderEvaluationMetric`
332
333 The evaluation metric to use. One of `cosine`, `fuzzy_match`, `bleu`,
334 `gleu`, `meteor`, `rouge_1`, `rouge_2`, `rouge_3`, `rouge_4`, `rouge_5`,
335 or `rouge_l`.
336
337 - `const TextSimilarityGraderEvaluationMetricCosine TextSimilarityGraderEvaluationMetric = "cosine"`
338
339 - `const TextSimilarityGraderEvaluationMetricFuzzyMatch TextSimilarityGraderEvaluationMetric = "fuzzy_match"`
340
341 - `const TextSimilarityGraderEvaluationMetricBleu TextSimilarityGraderEvaluationMetric = "bleu"`
342
343 - `const TextSimilarityGraderEvaluationMetricGleu TextSimilarityGraderEvaluationMetric = "gleu"`
344
345 - `const TextSimilarityGraderEvaluationMetricMeteor TextSimilarityGraderEvaluationMetric = "meteor"`
346
347 - `const TextSimilarityGraderEvaluationMetricRouge1 TextSimilarityGraderEvaluationMetric = "rouge_1"`
348
349 - `const TextSimilarityGraderEvaluationMetricRouge2 TextSimilarityGraderEvaluationMetric = "rouge_2"`
350
351 - `const TextSimilarityGraderEvaluationMetricRouge3 TextSimilarityGraderEvaluationMetric = "rouge_3"`
352
353 - `const TextSimilarityGraderEvaluationMetricRouge4 TextSimilarityGraderEvaluationMetric = "rouge_4"`
354
355 - `const TextSimilarityGraderEvaluationMetricRouge5 TextSimilarityGraderEvaluationMetric = "rouge_5"`
356
357 - `const TextSimilarityGraderEvaluationMetricRougeL TextSimilarityGraderEvaluationMetric = "rouge_l"`
358
359 - `Input string`
360
361 The text being graded.
362
363 - `Name string`
364
365 The name of the grader.
366
367 - `Reference string`
368
369 The text being graded against.
370
371 - `Type TextSimilarity`
372
373 The type of grader.
374
375 - `const TextSimilarityTextSimilarity TextSimilarity = "text_similarity"`
376
377 - `type PythonGrader struct{…}`
378
379 A PythonGrader object that runs a python script on the input.
380
381 - `Name string`
382
383 The name of the grader.
384
385 - `Source string`
386
387 The source code of the python script.
388
389 - `Type Python`
390
391 The object type, which is always `python`.
392
393 - `const PythonPython Python = "python"`
394
395 - `ImageTag string`
396
397 The image tag to use for the python script.
398
399 - `type ScoreModelGrader struct{…}`
400
401 A ScoreModelGrader object that uses a model to assign a score to the input.
402
403 - `Input []ScoreModelGraderInput`
404
405 The input messages evaluated by the grader. Supports text, output text, input image, and input audio content blocks, and may include template strings.
406
407 - `Content ScoreModelGraderInputContentUnion`
408
409 Inputs to the model - can contain template strings. Supports text, output text, input images, and input audio, either as a single item or an array of items.
410
411 - `string`
412
413 - `type ResponseInputText struct{…}`
414
415 A text input to the model.
416
417 - `Text string`
418
419 The text input to the model.
420
421 - `Type InputText`
422
423 The type of the input item. Always `input_text`.
424
425 - `const InputTextInputText InputText = "input_text"`
426
427 - `PromptCacheBreakpoint ResponseInputTextPromptCacheBreakpoint`
428
429 Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
430
431 - `Mode Explicit`
432
433 The breakpoint mode. Always `explicit`.
434
435 - `const ExplicitExplicit Explicit = "explicit"`
436
437 - `type ScoreModelGraderInputContentOutputText struct{…}`
438
439 A text output from the model.
440
441 - `Text string`
442
443 The text output from the model.
444
445 - `Type OutputText`
446
447 The type of the output text. Always `output_text`.
448
449 - `const OutputTextOutputText OutputText = "output_text"`
450
451 - `type ScoreModelGraderInputContentInputImage struct{…}`
452
453 An image input block used within EvalItem content arrays.
454
455 - `ImageURL string`
456
457 The URL of the image input.
458
459 - `Type InputImage`
460
461 The type of the image input. Always `input_image`.
462
463 - `const InputImageInputImage InputImage = "input_image"`
464
465 - `Detail string`
466
467 The detail level of the image to be sent to the model. One of `high`, `low`, or `auto`. Defaults to `auto`.
468
469 - `type ResponseInputAudio struct{…}`
470
471 An audio input to the model.
472
473 - `InputAudio ResponseInputAudioInputAudio`
474
475 - `Data string`
476
477 Base64-encoded audio data.
478
479 - `Format string`
480
481 The format of the audio data. Currently supported formats are `mp3` and
482 `wav`.
483
484 - `const ResponseInputAudioInputAudioFormatMP3 ResponseInputAudioInputAudioFormat = "mp3"`
485
486 - `const ResponseInputAudioInputAudioFormatWAV ResponseInputAudioInputAudioFormat = "wav"`
487
488 - `Type InputAudio`
489
490 The type of the input item. Always `input_audio`.
491
492 - `const InputAudioInputAudio InputAudio = "input_audio"`
493
494 - `type GraderInputs []GraderInputUnion`
495
496 A list of inputs, each of which may be either an input text, output text, input
497 image, or input audio object.
498
499 - `string`
500
501 - `type ResponseInputText struct{…}`
502
503 A text input to the model.
504
505 - `type GraderInputOutputText struct{…}`
506
507 A text output from the model.
508
509 - `Text string`
510
511 The text output from the model.
512
513 - `Type OutputText`
514
515 The type of the output text. Always `output_text`.
516
517 - `const OutputTextOutputText OutputText = "output_text"`
518
519 - `type GraderInputInputImage struct{…}`
520
521 An image input block used within EvalItem content arrays.
522
523 - `ImageURL string`
524
525 The URL of the image input.
526
527 - `Type InputImage`
528
529 The type of the image input. Always `input_image`.
530
531 - `const InputImageInputImage InputImage = "input_image"`
532
533 - `Detail string`
534
535 The detail level of the image to be sent to the model. One of `high`, `low`, or `auto`. Defaults to `auto`.
536
537 - `type ResponseInputAudio struct{…}`
538
539 An audio input to the model.
540
541 - `Role string`
542
543 The role of the message input. One of `user`, `assistant`, `system`, or
544 `developer`.
545
546 - `const ScoreModelGraderInputRoleUser ScoreModelGraderInputRole = "user"`
547
548 - `const ScoreModelGraderInputRoleAssistant ScoreModelGraderInputRole = "assistant"`
549
550 - `const ScoreModelGraderInputRoleSystem ScoreModelGraderInputRole = "system"`
551
552 - `const ScoreModelGraderInputRoleDeveloper ScoreModelGraderInputRole = "developer"`
553
554 - `Type string`
555
556 The type of the message input. Always `message`.
557
558 - `const ScoreModelGraderInputTypeMessage ScoreModelGraderInputType = "message"`
559
560 - `Model string`
561
562 The model to use for the evaluation.
563
564 - `Name string`
565
566 The name of the grader.
567
568 - `Type ScoreModel`
569
570 The object type, which is always `score_model`.
571
572 - `const ScoreModelScoreModel ScoreModel = "score_model"`
573
574 - `Range []float64`
575
576 The range of the score. Defaults to `[0, 1]`.
577
578 - `SamplingParams ScoreModelGraderSamplingParams`
579
580 The sampling parameters for the model.
581
582 - `MaxCompletionsTokens int64`
583
584 The maximum number of tokens the grader model may generate in its response.
585
586 - `ReasoningEffort ReasoningEffort`
587
588 Constrains effort on reasoning for reasoning models. Currently supported
589 values are `none`, `minimal`, `low`, `medium`, `high`, `xhigh`, and `max`.
590 Reducing reasoning effort can result in faster responses and fewer tokens
591 used on reasoning in a response. Not all reasoning models support every
592 value. See the
593 [reasoning guide](https://platform.openai.com/docs/guides/reasoning)
594 for model-specific support.
595
596 - `const ReasoningEffortNone ReasoningEffort = "none"`
597
598 - `const ReasoningEffortMinimal ReasoningEffort = "minimal"`
599
600 - `const ReasoningEffortLow ReasoningEffort = "low"`
601
602 - `const ReasoningEffortMedium ReasoningEffort = "medium"`
603
604 - `const ReasoningEffortHigh ReasoningEffort = "high"`
605
606 - `const ReasoningEffortXhigh ReasoningEffort = "xhigh"`
607
608 - `const ReasoningEffortMax ReasoningEffort = "max"`
609
610 - `Seed int64`
611
612 A seed value to initialize the randomness, during sampling.
613
614 - `Temperature float64`
615
616 A higher temperature increases randomness in the outputs.
617
618 - `TopP float64`
619
620 An alternative to temperature for nucleus sampling; 1.0 includes all tokens.
621
622 - `type LabelModelGrader struct{…}`
623
624 A LabelModelGrader object which uses a model to assign labels to each item
625 in the evaluation.
626
627 - `Input []LabelModelGraderInput`
628
629 - `Content LabelModelGraderInputContentUnion`
630
631 Inputs to the model - can contain template strings. Supports text, output text, input images, and input audio, either as a single item or an array of items.
632
633 - `string`
634
635 - `type ResponseInputText struct{…}`
636
637 A text input to the model.
638
639 - `type LabelModelGraderInputContentOutputText struct{…}`
640
641 A text output from the model.
642
643 - `Text string`
644
645 The text output from the model.
646
647 - `Type OutputText`
648
649 The type of the output text. Always `output_text`.
650
651 - `const OutputTextOutputText OutputText = "output_text"`
652
653 - `type LabelModelGraderInputContentInputImage struct{…}`
654
655 An image input block used within EvalItem content arrays.
656
657 - `ImageURL string`
658
659 The URL of the image input.
660
661 - `Type InputImage`
662
663 The type of the image input. Always `input_image`.
664
665 - `const InputImageInputImage InputImage = "input_image"`
666
667 - `Detail string`
668
669 The detail level of the image to be sent to the model. One of `high`, `low`, or `auto`. Defaults to `auto`.
670
671 - `type ResponseInputAudio struct{…}`
672
673 An audio input to the model.
674
675 - `type GraderInputs []GraderInputUnion`
676
677 A list of inputs, each of which may be either an input text, output text, input
678 image, or input audio object.
679
680 - `Role string`
681
682 The role of the message input. One of `user`, `assistant`, `system`, or
683 `developer`.
684
685 - `const LabelModelGraderInputRoleUser LabelModelGraderInputRole = "user"`
686
687 - `const LabelModelGraderInputRoleAssistant LabelModelGraderInputRole = "assistant"`
688
689 - `const LabelModelGraderInputRoleSystem LabelModelGraderInputRole = "system"`
690
691 - `const LabelModelGraderInputRoleDeveloper LabelModelGraderInputRole = "developer"`
692
693 - `Type string`
694
695 The type of the message input. Always `message`.
696
697 - `const LabelModelGraderInputTypeMessage LabelModelGraderInputType = "message"`
698
699 - `Labels []string`
700
701 The labels to assign to each item in the evaluation.
702
703 - `Model string`
704
705 The model to use for the evaluation. Must support structured outputs.
706
707 - `Name string`
708
709 The name of the grader.
710
711 - `PassingLabels []string`
712
713 The labels that indicate a passing result. Must be a subset of labels.
714
715 - `Type LabelModel`
716
717 The object type, which is always `label_model`.
718
719 - `const LabelModelLabelModel LabelModel = "label_model"`
720
721 - `Name string`
722
723 The name of the grader.
724
725 - `Type Multi`
726
727 The object type, which is always `multi`.
728
729 - `const MultiMulti Multi = "multi"`
730
731### Python Grader
732
733- `type PythonGrader struct{…}`
734
735 A PythonGrader object that runs a python script on the input.
736
737 - `Name string`
738
739 The name of the grader.
740
741 - `Source string`
742
743 The source code of the python script.
744
745 - `Type Python`
746
747 The object type, which is always `python`.
748
749 - `const PythonPython Python = "python"`
750
751 - `ImageTag string`
752
753 The image tag to use for the python script.
754
755### Score Model Grader
756
757- `type ScoreModelGrader struct{…}`
758
759 A ScoreModelGrader object that uses a model to assign a score to the input.
760
761 - `Input []ScoreModelGraderInput`
762
763 The input messages evaluated by the grader. Supports text, output text, input image, and input audio content blocks, and may include template strings.
764
765 - `Content ScoreModelGraderInputContentUnion`
766
767 Inputs to the model - can contain template strings. Supports text, output text, input images, and input audio, either as a single item or an array of items.
768
769 - `string`
770
771 - `type ResponseInputText struct{…}`
772
773 A text input to the model.
774
775 - `Text string`
776
777 The text input to the model.
778
779 - `Type InputText`
780
781 The type of the input item. Always `input_text`.
782
783 - `const InputTextInputText InputText = "input_text"`
784
785 - `PromptCacheBreakpoint ResponseInputTextPromptCacheBreakpoint`
786
787 Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
788
789 - `Mode Explicit`
790
791 The breakpoint mode. Always `explicit`.
792
793 - `const ExplicitExplicit Explicit = "explicit"`
794
795 - `type ScoreModelGraderInputContentOutputText struct{…}`
796
797 A text output from the model.
798
799 - `Text string`
800
801 The text output from the model.
802
803 - `Type OutputText`
804
805 The type of the output text. Always `output_text`.
806
807 - `const OutputTextOutputText OutputText = "output_text"`
808
809 - `type ScoreModelGraderInputContentInputImage struct{…}`
810
811 An image input block used within EvalItem content arrays.
812
813 - `ImageURL string`
814
815 The URL of the image input.
816
817 - `Type InputImage`
818
819 The type of the image input. Always `input_image`.
820
821 - `const InputImageInputImage InputImage = "input_image"`
822
823 - `Detail string`
824
825 The detail level of the image to be sent to the model. One of `high`, `low`, or `auto`. Defaults to `auto`.
826
827 - `type ResponseInputAudio struct{…}`
828
829 An audio input to the model.
830
831 - `InputAudio ResponseInputAudioInputAudio`
832
833 - `Data string`
834
835 Base64-encoded audio data.
836
837 - `Format string`
838
839 The format of the audio data. Currently supported formats are `mp3` and
840 `wav`.
841
842 - `const ResponseInputAudioInputAudioFormatMP3 ResponseInputAudioInputAudioFormat = "mp3"`
843
844 - `const ResponseInputAudioInputAudioFormatWAV ResponseInputAudioInputAudioFormat = "wav"`
845
846 - `Type InputAudio`
847
848 The type of the input item. Always `input_audio`.
849
850 - `const InputAudioInputAudio InputAudio = "input_audio"`
851
852 - `type GraderInputs []GraderInputUnion`
853
854 A list of inputs, each of which may be either an input text, output text, input
855 image, or input audio object.
856
857 - `string`
858
859 - `type ResponseInputText struct{…}`
860
861 A text input to the model.
862
863 - `type GraderInputOutputText struct{…}`
864
865 A text output from the model.
866
867 - `Text string`
868
869 The text output from the model.
870
871 - `Type OutputText`
872
873 The type of the output text. Always `output_text`.
874
875 - `const OutputTextOutputText OutputText = "output_text"`
876
877 - `type GraderInputInputImage struct{…}`
878
879 An image input block used within EvalItem content arrays.
880
881 - `ImageURL string`
882
883 The URL of the image input.
884
885 - `Type InputImage`
886
887 The type of the image input. Always `input_image`.
888
889 - `const InputImageInputImage InputImage = "input_image"`
890
891 - `Detail string`
892
893 The detail level of the image to be sent to the model. One of `high`, `low`, or `auto`. Defaults to `auto`.
894
895 - `type ResponseInputAudio struct{…}`
896
897 An audio input to the model.
898
899 - `Role string`
900
901 The role of the message input. One of `user`, `assistant`, `system`, or
902 `developer`.
903
904 - `const ScoreModelGraderInputRoleUser ScoreModelGraderInputRole = "user"`
905
906 - `const ScoreModelGraderInputRoleAssistant ScoreModelGraderInputRole = "assistant"`
907
908 - `const ScoreModelGraderInputRoleSystem ScoreModelGraderInputRole = "system"`
909
910 - `const ScoreModelGraderInputRoleDeveloper ScoreModelGraderInputRole = "developer"`
911
912 - `Type string`
913
914 The type of the message input. Always `message`.
915
916 - `const ScoreModelGraderInputTypeMessage ScoreModelGraderInputType = "message"`
917
918 - `Model string`
919
920 The model to use for the evaluation.
921
922 - `Name string`
923
924 The name of the grader.
925
926 - `Type ScoreModel`
927
928 The object type, which is always `score_model`.
929
930 - `const ScoreModelScoreModel ScoreModel = "score_model"`
931
932 - `Range []float64`
933
934 The range of the score. Defaults to `[0, 1]`.
935
936 - `SamplingParams ScoreModelGraderSamplingParams`
937
938 The sampling parameters for the model.
939
940 - `MaxCompletionsTokens int64`
941
942 The maximum number of tokens the grader model may generate in its response.
943
944 - `ReasoningEffort ReasoningEffort`
945
946 Constrains effort on reasoning for reasoning models. Currently supported
947 values are `none`, `minimal`, `low`, `medium`, `high`, `xhigh`, and `max`.
948 Reducing reasoning effort can result in faster responses and fewer tokens
949 used on reasoning in a response. Not all reasoning models support every
950 value. See the
951 [reasoning guide](https://platform.openai.com/docs/guides/reasoning)
952 for model-specific support.
953
954 - `const ReasoningEffortNone ReasoningEffort = "none"`
955
956 - `const ReasoningEffortMinimal ReasoningEffort = "minimal"`
957
958 - `const ReasoningEffortLow ReasoningEffort = "low"`
959
960 - `const ReasoningEffortMedium ReasoningEffort = "medium"`
961
962 - `const ReasoningEffortHigh ReasoningEffort = "high"`
963
964 - `const ReasoningEffortXhigh ReasoningEffort = "xhigh"`
965
966 - `const ReasoningEffortMax ReasoningEffort = "max"`
967
968 - `Seed int64`
969
970 A seed value to initialize the randomness, during sampling.
971
972 - `Temperature float64`
973
974 A higher temperature increases randomness in the outputs.
975
976 - `TopP float64`
977
978 An alternative to temperature for nucleus sampling; 1.0 includes all tokens.
979
980### String Check Grader
981
982- `type StringCheckGrader struct{…}`
983
984 A StringCheckGrader object that performs a string comparison between input and reference using a specified operation.
985
986 - `Input string`
987
988 The input text. This may include template strings.
989
990 - `Name string`
991
992 The name of the grader.
993
994 - `Operation StringCheckGraderOperation`
995
996 The string check operation to perform. One of `eq`, `ne`, `like`, or `ilike`.
997
998 - `const StringCheckGraderOperationEq StringCheckGraderOperation = "eq"`
999
1000 - `const StringCheckGraderOperationNe StringCheckGraderOperation = "ne"`
1001
1002 - `const StringCheckGraderOperationLike StringCheckGraderOperation = "like"`
1003
1004 - `const StringCheckGraderOperationIlike StringCheckGraderOperation = "ilike"`
1005
1006 - `Reference string`
1007
1008 The reference text. This may include template strings.
1009
1010 - `Type StringCheck`
1011
1012 The object type, which is always `string_check`.
1013
1014 - `const StringCheckStringCheck StringCheck = "string_check"`
1015
1016### Text Similarity Grader
1017
1018- `type TextSimilarityGrader struct{…}`
1019
1020 A TextSimilarityGrader object which grades text based on similarity metrics.
1021
1022 - `EvaluationMetric TextSimilarityGraderEvaluationMetric`
1023
1024 The evaluation metric to use. One of `cosine`, `fuzzy_match`, `bleu`,
1025 `gleu`, `meteor`, `rouge_1`, `rouge_2`, `rouge_3`, `rouge_4`, `rouge_5`,
1026 or `rouge_l`.
1027
1028 - `const TextSimilarityGraderEvaluationMetricCosine TextSimilarityGraderEvaluationMetric = "cosine"`
1029
1030 - `const TextSimilarityGraderEvaluationMetricFuzzyMatch TextSimilarityGraderEvaluationMetric = "fuzzy_match"`
1031
1032 - `const TextSimilarityGraderEvaluationMetricBleu TextSimilarityGraderEvaluationMetric = "bleu"`
1033
1034 - `const TextSimilarityGraderEvaluationMetricGleu TextSimilarityGraderEvaluationMetric = "gleu"`
1035
1036 - `const TextSimilarityGraderEvaluationMetricMeteor TextSimilarityGraderEvaluationMetric = "meteor"`
1037
1038 - `const TextSimilarityGraderEvaluationMetricRouge1 TextSimilarityGraderEvaluationMetric = "rouge_1"`
1039
1040 - `const TextSimilarityGraderEvaluationMetricRouge2 TextSimilarityGraderEvaluationMetric = "rouge_2"`
1041
1042 - `const TextSimilarityGraderEvaluationMetricRouge3 TextSimilarityGraderEvaluationMetric = "rouge_3"`
1043
1044 - `const TextSimilarityGraderEvaluationMetricRouge4 TextSimilarityGraderEvaluationMetric = "rouge_4"`
1045
1046 - `const TextSimilarityGraderEvaluationMetricRouge5 TextSimilarityGraderEvaluationMetric = "rouge_5"`
1047
1048 - `const TextSimilarityGraderEvaluationMetricRougeL TextSimilarityGraderEvaluationMetric = "rouge_l"`
1049
1050 - `Input string`
1051
1052 The text being graded.
1053
1054 - `Name string`
1055
1056 The name of the grader.
1057
1058 - `Reference string`
1059
1060 The text being graded against.
1061
1062 - `Type TextSimilarity`
1063
1064 The type of grader.
1065
1066 - `const TextSimilarityTextSimilarity TextSimilarity = "text_similarity"`