Register
Login
Resources
Docs Blog Datasets Glossary Case Studies Tutorials & Webinars
Product
Data Engine LLMs Platform Enterprise
Pricing Explore
Connect to our Discord channel

promptfooconfig.yaml 2.4 KB

You have to be logged in to leave a comment. Sign In
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
  1. # yaml-language-server: $schema=https://promptfoo.dev/config-schema.json
  2. prompts:
  3. - |
  4. Given this math puzzle: {{puzzle}}
  5. Please solve this step by step, showing your reasoning process.
  6. providers:
  7. - id: google:gemini-2.5-flash-preview-04-17
  8. config:
  9. generationConfig:
  10. temperature: 0.7
  11. maxOutputTokens: 2048
  12. thinkingConfig:
  13. thinkingBudget: 1024
  14. - google:gemini-2.0-flash-exp
  15. - google:gemini-2.0-flash-thinking-exp
  16. - id: google:gemini-2.5-pro-exp-03-25
  17. config:
  18. temperature: 0.7
  19. maxOutputTokens: 2048
  20. - id: google:gemini-1.5-pro
  21. config:
  22. temperature: 0.7
  23. maxOutputTokens: 1024
  24. topP: 0.9
  25. topK: 40
  26. # Structured output example
  27. - id: google:gemini-1.5-pro
  28. config:
  29. generationConfig:
  30. temperature: 0
  31. maxOutputTokens: 1024
  32. response_mime_type: 'application/json'
  33. response_schema:
  34. type: 'object'
  35. properties:
  36. answer:
  37. type: 'string'
  38. description: 'The numerical or text answer'
  39. confidence:
  40. type: 'string'
  41. enum: ['high', 'medium', 'low']
  42. method_used:
  43. type: 'string'
  44. description: 'One-word description of solving method'
  45. required: ['answer', 'confidence', 'method_used']
  46. # Function calling example
  47. - id: google:gemini-1.5-pro
  48. config:
  49. tools:
  50. function_declarations:
  51. - name: 'verify_answer'
  52. description: 'Verify if the answer is correct'
  53. parameters:
  54. type: 'object'
  55. properties:
  56. answer:
  57. type: 'string'
  58. description: 'The proposed answer'
  59. explanation:
  60. type: 'string'
  61. description: 'Brief explanation'
  62. required: ['answer']
  63. tool_config:
  64. function_calling_config:
  65. mode: 'auto'
  66. defaultTest:
  67. options:
  68. provider:
  69. text:
  70. id: google:gemini-2.0-flash-exp
  71. embedding:
  72. id: google:embedding:text-embedding-004
  73. tests:
  74. - vars:
  75. puzzle: 'If a train travels at 60 mph for 2.5 hours, then at 40 mph for 1.5 hours, what is the average speed for the entire journey?'
  76. assert:
  77. - type: contains
  78. value: 52.5
  79. - type: llm-rubric
  80. value: |
  81. The answer should be 52.5 mph.
  82. - type: similar
  83. value: 52.5 mph
Tip!

Press p or to see the previous file or, n or to see the next file

Comments

Loading...