promptfoo 0.71.0 → 0.72.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 (126) hide show
  1. package/README.md +2 -0
  2. package/dist/package.json +2 -1
  3. package/dist/src/assertions.d.ts +8 -0
  4. package/dist/src/assertions.d.ts.map +1 -1
  5. package/dist/src/assertions.js +79 -0
  6. package/dist/src/assertions.js.map +1 -1
  7. package/dist/src/commands/generate/redteam.d.ts +2 -1
  8. package/dist/src/commands/generate/redteam.d.ts.map +1 -1
  9. package/dist/src/commands/generate/redteam.js +6 -2
  10. package/dist/src/commands/generate/redteam.js.map +1 -1
  11. package/dist/src/commands/redteam.d.ts.map +1 -1
  12. package/dist/src/commands/redteam.js +1 -0
  13. package/dist/src/commands/redteam.js.map +1 -1
  14. package/dist/src/constants.d.ts +1 -0
  15. package/dist/src/constants.d.ts.map +1 -1
  16. package/dist/src/constants.js +6 -1
  17. package/dist/src/constants.js.map +1 -1
  18. package/dist/src/providers/manualInput.d.ts +15 -0
  19. package/dist/src/providers/manualInput.d.ts.map +1 -0
  20. package/dist/src/providers/manualInput.js +52 -0
  21. package/dist/src/providers/manualInput.js.map +1 -0
  22. package/dist/src/providers/mistral.d.ts.map +1 -1
  23. package/dist/src/providers/mistral.js +7 -0
  24. package/dist/src/providers/mistral.js.map +1 -1
  25. package/dist/src/providers.d.ts.map +1 -1
  26. package/dist/src/providers.js +8 -5
  27. package/dist/src/providers.js.map +1 -1
  28. package/dist/src/redteam/index.d.ts +6 -2
  29. package/dist/src/redteam/index.d.ts.map +1 -1
  30. package/dist/src/redteam/index.js +9 -9
  31. package/dist/src/redteam/index.js.map +1 -1
  32. package/dist/src/redteam/plugins/base.d.ts +3 -2
  33. package/dist/src/redteam/plugins/base.d.ts.map +1 -1
  34. package/dist/src/redteam/plugins/base.js +4 -2
  35. package/dist/src/redteam/plugins/base.js.map +1 -1
  36. package/dist/src/redteam/plugins/competitors.js +1 -1
  37. package/dist/src/redteam/plugins/contracts.js +1 -1
  38. package/dist/src/redteam/plugins/excessiveAgency.js +1 -1
  39. package/dist/src/redteam/plugins/hallucination.js +1 -1
  40. package/dist/src/redteam/plugins/harmful.d.ts.map +1 -1
  41. package/dist/src/redteam/plugins/harmful.js +23 -20
  42. package/dist/src/redteam/plugins/harmful.js.map +1 -1
  43. package/dist/src/redteam/plugins/hijacking.js +1 -1
  44. package/dist/src/redteam/plugins/overreliance.js +1 -1
  45. package/dist/src/redteam/plugins/pii.d.ts +2 -1
  46. package/dist/src/redteam/plugins/pii.d.ts.map +1 -1
  47. package/dist/src/redteam/plugins/pii.js +7 -5
  48. package/dist/src/redteam/plugins/pii.js.map +1 -1
  49. package/dist/src/redteam/plugins/politics.js +1 -1
  50. package/dist/src/redteam/providers/iterative.js +1 -1
  51. package/dist/src/redteam/providers/iterative.js.map +1 -1
  52. package/dist/src/redteam/providers/iterativeImage.js +1 -1
  53. package/dist/src/redteam/providers/iterativeImage.js.map +1 -1
  54. package/dist/src/types.d.ts +3 -1
  55. package/dist/src/types.d.ts.map +1 -1
  56. package/dist/src/types.js +2 -0
  57. package/dist/src/types.js.map +1 -1
  58. package/dist/src/updates.d.ts.map +1 -1
  59. package/dist/src/updates.js +2 -4
  60. package/dist/src/updates.js.map +1 -1
  61. package/dist/src/util/index.d.ts +1 -1
  62. package/dist/src/util/index.d.ts.map +1 -1
  63. package/dist/src/util/index.js +11 -10
  64. package/dist/src/util/index.js.map +1 -1
  65. package/dist/src/web/nextui/404/index.html +1 -1
  66. package/dist/src/web/nextui/404.html +1 -1
  67. package/dist/src/web/nextui/_next/static/chunks/{258-9bad5f8846b93785.js → 258-4acb452fe85cff6f.js} +2 -2
  68. package/dist/src/web/nextui/_next/static/chunks/{540-ab57db4fdf86cc8a.js → 448-4da3bf74eae4996a.js} +7 -7
  69. package/dist/src/web/nextui/_next/static/chunks/53-fae6e50ace6c83a1.js +1 -0
  70. package/dist/src/web/nextui/_next/static/chunks/{106-40e3e363c957c313.js → 578-8efe57f906f7573c.js} +6 -6
  71. package/dist/src/web/nextui/_next/static/chunks/737-dbd25d447fbc5006.js +1 -0
  72. package/dist/src/web/nextui/_next/static/chunks/{531-efd0c50e833e81f1.js → 905-0da344cee75690e7.js} +4 -4
  73. package/dist/src/web/nextui/_next/static/chunks/932-75585b3be8ce494d.js +1 -0
  74. package/dist/src/web/nextui/_next/static/chunks/973-ffe3726c956d08ef.js +2 -0
  75. package/dist/src/web/nextui/_next/static/chunks/app/auth/login/page-2e6452987650f232.js +1 -0
  76. package/dist/src/web/nextui/_next/static/chunks/app/auth/signup/page-d81a6cfb22f8b8a2.js +1 -0
  77. package/dist/src/web/nextui/_next/static/chunks/app/datasets/page-73b93abb6a46ca0e.js +1 -0
  78. package/dist/src/web/nextui/_next/static/chunks/app/eval/[id]/not-found-fe10d5df88bc44ef.js +1 -0
  79. package/dist/src/web/nextui/_next/static/chunks/app/eval/[id]/{page-7bc08c50ac222ddd.js → page-81aa116b34ef4a6b.js} +1 -1
  80. package/dist/src/web/nextui/_next/static/chunks/app/eval/page-56e122e6f2a64557.js +1 -0
  81. package/dist/src/web/nextui/_next/static/chunks/app/layout-ed6af4caf66026a5.js +1 -0
  82. package/dist/src/web/nextui/_next/static/chunks/app/{page-e07a0ddbf3d6e21c.js → page-122e9cfa52eb218a.js} +1 -1
  83. package/dist/src/web/nextui/_next/static/chunks/app/progress/page-aa447776a6487d50.js +1 -0
  84. package/dist/src/web/nextui/_next/static/chunks/app/prompts/{page-50e27c24c9e255bd.js → page-ac63288a243a9872.js} +1 -1
  85. package/dist/src/web/nextui/_next/static/chunks/app/report/{page-6716acff9825da98.js → page-be70065fb1472831.js} +1 -1
  86. package/dist/src/web/nextui/_next/static/chunks/app/setup/{page-59d712c1f56ecac6.js → page-b19fc52e084a3efe.js} +1 -1
  87. package/dist/src/web/nextui/_next/static/chunks/{main-app-929a26b3c8cd3f7a.js → main-app-7a1376166cb8b72e.js} +1 -1
  88. package/dist/src/web/nextui/_next/static/chunks/{webpack-c9f728822666f852.js → webpack-8a9bc9ee0defb756.js} +1 -1
  89. package/dist/src/web/nextui/_next/static/css/106779eb64615639.css +1 -0
  90. package/dist/src/web/nextui/auth/login/index.html +1 -1
  91. package/dist/src/web/nextui/auth/login/index.txt +6 -6
  92. package/dist/src/web/nextui/auth/signup/index.html +1 -1
  93. package/dist/src/web/nextui/auth/signup/index.txt +6 -6
  94. package/dist/src/web/nextui/datasets/index.html +1 -1
  95. package/dist/src/web/nextui/datasets/index.txt +6 -6
  96. package/dist/src/web/nextui/eval/index.html +1 -1
  97. package/dist/src/web/nextui/eval/index.txt +6 -6
  98. package/dist/src/web/nextui/index.html +1 -1
  99. package/dist/src/web/nextui/index.txt +5 -5
  100. package/dist/src/web/nextui/progress/index.html +1 -1
  101. package/dist/src/web/nextui/progress/index.txt +6 -6
  102. package/dist/src/web/nextui/prompts/index.html +1 -1
  103. package/dist/src/web/nextui/prompts/index.txt +6 -6
  104. package/dist/src/web/nextui/report/index.html +1 -1
  105. package/dist/src/web/nextui/report/index.txt +6 -6
  106. package/dist/src/web/nextui/setup/index.html +1 -27
  107. package/dist/src/web/nextui/setup/index.txt +7 -7
  108. package/dist/src/web/server.d.ts.map +1 -1
  109. package/dist/src/web/server.js +2 -1
  110. package/dist/src/web/server.js.map +1 -1
  111. package/package.json +2 -1
  112. package/dist/src/web/nextui/_next/static/chunks/215-f97c02cbf00861f3.js +0 -1
  113. package/dist/src/web/nextui/_next/static/chunks/611-d73a08bebf1d6f3c.js +0 -1
  114. package/dist/src/web/nextui/_next/static/chunks/770-8ec8b39ce6f615c4.js +0 -2
  115. package/dist/src/web/nextui/_next/static/chunks/858-9393537662061ee7.js +0 -1
  116. package/dist/src/web/nextui/_next/static/chunks/873-177b84c58d904b5a.js +0 -1
  117. package/dist/src/web/nextui/_next/static/chunks/app/auth/login/page-3bd92b90dc19429b.js +0 -1
  118. package/dist/src/web/nextui/_next/static/chunks/app/auth/signup/page-557ff1f8c491e68a.js +0 -1
  119. package/dist/src/web/nextui/_next/static/chunks/app/datasets/page-4f93aacd25866d60.js +0 -1
  120. package/dist/src/web/nextui/_next/static/chunks/app/eval/[id]/not-found-ce320e6d1e6d1d23.js +0 -1
  121. package/dist/src/web/nextui/_next/static/chunks/app/eval/page-b26513300f6f0273.js +0 -1
  122. package/dist/src/web/nextui/_next/static/chunks/app/layout-0b8a90b7e76a28ac.js +0 -1
  123. package/dist/src/web/nextui/_next/static/chunks/app/progress/page-e8235b15bd64fb03.js +0 -1
  124. package/dist/src/web/nextui/_next/static/css/5bd2f45de1f3ba83.css +0 -1
  125. /package/dist/src/web/nextui/_next/static/{LLUpdH9jfGXIcfy9L4wOs → 9oVNcJw_yPT1Zu44NMAgc}/_buildManifest.js +0 -0
  126. /package/dist/src/web/nextui/_next/static/{LLUpdH9jfGXIcfy9L4wOs → 9oVNcJw_yPT1Zu44NMAgc}/_ssgManifest.js +0 -0
@@ -1,12 +1,12 @@
1
1
  1:HL["/_next/static/media/c9a5bc6a7c948fb0-s.p.woff2",{"as":"font","type":"font/woff2"}]
2
- 2:HL["/_next/static/css/5bd2f45de1f3ba83.css",{"as":"style"}]
3
- 0:["LLUpdH9jfGXIcfy9L4wOs",[[["",{"children":["report",{"children":["__PAGE__",{}]}]},"$undefined","$undefined",true],"$L3",[[["$","link","0",{"rel":"stylesheet","href":"/_next/static/css/5bd2f45de1f3ba83.css","precedence":"next"}]],"$L4"]]]]
2
+ 2:HL["/_next/static/css/106779eb64615639.css",{"as":"style"}]
3
+ 0:["9oVNcJw_yPT1Zu44NMAgc",[[["",{"children":["report",{"children":["__PAGE__",{}]}]},"$undefined","$undefined",true],"$L3",[[["$","link","0",{"rel":"stylesheet","href":"/_next/static/css/106779eb64615639.css","precedence":"next"}]],"$L4"]]]]
4
4
  5:HL["/_next/static/css/dab5d695b3657d59.css",{"as":"style"}]
5
- 6:I{"id":30224,"chunks":["540:static/chunks/540-ab57db4fdf86cc8a.js","640:static/chunks/640-0f757e2fe135173d.js","620:static/chunks/620-7a5a7bf6e1fe49e5.js","163:static/chunks/163-e65e0f7f442a0c72.js","858:static/chunks/858-9393537662061ee7.js","185:static/chunks/app/layout-0b8a90b7e76a28ac.js"],"name":"PageShell","async":false}
6
- 7:I{"id":27883,"chunks":["272:static/chunks/webpack-c9f728822666f852.js","470:static/chunks/b6261da7-e9d81a4364ddd0c0.js","730:static/chunks/730-3eb7255cd813a727.js"],"name":"default","async":false}
7
- 8:I{"id":46785,"chunks":["272:static/chunks/webpack-c9f728822666f852.js","470:static/chunks/b6261da7-e9d81a4364ddd0c0.js","730:static/chunks/730-3eb7255cd813a727.js"],"name":"default","async":false}
5
+ 6:I{"id":5071,"chunks":["448:static/chunks/448-4da3bf74eae4996a.js","640:static/chunks/640-0f757e2fe135173d.js","620:static/chunks/620-7a5a7bf6e1fe49e5.js","374:static/chunks/374-d40afe599198abd3.js","163:static/chunks/163-e65e0f7f442a0c72.js","53:static/chunks/53-fae6e50ace6c83a1.js","185:static/chunks/app/layout-ed6af4caf66026a5.js"],"name":"PageShell","async":false}
6
+ 7:I{"id":27883,"chunks":["272:static/chunks/webpack-8a9bc9ee0defb756.js","470:static/chunks/b6261da7-e9d81a4364ddd0c0.js","730:static/chunks/730-3eb7255cd813a727.js"],"name":"default","async":false}
7
+ 8:I{"id":46785,"chunks":["272:static/chunks/webpack-8a9bc9ee0defb756.js","470:static/chunks/b6261da7-e9d81a4364ddd0c0.js","730:static/chunks/730-3eb7255cd813a727.js"],"name":"default","async":false}
8
8
  3:[null,["$","html",null,{"lang":"en","children":["$","body",null,{"className":"__className_c19315","children":["$","$L6",null,{"children":["$","$L7",null,{"parallelRouterKey":"children","segmentPath":["children"],"error":"$undefined","errorStyles":"$undefined","loading":"$undefined","loadingStyles":"$undefined","hasLoading":false,"template":["$","$L8",null,{}],"templateStyles":"$undefined","notFound":[["$","title",null,{"children":"404: This page could not be found."}],["$","div",null,{"style":{"fontFamily":"system-ui,\"Segoe UI\",Roboto,Helvetica,Arial,sans-serif,\"Apple Color Emoji\",\"Segoe UI Emoji\"","height":"100vh","textAlign":"center","display":"flex","flexDirection":"column","alignItems":"center","justifyContent":"center"},"children":["$","div",null,{"children":[["$","style",null,{"dangerouslySetInnerHTML":{"__html":"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}"}}],["$","h1",null,{"className":"next-error-h1","style":{"display":"inline-block","margin":"0 20px 0 0","padding":"0 23px 0 0","fontSize":24,"fontWeight":500,"verticalAlign":"top","lineHeight":"49px"},"children":"404"}],["$","div",null,{"style":{"display":"inline-block"},"children":["$","h2",null,{"style":{"fontSize":14,"fontWeight":400,"lineHeight":"49px","margin":0},"children":"This page could not be found."}]}]]}]}]],"notFoundStyles":"$undefined","childProp":{"current":["$","$L7",null,{"parallelRouterKey":"children","segmentPath":["children","report","children"],"error":"$undefined","errorStyles":"$undefined","loading":"$undefined","loadingStyles":"$undefined","hasLoading":false,"template":["$","$L8",null,{}],"templateStyles":"$undefined","notFound":"$undefined","notFoundStyles":"$undefined","childProp":{"current":["$L9","$La",null],"segment":"__PAGE__"},"styles":[["$","link","0",{"rel":"stylesheet","href":"/_next/static/css/dab5d695b3657d59.css","precedence":"next"}]]}],"segment":"report"},"styles":[]}]}]}]}],null]
9
9
  4:[["$","meta","0",{"charSet":"utf-8"}],["$","title","1",{"children":"promptfoo"}],["$","meta","2",{"name":"description","content":"LLM testing and evaluation"}],["$","meta","3",{"name":"viewport","content":"width=device-width, initial-scale=1"}],["$","meta","4",{"property":"og:image","content":"https://www.promptfoo.dev/img/thumbnail.png"}],["$","meta","5",{"name":"twitter:card","content":"summary"}],["$","meta","6",{"name":"twitter:image","content":"https://www.promptfoo.dev/img/thumbnail.png"}],["$","meta","7",{"name":"next-size-adjust"}]]
10
- b:I{"id":37493,"chunks":["540:static/chunks/540-ab57db4fdf86cc8a.js","215:static/chunks/215-f97c02cbf00861f3.js","620:static/chunks/620-7a5a7bf6e1fe49e5.js","770:static/chunks/770-8ec8b39ce6f615c4.js","304:static/chunks/304-9d57a2251034b801.js","995:static/chunks/995-803c74b81e7bf6cd.js","378:static/chunks/378-e22c8aeb8e031fad.js","180:static/chunks/180-46db19289d856800.js","420:static/chunks/app/report/page-6716acff9825da98.js"],"name":"","async":false}
10
+ b:I{"id":37493,"chunks":["448:static/chunks/448-4da3bf74eae4996a.js","620:static/chunks/620-7a5a7bf6e1fe49e5.js","973:static/chunks/973-ffe3726c956d08ef.js","304:static/chunks/304-9d57a2251034b801.js","995:static/chunks/995-803c74b81e7bf6cd.js","378:static/chunks/378-e22c8aeb8e031fad.js","180:static/chunks/180-46db19289d856800.js","420:static/chunks/app/report/page-be70065fb1472831.js"],"name":"","async":false}
11
11
  a:["$","$Lb",null,{}]
12
12
  9:null
