Build Your Own ChatGPT with Ruby on Rails 7 and OpenAI API

Sdílet
Vložit
  • čas přidán 28. 09. 2023
  • 👋 Hey there, tech enthusiasts! In today's tutorial, I'll walk you through creating your very own ChatGPT clone using Ruby on Rails 7.
    Follow along on Substack 👇
    seankeever.substack.com/p/min...
    🛠 Tech Stack:
    - Ruby on Rails 7
    - OpenAI
    - Stimulus
    🎯 Key Takeaways:
    - How to set up a new Rails app with necessary dependencies.
    - Adding chat functionality via OpenAI API.
    - Making the UI interactive with Stimulus.
    📦 GitHub Repo:
    github.com/swkeever/mini-chatgpt
    📚 Resources:
    Rails Documentation: guides.rubyonrails.org/
    OpenAI API Docs: platform.openai.com/docs/api-...
    Stimulus Reference: stimulus.hotwired.dev/referen...
    👤 About Me:
    I'm Sean Keever, a professional software engineer with a knack for breaking down complex topics into easily digestible pieces. Feel free to connect with me!
    If you found this tutorial useful, don't forget to hit the 👍 button and subscribe for more tech tutorials!
    #rubyonrails
  • Věda a technologie

Komentáře • 17

  • @quinnmclaughlin3818
    @quinnmclaughlin3818 Před 13 dny +1

    Love your code approach and your video. In 5 minutes. Hats off.

    • @SkiesDev
      @SkiesDev  Před 3 dny

      Thank you! I appreciate the comment

  • @SeanLazer
    @SeanLazer Před 6 měsíci +3

    Thanks for keeping this short and sweet!

  • @jav0
    @jav0 Před 9 měsíci +1

    Great content ;)

  • @sadiqmmm
    @sadiqmmm Před 7 měsíci +1

    Awesome video.

  • @pauljdavis
    @pauljdavis Před 5 měsíci

    Super helpful. Thanks so much. Any updates to this, or ideas of how you would do it differently/better today?

    • @SkiesDev
      @SkiesDev  Před 5 měsíci

      Thanks for the feedback! Whether I would do something different depends on the requirements of the app, but using SSE is still a viable option and probably what I’d look to first.

  • @cololo12
    @cololo12 Před 4 měsíci

    Amazing!! You know how to make this but with your own data, pdf?
    I can't find any info

    • @SkiesDev
      @SkiesDev  Před 4 měsíci

      I would take a look at fine tuning: platform.openai.com/docs/guides/fine-tuning

  • @ir8293
    @ir8293 Před 4 měsíci

    This does not scale beyond the web workers does it? So basically serve something like 8 users in parallel and then timeout for everyone else, right?

    • @SkiesDev
      @SkiesDev  Před 3 měsíci

      That’s a great question. Thanks! I confess I haven’t stress tested the tutorial implementation. However, OpenAI itself utilizes SSE to power the ChatGPT API to millions of users. So I don’t think it would be limited to a low number like 8, but it would probably depend on how much memory your server has.

  • @mycode0
    @mycode0 Před 3 měsíci

    Considering that this will hold the server until the whole response is rendered how well do you think it will scale. For example if 10 users make a request using this approach will the server start to struggle. Sorry if the question is stupid

    • @SkiesDev
      @SkiesDev  Před 3 měsíci

      SSE can handle multiple concurrent connections using a single HTTP connection for each client. While each connection does use server resources, modern servers, especially those running asynchronous technologies, can manage many connections at once. For handling more users, techniques like load balancing and horizontal scaling can improve scalability.

  • @mattgiaro
    @mattgiaro Před 5 měsíci

    Hi Sean
    This video is dope!
    Is there a way to contact you for Ruby on Rails mentoring/coaching?

    • @SkiesDev
      @SkiesDev  Před 5 měsíci

      Appreciate the feedback Matt! I don’t have bandwidth for coaching right now but I’m curious what topics are you interested in learning about?