Search Unity

  1. We are migrating the Unity Forums to Unity Discussions. On July 12, the Unity Forums will become read-only. On July 15, Unity Discussions will become read-only until July 18, when the new design and the migrated forum contents will go live. Read our full announcement for more information and let us know if you have any questions.

Question Issues with GPT-4 timeout

Discussion in 'Cloud Code' started by mChapuis, Feb 27, 2024.

  1. mChapuis

    mChapuis

    Joined:
    Jun 23, 2014
    Posts:
    23
    Hello,
    I'm experiencing timeouts when calling the OpenAI API for GPT-4 via C# Cloud Code. GPT-3.5 turbo works fine but the results aren’t as advanced. It appears there's a script run-time limit as mentioned in the documentation.

    Any insights on mitigating these timeouts?
     
  2. MaximeDelecourt

    MaximeDelecourt

    Unity Technologies

    Joined:
    Oct 21, 2021
    Posts:
    21
    Hi mChapuis,
    What kind of duration do you think you would require there?
    Know that we will be working on customizable limits for Cloud Code in a near future that will allow you to perform what you want to do there.
     
  3. mChapuis

    mChapuis

    Joined:
    Jun 23, 2014
    Posts:
    23
    Hi Maxime!

    I managed to tweak my prompt and I got ok results from GPT3.5 turbo. I'll wait until Openai optimize GPT4 to use it. They seem to be really quick at updating their models so I don't think it's going to take years.

    Thank you for your quick response!
     
  4. MaximeDelecourt

    MaximeDelecourt

    Unity Technologies

    Joined:
    Oct 21, 2021
    Posts:
    21
    Hello, good to know!
    I was wondering what duration you would expect before timeout? 30 sec, a minute, more? based on your use cases.
     
  5. mChapuis

    mChapuis

    Joined:
    Jun 23, 2014
    Posts:
    23
    I believe it should be 15 seconds or less for immediate results. If it's taking too long, I can ask the user to come back later. Making something load for longer is not going to work I think..