Giter Site home page Giter Site logo

令牌计算不正确 about one-api HOT 7 CLOSED

songquanpeng avatar songquanpeng commented on May 19, 2024
令牌计算不正确

from one-api.

Comments (7)

aiastia avatar aiastia commented on May 19, 2024

1、另外删除 令牌后 额度 视乎虚无了…
2 删除token 没二次确认 …

from one-api.

songquanpeng avatar songquanpeng commented on May 19, 2024
  1. 我也感觉令牌的消耗有点问题。
  2. 删除令牌后按理说无法使用了才对?难道你删完之后还可以用啊》
  3. 二次确认这个之后加上。

谢谢反馈,稍后处理。

from one-api.

aiastia avatar aiastia commented on May 19, 2024

视乎是夹带了上下文 😅> 我发送了一句话 (12个中文 消耗了 网站显示 用了2k的令牌。我用 openai token 计算也才26个

from one-api.

aiastia avatar aiastia commented on May 19, 2024

删除令牌

1。3.5好像是计算发送和上次回复(如果有)的吧。感觉 是吧回复的也计算进去了
2。应该是不能用 ,不过目前系统是有兑换按钮 目前如果 删除 了 兑换的次数不就找不回来了 🤔

from one-api.

songquanpeng avatar songquanpeng commented on May 19, 2024
  1. 是的,会把上下文算进去的,OpenAI 也是这样计费的,所以如果上下文很长是有可能一次消耗很多的。
  2. 是哦,删除后应该把剩余次数返还给用户,我忘记考虑这一点了。

from one-api.

songquanpeng avatar songquanpeng commented on May 19, 2024

我再次测试了一下,token 计算是正确的。
命令 ChatGPT 返回我们的输入,这样可以固定其输出。stream 模式和非 stream 模式下的 token 数一致:
image

from one-api.

songquanpeng avatar songquanpeng commented on May 19, 2024

删除时返还剩余额度已实现。

from one-api.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.