Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add cost, latency, tokens to playground #1096

Conversation

bekossy
Copy link
Member

@bekossy bekossy commented Dec 22, 2023

Description

Add cost, latency, tokens to playground

Related Issue

Issue #988
Sub issue #1059

@bekossy bekossy linked an issue Dec 24, 2023 that may be closed by this pull request
@bekossy bekossy marked this pull request as ready for review December 25, 2023 15:34
@mmabrouk
Copy link
Member

Thanks for the PR @bekossy
It seems the cypress tests in the playground are failing:

  Playground Prompt Test
App name: AM9aE
    1) Should test prompt functionality in the Playground


  0 passing (16s)
  1 failing

  1) Playground Prompt Test
       Should test prompt functionality in the Playground:
     TypeError: The following error originated from your application code, not from Cypress.

  > Cannot read properties of undefined (reading 'total_tokens')

When Cypress detects uncaught errors originating from your application it will automatically fail the current test.

This behavior is configurable, and you can choose to turn this off by listening to the `uncaught:exception` event.

https://on.cypress.io/uncaught-exception-from-application
      at BoxComponent (webpack-internal:///./src/components/Playground/Views/TestView.tsx:194:97)
      at renderWithHooks (webpack-internal:///./node_modules/react-dom/cjs/react-dom.development.js:16305:18)
      at updateFunctionComponent (webpack-internal:///./node_modules/react-dom/cjs/react-dom.development.js:19583:20)
      at beginWork (webpack-internal:///./node_modules/react-dom/cjs/react-dom.development.js:21596:16)
      at HTMLUnknownElement.callCallback (webpack-internal:///./node_modules/react-dom/cjs/react-dom.development.js:4164:14)
      at Object.invokeGuardedCallbackDev (webpack-internal:///./node_modules/react-dom/cjs/react-dom.development.js:4213:16)
      at invokeGuardedCallback (webpack-internal:///./node_modules/react-dom/cjs/react-dom.development.js:4277:31)
      at beginWork$1 (webpack-internal:///./node_modules/react-dom/cjs/react-dom.development.js:27446:7)
      at performUnitOfWork (webpack-internal:///./node_modules/react-dom/cjs/react-dom.development.js:26552:12)
      at workLoopSync (webpack-internal:///./node_modules/react-dom/cjs/react-dom.development.js:26461:5)
      at renderRootSync (webpack-internal:///./node_modules/react-dom/cjs/react-dom.development.js:26429:7)
      at performConcurrentWorkOnRoot (webpack-internal:///./node_modules/react-dom/cjs/react-dom.development.js:25733:74)
      at workLoop (webpack-internal:///./node_modules/scheduler/cjs/scheduler.development.js:266:34)
      at flushWork (webpack-internal:///./node_modules/scheduler/cjs/scheduler.development.js:239:14)
      at MessagePort.performWorkUntilDeadline (webpack-internal:///./node_modules/scheduler/cjs/scheduler.development.js:533:21)

Copy link
Member

@mmabrouk mmabrouk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the PR @bekossy !

@mmabrouk mmabrouk merged commit 01ba0d1 into feature/add-metrics-to-sdk-playground-evaluation Jan 4, 2024
3 of 4 checks passed
@bekossy bekossy deleted the Sub-issue-1059/-Add-cost,-latency,-tokens-to-playground branch January 4, 2024 11:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Sub Issue] Add cost, latency, tokens to playground
2 participants