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 1.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
  1. # yaml-language-server: $schema=https://promptfoo.dev/config-schema.json
  2. prompts:
  3. - |
  4. You are an internal corporate chatbot.
  5. Respond to this query: {{query}}
  6. Here is some context that you can use to write your response: {{context}}
  7. providers:
  8. - openai:gpt-4o-mini
  9. tests:
  10. - vars:
  11. query: What is the max purchase that doesn't require approval?
  12. context: file://docs/reimbursement.md
  13. assert:
  14. - type: contains
  15. value: '$500'
  16. - type: factuality
  17. value: the employee's manager is responsible for approvals
  18. - type: answer-relevance
  19. threshold: 0.9
  20. - type: context-recall
  21. threshold: 0.9
  22. value: max purchase price without approval is $500. Talk to Fred before submitting anything.
  23. - type: context-relevance
  24. threshold: 0.9
  25. - type: context-faithfulness
  26. threshold: 0.9
  27. - vars:
  28. query: How many weeks is maternity leave?
  29. context: file://docs/maternity.md
  30. assert:
  31. - type: factuality
  32. value: maternity leave is 4 months
  33. - type: answer-relevance
  34. threshold: 0.9
  35. - type: context-recall
  36. threshold: 0.9
  37. value: The company offers 4 months of maternity leave, unless you are an elephant, in which case you get 22 months of maternity leave.
  38. - type: context-relevance
  39. threshold: 0.9
  40. - type: context-faithfulness
  41. threshold: 0.9
Tip!

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

Comments

Loading...