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.ts 706 B

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
  1. import type { UnifiedConfig } from 'promptfoo';
  2. const config: UnifiedConfig = {
  3. description: 'A translator built with LLM',
  4. prompts: [
  5. 'Rephrase this in {{language}}: {{body}}',
  6. 'Translate this to conversational {{language}}: {{body}}',
  7. ],
  8. providers: ['openai:gpt-4.1-mini'],
  9. tests: [
  10. {
  11. vars: {
  12. language: 'French',
  13. body: 'Hello world',
  14. },
  15. },
  16. {
  17. vars: {
  18. language: 'French',
  19. body: "I'm hungry",
  20. },
  21. },
  22. {
  23. vars: {
  24. language: 'Pirate',
  25. body: 'Hello world',
  26. },
  27. },
  28. {
  29. vars: {
  30. language: 'Pirate',
  31. body: "I'm hungry",
  32. },
  33. },
  34. ],
  35. };
  36. export default config;
Tip!

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

Comments

Loading...