Can an API call start a playground style session, or is it a one time thing?

I am really new to OpenAI and coding.

I made a few Alexa applications using voiceflow no-coding designer, and I want to have Alexa talking to GPT-3

I managed to do successful API calls after a few hours trial and error, I just copy pasted the code from the OpenAI documentation.

My API call is very simple, send text and get a reply. It’s just a 1 time thing so far, but I want to build up a conversation over multiple API calls where GPT-3 saves the previous data.

I want to know if my API call is starting a session with GPT-3, (like I see when I am using Playground) or if it gets wiped and starts fresh every time.

How do I open a conversation that persists over several API calls? If that is possible, how do I clear the data when the conversation is finished?

If I can make a “session” then is it possible to use an API call to send the data from the full conversation to be saved? I am looking at the API to create a google text document.

Every time you create a new request, and pass in all the input data explicitly. There’s no notion of a session on the playground. Each subsequent call to the model will pass everything you see inside the playground text window as input.

Thanks for the reply.

I see, that’s how the playground works, everything is sent each time.

So it looks like I need to upload a text file with the initial prompt to begin. Then keep adding the input and output sentences to that prompt file and uploading it each time to progress a conversation.

I want to make it possible for my English learners to have a conversation using speech to text and text to speech via a smart speaker, so there won’t be any visible text, but I want to have a transcript file.

I saw it is possible to send whole files. Will that work with a POST API call for completion?