@@ -1,27 +1 @@
1
- <!DOCTYPE html><html lang="en"><head><meta charSet="utf-8"/><link rel="preload" as="font" href="/_next/static/media/c9a5bc6a7c948fb0-s.p.woff2" crossorigin="" type="font/woff2"/><link rel="stylesheet" href="/_next/static/css/5bd2f45de1f3ba83.css" data-precedence="next"/><link rel="stylesheet" href="/_next/static/css/edcd6f0b6c902fde.css" data-precedence="next"/><link rel="preload" href="/_next/static/chunks/webpack-c9f728822666f852.js" as="script"/><link rel="preload" href="/_next/static/chunks/b6261da7-e9d81a4364ddd0c0.js" as="script"/><link rel="preload" href="/_next/static/chunks/730-3eb7255cd813a727.js" as="script"/><link rel="preload" href="/_next/static/chunks/main-app-929a26b3c8cd3f7a.js" as="script"/><title>promptfoo</title><meta name="description" content="LLM testing and evaluation"/><meta name="viewport" content="width=device-width, initial-scale=1"/><meta property="og:image" content="https://www.promptfoo.dev/img/thumbnail.png"/><meta name="twitter:card" content="summary"/><meta name="twitter:image" content="https://www.promptfoo.dev/img/thumbnail.png"/><meta name="next-size-adjust"/><script src="/_next/static/chunks/polyfills-78c92fac7aa8fdd8.js" noModule=""></script></head><body class="__className_c19315"><div><style data-emotion="css jj2ztu">.css-jj2ztu{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-direction:row;-ms-flex-direction:row;flex-direction:row;}.css-jj2ztu>:not(style):not(style){margin:0;}.css-jj2ztu>:not(style)~:not(style){margin-left:16px;}</style><div class="MuiStack-root nav css-jj2ztu"><div class="logo MuiBox-root css-0"><img alt="Promptfoo logo" loading="lazy" width="25" height="25" decoding="async" data-nimg="1" style="color:transparent" src="/logo.svg"/> <span>promptfoo</span></div><a class="active" href="/setup/">New Eval</a><a class="" href="/eval/">Evals</a><a class="" href="/prompts/">Prompts</a><a class="" href="/datasets/">Datasets</a><a class="" href="/progress/">Progress</a><div class="right-aligned"><div class="dark-mode-toggle"><style data-emotion="css vubbuv">.css-vubbuv{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;width:1em;height:1em;display:inline-block;fill:currentColor;-webkit-flex-shrink:0;-ms-flex-negative:0;flex-shrink:0;-webkit-transition:fill 200ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;transition:fill 200ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;font-size:1.5rem;}</style><svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeMedium css-vubbuv" focusable="false" aria-hidden="true" viewBox="0 0 24 24" data-testid="LightModeIcon"><path d="M12 7c-2.76 0-5 2.24-5 5s2.24 5 5 5 5-2.24 5-5-2.24-5-5-5M2 13h2c.55 0 1-.45 1-1s-.45-1-1-1H2c-.55 0-1 .45-1 1s.45 1 1 1m18 0h2c.55 0 1-.45 1-1s-.45-1-1-1h-2c-.55 0-1 .45-1 1s.45 1 1 1M11 2v2c0 .55.45 1 1 1s1-.45 1-1V2c0-.55-.45-1-1-1s-1 .45-1 1m0 18v2c0 .55.45 1 1 1s1-.45 1-1v-2c0-.55-.45-1-1-1s-1 .45-1 1M5.99 4.58c-.39-.39-1.03-.39-1.41 0-.39.39-.39 1.03 0 1.41l1.06 1.06c.39.39 1.03.39 1.41 0s.39-1.03 0-1.41zm12.37 12.37c-.39-.39-1.03-.39-1.41 0-.39.39-.39 1.03 0 1.41l1.06 1.06c.39.39 1.03.39 1.41 0 .39-.39.39-1.03 0-1.41zm1.06-10.96c.39-.39.39-1.03 0-1.41-.39-.39-1.03-.39-1.41 0l-1.06 1.06c-.39.39-.39 1.03 0 1.41s1.03.39 1.41 0zM7.05 18.36c.39-.39.39-1.03 0-1.41-.39-.39-1.03-.39-1.41 0l-1.06 1.06c-.39.39-.39 1.03 0 1.41s1.03.39 1.41 0z"></path></svg></div></div></div><div><style data-emotion="css 19t2hy6">.css-19t2hy6{width:100%;margin-left:auto;box-sizing:border-box;margin-right:auto;display:block;padding-left:16px;padding-right:16px;margin-top:2rem;}@media (min-width:600px){.css-19t2hy6{padding-left:24px;padding-right:24px;}}@media (min-width:1200px){.css-19t2hy6{max-width:1200px;}}</style><div class="MuiContainer-root MuiContainer-maxWidthLg css-19t2hy6"><style data-emotion="css 1w57jtv">.css-1w57jtv{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-direction:row;-ms-flex-direction:row;flex-direction:row;-webkit-box-pack:justify;-webkit-justify-content:space-between;justify-content:space-between;}.css-1w57jtv>:not(style):not(style){margin:0;}.css-1w57jtv>:not(style)~:not(style){margin-left:16px;}</style><div class="MuiStack-root css-1w57jtv"><style data-emotion="css jqhduh">.css-jqhduh{margin:0;font-family:inherit;font-weight:400;font-size:2.125rem;line-height:1.235;}</style><h4 class="MuiTypography-root MuiTypography-h4 css-jqhduh">Set up an evaluation</h4><style data-emotion="css jj2ztu">.css-jj2ztu{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-direction:row;-ms-flex-direction:row;flex-direction:row;}.css-jj2ztu>:not(style):not(style){margin:0;}.css-jj2ztu>:not(style)~:not(style){margin-left:16px;}</style><div class="MuiStack-root css-jj2ztu"><style data-emotion="css 11kchfx">.css-11kchfx{font-family:inherit;font-weight:500;font-size:0.875rem;line-height:1.75;text-transform:uppercase;min-width:64px;padding:6px 16px;border-radius:4px;-webkit-transition:background-color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,box-shadow 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,border-color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;transition:background-color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,box-shadow 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,border-color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;color:#fff;background-color:#1976d2;box-shadow:0px 3px 1px -2px rgba(0,0,0,0.2),0px 2px 2px 0px rgba(0,0,0,0.14),0px 1px 5px 0px rgba(0,0,0,0.12);}.css-11kchfx:hover{-webkit-text-decoration:none;text-decoration:none;background-color:#1565c0;box-shadow:0px 2px 4px -1px rgba(0,0,0,0.2),0px 4px 5px 0px rgba(0,0,0,0.14),0px 1px 10px 0px rgba(0,0,0,0.12);}@media (hover: none){.css-11kchfx:hover{background-color:#1976d2;}}.css-11kchfx:active{box-shadow:0px 5px 5px -3px rgba(0,0,0,0.2),0px 8px 10px 1px rgba(0,0,0,0.14),0px 3px 14px 2px rgba(0,0,0,0.12);}.css-11kchfx.Mui-focusVisible{box-shadow:0px 3px 5px -1px rgba(0,0,0,0.2),0px 6px 10px 0px rgba(0,0,0,0.14),0px 1px 18px 0px rgba(0,0,0,0.12);}.css-11kchfx.Mui-disabled{color:rgba(0, 0, 0, 0.26);box-shadow:none;background-color:rgba(0, 0, 0, 0.12);}</style><style data-emotion="css 1r4sjx4">.css-1r4sjx4{display:-webkit-inline-box;display:-webkit-inline-flex;display:-ms-inline-flexbox;display:inline-flex;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:center;-ms-flex-pack:center;-webkit-justify-content:center;justify-content:center;position:relative;box-sizing:border-box;-webkit-tap-highlight-color:transparent;background-color:transparent;outline:0;border:0;margin:0;border-radius:0;padding:0;cursor:pointer;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;vertical-align:middle;-moz-appearance:none;-webkit-appearance:none;-webkit-text-decoration:none;text-decoration:none;color:inherit;font-family:inherit;font-weight:500;font-size:0.875rem;line-height:1.75;text-transform:uppercase;min-width:64px;padding:6px 16px;border-radius:4px;-webkit-transition:background-color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,box-shadow 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,border-color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;transition:background-color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,box-shadow 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,border-color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;color:#fff;background-color:#1976d2;box-shadow:0px 3px 1px -2px rgba(0,0,0,0.2),0px 2px 2px 0px rgba(0,0,0,0.14),0px 1px 5px 0px rgba(0,0,0,0.12);}.css-1r4sjx4::-moz-focus-inner{border-style:none;}.css-1r4sjx4.Mui-disabled{pointer-events:none;cursor:default;}@media print{.css-1r4sjx4{-webkit-print-color-adjust:exact;color-adjust:exact;}}.css-1r4sjx4:hover{-webkit-text-decoration:none;text-decoration:none;background-color:#1565c0;box-shadow:0px 2px 4px -1px rgba(0,0,0,0.2),0px 4px 5px 0px rgba(0,0,0,0.14),0px 1px 10px 0px rgba(0,0,0,0.12);}@media (hover: none){.css-1r4sjx4:hover{background-color:#1976d2;}}.css-1r4sjx4:active{box-shadow:0px 5px 5px -3px rgba(0,0,0,0.2),0px 8px 10px 1px rgba(0,0,0,0.14),0px 3px 14px 2px rgba(0,0,0,0.12);}.css-1r4sjx4.Mui-focusVisible{box-shadow:0px 3px 5px -1px rgba(0,0,0,0.2),0px 6px 10px 0px rgba(0,0,0,0.14),0px 1px 18px 0px rgba(0,0,0,0.12);}.css-1r4sjx4.Mui-disabled{color:rgba(0, 0, 0, 0.26);box-shadow:none;background-color:rgba(0, 0, 0, 0.12);}</style><button class="MuiButtonBase-root MuiButton-root MuiButton-contained MuiButton-containedPrimary MuiButton-sizeMedium MuiButton-containedSizeMedium MuiButton-colorPrimary MuiButton-root MuiButton-contained MuiButton-containedPrimary MuiButton-sizeMedium MuiButton-containedSizeMedium MuiButton-colorPrimary css-1r4sjx4" tabindex="0" type="button">Run Evaluation</button><style data-emotion="css 1l5hj2g">.css-1l5hj2g{font-family:inherit;font-weight:500;font-size:0.875rem;line-height:1.75;text-transform:uppercase;min-width:64px;padding:5px 15px;border-radius:4px;-webkit-transition:background-color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,box-shadow 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,border-color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;transition:background-color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,box-shadow 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,border-color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;border:1px solid rgba(25, 118, 210, 0.5);color:#1976d2;}.css-1l5hj2g:hover{-webkit-text-decoration:none;text-decoration:none;background-color:rgba(25, 118, 210, 0.04);border:1px solid #1976d2;}@media (hover: none){.css-1l5hj2g:hover{background-color:transparent;}}.css-1l5hj2g.Mui-disabled{color:rgba(0, 0, 0, 0.26);border:1px solid rgba(0, 0, 0, 0.12);}</style><style data-emotion="css 1avs8v6">.css-1avs8v6{display:-webkit-inline-box;display:-webkit-inline-flex;display:-ms-inline-flexbox;display:inline-flex;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:center;-ms-flex-pack:center;-webkit-justify-content:center;justify-content:center;position:relative;box-sizing:border-box;-webkit-tap-highlight-color:transparent;background-color:transparent;outline:0;border:0;margin:0;border-radius:0;padding:0;cursor:pointer;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;vertical-align:middle;-moz-appearance:none;-webkit-appearance:none;-webkit-text-decoration:none;text-decoration:none;color:inherit;font-family:inherit;font-weight:500;font-size:0.875rem;line-height:1.75;text-transform:uppercase;min-width:64px;padding:5px 15px;border-radius:4px;-webkit-transition:background-color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,box-shadow 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,border-color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;transition:background-color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,box-shadow 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,border-color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;border:1px solid rgba(25, 118, 210, 0.5);color:#1976d2;}.css-1avs8v6::-moz-focus-inner{border-style:none;}.css-1avs8v6.Mui-disabled{pointer-events:none;cursor:default;}@media print{.css-1avs8v6{-webkit-print-color-adjust:exact;color-adjust:exact;}}.css-1avs8v6:hover{-webkit-text-decoration:none;text-decoration:none;background-color:rgba(25, 118, 210, 0.04);border:1px solid #1976d2;}@media (hover: none){.css-1avs8v6:hover{background-color:transparent;}}.css-1avs8v6.Mui-disabled{color:rgba(0, 0, 0, 0.26);border:1px solid rgba(0, 0, 0, 0.12);}</style><button class="MuiButtonBase-root MuiButton-root MuiButton-outlined MuiButton-outlinedPrimary MuiButton-sizeMedium MuiButton-outlinedSizeMedium MuiButton-colorPrimary MuiButton-root MuiButton-outlined MuiButton-outlinedPrimary MuiButton-sizeMedium MuiButton-outlinedSizeMedium MuiButton-colorPrimary css-1avs8v6" tabindex="0" type="button"><style data-emotion="css 6xugel">.css-6xugel{display:inherit;margin-right:8px;margin-left:-4px;}.css-6xugel>*:nth-of-type(1){font-size:20px;}</style><span class="MuiButton-icon MuiButton-startIcon MuiButton-iconSizeMedium css-6xugel"><style data-emotion="css vubbuv">.css-vubbuv{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;width:1em;height:1em;display:inline-block;fill:currentColor;-webkit-flex-shrink:0;-ms-flex-negative:0;flex-shrink:0;-webkit-transition:fill 200ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;transition:fill 200ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;font-size:1.5rem;}</style><svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeMedium css-vubbuv" focusable="false" aria-hidden="true" viewBox="0 0 24 24" data-testid="SettingsIcon"><path d="M19.14 12.94c.04-.3.06-.61.06-.94 0-.32-.02-.64-.07-.94l2.03-1.58c.18-.14.23-.41.12-.61l-1.92-3.32c-.12-.22-.37-.29-.59-.22l-2.39.96c-.5-.38-1.03-.7-1.62-.94l-.36-2.54c-.04-.24-.24-.41-.48-.41h-3.84c-.24 0-.43.17-.47.41l-.36 2.54c-.59.24-1.13.57-1.62.94l-2.39-.96c-.22-.08-.47 0-.59.22L2.74 8.87c-.12.21-.08.47.12.61l2.03 1.58c-.05.3-.09.63-.09.94s.02.64.07.94l-2.03 1.58c-.18.14-.23.41-.12.61l1.92 3.32c.12.22.37.29.59.22l2.39-.96c.5.38 1.03.7 1.62.94l.36 2.54c.05.24.24.41.48.41h3.84c.24 0 .44-.17.47-.41l.36-2.54c.59-.24 1.13-.56 1.62-.94l2.39.96c.22.08.47 0 .59-.22l1.92-3.32c.12-.22.07-.47-.12-.61zM12 15.6c-1.98 0-3.6-1.62-3.6-3.6s1.62-3.6 3.6-3.6 3.6 1.62 3.6 3.6-1.62 3.6-3.6 3.6"></path></svg></span>API keys</button><style data-emotion="css 1k371a6">@media print{.css-1k371a6{position:absolute!important;}}</style><button class="MuiButtonBase-root MuiButton-root MuiButton-outlined MuiButton-outlinedPrimary MuiButton-sizeMedium MuiButton-outlinedSizeMedium MuiButton-colorPrimary MuiButton-root MuiButton-outlined MuiButton-outlinedPrimary MuiButton-sizeMedium MuiButton-outlinedSizeMedium MuiButton-colorPrimary css-1avs8v6" tabindex="0" type="button">Reset</button></div></div><style data-emotion="css h5fkc8">.css-h5fkc8{margin-top:32px;}</style><div class="MuiBox-root css-h5fkc8"></div><style data-emotion="css 1yuhvjn">.css-1yuhvjn{margin-top:16px;}</style><div class="MuiBox-root css-1yuhvjn"><style data-emotion="css 1nguorl">.css-1nguorl{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;-webkit-box-pack:justify;-webkit-justify-content:space-between;justify-content:space-between;}.css-1nguorl>:not(style):not(style){margin:0;}.css-1nguorl>:not(style)~:not(style){margin-top:16px;}</style><div class="MuiStack-root css-1nguorl"><style data-emotion="css 1d79rw6">.css-1d79rw6{margin:0;font-family:inherit;font-weight:400;font-size:1.5rem;line-height:1.334;}</style><h5 class="MuiTypography-root MuiTypography-h5 css-1d79rw6">Providers</h5><div class="MuiBox-root css-1yuhvjn"><style data-emotion="css 18col2x">.css-18col2x.Mui-focused .MuiAutocomplete-clearIndicator{visibility:visible;}@media (pointer: fine){.css-18col2x:hover .MuiAutocomplete-clearIndicator{visibility:visible;}}.css-18col2x .MuiAutocomplete-tag{margin:3px;max-width:calc(100% - 6px);}.MuiAutocomplete-hasPopupIcon.css-18col2x .MuiAutocomplete-inputRoot,.MuiAutocomplete-hasClearIcon.css-18col2x .MuiAutocomplete-inputRoot{padding-right:30px;}.MuiAutocomplete-hasPopupIcon.MuiAutocomplete-hasClearIcon.css-18col2x .MuiAutocomplete-inputRoot{padding-right:56px;}.css-18col2x .MuiAutocomplete-inputRoot .MuiAutocomplete-input{width:0;min-width:30px;}.css-18col2x .MuiInput-root{padding-bottom:1px;}.css-18col2x .MuiInput-root .MuiInput-input{padding:4px 4px 4px 0px;}.css-18col2x .MuiInput-root.MuiInputBase-sizeSmall .MuiInput-input{padding:2px 4px 3px 0;}.css-18col2x .MuiOutlinedInput-root{padding:9px;}.MuiAutocomplete-hasPopupIcon.css-18col2x .MuiOutlinedInput-root,.MuiAutocomplete-hasClearIcon.css-18col2x .MuiOutlinedInput-root{padding-right:39px;}.MuiAutocomplete-hasPopupIcon.MuiAutocomplete-hasClearIcon.css-18col2x .MuiOutlinedInput-root{padding-right:65px;}.css-18col2x .MuiOutlinedInput-root .MuiAutocomplete-input{padding:7.5px 4px 7.5px 5px;}.css-18col2x .MuiOutlinedInput-root .MuiAutocomplete-endAdornment{right:9px;}.css-18col2x .MuiOutlinedInput-root.MuiInputBase-sizeSmall{padding-top:6px;padding-bottom:6px;padding-left:6px;}.css-18col2x .MuiOutlinedInput-root.MuiInputBase-sizeSmall .MuiAutocomplete-input{padding:2.5px 4px 2.5px 8px;}.css-18col2x .MuiFilledInput-root{padding-top:19px;padding-left:8px;}.MuiAutocomplete-hasPopupIcon.css-18col2x .MuiFilledInput-root,.MuiAutocomplete-hasClearIcon.css-18col2x .MuiFilledInput-root{padding-right:39px;}.MuiAutocomplete-hasPopupIcon.MuiAutocomplete-hasClearIcon.css-18col2x .MuiFilledInput-root{padding-right:65px;}.css-18col2x .MuiFilledInput-root .MuiFilledInput-input{padding:7px 4px;}.css-18col2x .MuiFilledInput-root .MuiAutocomplete-endAdornment{right:9px;}.css-18col2x .MuiFilledInput-root.MuiInputBase-sizeSmall{padding-bottom:1px;}.css-18col2x .MuiFilledInput-root.MuiInputBase-sizeSmall .MuiFilledInput-input{padding:2.5px 4px;}.css-18col2x .MuiInputBase-hiddenLabel{padding-top:8px;}.css-18col2x .MuiFilledInput-root.MuiInputBase-hiddenLabel{padding-top:0;padding-bottom:0;}.css-18col2x .MuiFilledInput-root.MuiInputBase-hiddenLabel .MuiAutocomplete-input{padding-top:16px;padding-bottom:17px;}.css-18col2x .MuiFilledInput-root.MuiInputBase-hiddenLabel.MuiInputBase-sizeSmall .MuiAutocomplete-input{padding-top:8px;padding-bottom:9px;}.css-18col2x .MuiAutocomplete-input{-webkit-box-flex:1;-webkit-flex-grow:1;-ms-flex-positive:1;flex-grow:1;text-overflow:ellipsis;opacity:0;}.css-18col2x .MuiAutocomplete-input{opacity:1;}.css-18col2x .MuiAutocomplete-inputRoot{-webkit-box-flex-wrap:wrap;-webkit-flex-wrap:wrap;-ms-flex-wrap:wrap;flex-wrap:wrap;}</style><div class="MuiAutocomplete-root css-18col2x"><style data-emotion="css feqhe6">.css-feqhe6{display:-webkit-inline-box;display:-webkit-inline-flex;display:-ms-inline-flexbox;display:inline-flex;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;position:relative;min-width:0;padding:0;margin:0;border:0;vertical-align:top;width:100%;}</style><div class="MuiFormControl-root MuiFormControl-fullWidth MuiTextField-root css-feqhe6"><style data-emotion="css-global 1prfaxn">@-webkit-keyframes mui-auto-fill{from{display:block;}}@keyframes mui-auto-fill{from{display:block;}}@-webkit-keyframes mui-auto-fill-cancel{from{display:block;}}@keyframes mui-auto-fill-cancel{from{display:block;}}</style><style data-emotion="css 18bxsfn">.css-18bxsfn{font-family:inherit;font-weight:400;font-size:1rem;line-height:1.4375em;color:rgba(0, 0, 0, 0.87);box-sizing:border-box;position:relative;cursor:text;display:-webkit-inline-box;display:-webkit-inline-flex;display:-ms-inline-flexbox;display:inline-flex;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;width:100%;position:relative;border-radius:4px;}.css-18bxsfn.Mui-disabled{color:rgba(0, 0, 0, 0.38);cursor:default;}.css-18bxsfn:hover .MuiOutlinedInput-notchedOutline{border-color:rgba(0, 0, 0, 0.87);}@media (hover: none){.css-18bxsfn:hover .MuiOutlinedInput-notchedOutline{border-color:rgba(0, 0, 0, 0.23);}}.css-18bxsfn.Mui-focused .MuiOutlinedInput-notchedOutline{border-color:#1976d2;border-width:2px;}.css-18bxsfn.Mui-error .MuiOutlinedInput-notchedOutline{border-color:#d32f2f;}.css-18bxsfn.Mui-disabled .MuiOutlinedInput-notchedOutline{border-color:rgba(0, 0, 0, 0.26);}</style><div class="MuiInputBase-root MuiOutlinedInput-root MuiInputBase-colorPrimary MuiInputBase-fullWidth MuiInputBase-formControl MuiAutocomplete-inputRoot css-18bxsfn"><style data-emotion="css 1x5jdmq">.css-1x5jdmq{font:inherit;letter-spacing:inherit;color:currentColor;padding:4px 0 5px;border:0;box-sizing:content-box;background:none;height:1.4375em;margin:0;-webkit-tap-highlight-color:transparent;display:block;min-width:0;width:100%;-webkit-animation-name:mui-auto-fill-cancel;animation-name:mui-auto-fill-cancel;-webkit-animation-duration:10ms;animation-duration:10ms;padding:16.5px 14px;}.css-1x5jdmq::-webkit-input-placeholder{color:currentColor;opacity:0.42;-webkit-transition:opacity 200ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;transition:opacity 200ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;}.css-1x5jdmq::-moz-placeholder{color:currentColor;opacity:0.42;-webkit-transition:opacity 200ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;transition:opacity 200ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;}.css-1x5jdmq:-ms-input-placeholder{color:currentColor;opacity:0.42;-webkit-transition:opacity 200ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;transition:opacity 200ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;}.css-1x5jdmq::-ms-input-placeholder{color:currentColor;opacity:0.42;-webkit-transition:opacity 200ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;transition:opacity 200ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;}.css-1x5jdmq:focus{outline:0;}.css-1x5jdmq:invalid{box-shadow:none;}.css-1x5jdmq::-webkit-search-decoration{-webkit-appearance:none;}label[data-shrink=false]+.MuiInputBase-formControl .css-1x5jdmq::-webkit-input-placeholder{opacity:0!important;}label[data-shrink=false]+.MuiInputBase-formControl .css-1x5jdmq::-moz-placeholder{opacity:0!important;}label[data-shrink=false]+.MuiInputBase-formControl .css-1x5jdmq:-ms-input-placeholder{opacity:0!important;}label[data-shrink=false]+.MuiInputBase-formControl .css-1x5jdmq::-ms-input-placeholder{opacity:0!important;}label[data-shrink=false]+.MuiInputBase-formControl .css-1x5jdmq:focus::-webkit-input-placeholder{opacity:0.42;}label[data-shrink=false]+.MuiInputBase-formControl .css-1x5jdmq:focus::-moz-placeholder{opacity:0.42;}label[data-shrink=false]+.MuiInputBase-formControl .css-1x5jdmq:focus:-ms-input-placeholder{opacity:0.42;}label[data-shrink=false]+.MuiInputBase-formControl .css-1x5jdmq:focus::-ms-input-placeholder{opacity:0.42;}.css-1x5jdmq.Mui-disabled{opacity:1;-webkit-text-fill-color:rgba(0, 0, 0, 0.38);}.css-1x5jdmq:-webkit-autofill{-webkit-animation-duration:5000s;animation-duration:5000s;-webkit-animation-name:mui-auto-fill;animation-name:mui-auto-fill;}.css-1x5jdmq:-webkit-autofill{border-radius:inherit;}</style><input aria-invalid="false" autoComplete="off" id=":R3ahqmmla:" placeholder="Select LLM providers" type="text" class="MuiInputBase-input MuiOutlinedInput-input MuiAutocomplete-input MuiAutocomplete-inputFocused css-1x5jdmq" aria-autocomplete="list" aria-expanded="false" autoCapitalize="none" spellCheck="false" role="combobox" value=""/><style data-emotion="css 19w1uun">.css-19w1uun{border-color:rgba(0, 0, 0, 0.23);}</style><style data-emotion="css igs3ac">.css-igs3ac{text-align:left;position:absolute;bottom:0;right:0;top:-5px;left:0;margin:0;padding:0 8px;pointer-events:none;border-radius:inherit;border-style:solid;border-width:1px;overflow:hidden;min-width:0%;border-color:rgba(0, 0, 0, 0.23);}</style><fieldset aria-hidden="true" class="MuiOutlinedInput-notchedOutline css-igs3ac"><style data-emotion="css ihdtdm">.css-ihdtdm{float:unset;width:auto;overflow:hidden;padding:0;line-height:11px;-webkit-transition:width 150ms cubic-bezier(0.0, 0, 0.2, 1) 0ms;transition:width 150ms cubic-bezier(0.0, 0, 0.2, 1) 0ms;}</style><legend class="css-ihdtdm"><span class="notranslate">​</span></legend></fieldset></div></div></div></div></div></div><div class="MuiBox-root css-h5fkc8"></div><div><div class="MuiStack-root css-1w57jtv"><h5 class="MuiTypography-root MuiTypography-h5 css-1d79rw6">Prompts</h5><div><label for="file-input-add-prompt"><span aria-label="Upload prompt from file" class=""><style data-emotion="css 1wf493t">.css-1wf493t{text-align:center;-webkit-flex:0 0 auto;-ms-flex:0 0 auto;flex:0 0 auto;font-size:1.5rem;padding:8px;border-radius:50%;overflow:visible;color:rgba(0, 0, 0, 0.54);-webkit-transition:background-color 150ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;transition:background-color 150ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;}.css-1wf493t:hover{background-color:rgba(0, 0, 0, 0.04);}@media (hover: none){.css-1wf493t:hover{background-color:transparent;}}.css-1wf493t.Mui-disabled{background-color:transparent;color:rgba(0, 0, 0, 0.26);}</style><style data-emotion="css 1yxmbwk">.css-1yxmbwk{display:-webkit-inline-box;display:-webkit-inline-flex;display:-ms-inline-flexbox;display:inline-flex;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:center;-ms-flex-pack:center;-webkit-justify-content:center;justify-content:center;position:relative;box-sizing:border-box;-webkit-tap-highlight-color:transparent;background-color:transparent;outline:0;border:0;margin:0;border-radius:0;padding:0;cursor:pointer;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;vertical-align:middle;-moz-appearance:none;-webkit-appearance:none;-webkit-text-decoration:none;text-decoration:none;color:inherit;text-align:center;-webkit-flex:0 0 auto;-ms-flex:0 0 auto;flex:0 0 auto;font-size:1.5rem;padding:8px;border-radius:50%;overflow:visible;color:rgba(0, 0, 0, 0.54);-webkit-transition:background-color 150ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;transition:background-color 150ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;}.css-1yxmbwk::-moz-focus-inner{border-style:none;}.css-1yxmbwk.Mui-disabled{pointer-events:none;cursor:default;}@media print{.css-1yxmbwk{-webkit-print-color-adjust:exact;color-adjust:exact;}}.css-1yxmbwk:hover{background-color:rgba(0, 0, 0, 0.04);}@media (hover: none){.css-1yxmbwk:hover{background-color:transparent;}}.css-1yxmbwk.Mui-disabled{background-color:transparent;color:rgba(0, 0, 0, 0.26);}</style><span class="MuiButtonBase-root MuiIconButton-root MuiIconButton-sizeMedium css-1yxmbwk" tabindex="0" role="button"><svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeMedium css-vubbuv" focusable="false" aria-hidden="true" viewBox="0 0 24 24" data-testid="PublishIcon"><path d="M5 4v2h14V4zm0 10h4v6h6v-6h4l-7-7z"></path></svg></span><input id="file-input-add-prompt" type="file" accept=".txt,.md" style="display:none"/></span><style data-emotion="css 1e2dcm1">.css-1e2dcm1{z-index:1500;pointer-events:none;}</style><style data-emotion="css okvapm">.css-okvapm{z-index:1500;pointer-events:none;}</style></label><button class="MuiButtonBase-root MuiButton-root MuiButton-contained MuiButton-containedPrimary MuiButton-sizeMedium MuiButton-containedSizeMedium MuiButton-colorPrimary MuiButton-root MuiButton-contained MuiButton-containedPrimary MuiButton-sizeMedium MuiButton-containedSizeMedium MuiButton-colorPrimary css-1r4sjx4" tabindex="0" type="button">Add Prompt</button></div></div><style data-emotion="css kge0eu">.css-kge0eu{width:100%;overflow-x:auto;}</style><div class="MuiTableContainer-root css-kge0eu"><style data-emotion="css 1od17fy">.css-1od17fy{display:table;width:100%;border-collapse:collapse;border-spacing:0;}.css-1od17fy caption{font-family:inherit;font-weight:400;font-size:0.875rem;line-height:1.43;padding:16px;color:rgba(0, 0, 0, 0.6);text-align:left;caption-side:bottom;}</style><table class="MuiTable-root css-1od17fy"><style data-emotion="css 1xnox0e">.css-1xnox0e{display:table-row-group;}</style><tbody class="MuiTableBody-root css-1xnox0e"><style data-emotion="css 1gqug66">.css-1gqug66{color:inherit;display:table-row;vertical-align:middle;outline:0;}.css-1gqug66.MuiTableRow-hover:hover{background-color:rgba(0, 0, 0, 0.04);}.css-1gqug66.Mui-selected{background-color:rgba(25, 118, 210, 0.08);}.css-1gqug66.Mui-selected:hover{background-color:rgba(25, 118, 210, 0.12);}</style><tr class="MuiTableRow-root css-1gqug66"><style data-emotion="css qzozz">.css-qzozz{font-family:inherit;font-weight:400;font-size:0.875rem;line-height:1.43;display:table-cell;vertical-align:inherit;border-bottom:1px solid rgba(224, 224, 224, 1);text-align:center;padding:16px;color:rgba(0, 0, 0, 0.87);}</style><td class="MuiTableCell-root MuiTableCell-body MuiTableCell-alignCenter MuiTableCell-sizeMedium css-qzozz" colSpan="2">No prompts added yet.</td></tr></tbody></table></div></div><style data-emotion="css 1hnm6b6">.css-1hnm6b6{margin-top:48px;}</style><div class="MuiBox-root css-1hnm6b6"></div><div class="MuiStack-root css-1w57jtv"><h5 class="MuiTypography-root MuiTypography-h5 css-1d79rw6">Test Cases</h5><div><label for="file-input-add-test-case"><span aria-label="Upload test cases from csv" class=""><span class="MuiButtonBase-root MuiIconButton-root MuiIconButton-sizeMedium css-1yxmbwk" tabindex="0" role="button"><svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeMedium css-vubbuv" focusable="false" aria-hidden="true" viewBox="0 0 24 24" data-testid="PublishIcon"><path d="M5 4v2h14V4zm0 10h4v6h6v-6h4l-7-7z"></path></svg></span><input id="file-input-add-test-case" type="file" accept=".csv" style="display:none"/></span></label><button class="MuiButtonBase-root MuiButton-root MuiButton-contained MuiButton-containedPrimary MuiButton-sizeMedium MuiButton-containedSizeMedium MuiButton-colorPrimary MuiButton-root MuiButton-contained MuiButton-containedPrimary MuiButton-sizeMedium MuiButton-containedSizeMedium MuiButton-colorPrimary css-1r4sjx4" tabindex="0" type="button">Add Test Case</button></div></div><div class="MuiTableContainer-root css-kge0eu"><table class="MuiTable-root css-1od17fy"><style data-emotion="css 1wbz3t9">.css-1wbz3t9{display:table-header-group;}</style><thead class="MuiTableHead-root css-1wbz3t9"><tr class="MuiTableRow-root MuiTableRow-head css-1gqug66"><style data-emotion="css 75le9z">.css-75le9z{font-family:inherit;font-weight:500;font-size:0.875rem;line-height:1.5rem;display:table-cell;vertical-align:inherit;border-bottom:1px solid rgba(224, 224, 224, 1);text-align:left;padding:16px;color:rgba(0, 0, 0, 0.87);}</style><th class="MuiTableCell-root MuiTableCell-head MuiTableCell-sizeMedium css-75le9z" scope="col">Description</th><th class="MuiTableCell-root MuiTableCell-head MuiTableCell-sizeMedium css-75le9z" scope="col">Assertions</th><th class="MuiTableCell-root MuiTableCell-head MuiTableCell-sizeMedium css-75le9z" scope="col">Variables</th><style data-emotion="css qnurhq">.css-qnurhq{font-family:inherit;font-weight:500;font-size:0.875rem;line-height:1.5rem;display:table-cell;vertical-align:inherit;border-bottom:1px solid rgba(224, 224, 224, 1);text-align:right;padding:16px;color:rgba(0, 0, 0, 0.87);-webkit-flex-direction:row-reverse;-ms-flex-direction:row-reverse;flex-direction:row-reverse;}</style><th class="MuiTableCell-root MuiTableCell-head MuiTableCell-alignRight MuiTableCell-sizeMedium css-qnurhq" scope="col"></th></tr></thead><tbody class="MuiTableBody-root css-1xnox0e"><tr class="MuiTableRow-root css-1gqug66"><td class="MuiTableCell-root MuiTableCell-body MuiTableCell-alignCenter MuiTableCell-sizeMedium css-qzozz" colSpan="4">No test cases added yet.</td></tr></tbody></table></div><div class="MuiBox-root css-h5fkc8"><style data-emotion="css i3ihim">.css-i3ihim{margin:0;font-family:inherit;font-weight:400;font-size:1.5rem;line-height:1.334;margin-bottom:0.35em;}</style><h5 class="MuiTypography-root MuiTypography-h5 MuiTypography-gutterBottom css-i3ihim">Configuration</h5><style data-emotion="css wgumsr">.css-wgumsr{margin:0;font-family:inherit;font-weight:400;font-size:1rem;line-height:1.5;margin-bottom:0.35em;}</style><p class="MuiTypography-root MuiTypography-body1 MuiTypography-gutterBottom css-wgumsr">This is the YAML config that defines the evaluation and is processed by promptfoo. See<!-- --> <a target="_blank" href="https://promptfoo.dev/docs/configuration/guide">configuration docs</a> <!-- -->to learn more.</p><style data-emotion="css e0n8s">.css-e0n8s{font-family:inherit;font-weight:500;font-size:0.875rem;line-height:1.75;text-transform:uppercase;min-width:64px;padding:6px 8px;border-radius:4px;-webkit-transition:background-color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,box-shadow 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,border-color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;transition:background-color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,box-shadow 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,border-color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;color:#1976d2;}.css-e0n8s:hover{-webkit-text-decoration:none;text-decoration:none;background-color:rgba(25, 118, 210, 0.04);}@media (hover: none){.css-e0n8s:hover{background-color:transparent;}}.css-e0n8s.Mui-disabled{color:rgba(0, 0, 0, 0.26);}</style><style data-emotion="css 5rr5x6">.css-5rr5x6{display:-webkit-inline-box;display:-webkit-inline-flex;display:-ms-inline-flexbox;display:inline-flex;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:center;-ms-flex-pack:center;-webkit-justify-content:center;justify-content:center;position:relative;box-sizing:border-box;-webkit-tap-highlight-color:transparent;background-color:transparent;outline:0;border:0;margin:0;border-radius:0;padding:0;cursor:pointer;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;vertical-align:middle;-moz-appearance:none;-webkit-appearance:none;-webkit-text-decoration:none;text-decoration:none;color:inherit;font-family:inherit;font-weight:500;font-size:0.875rem;line-height:1.75;text-transform:uppercase;min-width:64px;padding:6px 8px;border-radius:4px;-webkit-transition:background-color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,box-shadow 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,border-color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;transition:background-color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,box-shadow 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,border-color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;color:#1976d2;}.css-5rr5x6::-moz-focus-inner{border-style:none;}.css-5rr5x6.Mui-disabled{pointer-events:none;cursor:default;}@media print{.css-5rr5x6{-webkit-print-color-adjust:exact;color-adjust:exact;}}.css-5rr5x6:hover{-webkit-text-decoration:none;text-decoration:none;background-color:rgba(25, 118, 210, 0.04);}@media (hover: none){.css-5rr5x6:hover{background-color:transparent;}}.css-5rr5x6.Mui-disabled{color:rgba(0, 0, 0, 0.26);}</style><button class="MuiButtonBase-root MuiButton-root MuiButton-text MuiButton-textPrimary MuiButton-sizeMedium MuiButton-textSizeMedium MuiButton-colorPrimary MuiButton-root MuiButton-text MuiButton-textPrimary MuiButton-sizeMedium MuiButton-textSizeMedium MuiButton-colorPrimary css-5rr5x6" tabindex="0" type="button"><span class="MuiButton-icon MuiButton-startIcon MuiButton-iconSizeMedium css-6xugel"><svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeMedium css-vubbuv" focusable="false" aria-hidden="true" viewBox="0 0 24 24" data-testid="EditIcon"><path d="M3 17.25V21h3.75L17.81 9.94l-3.75-3.75zM20.71 7.04c.39-.39.39-1.02 0-1.41l-2.34-2.34a.9959.9959 0 0 0-1.41 0l-1.83 1.83 3.75 3.75z"></path></svg></span>Edit YAML</button><div autoCapitalize="off" class="" style="position:relative;text-align:left;box-sizing:border-box;padding:0;overflow:hidden;font-family:&quot;Fira code&quot;, &quot;Fira Mono&quot;, monospace;font-size:14px"><pre aria-hidden="true" style="margin:0;border:0;background:none;box-sizing:inherit;display:inherit;font-family:inherit;font-size:inherit;font-style:inherit;font-variant-ligatures:inherit;font-weight:inherit;letter-spacing:inherit;line-height:inherit;tab-size:inherit;text-indent:inherit;text-rendering:inherit;text-transform:inherit;white-space:pre-wrap;word-break:keep-all;overflow-wrap:break-word;position:relative;pointer-events:none;padding-top:10px;padding-right:10px;padding-bottom:10px;padding-left:10px"><br /></pre><textarea style="margin:0;border:0;background:none;box-sizing:inherit;display:inherit;font-family:inherit;font-size:inherit;font-style:inherit;font-variant-ligatures:inherit;font-weight:inherit;letter-spacing:inherit;line-height:inherit;tab-size:inherit;text-indent:inherit;text-rendering:inherit;text-transform:inherit;white-space:pre-wrap;word-break:keep-all;overflow-wrap:break-word;position:absolute;top:0;left:0;height:100%;width:100%;resize:none;color:inherit;overflow:hidden;-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;-webkit-text-fill-color:transparent;padding-top:10px;padding-right:10px;padding-bottom:10px;padding-left:10px" class="npm__react-simple-code-editor__textarea" disabled="" autoCapitalize="off" autoComplete="off" autoCorrect="off" spellCheck="false" data-gramm="false"></textarea><style>
2
- /**
3
- * Reset the text fill color so that placeholder is visible
4
- */
5
- .npm__react-simple-code-editor__textarea:empty {
6
- -webkit-text-fill-color: inherit !important;
7
- }
8
-
9
- /**
10
- * Hack to apply on some CSS on IE10 and IE11
11
- */
12
- @media all and (-ms-high-contrast: none), (-ms-high-contrast: active) {
13
- /**
14
- * IE doesn't support '-webkit-text-fill-color'
15
- * So we use 'color: transparent' to make the text transparent on IE
16
- * Unlike other browsers, it doesn't affect caret color in IE
17
- */
18
- .npm__react-simple-code-editor__textarea {
19
- color: transparent !important;
20
- }
21
-
22
- .npm__react-simple-code-editor__textarea::selection {
23
- background-color: #accef7 !important;
24
- color: transparent !important;
25
- }
26
- }
27
- </style></div></div></div></div></div><script src="/_next/static/chunks/webpack-c9f728822666f852.js" async=""></script><script src="/_next/static/chunks/b6261da7-e9d81a4364ddd0c0.js" async=""></script><script src="/_next/static/chunks/730-3eb7255cd813a727.js" async=""></script><script src="/_next/static/chunks/main-app-929a26b3c8cd3f7a.js" async=""></script><script>(self.__next_f=self.__next_f||[]).push([0])</script><script>self.__next_f.push([1,"1:HL[\"/_next/static/media/c9a5bc6a7c948fb0-s.p.woff2\",{\"as\":\"font\",\"type\":\"font/woff2\"}]\n2:HL[\"/_next/static/css/5bd2f45de1f3ba83.css\",{\"as\":\"style\"}]\n0:\"$L3\"\n"])</script><script>self.__next_f.push([1,"4:HL[\"/_next/static/css/edcd6f0b6c902fde.css\",{\"as\":\"style\"}]\n"])</script><script>self.__next_f.push([1,"5:I{\"id\":83507,\"chunks\":[\"272:static/chunks/webpack-c9f728822666f852.js\",\"470:static/chunks/b6261da7-e9d81a4364ddd0c0.js\",\"730:static/chunks/730-3eb7255cd813a727.js\"],\"name\":\"default\",\"async\":false}\n7:I{\"id\":6020,\"chunks\":[\"272:static/chunks/webpack-c9f728822666f852.js\",\"470:static/chunks/b6261da7-e9d81a4364ddd0c0.js\",\"730:static/chunks/730-3eb7255cd813a727.js\"],\"name\":\"\",\"async\":false}\n8:I{\"id\":30224,\"chunks\":[\"540:static/chunks/540-ab57db4fdf86cc8a.js\",\"640:static/chunks/640-0f757e2fe135173d.js\",\"620:stat"])</script><script>self.__next_f.push([1,"ic/chunks/620-7a5a7bf6e1fe49e5.js\",\"163:static/chunks/163-e65e0f7f442a0c72.js\",\"858:static/chunks/858-9393537662061ee7.js\",\"185:static/chunks/app/layout-0b8a90b7e76a28ac.js\"],\"name\":\"PageShell\",\"async\":false}\n9:I{\"id\":27883,\"chunks\":[\"272:static/chunks/webpack-c9f728822666f852.js\",\"470:static/chunks/b6261da7-e9d81a4364ddd0c0.js\",\"730:static/chunks/730-3eb7255cd813a727.js\"],\"name\":\"default\",\"async\":false}\na:I{\"id\":46785,\"chunks\":[\"272:static/chunks/webpack-c9f728822666f852.js\",\"470:static/chunks/b6261da7-e9d"])</script><script>self.__next_f.push([1,"81a4364ddd0c0.js\",\"730:static/chunks/730-3eb7255cd813a727.js\"],\"name\":\"default\",\"async\":false}\nc:I{\"id\":27382,\"chunks\":[\"272:static/chunks/webpack-c9f728822666f852.js\",\"470:static/chunks/b6261da7-e9d81a4364ddd0c0.js\",\"730:static/chunks/730-3eb7255cd813a727.js\"],\"name\":\"default\",\"async\":false}\n"])</script><script>self.__next_f.push([1,"d:I{\"id\":83013,\"chunks\":[\"540:static/chunks/540-ab57db4fdf86cc8a.js\",\"640:static/chunks/640-0f757e2fe135173d.js\",\"215:static/chunks/215-f97c02cbf00861f3.js\",\"620:static/chunks/620-7a5a7bf6e1fe49e5.js\",\"770:static/chunks/770-8ec8b39ce6f615c4.js\",\"304:static/chunks/304-9d57a2251034b801.js\",\"339:static/chunks/339-db5bd05e24dde905.js\",\"995:static/chunks/995-803c74b81e7bf6cd.js\",\"378:static/chunks/378-e22c8aeb8e031fad.js\",\"374:static/chunks/374-d40afe599198abd3.js\",\"235:static/chunks/235-2bbcbc3cd37eef0f.js\",\"106:static/chunks/106-40e3e363c957c313.js\",\"873:static/chunks/873-177b84c58d904b5a.js\",\"258:static/chunks/258-9bad5f8846b93785.js\",\"413:static/chunks/app/setup/page-59d712c1f56ecac6.js\"],\"name\":\"\",\"async\":false}\n"])</script><script>self.__next_f.push([1,"3:[[[\"$\",\"link\",\"0\",{\"rel\":\"stylesheet\",\"href\":\"/_next/static/css/5bd2f45de1f3ba83.css\",\"precedence\":\"next\"}]],[\"$\",\"$L5\",null,{\"buildId\":\"LLUpdH9jfGXIcfy9L4wOs\",\"assetPrefix\":\"\",\"initialCanonicalUrl\":\"/setup/\",\"initialTree\":[\"\",{\"children\":[\"setup\",{\"children\":[\"__PAGE__\",{}]}]},\"$undefined\",\"$undefined\",true],\"initialHead\":\"$L6\",\"globalErrorComponent\":\"$7\",\"children\":[null,[\"$\",\"html\",null,{\"lang\":\"en\",\"children\":[\"$\",\"body\",null,{\"className\":\"__className_c19315\",\"children\":[\"$\",\"$L8\",null,{\"children\":[\"$\",\"$L9\",null,{\"parallelRouterKey\":\"children\",\"segmentPath\":[\"children\"],\"error\":\"$undefined\",\"errorStyles\":\"$undefined\",\"loading\":\"$undefined\",\"loadingStyles\":\"$undefined\",\"hasLoading\":false,\"template\":[\"$\",\"$La\",null,{}],\"templateStyles\":\"$undefined\",\"notFound\":[[\"$\",\"title\",null,{\"children\":\"404: This page could not be found.\"}],[\"$\",\"div\",null,{\"style\":{\"fontFamily\":\"system-ui,\\\"Segoe UI\\\",Roboto,Helvetica,Arial,sans-serif,\\\"Apple Color Emoji\\\",\\\"Segoe UI Emoji\\\"\",\"height\":\"100vh\",\"textAlign\":\"center\",\"display\":\"flex\",\"flexDirection\":\"column\",\"alignItems\":\"center\",\"justifyContent\":\"center\"},\"children\":[\"$\",\"div\",null,{\"children\":[[\"$\",\"style\",null,{\"dangerouslySetInnerHTML\":{\"__html\":\"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}\"}}],[\"$\",\"h1\",null,{\"className\":\"next-error-h1\",\"style\":{\"display\":\"inline-block\",\"margin\":\"0 20px 0 0\",\"padding\":\"0 23px 0 0\",\"fontSize\":24,\"fontWeight\":500,\"verticalAlign\":\"top\",\"lineHeight\":\"49px\"},\"children\":\"404\"}],[\"$\",\"div\",null,{\"style\":{\"display\":\"inline-block\"},\"children\":[\"$\",\"h2\",null,{\"style\":{\"fontSize\":14,\"fontWeight\":400,\"lineHeight\":\"49px\",\"margin\":0},\"children\":\"This page could not be found.\"}]}]]}]}]],\"notFoundStyles\":\"$undefined\",\"childProp\":{\"current\":[\"$\",\"$L9\",null,{\"parallelRouterKey\":\"children\",\"segmentPath\":[\"children\",\"setup\",\"children\"],\"error\":\"$undefined\",\"errorStyles\":\"$undefined\",\"loading\":\"$undefined\",\"loadingStyles\":\"$undefined\",\"hasLoading\":false,\"template\":[\"$\",\"$La\",null,{}],\"templateStyles\":\"$undefined\",\"notFound\":\"$undefined\",\"notFoundStyles\":\"$undefined\",\"childProp\":{\"current\":[\"$Lb\",[\"$\",\"$Lc\",null,{\"propsForComponent\":{\"params\":{}},\"Component\":\"$d\"}],null],\"segment\":\"__PAGE__\"},\"styles\":[[\"$\",\"link\",\"0\",{\"rel\":\"stylesheet\",\"href\":\"/_next/static/css/edcd6f0b6c902fde.css\",\"precedence\":\"next\"}]]}],\"segment\":\"setup\"},\"styles\":[]}]}]}]}],null]}]]\n"])</script><script>self.__next_f.push([1,"6:[[\"$\",\"meta\",\"0\",{\"charSet\":\"utf-8\"}],[\"$\",\"title\",\"1\",{\"children\":\"promptfoo\"}],[\"$\",\"meta\",\"2\",{\"name\":\"description\",\"content\":\"LLM testing and evaluation\"}],[\"$\",\"meta\",\"3\",{\"name\":\"viewport\",\"content\":\"width=device-width, initial-scale=1\"}],[\"$\",\"meta\",\"4\",{\"property\":\"og:image\",\"content\":\"https://www.promptfoo.dev/img/thumbnail.png\"}],[\"$\",\"meta\",\"5\",{\"name\":\"twitter:card\",\"content\":\"summary\"}],[\"$\",\"meta\",\"6\",{\"name\":\"twitter:image\",\"content\":\"https://www.promptfoo.dev/img/thumbnail.png\"}],[\"$\",\"meta\",\"7\",{\"name\":\"next-size-adjust\"}]]\n"])</script><script>self.__next_f.push([1,"b:null\n"])</script></body></html>
1
+ <!DOCTYPE html><html lang="en"><head><meta charSet="utf-8"/><link rel="preload" as="font" href="/_next/static/media/c9a5bc6a7c948fb0-s.p.woff2" crossorigin="" type="font/woff2"/><link rel="stylesheet" href="/_next/static/css/106779eb64615639.css" data-precedence="next"/><link rel="preload" as="style" href="/_next/static/css/edcd6f0b6c902fde.css"/><link rel="preload" href="/_next/static/chunks/webpack-8a9bc9ee0defb756.js" as="script"/><link rel="preload" href="/_next/static/chunks/b6261da7-e9d81a4364ddd0c0.js" as="script"/><link rel="preload" href="/_next/static/chunks/730-3eb7255cd813a727.js" as="script"/><link rel="preload" href="/_next/static/chunks/main-app-7a1376166cb8b72e.js" as="script"/><title>promptfoo</title><meta name="description" content="LLM testing and evaluation"/><meta name="viewport" content="width=device-width, initial-scale=1"/><meta property="og:image" content="https://www.promptfoo.dev/img/thumbnail.png"/><meta name="twitter:card" content="summary"/><meta name="twitter:image" content="https://www.promptfoo.dev/img/thumbnail.png"/><meta name="next-size-adjust"/><script src="/_next/static/chunks/polyfills-78c92fac7aa8fdd8.js" noModule=""></script></head><body class="__className_c19315"><script src="/_next/static/chunks/webpack-8a9bc9ee0defb756.js" async=""></script><script src="/_next/static/chunks/b6261da7-e9d81a4364ddd0c0.js" async=""></script><script src="/_next/static/chunks/730-3eb7255cd813a727.js" async=""></script><script src="/_next/static/chunks/main-app-7a1376166cb8b72e.js" async=""></script><script>(self.__next_f=self.__next_f||[]).push([0])</script><script>self.__next_f.push([1,"1:HL[\"/_next/static/media/c9a5bc6a7c948fb0-s.p.woff2\",{\"as\":\"font\",\"type\":\"font/woff2\"}]\n2:HL[\"/_next/static/css/106779eb64615639.css\",{\"as\":\"style\"}]\n0:\"$L3\"\n"])</script><script>self.__next_f.push([1,"4:HL[\"/_next/static/css/edcd6f0b6c902fde.css\",{\"as\":\"style\"}]\n"])</script><script>self.__next_f.push([1,"5:I{\"id\":83507,\"chunks\":[\"272:static/chunks/webpack-8a9bc9ee0defb756.js\",\"470:static/chunks/b6261da7-e9d81a4364ddd0c0.js\",\"730:static/chunks/730-3eb7255cd813a727.js\"],\"name\":\"default\",\"async\":false}\n7:I{\"id\":6020,\"chunks\":[\"272:static/chunks/webpack-8a9bc9ee0defb756.js\",\"470:static/chunks/b6261da7-e9d81a4364ddd0c0.js\",\"730:static/chunks/730-3eb7255cd813a727.js\"],\"name\":\"\",\"async\":false}\n8:I{\"id\":5071,\"chunks\":[\"448:static/chunks/448-4da3bf74eae4996a.js\",\"640:static/chunks/640-0f757e2fe135173d.js\",\"620:stati"])</script><script>self.__next_f.push([1,"c/chunks/620-7a5a7bf6e1fe49e5.js\",\"374:static/chunks/374-d40afe599198abd3.js\",\"163:static/chunks/163-e65e0f7f442a0c72.js\",\"53:static/chunks/53-fae6e50ace6c83a1.js\",\"185:static/chunks/app/layout-ed6af4caf66026a5.js\"],\"name\":\"PageShell\",\"async\":false}\n9:I{\"id\":27883,\"chunks\":[\"272:static/chunks/webpack-8a9bc9ee0defb756.js\",\"470:static/chunks/b6261da7-e9d81a4364ddd0c0.js\",\"730:static/chunks/730-3eb7255cd813a727.js\"],\"name\":\"default\",\"async\":false}\na:I{\"id\":46785,\"chunks\":[\"272:static/chunks/webpack-8a9bc9ee0de"])</script><script>self.__next_f.push([1,"fb756.js\",\"470:static/chunks/b6261da7-e9d81a4364ddd0c0.js\",\"730:static/chunks/730-3eb7255cd813a727.js\"],\"name\":\"default\",\"async\":false}\nc:I{\"id\":27382,\"chunks\":[\"272:static/chunks/webpack-8a9bc9ee0defb756.js\",\"470:static/chunks/b6261da7-e9d81a4364ddd0c0.js\",\"730:static/chunks/730-3eb7255cd813a727.js\"],\"name\":\"default\",\"async\":false}\n"])</script><script>self.__next_f.push([1,"d:I{\"id\":83013,\"chunks\":[\"448:static/chunks/448-4da3bf74eae4996a.js\",\"640:static/chunks/640-0f757e2fe135173d.js\",\"620:static/chunks/620-7a5a7bf6e1fe49e5.js\",\"973:static/chunks/973-ffe3726c956d08ef.js\",\"304:static/chunks/304-9d57a2251034b801.js\",\"339:static/chunks/339-db5bd05e24dde905.js\",\"995:static/chunks/995-803c74b81e7bf6cd.js\",\"374:static/chunks/374-d40afe599198abd3.js\",\"378:static/chunks/378-e22c8aeb8e031fad.js\",\"235:static/chunks/235-2bbcbc3cd37eef0f.js\",\"578:static/chunks/578-8efe57f906f7573c.js\",\"932:static/chunks/932-75585b3be8ce494d.js\",\"258:static/chunks/258-4acb452fe85cff6f.js\",\"413:static/chunks/app/setup/page-b19fc52e084a3efe.js\"],\"name\":\"\",\"async\":false}\n"])</script><script>self.__next_f.push([1,"3:[[[\"$\",\"link\",\"0\",{\"rel\":\"stylesheet\",\"href\":\"/_next/static/css/106779eb64615639.css\",\"precedence\":\"next\"}]],[\"$\",\"$L5\",null,{\"buildId\":\"9oVNcJw_yPT1Zu44NMAgc\",\"assetPrefix\":\"\",\"initialCanonicalUrl\":\"/setup/\",\"initialTree\":[\"\",{\"children\":[\"setup\",{\"children\":[\"__PAGE__\",{}]}]},\"$undefined\",\"$undefined\",true],\"initialHead\":\"$L6\",\"globalErrorComponent\":\"$7\",\"children\":[null,[\"$\",\"html\",null,{\"lang\":\"en\",\"children\":[\"$\",\"body\",null,{\"className\":\"__className_c19315\",\"children\":[\"$\",\"$L8\",null,{\"children\":[\"$\",\"$L9\",null,{\"parallelRouterKey\":\"children\",\"segmentPath\":[\"children\"],\"error\":\"$undefined\",\"errorStyles\":\"$undefined\",\"loading\":\"$undefined\",\"loadingStyles\":\"$undefined\",\"hasLoading\":false,\"template\":[\"$\",\"$La\",null,{}],\"templateStyles\":\"$undefined\",\"notFound\":[[\"$\",\"title\",null,{\"children\":\"404: This page could not be found.\"}],[\"$\",\"div\",null,{\"style\":{\"fontFamily\":\"system-ui,\\\"Segoe UI\\\",Roboto,Helvetica,Arial,sans-serif,\\\"Apple Color Emoji\\\",\\\"Segoe UI Emoji\\\"\",\"height\":\"100vh\",\"textAlign\":\"center\",\"display\":\"flex\",\"flexDirection\":\"column\",\"alignItems\":\"center\",\"justifyContent\":\"center\"},\"children\":[\"$\",\"div\",null,{\"children\":[[\"$\",\"style\",null,{\"dangerouslySetInnerHTML\":{\"__html\":\"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}\"}}],[\"$\",\"h1\",null,{\"className\":\"next-error-h1\",\"style\":{\"display\":\"inline-block\",\"margin\":\"0 20px 0 0\",\"padding\":\"0 23px 0 0\",\"fontSize\":24,\"fontWeight\":500,\"verticalAlign\":\"top\",\"lineHeight\":\"49px\"},\"children\":\"404\"}],[\"$\",\"div\",null,{\"style\":{\"display\":\"inline-block\"},\"children\":[\"$\",\"h2\",null,{\"style\":{\"fontSize\":14,\"fontWeight\":400,\"lineHeight\":\"49px\",\"margin\":0},\"children\":\"This page could not be found.\"}]}]]}]}]],\"notFoundStyles\":\"$undefined\",\"childProp\":{\"current\":[\"$\",\"$L9\",null,{\"parallelRouterKey\":\"children\",\"segmentPath\":[\"children\",\"setup\",\"children\"],\"error\":\"$undefined\",\"errorStyles\":\"$undefined\",\"loading\":\"$undefined\",\"loadingStyles\":\"$undefined\",\"hasLoading\":false,\"template\":[\"$\",\"$La\",null,{}],\"templateStyles\":\"$undefined\",\"notFound\":\"$undefined\",\"notFoundStyles\":\"$undefined\",\"childProp\":{\"current\":[\"$Lb\",[\"$\",\"$Lc\",null,{\"propsForComponent\":{\"params\":{}},\"Component\":\"$d\"}],null],\"segment\":\"__PAGE__\"},\"styles\":[[\"$\",\"link\",\"0\",{\"rel\":\"stylesheet\",\"href\":\"/_next/static/css/edcd6f0b6c902fde.css\",\"precedence\":\"next\"}]]}],\"segment\":\"setup\"},\"styles\":[]}]}]}]}],null]}]]\n"])</script><script>self.__next_f.push([1,"6:[[\"$\",\"meta\",\"0\",{\"charSet\":\"utf-8\"}],[\"$\",\"title\",\"1\",{\"children\":\"promptfoo\"}],[\"$\",\"meta\",\"2\",{\"name\":\"description\",\"content\":\"LLM testing and evaluation\"}],[\"$\",\"meta\",\"3\",{\"name\":\"viewport\",\"content\":\"width=device-width, initial-scale=1\"}],[\"$\",\"meta\",\"4\",{\"property\":\"og:image\",\"content\":\"https://www.promptfoo.dev/img/thumbnail.png\"}],[\"$\",\"meta\",\"5\",{\"name\":\"twitter:card\",\"content\":\"summary\"}],[\"$\",\"meta\",\"6\",{\"name\":\"twitter:image\",\"content\":\"https://www.promptfoo.dev/img/thumbnail.png\"}],[\"$\",\"meta\",\"7\",{\"name\":\"next-size-adjust\"}]]\n"])</script><script>self.__next_f.push([1,"b:null\n"])</script></body></html>
@@ -1,12 +1,12 @@
1
1
  1:HL["/_next/static/media/c9a5bc6a7c948fb0-s.p.woff2",{"as":"font","type":"font/woff2"}]
2
- 2:HL["/_next/static/css/5bd2f45de1f3ba83.css",{"as":"style"}]
3
- 0:["LLUpdH9jfGXIcfy9L4wOs",[[["",{"children":["setup",{"children":["__PAGE__",{}]}]},"$undefined","$undefined",true],"$L3",[[["$","link","0",{"rel":"stylesheet","href":"/_next/static/css/5bd2f45de1f3ba83.css","precedence":"next"}]],"$L4"]]]]
2
+ 2:HL["/_next/static/css/106779eb64615639.css",{"as":"style"}]
3
+ 0:["9oVNcJw_yPT1Zu44NMAgc",[[["",{"children":["setup",{"children":["__PAGE__",{}]}]},"$undefined","$undefined",true],"$L3",[[["$","link","0",{"rel":"stylesheet","href":"/_next/static/css/106779eb64615639.css","precedence":"next"}]],"$L4"]]]]
4
4
  5:HL["/_next/static/css/edcd6f0b6c902fde.css",{"as":"style"}]
5
- 6:I{"id":30224,"chunks":["540:static/chunks/540-ab57db4fdf86cc8a.js","640:static/chunks/640-0f757e2fe135173d.js","620:static/chunks/620-7a5a7bf6e1fe49e5.js","163:static/chunks/163-e65e0f7f442a0c72.js","858:static/chunks/858-9393537662061ee7.js","185:static/chunks/app/layout-0b8a90b7e76a28ac.js"],"name":"PageShell","async":false}
6
- 7:I{"id":27883,"chunks":["272:static/chunks/webpack-c9f728822666f852.js","470:static/chunks/b6261da7-e9d81a4364ddd0c0.js","730:static/chunks/730-3eb7255cd813a727.js"],"name":"default","async":false}
7
- 8:I{"id":46785,"chunks":["272:static/chunks/webpack-c9f728822666f852.js","470:static/chunks/b6261da7-e9d81a4364ddd0c0.js","730:static/chunks/730-3eb7255cd813a727.js"],"name":"default","async":false}
8
- a:I{"id":27382,"chunks":["272:static/chunks/webpack-c9f728822666f852.js","470:static/chunks/b6261da7-e9d81a4364ddd0c0.js","730:static/chunks/730-3eb7255cd813a727.js"],"name":"default","async":false}
9
- b:I{"id":83013,"chunks":["540:static/chunks/540-ab57db4fdf86cc8a.js","640:static/chunks/640-0f757e2fe135173d.js","215:static/chunks/215-f97c02cbf00861f3.js","620:static/chunks/620-7a5a7bf6e1fe49e5.js","770:static/chunks/770-8ec8b39ce6f615c4.js","304:static/chunks/304-9d57a2251034b801.js","339:static/chunks/339-db5bd05e24dde905.js","995:static/chunks/995-803c74b81e7bf6cd.js","378:static/chunks/378-e22c8aeb8e031fad.js","374:static/chunks/374-d40afe599198abd3.js","235:static/chunks/235-2bbcbc3cd37eef0f.js","106:static/chunks/106-40e3e363c957c313.js","873:static/chunks/873-177b84c58d904b5a.js","258:static/chunks/258-9bad5f8846b93785.js","413:static/chunks/app/setup/page-59d712c1f56ecac6.js"],"name":"","async":false}
5
+ 6:I{"id":5071,"chunks":["448:static/chunks/448-4da3bf74eae4996a.js","640:static/chunks/640-0f757e2fe135173d.js","620:static/chunks/620-7a5a7bf6e1fe49e5.js","374:static/chunks/374-d40afe599198abd3.js","163:static/chunks/163-e65e0f7f442a0c72.js","53:static/chunks/53-fae6e50ace6c83a1.js","185:static/chunks/app/layout-ed6af4caf66026a5.js"],"name":"PageShell","async":false}
6
+ 7:I{"id":27883,"chunks":["272:static/chunks/webpack-8a9bc9ee0defb756.js","470:static/chunks/b6261da7-e9d81a4364ddd0c0.js","730:static/chunks/730-3eb7255cd813a727.js"],"name":"default","async":false}
7
+ 8:I{"id":46785,"chunks":["272:static/chunks/webpack-8a9bc9ee0defb756.js","470:static/chunks/b6261da7-e9d81a4364ddd0c0.js","730:static/chunks/730-3eb7255cd813a727.js"],"name":"default","async":false}
8
+ a:I{"id":27382,"chunks":["272:static/chunks/webpack-8a9bc9ee0defb756.js","470:static/chunks/b6261da7-e9d81a4364ddd0c0.js","730:static/chunks/730-3eb7255cd813a727.js"],"name":"default","async":false}
9
+ b:I{"id":83013,"chunks":["448:static/chunks/448-4da3bf74eae4996a.js","640:static/chunks/640-0f757e2fe135173d.js","620:static/chunks/620-7a5a7bf6e1fe49e5.js","973:static/chunks/973-ffe3726c956d08ef.js","304:static/chunks/304-9d57a2251034b801.js","339:static/chunks/339-db5bd05e24dde905.js","995:static/chunks/995-803c74b81e7bf6cd.js","374:static/chunks/374-d40afe599198abd3.js","378:static/chunks/378-e22c8aeb8e031fad.js","235:static/chunks/235-2bbcbc3cd37eef0f.js","578:static/chunks/578-8efe57f906f7573c.js","932:static/chunks/932-75585b3be8ce494d.js","258:static/chunks/258-4acb452fe85cff6f.js","413:static/chunks/app/setup/page-b19fc52e084a3efe.js"],"name":"","async":false}
10
10
  3:[null,["$","html",null,{"lang":"en","children":["$","body",null,{"className":"__className_c19315","children":["$","$L6",null,{"children":["$","$L7",null,{"parallelRouterKey":"children","segmentPath":["children"],"error":"$undefined","errorStyles":"$undefined","loading":"$undefined","loadingStyles":"$undefined","hasLoading":false,"template":["$","$L8",null,{}],"templateStyles":"$undefined","notFound":[["$","title",null,{"children":"404: This page could not be found."}],["$","div",null,{"style":{"fontFamily":"system-ui,\"Segoe UI\",Roboto,Helvetica,Arial,sans-serif,\"Apple Color Emoji\",\"Segoe UI Emoji\"","height":"100vh","textAlign":"center","display":"flex","flexDirection":"column","alignItems":"center","justifyContent":"center"},"children":["$","div",null,{"children":[["$","style",null,{"dangerouslySetInnerHTML":{"__html":"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}"}}],["$","h1",null,{"className":"next-error-h1","style":{"display":"inline-block","margin":"0 20px 0 0","padding":"0 23px 0 0","fontSize":24,"fontWeight":500,"verticalAlign":"top","lineHeight":"49px"},"children":"404"}],["$","div",null,{"style":{"display":"inline-block"},"children":["$","h2",null,{"style":{"fontSize":14,"fontWeight":400,"lineHeight":"49px","margin":0},"children":"This page could not be found."}]}]]}]}]],"notFoundStyles":"$undefined","childProp":{"current":["$","$L7",null,{"parallelRouterKey":"children","segmentPath":["children","setup","children"],"error":"$undefined","errorStyles":"$undefined","loading":"$undefined","loadingStyles":"$undefined","hasLoading":false,"template":["$","$L8",null,{}],"templateStyles":"$undefined","notFound":"$undefined","notFoundStyles":"$undefined","childProp":{"current":["$L9",["$","$La",null,{"propsForComponent":{"params":{}},"Component":"$b"}],null],"segment":"__PAGE__"},"styles":[["$","link","0",{"rel":"stylesheet","href":"/_next/static/css/edcd6f0b6c902fde.css","precedence":"next"}]]}],"segment":"setup"},"styles":[]}]}]}]}],null]
11
11
  4:[["$","meta","0",{"charSet":"utf-8"}],["$","title","1",{"children":"promptfoo"}],["$","meta","2",{"name":"description","content":"LLM testing and evaluation"}],["$","meta","3",{"name":"viewport","content":"width=device-width, initial-scale=1"}],["$","meta","4",{"property":"og:image","content":"https://www.promptfoo.dev/img/thumbnail.png"}],["$","meta","5",{"name":"twitter:card","content":"summary"}],["$","meta","6",{"name":"twitter:image","content":"https://www.promptfoo.dev/img/thumbnail.png"}],["$","meta","7",{"name":"next-size-adjust"}]]
12
12
  9:null
@@ -1 +1 @@
1
- {"version":3,"file":"server.d.ts","sourceRoot":"","sources":["../../../src/web/server.ts"],"names":[],"mappings":"AA2CA,oBAAY,eAAe;IACzB,GAAG,IAAI;IACP,IAAI,IAAI;IACR,IAAI,IAAI;CACT;AAED,wBAAsB,WAAW,CAC/B,IAAI,SAAQ,EACZ,UAAU,SAAK,EACf,eAAe,kBAAsB,EACrC,iBAAiB,CAAC,EAAE,MAAM,iBA4M3B"}
1
+ {"version":3,"file":"server.d.ts","sourceRoot":"","sources":["../../../src/web/server.ts"],"names":[],"mappings":"AA2CA,oBAAY,eAAe;IACzB,GAAG,IAAI;IACP,IAAI,IAAI;IACR,IAAI,IAAI;CACT;AAED,wBAAsB,WAAW,CAC/B,IAAI,SAAQ,EACZ,UAAU,SAAK,EACf,eAAe,kBAAsB,EACrC,iBAAiB,CAAC,EAAE,MAAM,iBAiN3B"}
@@ -59,7 +59,8 @@ async function startServer(port = 15500, apiBaseUrl = '', browserBehavior = Brow
59
59
  socket.emit('init', await (0, util_1.readLatestResults)(filterDescription));
60
60
  });
