OpenAI Assistants API - Code Tutorial (NodeJs)

Поделиться
HTML-код
  • Опубликовано: 16 июн 2024
  • How to build a custom AI Assistants with OpenAI's Assistants API
    platform.openai.com/docs/assi...
    Create a custom AI assistant by OpenAI using Javascript (Nodejs). Let me know if you're interested in seeing the Python code version instead.
    Working code example on GitHub: github.com/hilmanski/assistan...
    This is a comprehensive tutorial on how to use OpenAI's Assistants API to create custom AI assistants. We'll learn the difference between Assistants API and the chat completion method, where Assistants API can retain conversation context, making it unique for every user.
    The tutorial includes a step-by-step guide on creating a marketing assistant that remembers user interactions, demonstrates how to generate thread IDs for unique conversations, send messages, and handle responses by running the assistant.
    The tutorial is geared towards developers seeking to integrate AI-driven conversation capabilities into their applications without relying on predefined chat models like ChatGPT. This way, you also won't need to build your custom LLM or prepare a vector database since the API can already remember the context conversation.
    00:00 Introduction to OpenAI's Assistants API
    00:36 Understanding Assistants API vs. Chat Completion
    01:11 Demo of a Marketing Assistant Example
    03:19 Creating and Managing Threads
    04:03 Step-by-Step Guide to Creating Your Own Assistant
    05:25 Implementing the Code: From Setup to Response Handling
    10:47 Demonstrating the Assistant in Action
    12:34 Conclusion and Final Thoughts
  • НаукаНаука

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

  • @KenshiDigital
    @KenshiDigital 18 часов назад

    Is it possible that when the user says “Thank you”, the ai assistant never responds again as like never responds to the conversation or maybe turns off? Is that possible?

  • @serpapi
    @serpapi  2 месяца назад

    Intro to function calling at OpenAI: ruclips.net/video/LyeiN2INS04/видео.html

  • @InnocenceVVX
    @InnocenceVVX 3 месяца назад

    What route would you advise to go from an unstructured individual pdf to a structured json output with the help of an api?

    • @serpapi
      @serpapi  3 месяца назад

      Hi, you can upload your PDFs on the OpenAI dashboard upon creating the assistant. For the output, you can use function calling feature from OpenAI ruclips.net/video/LyeiN2INS04/видео.html

    • @InnocenceVVX
      @InnocenceVVX 3 месяца назад

      @@serpapiThanks, this is very helpful!

  • @pabloduchovny6078
    @pabloduchovny6078 Месяц назад

    Great video! I'm having this error when the runAssistant function runs: 404 No assistant found with id 'asst_b..' I tried copying my id instead of using dotenv, I made a new assistant, but keep getting the same error. Thanks!

    • @serpapi
      @serpapi  Месяц назад

      Hi, thank you very much for your kind words! make sure you're using the correct OPENAI Key as well. I suggest to search and discuss OpenAI specific question on the forum here: community.openai.com/

  • @robgalvin7848
    @robgalvin7848 2 месяца назад

    @hillman Are you available for hire?