Chat GPT Api response length

Been playing around with the chat GPT api.
Interfacing is pretty simple but i only get a response of around 20 characters. Anyone any ideas why?

if I ask

i only get about a 20 character response

Found the issue, had to increase max_tokens

1 Like

Remember the token size has to be adjusted for the length of the input. They are combined as a total and if exceeded an error will be returned. If you have a token size of 2048 and the input is 100 characters, the token then becomes 2148, and you may get an error. Adjust accordingly. Or add a limit to the input.

Yes, had max_tokens set really low, now set to 2000 and it’s working perfectly

Verse 1:
I’m here to show you the power of Wappler,
It’s the best way to create a web app, faster.
No more coding and debugging,
Just drag and drop and you’re good to go.

Chorus:
Wappler, Wappler,
It’s the best way to build a web app.
Wappler, Wappler,
It’s the fastest way to go.

Verse 2:
The interface is easy to use,
Just click and drag to get the job done.
You can create a website in no time,
No need to worry about coding and design.

Chorus:
Wappler, Wappler,
It’s the best way to build a web app.
Wappler, Wappler,
It’s the fastest way to go.

Verse 3:
You can create a website with ease,
No need to worry about the complexity.
It’s the perfect tool to get the job done,
Wappler will make it look like it’s from the pros.

Chorus:
Wappler, Wappler,
It’s the best way to build a web app.
Wappler, Wappler,
It’s the fastest way to go.

8 Likes

Do you have any plans for doing a short tutorial on this subject Brian…?

If people want one, it really is just a simple API call but happy to oblige if useful

4 Likes

You could also ask Chat GPT to create the code for you @TMR

:slight_smile:

1 Like

That was actually what I did, asked for a .js api solution and that gave me the parameters then I simply transposed them into a wappler API action.

1 Like

It’d be really useful, the Wappler API docs aren’t as good as your tutorials. Ive been dabbling with it but cant seem to get it right - first time I’ve used any APIs.

Will try to put something together tomorrow.

4 Likes