High cost for 15 consultations

Hey guys!

I made approximately 15 queries via API and it generated a very high cost.
And they were basic queries, such as generating a response to a simple text. Am I doing something wrong or is the cost just that high?

Scroll down to:

Daily usage breakdown (UTC)

Select that day and show a screenshot of that please.

1 Like

How were you using the API key? Putting it into someone else’s software or site for the key to be stolen and abused?

The orange color is for instructgpt models, which is gpt-3.5-turbo-instruct in the newest models, but may also be the category for text-davinci-003, still only $0.0200 / 1K tokens.

When selecting the day at the bottom there is a breakdown for the number of uses every five minutes.

I was using langchain to read a pdf and summarize it. And the model was not set. After setting the model, the problem was resolved.

new OpenAI({
apiKey: process.env.OPENAI_API_KEY,
temperature: 0.3,
model_name: ‘gpt-3.5-turbo-4k’,
});

Langchain can be autonomous and make the bajillion calls on your behalf, like the 1000 token chunks x 2640 if you say “read this PDF for me”.

Somehow this software is often found by new API users as some solution to their problems instead of it actually being a problem looking for a use.

2 Likes

langchain really should have a max token/cost for main task…

I have been working with web development for 15 years. I’m starting out in the world of artificial intelligence. I am developing a project aimed at Brazilian law. To do this, I need to better understand how AI works and the best flow to teach AI to consult Brazilian laws and help lawyers prepare theses, summarize processes, etc…