Create REST API using NestJS(NodeJS) and ChatGPT

Поделиться
HTML-код
  • Опубликовано: 8 ноя 2024

Комментарии • 17

  • @MagicHappyPotato
    @MagicHappyPotato Год назад +2

    Wow, it's really useful video. Thanks for sharing!

  • @gokselozkazanc2917
    @gokselozkazanc2917 Год назад +2

    Thanks a lot, I followed the steps and it worked.
    Could you please provide the test file for the service? I tried it but could not make it work.

    • @computingpower
      @computingpower  Год назад +1

      Hello! Sure, I can make some unit tests and end-to-end tests for the application and share them in the Github repository :)!

    • @gokselozkazanc2917
      @gokselozkazanc2917 Год назад

      @@computingpower Thanks a lot!
      Could you also share the github repo. I could not find it here in the description.

    • @computingpower
      @computingpower  Год назад

      @@gokselozkazanc2917 github.com/Mpcsj-Computing/NestJsRestAPIChatGpt

    • @computingpower
      @computingpower  Год назад

      I just updated the main branch of the repository to include unit tests and end-to-end tests. You can run "yarn test" to run unit and integration tests and "yarn test:e2e" to run end-to-end tests

  • @wassimbenr
    @wassimbenr Год назад +2

    Great video! just one question, When I provide a complicated question that require a lot long response, what should I do to receive all the information?
    Because I only get the first line of the response! thank you

    • @computingpower
      @computingpower  Год назад

      Thank you Wassim! Have you checked if the option "see more" Is available?

  • @PigtailAIDevelopers
    @PigtailAIDevelopers Год назад

    Thanks a lot! Can you tell me how can I use "gpt-3.5-turbo" as model, when I change to that model throws an error. Thanks again

    • @computingpower
      @computingpower  Год назад

      Hello. For using "gpt-3.5-turbo" or "gpt-4" (if OpenAI gave access to you), you must use the Chat Completion API: platform.openai.com/docs/guides/chat
      which is different from this one.

    • @computingpower
      @computingpower  Год назад +1

      I forgot to mention that I have a new video using gpt3.5-turbo and Python for an AI Voice assistant project:
      ruclips.net/video/UCuaPy45F7I/видео.html

    • @PigtailAIDevelopers
      @PigtailAIDevelopers Год назад

      @@computingpower Super!! Thanks dude. I will watch it

  • @the_tech_senseii
    @the_tech_senseii Год назад +1

    And the test?

    • @computingpower
      @computingpower  Год назад

      I haven't worked on the tests for this video, but I can do it in another video.

  • @JBRandria
    @JBRandria Год назад +1

    thank you , but when i try , i don't have response in body , just 201 Created as Status

    • @computingpower
      @computingpower  Год назад

      Hello, what API call did you try? The one for listing the models or getting an answer for ChatGPT?

    • @JBRandria
      @JBRandria Год назад +1

      @@computingpower Finaly i have to change :
      /*const params: CreateCompletionRequest = {
      prompt: input.question,
      model: input.getModelId(),
      temperature: input.getTemperature(),
      max_tokens: input.getMaxTokens(),
      };*/
      to
      const params: CreateCompletionRequest = {
      prompt: input.question,
      model: 'text-davinci-003',
      temperature: 0.9,
      max_tokens: 2048,
      }
      there is an error with input.getTemperature(),input.getModelId() and input.getMaxTokens(),