61
61
  app.get('/api/results', (req, res) => {
62
- const previousResults = (0, util_1.listPreviousResults)(undefined /* limit */, filterDescription);
62
+ const datasetId = req.query.datasetId;
63
+ const previousResults = (0, util_1.listPreviousResults)(undefined /* limit */, filterDescription, datasetId);
63
64
  res.json({
64
65
  data: previousResults.map((meta) => {
65
66
  return {
@@ -1 +1 @@
1
- {"version":3,"file":"server.js","sourceRoot":"","sources":["../../../src/web/server.ts"],"names":[],"mappings":";;;;;;AAiDA,kCAgNC;AAjQD,8DAAsC;AACtC,gDAAwB;AACxB,wDAAgC;AAChC,sDAA8B;AAC9B,4CAA+B;AAC/B,0DAA6B;AAC7B,0DAA6B;AAC7B,kEAAqC;AACrC,oDAA4B;AAC5B,yCAAqD;AACrD,oEAAuC;AACvC,+BAAoC;AACpC,0CAA8C;AAC9C,gCAAsC;AACtC,qDAOkB;AAClB,uDAA+B;AAC/B,4CAAuD;AACvD,kCAWiB;AAEjB,eAAe;AACf,MAAM,QAAQ,GAAG,IAAI,GAAG,EAAe,CAAC;AAExC,gBAAgB;AAChB,IAAI,UAAU,GAAgC,IAAI,CAAC;AAEnD,IAAY,eAIX;AAJD,WAAY,eAAe;IACzB,mDAAO,CAAA;IACP,qDAAQ,CAAA;IACR,qDAAQ,CAAA;AACV,CAAC,EAJW,eAAe,+BAAf,eAAe,QAI1B;AAEM,KAAK,UAAU,WAAW,CAC/B,IAAI,GAAG,KAAK,EACZ,UAAU,GAAG,EAAE,EACf,eAAe,GAAG,eAAe,CAAC,GAAG,EACrC,iBAA0B;IAE1B,MAAM,GAAG,GAAG,IAAA,iBAAO,GAAE,CAAC;IAEtB,MAAM,SAAS,GAAG,mBAAI,CAAC,IAAI,CAAC,IAAA,kBAAY,GAAE,EAAE,KAAK,EAAE,QAAQ,CAAC,CAAC;IAE7D,GAAG,CAAC,GAAG,CAAC,IAAA,cAAI,GAAE,CAAC,CAAC;IAChB,GAAG,CAAC,GAAG,CAAC,IAAA,qBAAW,GAAE,CAAC,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C3D,IAAI,MAAM,CAAC,WAAW,EAAE,CAAC,UAAU,CAAC,GAAG,CAAC,EAAE,CAAC;oBACzC,OAAO,EAAE,CAAC;gBACZ,CAAC;gBACD,EAAE,CAAC,KAAK,EAAE,CAAC;YACb,CAAC,CAAC,CAAC;QACL,CAAC;IACH,CAAC,CAAC,CAAC;AACL,CAAC"}
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "promptfoo",
3
3
  "description": "LLM eval & testing toolkit",
4
4
  "author": "Ian Webster",
5
- "version": "0.71.0",
5
+ "version": "0.72.0",
6
6
  "license": "MIT",
7
7
  "type": "commonjs",
8
8
  "repository": {
@@ -131,6 +131,7 @@
131
131
  "drizzle-orm": "^0.32.0",
132
132
  "express": "^4.19.2",
133
133
  "fast-deep-equal": "^3.1.3",
134
+ "fast-xml-parser": "^4.4.0",
134
135
  "fastest-levenshtein": "^1.0.16",
135
136
  "glob": "^10.4.3",
136
137
  "inquirer": "^8.2.6",
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[215],{613:function(e,t,o){o.d(t,{u:function(){return v}});var a=o(79042),r=o(94312),n=o(14978),i=o(76008),l=o(64469),s=o(82063),d=o(94751),c=o(24004);let u=["onChange","maxRows","minRows","style","value"];function p(e){return parseInt(e,10)||0}let h={shadow:{visibility:"hidden",position:"absolute",overflow:"hidden",height:0,top:0,left:0,transform:"translateZ(0)"}},v=n.forwardRef(function(e,t){let{onChange:o,maxRows:v,minRows:m=1,style:g,value:x}=e,b=(0,r.Z)(e,u),{current:f}=n.useRef(null!=x),S=n.useRef(null),y=(0,i.Z)(t,S),z=n.useRef(null),Z=n.useCallback(()=>{let t=S.current,o=(0,l.Z)(t),a=o.getComputedStyle(t);if("0px"===a.width)return{outerHeightStyle:0,overflowing:!1};let r=z.current;r.style.width=a.width,r.value=t.value||e.placeholder||"x","\n"===r.value.slice(-1)&&(r.value+=" ");let n=a.boxSizing,i=p(a.paddingBottom)+p(a.paddingTop),s=p(a.borderBottomWidth)+p(a.borderTopWidth),d=r.scrollHeight;r.value="x";let c=r.scrollHeight,u=d;m&&(u=Math.max(Number(m)*c,u)),v&&(u=Math.min(Number(v)*c,u)),u=Math.max(u,c);let h=u+("border-box"===n?i+s:0),g=1>=Math.abs(u-d);return{outerHeightStyle:h,overflowing:g}},[v,m,e.placeholder]),w=n.useCallback(()=>{let e=Z();if(null==e||0===Object.keys(e).length||0===e.outerHeightStyle&&!e.overflowing)return;let t=S.current;t.style.height=`${e.outerHeightStyle}px`,t.style.overflow=e.overflowing?"hidden":""},[Z]);return(0,s.Z)(()=>{let e,t;let o=()=>{w()},a=(0,d.Z)(o),r=S.current,n=(0,l.Z)(r);return n.addEventListener("resize",a),"undefined"!=typeof ResizeObserver&&(t=new ResizeObserver(o)).observe(r),()=>{a.clear(),cancelAnimationFrame(e),n.removeEventListener("resize",a),t&&t.disconnect()}},[Z,w]),(0,s.Z)(()=>{w()}),(0,c.jsxs)(n.Fragment,{children:[(0,c.jsx)("textarea",(0,a.Z)({value:x,onChange:e=>{f||w(),o&&o(e)},ref:y,rows:m,style:g},b)),(0,c.jsx)("textarea",{"aria-hidden":!0,className:e.className,readOnly:!0,ref:z,tabIndex:-1,style:(0,a.Z)({},h.shadow,g,{paddingTop:0,paddingBottom:0})})]})})},40982:function(e,t,o){o.d(t,{Z:function(){return k}});var a=o(94312),r=o(79042),n=o(14978),i=o(53468),l=o(75850),s=o(3982),d=o(13477),c=o(31608),u=o(11874),p=o(87286),h=o(30151),v=o(81427),m=o(25800),g=o(46213);function x(e){return(0,g.ZP)("MuiButton",e)}let b=(0,m.Z)("MuiButton",["root","text","textInherit","textPrimary","textSecondary","textSuccess","textError","textInfo","textWarning","outlined","outlinedInherit","outlinedPrimary","outlinedSecondary","outlinedSuccess","outlinedError","outlinedInfo","outlinedWarning","contained","containedInherit","containedPrimary","containedSecondary","containedSuccess","containedError","containedInfo","containedWarning","disableElevation","focusVisible","disabled","colorInherit","colorPrimary","colorSecondary","colorSuccess","colorError","colorInfo","colorWarning","textSizeSmall","textSizeMedium","textSizeLarge","outlinedSizeSmall","outlinedSizeMedium","outlinedSizeLarge","containedSizeSmall","containedSizeMedium","containedSizeLarge","sizeMedium","sizeSmall","sizeLarge","fullWidth","startIcon","endIcon","icon","iconSizeSmall","iconSizeMedium","iconSizeLarge"]),f=n.createContext({}),S=n.createContext(void 0);var y=o(24004);let z=["children","color","component","className","disabled","disableElevation","disableFocusRipple","endIcon","focusVisibleClassName","fullWidth","size","startIcon","type","variant"],Z=e=>{let{color:t,disableElevation:o,fullWidth:a,size:n,variant:i,classes:l}=e,d={root:["root",i,`${i}${(0,v.Z)(t)}`,`size${(0,v.Z)(n)}`,`${i}Size${(0,v.Z)(n)}`,`color${(0,v.Z)(t)}`,o&&"disableElevation",a&&"fullWidth"],label:["label"],startIcon:["icon","startIcon",`iconSize${(0,v.Z)(n)}`],endIcon:["icon","endIcon",`iconSize${(0,v.Z)(n)}`]},c=(0,s.Z)(d,x,l);return(0,r.Z)({},l,c)},w=e=>(0,r.Z)({},"small"===e.size&&{"& > *:nth-of-type(1)":{fontSize:18}},"medium"===e.size&&{"& > *:nth-of-type(1)":{fontSize:20}},"large"===e.size&&{"& > *:nth-of-type(1)":{fontSize:22}}),C=(0,c.ZP)(h.Z,{shouldForwardProp:e=>(0,u.Z)(e)||"classes"===e,name:"MuiButton",slot:"Root",overridesResolver:(e,t)=>{let{ownerState:o}=e;return[t.root,t[o.variant],t[`${o.variant}${(0,v.Z)(o.color)}`],t[`size${(0,v.Z)(o.size)}`],t[`${o.variant}Size${(0,v.Z)(o.size)}`],"inherit"===o.color&&t.colorInherit,o.disableElevation&&t.disableElevation,o.fullWidth&&t.fullWidth]}})(({theme:e,ownerState:t})=>{var o,a;let n="light"===e.palette.mode?e.palette.grey[300]:e.palette.grey[800],i="light"===e.palette.mode?e.palette.grey.A100:e.palette.grey[700];return(0,r.Z)({},e.typography.button,{minWidth:64,padding:"6px 16px",borderRadius:(e.vars||e).shape.borderRadius,transition:e.transitions.create(["background-color","box-shadow","border-color","color"],{duration:e.transitions.duration.short}),"&:hover":(0,r.Z)({textDecoration:"none",backgroundColor:e.vars?`rgba(${e.vars.palette.text.primaryChannel} / ${e.vars.palette.action.hoverOpacity})`:(0,d.Fq)(e.palette.text.primary,e.palette.action.hoverOpacity),"@media (hover: none)":{backgroundColor:"transparent"}},"text"===t.variant&&"inherit"!==t.color&&{backgroundColor:e.vars?`rgba(${e.vars.palette[t.color].mainChannel} / ${e.vars.palette.action.hoverOpacity})`:(0,d.Fq)(e.palette[t.color].main,e.palette.action.hoverOpacity),"@media (hover: none)":{backgroundColor:"transparent"}},"outlined"===t.variant&&"inherit"!==t.color&&{border:`1px solid ${(e.vars||e).palette[t.color].main}`,backgroundColor:e.vars?`rgba(${e.vars.palette[t.color].mainChannel} / ${e.vars.palette.action.hoverOpacity})`:(0,d.Fq)(e.palette[t.color].main,e.palette.action.hoverOpacity),"@media (hover: none)":{backgroundColor:"transparent"}},"contained"===t.variant&&{backgroundColor:e.vars?e.vars.palette.Button.inheritContainedHoverBg:i,boxShadow:(e.vars||e).shadows[4],"@media (hover: none)":{boxShadow:(e.vars||e).shadows[2],backgroundColor:(e.vars||e).palette.grey[300]}},"contained"===t.variant&&"inherit"!==t.color&&{backgroundColor:(e.vars||e).palette[t.color].dark,"@media (hover: none)":{backgroundColor:(e.vars||e).palette[t.color].main}}),"&:active":(0,r.Z)({},"contained"===t.variant&&{boxShadow:(e.vars||e).shadows[8]}),[`&.${b.focusVisible}`]:(0,r.Z)({},"contained"===t.variant&&{boxShadow:(e.vars||e).shadows[6]}),[`&.${b.disabled}`]:(0,r.Z)({color:(e.vars||e).palette.action.disabled},"outlined"===t.variant&&{border:`1px solid ${(e.vars||e).palette.action.disabledBackground}`},"contained"===t.variant&&{color:(e.vars||e).palette.action.disabled,boxShadow:(e.vars||e).shadows[0],backgroundColor:(e.vars||e).palette.action.disabledBackground})},"text"===t.variant&&{padding:"6px 8px"},"text"===t.variant&&"inherit"!==t.color&&{color:(e.vars||e).palette[t.color].main},"outlined"===t.variant&&{padding:"5px 15px",border:"1px solid currentColor"},"outlined"===t.variant&&"inherit"!==t.color&&{color:(e.vars||e).palette[t.color].main,border:e.vars?`1px solid rgba(${e.vars.palette[t.color].mainChannel} / 0.5)`:`1px solid ${(0,d.Fq)(e.palette[t.color].main,.5)}`},"contained"===t.variant&&{color:e.vars?e.vars.palette.text.primary:null==(o=(a=e.palette).getContrastText)?void 0:o.call(a,e.palette.grey[300]),backgroundColor:e.vars?e.vars.palette.Button.inheritContainedBg:n,boxShadow:(e.vars||e).shadows[2]},"contained"===t.variant&&"inherit"!==t.color&&{color:(e.vars||e).palette[t.color].contrastText,backgroundColor:(e.vars||e).palette[t.color].main},"inherit"===t.color&&{color:"inherit",borderColor:"currentColor"},"small"===t.size&&"text"===t.variant&&{padding:"4px 5px",fontSize:e.typography.pxToRem(13)},"large"===t.size&&"text"===t.variant&&{padding:"8px 11px",fontSize:e.typography.pxToRem(15)},"small"===t.size&&"outlined"===t.variant&&{padding:"3px 9px",fontSize:e.typography.pxToRem(13)},"large"===t.size&&"outlined"===t.variant&&{padding:"7px 21px",fontSize:e.typography.pxToRem(15)},"small"===t.size&&"contained"===t.variant&&{padding:"4px 10px",fontSize:e.typography.pxToRem(13)},"large"===t.size&&"contained"===t.variant&&{padding:"8px 22px",fontSize:e.typography.pxToRem(15)},t.fullWidth&&{width:"100%"})},({ownerState:e})=>e.disableElevation&&{boxShadow:"none","&:hover":{boxShadow:"none"},[`&.${b.focusVisible}`]:{boxShadow:"none"},"&:active":{boxShadow:"none"},[`&.${b.disabled}`]:{boxShadow:"none"}}),$=(0,c.ZP)("span",{name:"MuiButton",slot:"StartIcon",overridesResolver:(e,t)=>{let{ownerState:o}=e;return[t.startIcon,t[`iconSize${(0,v.Z)(o.size)}`]]}})(({ownerState:e})=>(0,r.Z)({display:"inherit",marginRight:8,marginLeft:-4},"small"===e.size&&{marginLeft:-2},w(e))),I=(0,c.ZP)("span",{name:"MuiButton",slot:"EndIcon",overridesResolver:(e,t)=>{let{ownerState:o}=e;return[t.endIcon,t[`iconSize${(0,v.Z)(o.size)}`]]}})(({ownerState:e})=>(0,r.Z)({display:"inherit",marginRight:-4,marginLeft:8},"small"===e.size&&{marginRight:-2},w(e))),R=n.forwardRef(function(e,t){let o=n.useContext(f),s=n.useContext(S),d=(0,l.Z)(o,e),c=(0,p.i)({props:d,name:"MuiButton"}),{children:u,color:h="primary",component:v="button",className:m,disabled:g=!1,disableElevation:x=!1,disableFocusRipple:b=!1,endIcon:w,focusVisibleClassName:R,fullWidth:k=!1,size:B="medium",startIcon:E,type:M,variant:N="text"}=c,W=(0,a.Z)(c,z),T=(0,r.Z)({},c,{color:h,component:v,disabled:g,disableElevation:x,disableFocusRipple:b,fullWidth:k,size:B,type:M,variant:N}),L=Z(T),O=E&&(0,y.jsx)($,{className:L.startIcon,ownerState:T,children:E}),P=w&&(0,y.jsx)(I,{className:L.endIcon,ownerState:T,children:w}),F=s||"";return(0,y.jsxs)(C,(0,r.Z)({ownerState:T,className:(0,i.Z)(o.className,L.root,m,F),component:v,disabled:g,focusRipple:!b,focusVisibleClassName:(0,i.Z)(L.focusVisible,R),ref:t,type:M},W,{classes:L,children:[O,u,P]}))});var k=R}}]);
@@ -1 +0,0 @@
1
- (self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[611],{49532:function(e,t,s){"use strict";let n,l;async function a(){if(n||(l||(l=fetch("/api/config").then(e=>e.json()).then(e=>n=e.apiBaseUrl)),await l),void 0===n)throw Error("API base URL is undefined");return n}s.d(t,{b:function(){return a}})},31611:function(e,t,s){"use strict";s.r(t),s.d(t,{default:function(){return e6}});var n=s(24004),l=s(14978),a=s(77580);let r=a.env.NEXT_PUBLIC_PROMPTFOO_REMOTE_API_BASE_URL||a.env.NEXT_PUBLIC_PROMPTFOO_BASE_URL||a.env.PROMPTFOO_REMOTE_API_BASE_URL||"https://api.promptfoo.dev",i=a.env.NEXT_PUBLIC_PROMPTFOO_BASE_URL||a.env.PROMPTFOO_REMOTE_APP_BASE_URL||"https://app.promptfoo.dev";a?.stdout?.columns&&a?.stdout?.columns>10&&a?.stdout?.columns;var o=s(49532);let c=(0,l.createContext)(void 0),d=e=>{let{children:t}=e,[s,a]=(0,l.useState)(!1);return(0,l.useEffect)(()=>{let e=e=>{"Shift"===e.key&&a(!0)},t=e=>{"Shift"===e.key&&a(!1)};return window.addEventListener("keydown",e),window.addEventListener("keyup",t),()=>{window.removeEventListener("keydown",e),window.removeEventListener("keyup",t)}},[]),(0,n.jsx)(c.Provider,{value:s,children:t})};var u=s(52428),h=s(11615),p=s(12594),m=s(28891),x=s(74997),g=s(93179),j=s(47887),v=s(43205),f=s(5592),b=s(14931),y=s(75307),Z=s(17178),w=s(42610),C=s(49567),k=s(40982),S=s(24362),R=s(885),N=s(39813),I=s(1852),E=s(57027),P=s(94941),F=s(36273),T=s(96976),M=s(8508),D=s(34304),O=s(42671),L=s(32414),A=s(67339),U=s(65969),W=s(63147),_=s(14059),z=s(23223),V=s(26110),B=s(48931),J=s(99645),H=s(29794),K=s(22701),G=s(51956),X=s(82669),q=s(77656),Y=s(37204),$=s(79685),Q=s(74595);let ee={getItem:async e=>await (0,Y.U2)(e)||null,setItem:async(e,t)=>{await (0,Y.t8)(e,t)},removeItem:async e=>{await (0,Y.IV)(e)}},et=(0,$.Ue)()((0,Q.tJ)((e,t)=>({evalId:null,setEvalId:t=>e(()=>({evalId:t})),author:null,setAuthor:t=>e(()=>({author:t})),table:null,setTable:t=>e(()=>({table:t})),config:null,setConfig:t=>e(()=>({config:t})),maxTextLength:250,setMaxTextLength:t=>e(()=>({maxTextLength:t})),wordBreak:"break-word",setWordBreak:t=>e(()=>({wordBreak:t})),showInferenceDetails:!0,setShowInferenceDetails:t=>e(()=>({showInferenceDetails:t})),renderMarkdown:!1,setRenderMarkdown:t=>e(()=>({renderMarkdown:t})),prettifyJson:!1,setPrettifyJson:t=>e(()=>({prettifyJson:t})),showPrompts:!1,setShowPrompts:t=>e(()=>({showPrompts:t})),showPassFail:!0,setShowPassFail:t=>e(()=>({showPassFail:t}))}),{name:"ResultsViewStorage",storage:(0,Q.FL)(()=>ee)}));function es(e){let{open:t,onClose:a}=e,{config:r}=et(),i=l.useRef(null),[o,c]=l.useState(!1),[d,u]=l.useState("");l.useEffect(()=>{t&&(async()=>{let{default:e}=await Promise.resolve().then(s.bind(s,34235));u(e.dump(r))})()},[t,r]);let h=()=>{c(!1),a()};return(0,n.jsxs)(H.Z,{open:t,onClose:h,"aria-labelledby":"config-dialog-title",maxWidth:"md",fullWidth:!0,children:[(0,n.jsx)(X.Z,{id:"config-dialog-title",children:(0,n.jsxs)(C.Z,{display:"flex",justifyContent:"space-between",alignItems:"center",children:[(0,n.jsx)(W.Z,{variant:"h6",style:{flexGrow:1},children:"Config"}),(0,n.jsxs)(C.Z,{children:[(0,n.jsx)(U.Z,{title:"Copy to clipboard",children:(0,n.jsx)(q.Z,{onClick:()=>{i.current&&(i.current.select(),document.execCommand("copy"),c(!0))},children:o?(0,n.jsx)(V.Z,{}):(0,n.jsx)(J.Z,{})})}),(0,n.jsx)(U.Z,{title:"Download .yaml",children:(0,n.jsx)(q.Z,{onClick:()=>{let e=new Blob([d],{type:"text/yaml;charset=utf-8"}),t=URL.createObjectURL(e),s=document.createElement("a");s.href=t,s.download="config.yaml",document.body.appendChild(s),s.click(),document.body.removeChild(s),URL.revokeObjectURL(t)},children:(0,n.jsx)(B.Z,{})})})]})]})}),(0,n.jsx)(G.Z,{children:(0,n.jsx)(W.Z,{variant:"body1",component:"div",children:(0,n.jsx)("textarea",{ref:i,readOnly:!0,value:d,style:{width:"100%",minHeight:"400px",fontFamily:"monospace",border:"1px solid #ccc"}})})}),(0,n.jsx)(K.Z,{children:(0,n.jsx)(k.Z,{onClick:h,color:"primary",children:"Close"})})]})}var en=s(79715),el=s(34235),ea=function(){let{table:e,config:t,evalId:s}=et(),[a,r]=l.useState(!1),i=(e,t)=>{let s=URL.createObjectURL(e),n=document.createElement("a");n.href=s,n.download=t,document.body.appendChild(n),n.click(),document.body.removeChild(n),URL.revokeObjectURL(s)},o=()=>{r(!1)};return(0,n.jsxs)(n.Fragment,{children:[(0,n.jsxs)(T.Z,{onClick:()=>{r(!0)},children:[(0,n.jsx)(E.Z,{children:(0,n.jsx)(B.Z,{fontSize:"small"})}),(0,n.jsx)(P.Z,{children:"Download"})]}),(0,n.jsx)(H.Z,{onClose:o,open:a,children:(0,n.jsx)(G.Z,{children:(0,n.jsxs)(L.Z,{direction:"column",spacing:2,sx:{width:"100%"},children:[(0,n.jsx)(k.Z,{onClick:()=>{let e=el.default.dump(t),s=new Blob([e],{type:"text/yaml;charset=utf-8"});i(s,"promptfooconfig.yaml"),o()},startIcon:(0,n.jsx)(B.Z,{}),fullWidth:!0,sx:{justifyContent:"flex-start"},children:"Download YAML Config"}),(0,n.jsx)(k.Z,{onClick:()=>{if(!e){alert("No table data");return}let t=[],n=[...e.head.vars,...e.head.prompts.map(e=>"[".concat(e.provider,"] ").concat(e.label))];t.push(n),e.body.forEach(e=>{let s=[...e.vars,...e.outputs.map(e=>{let{pass:t,text:s}=e;return(t?"[PASS] ":"[FAIL] ")+s})];t.push(s)});let l=(0,en.P)(t),a=new Blob([l],{type:"text/csv;charset=utf-8;"});i(a,"".concat(s,"-table.csv")),o()},startIcon:(0,n.jsx)(B.Z,{}),fullWidth:!0,sx:{justifyContent:"flex-start"},children:"Download Table CSV"}),(0,n.jsx)(k.Z,{onClick:()=>{if(!e){alert("No table data");return}let t=new Blob([JSON.stringify(e,null,2)],{type:"application/json"});i(t,"".concat(s,"-table.json")),o()},startIcon:(0,n.jsx)(B.Z,{}),fullWidth:!0,sx:{justifyContent:"flex-start"},children:"Download Table JSON"}),(0,n.jsx)(k.Z,{onClick:()=>{if(!e){alert("No table data");return}let t=e.body.map((t,s)=>({chosen:t.outputs.filter(e=>e.pass).map(e=>e.text),rejected:t.outputs.filter(e=>!e.pass).map(e=>e.text),vars:t.test.vars,providers:e.head.prompts.map(e=>e.provider),prompts:e.head.prompts.map(e=>e.label||e.display||e.raw)})),n=new Blob([JSON.stringify(t,null,2)],{type:"application/json"});i(n,"".concat(s,"-dpo.json")),o()},startIcon:(0,n.jsx)(B.Z,{}),fullWidth:!0,sx:{justifyContent:"flex-start"},children:"Download DPO JSON"})]})})})]})},er=s(49653),ei=s(37803),eo=s(65068),ec=s(70417),ed=s(21303),eu=s(61451),eh=s(26485),ep=s(30021),em=s(32162),ex=s.n(em),eg=e=>{let{recentEvals:t,onRecentEvalSelected:s,currentEval:a}=e,[r,i]=(0,l.useState)(!1),[o,c]=(0,l.useState)(""),[d,u]=(0,l.useState)(-1),h=l.useRef(null),p=l.useRef(null),m=()=>{i(!0),u(0),setTimeout(()=>{var e;null===(e=h.current)||void 0===e||e.focus()},0)},x=()=>{i(!1),c(""),u(-1)},g=t.filter(e=>ex()(o.toLowerCase(),e.label.toLowerCase())||"string"==typeof e.description&&ex()(o.toLowerCase(),e.description.toLowerCase())),j=e=>{s(e),x()},v=l.useCallback(()=>{if(d>=0&&p.current){let e=p.current.querySelectorAll("tbody tr"),t=Math.min(d+3,e.length-1);e[t]&&e[t].scrollIntoView({behavior:"smooth",block:"nearest"})}},[d]);l.useEffect(()=>{v()},[v]),l.useEffect(()=>{let e=e=>{(e.ctrlKey||e.metaKey)&&"k"===e.key&&(e.preventDefault(),m())};return window.addEventListener("keydown",e),()=>{window.removeEventListener("keydown",e)}},[]);let f="undefined"!=typeof navigator&&-1!==navigator.platform.toUpperCase().indexOf("MAC");return(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)(U.Z,{title:f?"Search for Evals (⌘ + K)":"Search for Evals (Ctrl + K)",arrow:!0,children:(0,n.jsx)(q.Z,{onClick:m,color:"primary",size:"small",children:(0,n.jsx)(er.Z,{})})}),(0,n.jsxs)(H.Z,{open:r,onClose:x,maxWidth:"md",fullWidth:!0,children:[(0,n.jsx)(X.Z,{children:"Open an Eval"}),(0,n.jsx)(G.Z,{children:(0,n.jsxs)(C.Z,{sx:{width:"100%",mt:2},children:[(0,n.jsx)(A.Z,{fullWidth:!0,variant:"outlined",placeholder:"Search",value:o,onChange:e=>{c(e.target.value),u(0)},onKeyDown:e=>{switch(e.key){case"ArrowDown":e.preventDefault(),u(e=>Math.min(e+1,g.length-1));break;case"ArrowUp":e.preventDefault(),u(e=>Math.max(e-1,0));break;case"Enter":e.preventDefault(),d>=0&&d<g.length?j(g[d].evalId):g.length>0&&j(g[0].evalId)}},sx:{mb:2},inputRef:h}),(0,n.jsx)(eu.Z,{component:ei.Z,sx:{height:"600px",overflow:"auto"},ref:p,children:(0,n.jsxs)(eo.Z,{stickyHeader:!0,children:[(0,n.jsx)(eh.Z,{children:(0,n.jsxs)(ep.Z,{children:[(0,n.jsx)(ed.Z,{children:"Created"}),(0,n.jsx)(ed.Z,{children:"Description"}),(0,n.jsx)(ed.Z,{children:"# Tests"})]})}),(0,n.jsx)(ec.Z,{children:g.map((e,t)=>(0,n.jsxs)(ep.Z,{hover:!0,onClick:()=>j(e.evalId),sx:{cursor:"pointer",backgroundColor:t===d?"rgba(255, 255, 0, 0.1)":"inherit"},children:[(0,n.jsx)(ed.Z,{children:new Date(e.createdAt).toLocaleString()}),(0,n.jsx)(ed.Z,{children:e.description||e.label}),(0,n.jsx)(ed.Z,{children:e.numTests})]},e.evalId))})]})})]})}),(0,n.jsx)(K.Z,{children:(0,n.jsx)(k.Z,{onClick:x,children:"Cancel"})})]})]})},ej=s(69179),ev=s(92715),ef=s(92863),eb=s(36001);let ey=["#fd7f6f","#7eb0d5","#b2e061","#bd7ebe","#ffb55a","#ffee65","#beb9db","#fdcce5","#8bd3c7"];function eZ(e){let{table:t}=e,s=(0,l.useRef)(null),a=(0,l.useRef)(null);return(0,l.useEffect)(()=>{if(!s.current)return;a.current&&a.current.destroy();let e=t.body.flatMap(e=>e.outputs.map(e=>e.score)),n=Math.min(...e),l=(Math.ceil(Math.max(...e))-Math.floor(n))/10,r=Array.from({length:11},(e,t)=>parseFloat((Math.floor(n)+t*l).toFixed(2))),i=t.head.prompts.map((e,s)=>{let n=t.body.flatMap(e=>e.outputs[s].score),a=r.map(e=>n.filter(t=>t>=e&&t<e+l).length);return{label:"Column ".concat(s+1),data:a,backgroundColor:ey[s%ey.length]}});a.current=new eb.kL(s.current,{type:"bar",data:{labels:r,datasets:i},options:{animation:!1,plugins:{title:{display:!0,text:"Score Distribution"},legend:{display:!1},tooltip:{callbacks:{title:function(e){let t=e[0].datasetIndex;return"Column ".concat(t+1)},label:function(e){let t=e.dataIndex,s=r[t],n=r[t+1];return n?"".concat(s," <= score < ").concat(n):"".concat(s," <= score")}}}}}})},[t]),(0,n.jsx)("canvas",{ref:s,style:{maxHeight:"300px"}})}function ew(e){let{table:t}=e,s=(0,l.useRef)(null),a=(0,l.useRef)(null);return(0,l.useEffect)(()=>{if(!s.current)return;a.current&&a.current.destroy();let e=t.head.prompts.map((e,s)=>{let n=t.body.flatMap(e=>e.outputs[s]),l=n.filter(e=>e.pass).length,a=l/n.length*100;return{label:"Column ".concat(s+1),data:[a],backgroundColor:ey[s%ey.length]}});a.current=new eb.kL(s.current,{type:"bar",data:{labels:["Pass Rate (%)"],datasets:e},options:{animation:!1,plugins:{title:{display:!0,text:"Pass rate"},legend:{display:!0}}}})},[t]),(0,n.jsx)("canvas",{ref:s,style:{maxHeight:"300px"}})}function eC(e){let{table:t}=e,s=(0,l.useRef)(null),a=(0,l.useRef)(null),[r,i]=(0,l.useState)(0),[o,c]=(0,l.useState)(1),[d,u]=(0,l.useState)(!1);return(0,l.useEffect)(()=>{if(!s.current)return;a.current&&a.current.destroy();let e=t.body.flatMap(e=>e.outputs.map(e=>e.score)),n=Math.min(...e),l=Math.max(...e),i=t.body.map(e=>{let t=e.outputs[r].score,s=e.outputs[o].score;return{x:t,y:s,backgroundColor:s>t?"green":s<t?"red":"gray"}});a.current=new eb.kL(s.current,{type:"scatter",data:{datasets:[{data:i,backgroundColor:i.map(e=>e.backgroundColor)},{type:"line",data:[{x:n,y:n},{x:l,y:l}],borderColor:"gray",borderWidth:1,borderDash:[5,5],pointRadius:0}]},options:{animation:!1,plugins:{legend:{display:!1},tooltip:{callbacks:{label:function(e){let s=t.body[e.dataIndex],n=s.outputs[0].text,l=s.outputs[1].text;return n.length>30&&(n=n.substring(0,30)+"..."),l.length>30&&(l=l.substring(0,30)+"..."),"Output 1: ".concat(n,"\nOutput 2: ").concat(l)}}}},scales:{x:{title:{display:!0,text:"Prompt ".concat(r+1," Score")},ticks:{callback:function(e,t,s){let n=String(Math.round(100*Number(e)));return t===s.length-1&&(n+="%"),n}}},y:{title:{display:!0,text:"Prompt ".concat(o+1," Score")},ticks:{callback:function(e,t,s){let n=String(Math.round(100*Number(e)));return t===s.length-1&&(n+="%"),n}}}}}})},[t,r,o]),(0,n.jsxs)(n.Fragment,{children:[(0,n.jsxs)(H.Z,{open:d,onClose:()=>u(!1),children:[(0,n.jsx)(X.Z,{children:"Compare prompt outputs"}),(0,n.jsxs)(G.Z,{children:[(0,n.jsx)(N.Z,{sx:{m:1,minWidth:120},children:(0,n.jsx)(D.Z,{value:r,onChange:e=>i(Number(e.target.value)),children:t.head.prompts.map((e,t)=>(0,n.jsxs)(T.Z,{value:t,children:["Prompt ",t+1]},t))})}),(0,n.jsx)(N.Z,{sx:{m:1,minWidth:120},children:(0,n.jsx)(D.Z,{value:o,onChange:e=>c(Number(e.target.value)),children:t.head.prompts.map((e,t)=>(0,n.jsxs)(T.Z,{value:t,children:["Prompt ",t+1]},t))})})]})]}),(0,n.jsx)("canvas",{ref:s,style:{maxHeight:"300px",cursor:"pointer"},onClick:()=>u(!0)})]})}function ek(e){let{table:t}=e,s=(0,l.useRef)(null),a=(0,l.useRef)(null);return(0,l.useEffect)(()=>{var e;if(!s.current)return;a.current&&a.current.destroy();let n=Object.keys((null===(e=t.head.prompts[0].metrics)||void 0===e?void 0:e.namedScores)||{}),l=t.head.prompts.map((e,s)=>{let l=n.map(s=>{var n;let l=(null===(n=e.metrics)||void 0===n?void 0:n.namedScores[s])||0,a=Math.max(...t.head.prompts.map(e=>{var t;return(null===(t=e.metrics)||void 0===t?void 0:t.namedScores[s])||0}));return l/a});return{label:"".concat(t.head.prompts[s].provider),data:l,backgroundColor:ey[s%ey.length]}});a.current=new eb.kL(s.current,{type:"bar",data:{labels:n,datasets:l},options:{scales:{x:{grid:{display:!1}},y:{ticks:{callback:function(e,t,s){let n=String(Math.round(100*Number(e)));return t===s.length-1&&(n+="%"),n}}}},plugins:{tooltip:{callbacks:{title:function(e){return e[0].dataset.label},label:function(e){let t=e.parsed.y;return"".concat(n[e.dataIndex],": ").concat((100*t).toFixed(2),"% pass rate")}}}}}})},[t]),(0,n.jsx)("canvas",{ref:s,style:{maxHeight:"300px"}})}eb.kL.register(eb.vn,eb.ST,eb.ho,eb.uw,eb.f$,eb.ZL,eb.jn,eb.od,eb.u,eb.wL);var eS=l.memo(function(e){var t;let{columnVisibility:s}=e,a=(0,ef.Z)();eb.kL.defaults.color="dark"===a.palette.mode?"#aaa":"#666";let[r,i]=(0,l.useState)(!0),{table:o}=et();if(!o||!r||o.head.prompts.length<2)return null;let c=o.body.flatMap(e=>e.outputs.map(e=>e.score)),d=new Set(c);return 1===d.size?null:(0,n.jsx)(ej.SV,{fallback:null,children:(0,n.jsxs)(ei.Z,{style:{position:"relative",padding:a.spacing(3)},children:[(0,n.jsx)(q.Z,{style:{position:"absolute",right:0,top:0},onClick:()=>i(!1),children:(0,n.jsx)(ev.Z,{})}),(0,n.jsxs)("div",{style:{display:"flex",justifyContent:"space-between",width:"100%"},children:[(0,n.jsx)("div",{style:{width:"33%"},children:(0,n.jsx)(ew,{table:o})}),(0,n.jsx)("div",{style:{width:"33%"},children:d.size<=3&&Object.keys((null===(t=o.head.prompts[0].metrics)||void 0===t?void 0:t.namedScores)||{}).length>1?(0,n.jsx)(ek,{table:o}):(0,n.jsx)(eZ,{table:o})}),(0,n.jsx)("div",{style:{width:"33%"},children:(0,n.jsx)(eC,{table:o})})]})]})})}),eR=s(36128),eN=s(9317),eI=s(20286);s(55974);var eE=e=>{let{lookup:t,metricTotals:s,onSearchTextChange:l}=e;return t&&Object.keys(t).length?(0,n.jsx)("div",{className:"custom-metric-container",children:Object.entries(t).map(e=>{let[t,a]=e;return t&&void 0!==a?(0,n.jsxs)("span",{onClick:()=>l&&l("metric=".concat(t,":[^0]")),className:l?"clickable":"",children:[t,":"," ",s&&s[t]?(0,n.jsxs)(n.Fragment,{children:[(a/s[t]*100).toFixed(2),"% (",a,"/",s[t],")"]}):a]},t):null})}):null},eP=s(35185),eF=s(613);function eT(e){let{gradingResults:t}=e;return t?(0,n.jsxs)(C.Z,{mt:2,children:[(0,n.jsx)(W.Z,{variant:"subtitle1",children:"Assertions"}),(0,n.jsx)(eu.Z,{children:(0,n.jsxs)(eo.Z,{children:[(0,n.jsx)(eh.Z,{children:(0,n.jsxs)(ep.Z,{children:[(0,n.jsx)(ed.Z,{style:{fontWeight:"bold"},children:"Pass"}),(0,n.jsx)(ed.Z,{style:{fontWeight:"bold"},children:"Score"}),(0,n.jsx)(ed.Z,{style:{fontWeight:"bold"},children:"Type"}),(0,n.jsx)(ed.Z,{style:{fontWeight:"bold"},children:"Value"}),(0,n.jsx)(ed.Z,{style:{fontWeight:"bold"},children:"Reason"})]})}),(0,n.jsx)(ec.Z,{children:t.map((e,t)=>{var s,l,a;return e?(0,n.jsxs)(ep.Z,{children:[(0,n.jsx)(ed.Z,{children:e.pass?"✅":"❌"}),(0,n.jsx)(ed.Z,{children:null===(s=e.score)||void 0===s?void 0:s.toFixed(2)}),(0,n.jsx)(ed.Z,{children:(null===(l=e.assertion)||void 0===l?void 0:l.type)||""}),(0,n.jsx)(ed.Z,{style:{whiteSpace:"pre-wrap"},children:(null===(a=e.assertion)||void 0===a?void 0:a.value)?String(e.assertion.value):"-"}),(0,n.jsx)(ed.Z,{style:{whiteSpace:"pre-wrap"},children:e.reason})]},t):null})})]})})]}):null}function eM(e){let{open:t,onClose:s,prompt:a,provider:r,output:i,gradingResults:o,metadata:c}=e,[d,u]=(0,l.useState)(!1);(0,l.useEffect)(()=>{u(!1)},[a]);let h=async e=>{await navigator.clipboard.writeText(e),u(!0)};return(0,n.jsxs)(H.Z,{open:t,onClose:s,fullWidth:!0,maxWidth:"lg",children:[(0,n.jsxs)(X.Z,{children:["Details",r&&": ".concat(r)]}),(0,n.jsxs)(G.Z,{children:[(0,n.jsxs)(C.Z,{mb:2,children:[(0,n.jsx)(W.Z,{variant:"subtitle1",style:{marginBottom:"1rem"},children:"Prompt"}),(0,n.jsx)(eF.u,{readOnly:!0,value:a,style:{width:"100%",padding:"0.75rem"},maxRows:20}),(0,n.jsx)(q.Z,{onClick:()=>h(a),style:{position:"absolute",right:"10px",top:"10px"},children:d?(0,n.jsx)(V.Z,{}):(0,n.jsx)(eP.Z,{})})]}),(null==c?void 0:c.redteamFinalPrompt)&&(0,n.jsxs)(C.Z,{my:2,children:[(0,n.jsx)(W.Z,{variant:"subtitle1",style:{marginBottom:"1rem",marginTop:"1rem"},children:"Modified User Input (Red Team)"}),(0,n.jsx)(eF.u,{readOnly:!0,maxRows:20,value:c.redteamFinalPrompt,style:{width:"100%",padding:"0.75rem"}})]}),i&&(0,n.jsxs)(C.Z,{my:2,children:[(0,n.jsx)(W.Z,{variant:"subtitle1",style:{marginBottom:"1rem",marginTop:"1rem"},children:"Output"}),(0,n.jsx)(eF.u,{readOnly:!0,maxRows:20,value:i,style:{width:"100%",padding:"0.75rem"}})]}),(0,n.jsx)(eT,{gradingResults:o})]}),(0,n.jsx)(K.Z,{children:(0,n.jsx)(k.Z,{onClick:s,children:"Close"})})]})}var eD=s(12431),eO=s(8541),eL=function(){let e=(0,ef.Z)(),[t,s]=l.useState(!1),a=()=>{s(!1)};return(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)("div",{style:{textAlign:"center",marginTop:20,marginBottom:40},children:(0,n.jsx)(k.Z,{variant:"text",color:"primary",startIcon:(0,n.jsx)(eD.Z,{}),onClick:()=>{s(!0)},children:"Generate test cases"})}),(0,n.jsxs)(H.Z,{open:t,onClose:a,children:[(0,n.jsx)(X.Z,{children:"Run on Command Line"}),(0,n.jsx)(G.Z,{children:(0,n.jsxs)(eO.Z,{children:[(0,n.jsx)("p",{children:"This feature is in beta. UI coming soon."}),(0,n.jsxs)("p",{children:["Run"," ",(0,n.jsx)(C.Z,{component:"code",sx:{backgroundColor:"dark"===e.palette.mode?"#424242":"#f0f0f0",padding:"2px 4px",borderRadius:"4px"},children:"promptfoo generate dataset"}),"to generate test cases on the command line."]})]})}),(0,n.jsx)(K.Z,{children:(0,n.jsx)(k.Z,{onClick:a,color:"primary",children:"Close"})})]})]})};function eA(e){return"string"==typeof e||"number"==typeof e?e.toString().length:Array.isArray(e)?e.reduce((e,t)=>e+eA(t),0):l.isValidElement(e)&&e.props.children?l.Children.toArray(e.props.children).reduce((e,t)=>e+eA(t),0):0}let eU=l.memo(function(e){let t,{text:s,maxLength:a}=e,[r,i]=l.useState(!0),o=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;if("string"==typeof e||"number"==typeof e){let s=e.toString();return s.slice(0,a-t)}if(Array.isArray(e)){let s=[],n=t;for(let t of e){let e=eA(t);if(n+e>a){s.push(o(t,n));break}s.push(t),n+=e}return s}if(l.isValidElement(e)&&e.props.children){let s=eA(e.props.children);if(s>a-t)return l.cloneElement(e,{...e.props,children:o(e.props.children,t)})}return e};t=l.isValidElement(s)||"string"==typeof s?s:JSON.stringify(s);let c=r?o(t):t,d=eA(t)>a;return(0,n.jsxs)("div",{style:{cursor:d?"pointer":"normal"},onClick:()=>{i(!r)},children:[c,r&&eA(t)>a&&(0,n.jsx)("span",{children:"..."})]})});var eW=s(59682),e_=s(62268),ez=s(38640),eV=s.n(ez),eB=s(33352),eJ=s(73490),eH=s(24495);s(16658);var eK=e=>{let{failReasons:t}=e,[s,a]=(0,l.useState)(0);return t.length<1?null:(0,n.jsxs)("div",{className:"fail-reason",children:[t.length>1&&(0,n.jsxs)("span",{className:"fail-reason-carousel-controls",children:[(0,n.jsx)(q.Z,{onClick:()=>{a(e=>e>0?e-1:t.length-1)},children:(0,n.jsx)(eJ.Z,{sx:{fontSize:12}})}),(0,n.jsxs)("span",{children:[s+1,"/",t.length]}),(0,n.jsx)(q.Z,{onClick:()=>{a(e=>e<t.length-1?e+1:0)},children:(0,n.jsx)(eH.Z,{sx:{fontSize:12}})})]}),t[s].trim().split("\n").map((e,t)=>(0,n.jsxs)(l.Fragment,{children:[e,(0,n.jsx)("br",{})]},t))]})},eG=e=>{let{open:t,contextText:s,commentText:l,onClose:a,onSave:r,onChange:i}=e;return(0,n.jsxs)(H.Z,{open:t,onClose:a,fullWidth:!0,maxWidth:"sm",children:[(0,n.jsx)(X.Z,{children:"Edit Comment"}),(0,n.jsxs)(G.Z,{children:[(0,n.jsx)(C.Z,{sx:{backgroundColor:"#f0f0f0",padding:2,marginBottom:2},children:s}),(0,n.jsx)(A.Z,{autoFocus:!0,margin:"dense",type:"text",fullWidth:!0,multiline:!0,rows:4,value:l,onChange:e=>i(e.target.value)})]}),(0,n.jsxs)(K.Z,{children:[(0,n.jsx)(k.Z,{onClick:r,color:"primary",variant:"contained",children:"Save"}),(0,n.jsx)(k.Z,{onClick:a,color:"primary",children:"Cancel"})]})]})};let eX=()=>{let e=(0,l.useContext)(c);if(void 0===e)throw Error("useShiftKey must be used within a ShiftKeyProvider");return e};var eq=s(19116);let eY=l.memo(function(e){var t,s,a,r,i,o,c,d,u,h,p,m,x;let g,j,v,f,b,y,{output:Z,maxTextLength:w,rowIndex:C,promptIndex:k,onRating:S,firstOutput:R,showDiffs:N,searchText:I,showStats:E}=e,{renderMarkdown:P,prettifyJson:F,showPrompts:T,showPassFail:M}=et(),[D,O]=l.useState(!1),[L,A]=l.useState(!1),[W,_]=l.useState(null),z=e=>{_(e||null),A(!L)},[V,B]=l.useState(!1),[J,H]=l.useState((null===(t=Z.gradingResult)||void 0===t?void 0:t.comment)||""),K=()=>{B(!0)},G="string"==typeof Z.text?Z.text:JSON.stringify(Z.text),X=[];if(!Z.pass&&G.includes("---")&&(X=((null===(h=Z.gradingResult)||void 0===h?void 0:h.componentResults)||[]).filter(e=>!!e&&!e.pass).map(e=>e.reason),G=G.split("---").slice(1).join("---")),N&&R){let e,t="string"==typeof R.text?R.text:JSON.stringify(R.text);t.includes("---")&&(t=t.split("---").slice(1).join("---"));try{JSON.parse(t),JSON.parse(G),e=(0,eq.CT)(t,G)}catch(s){e=t.includes(". ")&&G.includes(". ")?(0,eq.SY)(t,G):(0,eq.NV)(t,G)}g=(0,n.jsx)(n.Fragment,{children:e.map((e,t)=>e.added?(0,n.jsx)("ins",{children:e.value},t):e.removed?(0,n.jsx)("del",{children:e.value},t):(0,n.jsx)("span",{children:e.value},t))})}if(I)try{let e;let t=RegExp(I,"gi"),s=[];for(;null!==(e=t.exec(G));)s.push({start:e.index,end:t.lastIndex});g=(0,n.jsx)(n.Fragment,{children:s.length>0?(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)("span",{children:G.substring(0,s[0].start)},"text-before"),s.map((e,t)=>(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)("span",{className:"search-highlight",children:G.substring(e.start,e.end)},"match-"+t),(0,n.jsx)("span",{children:G.substring(e.end,s[t+1]?s[t+1].start:G.length)},"text-after-"+t)]}))]}):(0,n.jsx)("span",{children:G},"no-match")})}catch(e){console.error("Invalid regular expression:",e.message)}else if(P&&!N)g=(0,n.jsx)(eI.U,{remarkPlugins:[eB.Z],components:{img:e=>{let{src:t,alt:s}=e;return(0,n.jsx)("img",{loading:"lazy",src:t,alt:s,onClick:()=>z(t),style:{cursor:"pointer"}})}},children:G});else if(F)try{g=(0,n.jsx)("pre",{children:JSON.stringify(JSON.parse(G),null,2)})}catch(e){}let q=l.useCallback(e=>{var t;S(e,void 0,null===(t=Z.gradingResult)||void 0===t?void 0:t.comment)},[S,null===(s=Z.gradingResult)||void 0===s?void 0:s.comment]),Y=l.useCallback(()=>{let e=prompt("Set test score (0.0 - 1.0):",String(Z.score));if(null!==e){let s=parseFloat(e);if(!isNaN(s)&&s>=0&&s<=1){var t;S(void 0,s,null===(t=Z.gradingResult)||void 0===t?void 0:t.comment)}else alert("Invalid score. Please enter a value between 0.0 and 1.0.")}},[S,Z.score,null===(a=Z.gradingResult)||void 0===a?void 0:a.comment]),[$,Q]=l.useState(!1),ee=l.useCallback(()=>{navigator.clipboard.writeText(Z.text),Q(!0)},[Z.text]);if(Z.latencyMs&&(v=(0,n.jsxs)("span",{children:[Intl.NumberFormat(void 0,{maximumFractionDigits:0}).format(Z.latencyMs)," ms"]})),null===(r=Z.tokenUsage)||void 0===r?void 0:r.completion){let e=Z.tokenUsage.completion/(Z.latencyMs/1e3);f=(0,n.jsx)("span",{children:Intl.NumberFormat(void 0,{maximumFractionDigits:0}).format(e)})}if(Z.cost&&(b=(0,n.jsxs)("span",{children:["$",Z.cost.toPrecision(2)]})),null===(i=Z.tokenUsage)||void 0===i?void 0:i.cached)j=(0,n.jsxs)("span",{children:[Intl.NumberFormat(void 0,{maximumFractionDigits:0}).format(Z.tokenUsage.cached)," ","(cached)"]});else if(null===(o=Z.tokenUsage)||void 0===o?void 0:o.total){let e=Intl.NumberFormat(void 0,{maximumFractionDigits:0}).format(null!==(p=Z.tokenUsage.prompt)&&void 0!==p?p:0),t=Intl.NumberFormat(void 0,{maximumFractionDigits:0}).format(null!==(m=Z.tokenUsage.completion)&&void 0!==m?m:0),s=Intl.NumberFormat(void 0,{maximumFractionDigits:0}).format(Z.tokenUsage.total);j=(0,n.jsx)(U.Z,{title:"".concat(e," prompt tokens + ").concat(t," completion tokens = ").concat(s," total"),children:(0,n.jsxs)("span",{children:[s,("0"!==e||"0"!==t)&&" (".concat(e,"+").concat(t,")")]})})}let es=(null===(c=Z.gradingResult)||void 0===c?void 0:c.comment)&&"!highlight"!==Z.gradingResult.comment?(0,n.jsx)("div",{className:"comment",onClick:K,children:Z.gradingResult.comment}):null,en=E?(0,n.jsxs)("div",{className:"cell-detail",children:[j&&(0,n.jsxs)("div",{className:"stat-item",children:[(0,n.jsx)("strong",{children:"Tokens:"})," ",j]}),v&&(0,n.jsxs)("div",{className:"stat-item",children:[(0,n.jsx)("strong",{children:"Latency:"})," ",v]}),f&&(0,n.jsxs)("div",{className:"stat-item",children:[(0,n.jsx)("strong",{children:"Tokens/Sec:"})," ",f]}),b&&(0,n.jsxs)("div",{className:"stat-item",children:[(0,n.jsx)("strong",{children:"Cost:"})," ",b]})]}):null,el=eX(),ea=(0,n.jsxs)("div",{className:"cell-actions",children:[el&&(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)("span",{className:"action",onClick:ee,onMouseDown:e=>e.preventDefault(),children:(0,n.jsx)(U.Z,{title:"Copy output to clipboard",children:(0,n.jsx)("span",{children:$?"✅":"\uD83D\uDCCB"})})}),(0,n.jsx)("span",{className:"action",onClick:()=>{let e;J.startsWith("!highlight")?S(void 0,void 0,e=J.slice(10).trim()):S(void 0,void 0,e=("!highlight "+J).trim()),H(e)},onMouseDown:e=>e.preventDefault(),children:(0,n.jsx)(U.Z,{title:"Toggle test highlight",children:(0,n.jsx)("span",{children:"\uD83C\uDF1F"})})})]}),Z.prompt&&(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)("span",{className:"action",onClick:()=>{O(!0)},children:(0,n.jsx)(U.Z,{title:"View output and test details",children:(0,n.jsx)("span",{children:"\uD83D\uDD0E"})})}),(0,n.jsx)(eM,{open:D,onClose:()=>{O(!1)},prompt:Z.prompt,provider:Z.provider,gradingResults:null===(d=Z.gradingResult)||void 0===d?void 0:d.componentResults,output:G,metadata:Z.metadata})]}),(0,n.jsx)("span",{className:"action",onClick:()=>q(!0),children:(0,n.jsx)(U.Z,{title:"Mark test passed (score 1.0)",children:(0,n.jsx)("span",{children:"\uD83D\uDC4D"})})}),(0,n.jsx)("span",{className:"action",onClick:()=>q(!1),children:(0,n.jsx)(U.Z,{title:"Mark test failed (score 0.0)",children:(0,n.jsx)("span",{children:"\uD83D\uDC4E"})})}),(0,n.jsx)("span",{className:"action",onClick:Y,children:(0,n.jsx)(U.Z,{title:"Set test score",children:(0,n.jsx)("span",{children:"\uD83D\uDD22"})})}),(0,n.jsx)("span",{className:"action",onClick:K,children:(0,n.jsx)(U.Z,{title:"Edit comment",children:(0,n.jsx)("span",{children:"✏️"})})})]}),er={};(null===(u=Z.gradingResult)||void 0===u?void 0:u.comment)==="!highlight"&&(er.backgroundColor="#ffffeb");let ei=0,eo=0,ec=Z.gradingResult;if(ec?ec.componentResults?ec.componentResults.forEach(e=>{(null==e?void 0:e.pass)?ei++:eo++}):(ei=ec.pass?1:0,eo=ec.pass?0:1):Z.pass?ei=1:Z.pass||(eo=1),1===eo&&1===ei)y=(0,n.jsxs)(n.Fragment,{children:["".concat(eo," FAIL")," ","".concat(ei," PASS")]});else{let e="";eo>1||ei>1&&eo>0?e="".concat(eo," FAIL"):1===eo&&(e="FAIL");let t="";ei>1||eo>1&&ei>0?t="".concat(ei," PASS"):1===ei&&0===eo&&(t="PASS");let s=e&&t?" ":"";y=(0,n.jsxs)(n.Fragment,{children:[e,s,t]})}let ed=null===(x=Z.score)||0===x||1===x?"":"(".concat(x.toFixed(2),")");return(0,n.jsxs)("div",{className:"cell",style:er,children:[M&&(0,n.jsx)(n.Fragment,{children:Z.pass?(0,n.jsx)(n.Fragment,{children:(0,n.jsxs)("div",{className:"status pass",children:[(0,n.jsxs)("div",{className:"pill",children:[y,ed&&(0,n.jsxs)("span",{className:"score",children:[" ",ed]})]}),(0,n.jsx)(eE,{lookup:Z.namedScores})]})}):(0,n.jsx)(n.Fragment,{children:(0,n.jsxs)("div",{className:"status fail",children:[(0,n.jsxs)("div",{className:"pill",children:[y,ed&&(0,n.jsxs)("span",{className:"score",children:[" ",ed]})]}),(0,n.jsx)(eE,{lookup:Z.namedScores}),(0,n.jsx)("span",{className:"fail-reason",children:(0,n.jsx)(eK,{failReasons:X})})]})})}),T&&R.prompt&&(0,n.jsxs)("div",{className:"prompt",children:[(0,n.jsx)("span",{className:"pill",children:"Prompt"}),Z.prompt]}),(0,n.jsx)(eU,{text:g||G,maxLength:w}),es,en,ea,L&&W&&(0,n.jsx)("div",{className:"lightbox",onClick:()=>z(),children:(0,n.jsx)("img",{src:W,alt:"Lightbox"})}),(0,n.jsx)(eG,{open:V,contextText:Z.text,commentText:J,onClose:()=>{B(!1)},onSave:()=>{S(void 0,void 0,J),B(!1)},onChange:H})]})});function e$(e){let{text:t,maxLength:s,expandedText:a,resourceId:r,className:i}=e,[o,c]=l.useState(!1);return(0,n.jsxs)("div",{className:"".concat(i||""),children:[(0,n.jsx)(eU,{text:t,maxLength:s}),a&&(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)(U.Z,{title:"View prompt",children:(0,n.jsx)("span",{className:"action",onClick:()=>{c(!0)},children:"\uD83D\uDD0E"})}),(0,n.jsx)(eM,{open:o,onClose:()=>{c(!1)},prompt:a}),r&&(0,n.jsx)(U.Z,{title:"View other evals and datasets for this prompt",children:(0,n.jsx)("span",{className:"action",children:(0,n.jsx)(eV(),{href:"/prompts/?id=".concat(r),target:"_blank",children:(0,n.jsx)(eW.Z,{fontSize:"small"})})})})]})]})}s(93207);var eQ=l.memo(function(e){let{maxTextLength:t,columnVisibility:s,wordBreak:a,filterMode:r,failureFilter:i,searchText:c,showStats:d,onFailureFilterToggle:u,onSearchTextChange:h}=e,{evalId:p,table:m,setTable:x}=et();(0,g.Z)(m,"Table should be defined");let{head:j,body:v}=m,f=l.useCallback(async(e,t,s,n,l)=>{var a,r;let i=[...v],c={...i[e]},d=[...c.outputs],u=null!=s?s:d[t].pass,h=void 0===n?s?1:0:n||0;d[t].pass=u,d[t].score=h;let m=(null===(a=d[t].gradingResult)||void 0===a?void 0:a.componentResults)||[];if(void 0!==s){let e=m.findIndex(e=>{var t;return(null===(t=e.assertion)||void 0===t?void 0:t.type)==="human"}),t={pass:u,score:h,reason:"Manual result (overrides all other grading results)",comment:l,assertion:{type:"human"}};-1!==e?m[e]=t:m.push(t)}let g={...d[t].gradingResult||{},pass:u,score:h,reason:"Manual result (overrides all other grading results)",comment:l,assertion:(null===(r=d[t].gradingResult)||void 0===r?void 0:r.assertion)||null,componentResults:m};d[t].gradingResult=g,c.outputs=d,i[e]=c;let f={head:j,body:i};x(f);try{let e=await fetch("".concat(await (0,o.b)(),"/api/eval/").concat(p),{method:"PATCH",headers:{"Content-Type":"application/json"},body:JSON.stringify({table:f})});if(!e.ok)throw Error("Network response was not ok")}catch(e){console.error("Failed to update table:",e)}},[v,j,x,p]),b=Object.keys(s).length>0,y=l.useMemo(()=>{try{return RegExp(c,"i")}catch(e){return console.error("Invalid regular expression:",e.message),null}},[c]),Z=l.useMemo(()=>{try{return v.map((e,t)=>({...e,outputs:e.outputs.map((e,s)=>({...e,originalRowIndex:t,originalPromptIndex:s}))})).filter(e=>{let t=!0;return"failures"===r?t=e.outputs.some((e,t)=>{let n="Prompt ".concat(t+1);return i[n]&&!e.pass&&(!b||s[n])}):"different"===r?t=!e.outputs.every(t=>t.text===e.outputs[0].text):"highlights"===r&&(console.log(e.outputs[0].text),t=e.outputs.some(e=>{var t,s;return null===(s=e.gradingResult)||void 0===s?void 0:null===(t=s.comment)||void 0===t?void 0:t.startsWith("!highlight")})),!!t&&(!c||!y||e.outputs.some(t=>{var s,n;let l=e.vars.map(e=>"var=".concat(e)).join(" "),a="".concat(t.text," ").concat(Object.keys(t.namedScores).map(e=>"metric=".concat(e,":").concat(t.namedScores[e])).join(" ")," ").concat((null===(s=t.gradingResult)||void 0===s?void 0:s.reason)||""," ").concat((null===(n=t.gradingResult)||void 0===n?void 0:n.comment)||""),r="".concat(l," ").concat(a);return y.test(r)}))})}catch(e){return console.error("Invalid regular expression:",e.message),v}},[v,i,r,c,s,b,y]),[w,R]=l.useState({pageIndex:0,pageSize:50});l.useEffect(()=>{R(e=>({...e,pageIndex:0}))},[i,r,c]);let N=l.useMemo(()=>j.prompts.map((e,t)=>v.reduce((e,s)=>e+(s.outputs[t].pass?1:0),0)),[j.prompts,v]),I=l.useMemo(()=>j.prompts.map((e,t)=>v.reduce((e,s)=>{var n,l;return e+((null===(l=s.outputs[t].gradingResult)||void 0===l?void 0:null===(n=l.componentResults)||void 0===n?void 0:n.length)||0)},0)),[j.prompts,v]),E=l.useMemo(()=>j.prompts.map((e,t)=>v.reduce((e,s)=>{var n;let l=null===(n=s.outputs[t].gradingResult)||void 0===n?void 0:n.componentResults;return e+(l?l.filter(e=>null==e?void 0:e.pass).length:0)},0)),[j.prompts,v]),P=l.useMemo(()=>N.reduce((e,t,s,n)=>t>n[e]?s:e,0),[N]),F=N[P],M=l.useMemo(()=>(0,eR.Cl)(),[]),{renderMarkdown:O}=et(),L=l.useMemo(()=>j.vars.length>0?[M.group({id:"vars",header:()=>(0,n.jsx)("span",{className:"font-bold",children:"Variables"}),columns:j.vars.map((e,s)=>M.accessor(e=>e.vars[s],{id:"Variable ".concat(s+1),header:()=>(0,n.jsx)(e$,{text:e,maxLength:t,className:"font-bold"}),cell:e=>{let s=e.getValue();return(0,n.jsx)("div",{className:"cell",children:O?(0,n.jsx)(eI.U,{remarkPlugins:[eB.Z],children:s}):(0,n.jsx)(eU,{text:s,maxLength:t})})},size:50}))})]:[],[M,j.vars,t,O]),U=l.useCallback((e,t)=>Z[e].outputs[t],[Z]),_=l.useCallback(e=>Z[e].outputs[0],[Z]),z=l.useMemo(()=>{let e={};return null==m||m.body.forEach(t=>{var s;null===(s=t.test.assert)||void 0===s||s.forEach(t=>{t.metric&&(e[t.metric]=(e[t.metric]||0)+1),"assert"in t&&Array.isArray(t.assert)&&t.assert.forEach(t=>{"metric"in t&&t.metric&&(e[t.metric]=(e[t.metric]||0)+1)})})}),e},[m]),V=l.useMemo(()=>[M.group({id:"prompts",header:()=>(0,n.jsx)("span",{className:"font-bold",children:"Outputs"}),columns:j.prompts.map((e,s)=>M.accessor(e=>(function(e){if("string"==typeof e){let t=e.startsWith("[PASS]"),s=e;return e.startsWith("[PASS]")?s=s.slice(6):e.startsWith("[FAIL]")&&(s=s.slice(6)),{text:s,pass:t,score:t?1:0}}return e})(e.outputs[s]),{id:"Prompt ".concat(s+1),header:()=>{var l,a,o,c,p,m,x,g;let j=N[s]&&v.length?(N[s]/v.length*100).toFixed(2):"0.00",f=N[s]===F&&0!==F,b="Prompt ".concat(s+1),y=i[b]||!1,Z=d?(0,n.jsxs)("div",{className:"prompt-detail",children:[I[s]?(0,n.jsxs)("div",{children:[(0,n.jsx)("strong",{children:"Asserts:"})," ",E[s],"/",I[s]," passed"]}):null,(null===(l=e.metrics)||void 0===l?void 0:l.totalLatencyMs)?(0,n.jsxs)("div",{children:[(0,n.jsx)("strong",{children:"Avg Latency:"})," ",Intl.NumberFormat(void 0,{maximumFractionDigits:0}).format(e.metrics.totalLatencyMs/v.length)," ","ms"]}):null,(null===(o=e.metrics)||void 0===o?void 0:null===(a=o.tokenUsage)||void 0===a?void 0:a.total)?(0,n.jsxs)("div",{children:[(0,n.jsx)("strong",{children:"Avg Tokens:"})," ",Intl.NumberFormat(void 0,{maximumFractionDigits:0}).format(e.metrics.tokenUsage.total/v.length)]}):null,(null===(c=e.metrics)||void 0===c?void 0:c.totalLatencyMs)&&(null===(m=e.metrics)||void 0===m?void 0:null===(p=m.tokenUsage)||void 0===p?void 0:p.completion)?(0,n.jsxs)("div",{children:[(0,n.jsx)("strong",{children:"Tokens/Sec:"})," ",Intl.NumberFormat(void 0,{maximumFractionDigits:0}).format(e.metrics.tokenUsage.completion/(e.metrics.totalLatencyMs/1e3))]}):null,(null===(x=e.metrics)||void 0===x?void 0:x.cost)?(0,n.jsxs)("div",{children:[(0,n.jsx)("strong",{children:"Cost:"})," $",e.metrics.cost.toPrecision(2)]}):null]}):null,w=e.provider?e.provider.split(":"):[],C=w.length>1?(0,n.jsxs)(n.Fragment,{children:[w[0],":",(0,n.jsx)("strong",{children:w.slice(1).join(":")})]}):(0,n.jsx)("strong",{children:e.provider});return(0,n.jsxs)("div",{className:"output-header",children:[(0,n.jsxs)("div",{className:"pills",children:[e.provider?(0,n.jsx)("div",{className:"provider",children:C}):null,(0,n.jsx)("div",{className:"summary",children:(0,n.jsxs)("div",{className:"highlight ".concat(f?"success":""),children:[(0,n.jsxs)("strong",{children:[j,"% passing"]})," (",N[s],"/",v.length," cases)"]})}),(null===(g=e.metrics)||void 0===g?void 0:g.namedScores)&&Object.keys(e.metrics.namedScores).length>0?(0,n.jsx)(eE,{lookup:e.metrics.namedScores,metricTotals:z,onSearchTextChange:h}):null]}),(0,n.jsx)(e$,{className:"prompt-container",text:e.label||e.display||e.raw,expandedText:e.raw,maxLength:t,resourceId:e.id}),Z,"failures"===r&&(0,n.jsx)(e_.Z,{sx:{"& .MuiFormControlLabel-label":{fontSize:"0.75rem"}},control:(0,n.jsx)(S.Z,{checked:y,onChange:e=>u(b,e.target.checked)}),label:"Show failures"})]})},cell:e=>{var l,a;let i=U(e.row.index,s);return(0,n.jsx)(eY,{output:i,maxTextLength:t,rowIndex:e.row.index,promptIndex:s,onRating:f.bind(null,null!==(l=i.originalRowIndex)&&void 0!==l?l:e.row.index,null!==(a=i.originalPromptIndex)&&void 0!==a?a:s),firstOutput:_(e.row.index),showDiffs:"different"===r,searchText:c,showStats:d})}}))})],[v.length,M,i,r,_,U,f,j.prompts,F,t,z,I,E,N,u,h,c,d]),B=l.useMemo(()=>{let e=v.some(e=>e.description);return e?{accessorFn:e=>e.description||"",id:"description",header:()=>(0,n.jsx)("span",{className:"font-bold",children:"Description"}),cell:e=>(0,n.jsx)("div",{className:"cell",children:(0,n.jsx)(eU,{text:String(e.getValue()),maxLength:t})}),size:50}:null},[v,t]),J=l.useMemo(()=>{let e=[];return B&&e.push(B),e.push(...L,...V),e},[B,L,V]),H=(0,eN.b7)({data:Z,columns:J,columnResizeMode:"onChange",getCoreRowModel:(0,eR.sC)(),getPaginationRowModel:(0,eR.G_)(),state:{columnVisibility:s,pagination:w}});return(0,n.jsxs)("div",{children:[(0,n.jsxs)("table",{className:"results-table firefox-fix ".concat(t<=25?"compact":""),style:{wordBreak:a},children:[(0,n.jsx)("thead",{children:H.getHeaderGroups().map(e=>(0,n.jsx)("tr",{className:"header",children:e.headers.map(e=>(0,n.jsxs)("th",{colSpan:e.colSpan,style:{width:e.getSize()},children:[e.isPlaceholder?null:(0,eN.ie)(e.column.columnDef.header,e.getContext()),(0,n.jsx)("div",{onMouseDown:e.getResizeHandler(),onTouchStart:e.getResizeHandler(),className:"resizer ".concat(e.column.getIsResizing()?"isResizing":"")})]},e.id))},e.id))}),(0,n.jsx)("tbody",{children:H.getRowModel().rows.map((e,t)=>{let s=!1;return(0,n.jsx)("tr",{children:e.getVisibleCells().map(e=>{let l=e.column.id.startsWith("Variable")||"description"===e.column.id,a=!l&&!s;return a&&(s=!0),(0,n.jsx)("td",{style:{width:e.column.getSize()},className:"".concat(l?"variable":""," ").concat(0!==t||l?"":"first-prompt-row"," ").concat(a?"first-prompt-col":""),children:(0,eN.ie)(e.column.columnDef.cell,e.getContext())},e.id)})},e.id)})})]}),H.getPageCount()>1&&(0,n.jsxs)(C.Z,{className:"pagination",mx:1,sx:{display:"flex",alignItems:"center",gap:2},children:[(0,n.jsx)(k.Z,{onClick:()=>{R(e=>({...e,pageIndex:Math.max(e.pageIndex-1,0)})),window.scrollTo(0,0)},disabled:0===H.getState().pagination.pageIndex,variant:"contained",children:"Previous"}),(0,n.jsxs)(W.Z,{component:"span",sx:{display:"flex",alignItems:"center",gap:1},children:["Page",(0,n.jsx)(A.Z,{size:"small",type:"number",value:H.getState().pagination.pageIndex+1,onChange:e=>{let t=e.target.value?Number(e.target.value)-1:0;R(e=>({...e,pageIndex:Math.min(Math.max(t,0),H.getPageCount()-1)}))},InputProps:{style:{width:"60px",textAlign:"center"}},variant:"outlined"}),(0,n.jsxs)("span",{children:["of ",H.getPageCount()]})]}),(0,n.jsx)(k.Z,{onClick:()=>{R(e=>({...e,pageIndex:Math.min(e.pageIndex+1,H.getPageCount()-1)})),window.scrollTo(0,0)},disabled:H.getState().pagination.pageIndex+1>=H.getPageCount(),variant:"contained",children:"Next"}),(0,n.jsxs)(W.Z,{component:"span",sx:{display:"flex",alignItems:"center",gap:1},children:[(0,n.jsxs)(D.Z,{value:w.pageSize,onChange:e=>{R({pageIndex:0,pageSize:Number(e.target.value)}),window.scrollTo(0,0)},displayEmpty:!0,inputProps:{"aria-label":"Results per page"},size:"small",sx:{m:1,minWidth:80},children:[(0,n.jsx)(T.Z,{value:10,children:"10"}),(0,n.jsx)(T.Z,{value:50,children:"50"}),(0,n.jsx)(T.Z,{value:100,children:"100"}),(0,n.jsx)(T.Z,{value:500,children:"500"}),(0,n.jsx)(T.Z,{value:1e3,children:"1000"})]}),(0,n.jsx)("span",{children:"results per page"})]})]}),(0,n.jsx)(eL,{})]})}),e0=s(22695),e1=e=>{let{open:t,onClose:s}=e,{maxTextLength:l,setMaxTextLength:a,wordBreak:r,setWordBreak:i,showInferenceDetails:o,setShowInferenceDetails:c,renderMarkdown:d,setRenderMarkdown:u,prettifyJson:h,setPrettifyJson:p,showPrompts:m,setShowPrompts:x,showPassFail:g,setShowPassFail:j}=et();return(0,n.jsxs)(H.Z,{open:t,onClose:s,fullWidth:!0,maxWidth:"sm",children:[(0,n.jsx)(X.Z,{children:"Table View Settings"}),(0,n.jsxs)(G.Z,{children:[(0,n.jsx)(C.Z,{children:(0,n.jsx)(U.Z,{title:"Forcing line breaks makes it easier to adjust column widths to your liking",placement:"right",children:(0,n.jsx)(e_.Z,{control:(0,n.jsx)(S.Z,{checked:"break-all"===r,onChange:e=>i(e.target.checked?"break-all":"break-word")}),label:"Force line breaks"})})}),(0,n.jsx)(C.Z,{children:(0,n.jsx)(e_.Z,{control:(0,n.jsx)(S.Z,{checked:d,onChange:e=>u(e.target.checked)}),label:"Render model outputs as Markdown"})}),(0,n.jsx)(C.Z,{children:(0,n.jsx)(e_.Z,{control:(0,n.jsx)(S.Z,{checked:h,onChange:e=>p(e.target.checked)}),label:"Prettify JSON outputs"})}),(0,n.jsx)(C.Z,{children:(0,n.jsx)(U.Z,{title:"Show the final prompt that produced the output in each cell.",placement:"right",children:(0,n.jsx)(e_.Z,{control:(0,n.jsx)(S.Z,{checked:m,onChange:e=>x(e.target.checked)}),label:"Show full prompt in output cell"})})}),(0,n.jsx)(C.Z,{children:(0,n.jsx)(U.Z,{title:"Show pass/fail status for each output.",placement:"right",children:(0,n.jsx)(e_.Z,{control:(0,n.jsx)(S.Z,{checked:g,onChange:e=>j(e.target.checked)}),label:"Show pass/fail status"})})}),(0,n.jsx)(C.Z,{children:(0,n.jsx)(U.Z,{title:"Show detailed inference statistics such as latency, tokens used, cost, etc.",placement:"right",children:(0,n.jsx)(e_.Z,{control:(0,n.jsx)(S.Z,{checked:o,onChange:e=>c(e.target.checked)}),label:"Show inference details"})})}),(0,n.jsxs)(C.Z,{maxWidth:"sm",children:[(0,n.jsxs)(W.Z,{mt:2,children:["Max text length: ",l]}),(0,n.jsx)(e0.ZP,{min:25,max:1e3,value:l,onChange:(e,t)=>a(t)})]})]}),(0,n.jsx)(K.Z,{children:(0,n.jsx)(k.Z,{onClick:s,children:"Close"})})]})},e2=e=>{let{open:t,onClose:s,shareUrl:a}=e,r=(0,l.useRef)(null),[i,o]=(0,l.useState)(!1),c=()=>{s(),o(!1)};return(0,n.jsxs)(H.Z,{open:t,onClose:c,PaperProps:{style:{minWidth:"min(660px, 100%)"}},children:[(0,n.jsx)(X.Z,{children:"Your eval is ready to share"}),(0,n.jsxs)(G.Z,{children:[(0,n.jsx)(A.Z,{inputRef:r,value:a,fullWidth:!0,InputProps:{readOnly:!0,endAdornment:(0,n.jsx)(q.Z,{onClick:()=>{r.current&&(r.current.select(),document.execCommand("copy"),o(!0))},children:i?(0,n.jsx)(V.Z,{}):(0,n.jsx)(J.Z,{})})}}),(0,n.jsx)(eO.Z,{sx:{fontSize:"0.75rem"},children:"Shared URLs are deleted after 2 weeks."})]}),(0,n.jsx)(K.Z,{children:(0,n.jsx)(k.Z,{onClick:c,color:"primary",children:"Close"})})]})};s(58022);let e5=(0,_.Z)(L.Z)(e=>{let{theme:t}=e;return{maxWidth:"100%",flexWrap:"wrap",[t.breakpoints.down("sm")]:{flexDirection:"column"}}});function e3(e){var t;let{recentEvals:s,onRecentEvalSelected:a,defaultEvalId:c}=e,d=(0,m.useRouter)(),u=(0,m.useSearchParams)(),{author:p,table:x,config:L,setConfig:_,maxTextLength:V,wordBreak:B,showInferenceDetails:J,evalId:H}=et(),{setStateFromConfig:K}=(0,j.o)(),[G,X]=l.useState((null==u?void 0:u.get("search"))||""),[q]=(0,z.Nr)(G,1e3),Y=e=>{X(e)},[$,Q]=l.useState({}),ee=l.useCallback((e,t)=>{Q(s=>({...s,[e]:t}))},[Q]);(0,g.Z)(x,"Table data must be loaded before rendering ResultsView");let{head:en}=x,[el,er]=l.useState("all"),[ei,eo]=l.useState(!1),[ec,ed]=l.useState(""),[eu,eh]=l.useState(!1),ep=async()=>{eh(!0);try{let e=await fetch("".concat(r,"/api/eval"),{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({data:{version:2,createdAt:new Date().toISOString(),results:{table:x},config:L}})}),{id:t}=await e.json(),s="".concat(i,"/eval/").concat(t);ed(s),eo(!0)}catch(e){alert("Sorry, something went wrong.")}finally{eh(!1)}},em=l.useMemo(()=>x.body.some(e=>e.description),[x.body]),ex=l.useMemo(()=>[...em?[{value:"description",label:"Description"}]:[],...en.vars.map((e,t)=>({value:"Variable ".concat(t+1),label:"Var ".concat(t+1,": ").concat(en.vars[t].length>100?en.vars[t].slice(0,97)+"...":en.vars[t]),group:"Variables"})),...en.prompts.map((e,t)=>{let s=en.prompts[t],n=s.label||s.display||s.raw;return{value:"Prompt ".concat(t+1),label:"Prompt ".concat(t+1,": ").concat(n.length>100?n.slice(0,97)+"...":n),group:"Prompts"}})],[en.vars,en.prompts,em]),[ej,ev]=l.useState(!1),[ef,eb]=l.useState(!1),[ey,eZ]=l.useState({}),[ew,eC]=l.useState(ex.map(e=>e.value)),ek=async()=>{(0,g.Z)(L,"Config must be loaded before clicking its description");let e=window.prompt("Enter new description:",L.description);if(null!==e&&e!==L.description){let t={...L,description:e};try{let e=await fetch("".concat(await (0,o.b)(),"/api/eval/").concat(H),{method:"PATCH",headers:{"Content-Type":"application/json"},body:JSON.stringify({config:t})});if(!e.ok)throw Error("Network response was not ok");_(t)}catch(e){console.error("Failed to update table:",e)}}},eR=async()=>{if(window.confirm("Are you sure you want to delete this evaluation?"))try{let e=await fetch("".concat(await (0,o.b)(),"/api/eval/").concat(H),{method:"DELETE"});if(!e.ok)throw Error("Network response was not ok");d.push("/")}catch(e){console.error("Failed to delete evaluation:",e),alert("Failed to delete evaluation")}},[eN,eI]=l.useState(null),[eE,eP]=l.useState(!1),eF=async()=>{H&&(await navigator.clipboard.writeText(H),eP(!0),setTimeout(()=>{eP(!1)},1e3))};return(0,n.jsxs)("div",{style:{marginLeft:"1rem",marginRight:"1rem"},children:[(0,n.jsxs)(e5,{direction:"row",mb:2,spacing:1,alignItems:"center",className:"eval-header",children:[s&&s.length>0&&(0,n.jsx)(eg,{recentEvals:s,onRecentEvalSelected:a,currentEval:s.find(e=>e.evalId===H)||null}),(0,n.jsx)(W.Z,{variant:"h5",sx:{display:"flex",alignItems:"center"},children:(0,n.jsx)(U.Z,{title:"Click to edit description",children:(0,n.jsx)("span",{className:"description",onClick:ek,children:(null==L?void 0:L.description)||H})})}),(null==L?void 0:L.description)&&H&&(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)(U.Z,{title:"Click to copy",children:(0,n.jsx)(R.Z,{size:"small",label:(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)("strong",{children:"ID:"})," ",H]}),sx:{opacity:.7,cursor:"pointer"},onClick:eF})}),(0,n.jsx)(O.Z,{open:eE,autoHideDuration:1e3,onClose:()=>eP(!1),message:"Eval id copied to clipboard"})]}),(0,n.jsx)(U.Z,{title:p?"":"Set eval author with `promptfoo config set email`",children:(0,n.jsx)(R.Z,{size:"small",label:(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)("strong",{children:"Author:"})," ",p||"Unknown"]}),sx:{opacity:.7}})})]}),(0,n.jsxs)(e5,{direction:"row",spacing:4,alignItems:"center",children:[(0,n.jsx)(C.Z,{children:(0,n.jsxs)(N.Z,{sx:{m:1,minWidth:200,maxWidth:350},size:"small",children:[(0,n.jsx)(I.Z,{id:"visible-columns-label",children:"Columns"}),(0,n.jsx)(D.Z,{labelId:"visible-columns-label",id:"visible-columns",multiple:!0,value:ew,onChange:e=>{let{target:{value:t}}=e;eC("string"==typeof t?t.split(","):t);let s=[...em?["description"]:[],...en.vars.map((e,t)=>"Variable ".concat(t+1)),...en.prompts.map((e,t)=>"Prompt ".concat(t+1))],n={};s.forEach(e=>{n[e]=("string"==typeof t?t.split(","):t).includes(e)}),eZ(n)},input:(0,n.jsx)(M.Z,{label:"Visible columns"}),renderValue:e=>e.join(", "),children:ex.map(e=>(0,n.jsxs)(T.Z,{dense:!0,value:e.value,children:[(0,n.jsx)(S.Z,{checked:ew.indexOf(e.value)>-1}),(0,n.jsx)(P.Z,{primary:e.label})]},e.value))})]})}),(0,n.jsx)(C.Z,{children:(0,n.jsxs)(N.Z,{sx:{minWidth:180},size:"small",children:[(0,n.jsx)(I.Z,{id:"failure-filter-mode-label",children:"Display"}),(0,n.jsxs)(D.Z,{labelId:"filter-mode-label",id:"filter-mode",value:el,onChange:e=>{let t=e.target.value;er(t);let s={};en.prompts.forEach((e,n)=>{s["Prompt ".concat(n+1)]="failures"===t}),Q(s)},label:"Filter",children:[(0,n.jsx)(T.Z,{value:"all",children:"Show all results"}),(0,n.jsx)(T.Z,{value:"failures",children:"Show failures only"}),(0,n.jsx)(T.Z,{value:"different",children:"Show different only"}),(0,n.jsx)(T.Z,{value:"highlights",children:"Show highlights only"})]})]})}),(0,n.jsx)(C.Z,{children:(0,n.jsx)(A.Z,{sx:{minWidth:180},size:"small",label:"Search",placeholder:"Text or regex",value:G,onChange:e=>Y(e.target.value)})}),(0,n.jsx)(C.Z,{flexGrow:1}),(0,n.jsx)(C.Z,{display:"flex",justifyContent:"flex-end",children:(0,n.jsxs)(e5,{direction:"row",spacing:2,children:[(0,n.jsx)(k.Z,{color:"primary",onClick:e=>{eI(e.currentTarget)},startIcon:(0,n.jsx)(v.Z,{}),children:"Eval actions"}),L&&(0,n.jsxs)(F.Z,{id:"eval-actions-menu",anchorEl:eN,keepMounted:!0,open:!!eN,onClose:()=>{eI(null)},children:[(0,n.jsx)(U.Z,{title:"View the configuration that defines this eval",placement:"left",children:(0,n.jsxs)(T.Z,{onClick:()=>ev(!0),children:[(0,n.jsx)(E.Z,{children:(0,n.jsx)(w.Z,{fontSize:"small"})}),"View YAML"]})}),(0,n.jsx)(U.Z,{title:"Edit this eval in the web UI",placement:"left",children:(0,n.jsxs)(T.Z,{onClick:()=>{K(L),d.push("/setup/")},children:[(0,n.jsx)(E.Z,{children:(0,n.jsx)(b.Z,{fontSize:"small"})}),"Edit Eval"]})}),(0,n.jsx)(ea,{}),(null==L?void 0:L.sharing)&&(0,n.jsx)(U.Z,{title:"Generate a unique URL that others can access",placement:"left",children:(0,n.jsxs)(T.Z,{onClick:ep,disabled:eu,children:[(0,n.jsx)(E.Z,{children:eu?(0,n.jsx)(h.Z,{size:16}):(0,n.jsx)(Z.Z,{fontSize:"small"})}),"Share"]})}),(0,n.jsx)(U.Z,{title:"Delete this eval",placement:"left",children:(0,n.jsxs)(T.Z,{onClick:eR,children:[(0,n.jsx)(E.Z,{children:(0,n.jsx)(f.Z,{fontSize:"small"})}),"Delete"]})})]}),(0,n.jsx)(U.Z,{title:"Edit table view settings",placement:"bottom",children:(0,n.jsx)(k.Z,{color:"primary",onClick:()=>eb(!0),startIcon:(0,n.jsx)(y.Z,{}),children:"Table Settings"})}),(null==L?void 0:null===(t=L.metadata)||void 0===t?void 0:t.redteam)&&(0,n.jsx)(U.Z,{title:"View vulnerability scan report",placement:"bottom",children:(0,n.jsx)(k.Z,{color:"primary",startIcon:(0,n.jsx)(w.Z,{}),onClick:()=>d.push("/report/?evalId=".concat(H)),children:"Vulnerability Report"})})]})})]}),(0,n.jsx)(eS,{columnVisibility:ey}),(0,n.jsx)(eQ,{maxTextLength:V,columnVisibility:ey,wordBreak:B,showStats:J,filterMode:el,failureFilter:$,searchText:q,onFailureFilterToggle:ee,onSearchTextChange:Y}),(0,n.jsx)(es,{open:ej,onClose:()=>ev(!1)}),(0,n.jsx)(e2,{open:ei,onClose:()=>eo(!1),shareUrl:ec}),(0,n.jsx)(e1,{open:ef,onClose:()=>eb(!1)})]})}async function e4(){let e=(0,p.createClientComponentClient)(),{data:{user:t}}=await e.auth.getUser();(0,g.Z)(t,"User not logged in");let{data:s,error:n}=await e.from("EvaluationResult").select("id, createdAt").eq("user_id",t.id).order("createdAt",{ascending:!1}).limit(100);return s||[]}async function e7(e){let t=(0,p.createClientComponentClient)(),{data:s,error:n}=await t.from("EvaluationResult").select("*").eq("id",e).single();return s}function e6(e){var t;let{fetchId:s,preloadedData:a,recentEvals:i,defaultEvalId:c}=e,p=(0,m.useRouter)(),{table:j,setTable:v,setConfig:f,setEvalId:b,setAuthor:y}=et(),[Z,w]=l.useState(!1),[C,k]=l.useState(!1),[S,R]=l.useState(i||[]),N=async()=>{let e=await fetch("".concat(await (0,o.b)(),"/api/results"),{cache:"no-store"}),t=await e.json();return R(t.data),t.data},I=l.useCallback(async e=>{let t=await fetch("".concat(await (0,o.b)(),"/api/results/").concat(e),{cache:"no-store"}),s=await t.json();v(s.data.results.table),f(s.data.config),y(s.data.author),b(e)},[v,f,b,y]),E=async e=>{u.Ox?(w(!1),p.push("/eval/remote:".concat(encodeURIComponent(e)))):p.push("/eval/?evalId=".concat(encodeURIComponent(e)))},[P,F]=l.useState(c||(null===(t=S[0])||void 0===t?void 0:t.evalId)),T=(0,m.useSearchParams)(),M=T?T.get("evalId"):null;return(l.useEffect(()=>{if(M){let e=async()=>{await I(M),w(!0),F(M),N()};e()}else if(a){var e;v(null===(e=a.data.results)||void 0===e?void 0:e.table),f(a.data.config),y(a.data.author||null),w(!0)}else if(s){let e=async()=>{var e;let t="".concat(r,"/api/eval/").concat(s);console.log("Fetching eval from remote server",t);let n=await fetch(t);if(!n.ok){k(!0);return}let l=await n.json();v(null===(e=l.data.results)||void 0===e?void 0:e.table),f(l.data.config),y(l.data.author||null),w(!0)};e()}else if(u.T8)(0,o.b)().then(e=>{let t=(0,x.io)(e);return t.on("init",e=>{console.log("Initialized socket connection",e),w(!0),v(null==e?void 0:e.results.table),f(null==e?void 0:e.config),y((null==e?void 0:e.author)||null),N().then(e=>{var t,s;F(null===(t=e[0])||void 0===t?void 0:t.id),b(null===(s=e[0])||void 0===s?void 0:s.id)})}),t.on("update",e=>{console.log("Received data update",e),v(e.results.table),f(e.config),y(e.author||null),N().then(e=>{var t;let s=null===(t=e[0])||void 0===t?void 0:t.id;s&&(F(s),b(s))})}),()=>{t.disconnect()}});else if(u.Ox)e4().then(e=>{R(e.map(e=>({evalId:e.id,label:e.createdAt,createdAt:new Date(e.createdAt).getTime(),description:"None",numTests:-1}))),e.length>0&&e7(e[0].id).then(t=>{(0,g.Z)(t,"Eval not found");let s=t.results,n=t.config;F(e[0].id),v(s.table),f(n),y(null),w(!0)})});else{let e=async()=>{let e=await N();if(!(e.length>0))return(0,n.jsx)("div",{className:"notice",children:"No evals yet. Share some evals to this server and they will appear here."});{let t=await (0,o.b)(),s=e[0].id,n=await fetch("".concat(t,"/api/results/").concat(s)),l=await n.json();v(l.data.results.table),f(l.data.config),y(l.data.author||null),w(!0),F(s),b(s)}};e()}},[s,v,f,y,b,I,a,F,M]),C)?(0,n.jsx)("div",{className:"notice",children:"404 Eval not found"}):Z&&j?(0,n.jsx)(d,{children:(0,n.jsx)(e3,{defaultEvalId:P,recentEvals:S,onRecentEvalSelected:E})}):(0,n.jsxs)("div",{className:"notice",children:[(0,n.jsx)("div",{children:(0,n.jsx)(h.Z,{size:22})}),(0,n.jsx)("div",{children:"Waiting for eval data"})]})}s(94455)},52428:function(e,t,s){"use strict";s.d(t,{Ox:function(){return a},T8:function(){return l},eA:function(){return r}});var n=s(77580);let l=!n.env.NEXT_PUBLIC_PROMPTFOO_BUILD_STANDALONE_SERVER,a=!!n.env.NEXT_PUBLIC_PROMPTFOO_USE_SUPABASE,r=""},47887:function(e,t,s){"use strict";s.d(t,{o:function(){return a}});var n=s(79685),l=s(74595);let a=(0,n.Ue)()((0,l.tJ)((e,t)=>({env:{},testCases:[],description:"",providers:[],prompts:[],defaultTest:{},evaluateOptions:{},scenarios:[],setEnv:t=>e({env:t}),setTestCases:t=>e({testCases:t}),setDescription:t=>e({description:t}),setProviders:t=>e({providers:t}),setPrompts:t=>e({prompts:t}),setDefaultTest:t=>e({defaultTest:t}),setEvaluateOptions:t=>e({evaluateOptions:t}),setScenarios:t=>e({scenarios:t}),setStateFromConfig:t=>{let s={};t.description&&(s.description=t.description||""),t.tests&&(s.testCases=t.tests),t.providers&&(s.providers=t.providers),t.prompts&&("string"==typeof t.prompts?s.prompts=[t.prompts]:Array.isArray(t.prompts)?s.prompts=t.prompts.filter(e=>"string"==typeof e&&!e.endsWith(".txt")&&!e.endsWith(".json")&&!e.endsWith(".yaml")):console.warn("Invalid prompts config",t.prompts)),t.defaultTest&&(s.defaultTest=t.defaultTest),t.evaluateOptions&&(s.evaluateOptions=t.evaluateOptions),t.scenarios&&(s.scenarios=t.scenarios),e(s)},getTestSuite:()=>{let{description:e,testCases:s,providers:n,prompts:l,env:a,scenarios:r}=t();return{env:a,description:e,providers:n,prompts:l,tests:s,scenarios:r}}}),{name:"promptfoo",skipHydration:!0}))},55974:function(){},94455:function(){},16658:function(){},93207:function(){},58022:function(){}}]);