Use AI to chat with a relational SQL database with natural language!

  Рет қаралды 8,779

The Code Wolf

The Code Wolf

Күн бұрын

Demo app: github.com/alex-wolf-ps/chat-...
Intro to Azure OpenAI
• Learn Azure OpenAI - G...
My other AI videos:
Use AI to chat with a NoSQL database: • Use AI to chat with a ...
Learn to code a simple AI powered app: • Learn Azure OpenAI - B...
Learn to use AI to chat with your document data: • Learn Azure OpenAI - C...
Learn Azure OpenAI fundamentals: • Learn Azure OpenAI - G...
Learn how to authenticate to Azure OpenAI the RIGHT way: • Authenticate to Azure ...
In this video we'll explore how to use the powerful OpenAI gpt-4 model to search your SQL Database using natural language. GPT-4 excels at understanding natural language, and can even understand database schemas and produces code and SQL queries of its own. We'll explore a working demo, the app architecture and the code necessary to get this working.
00:00 Intro
01:09 App demo
05:53 Architecture
07:12 Database setup
09:17 AI service setup
10:57 Explore the app code
20:13 Search service concepts

Пікірлер: 55
@alexthecodewolf
@alexthecodewolf 20 күн бұрын
The demo app is now available here: github.com/alex-wolf-ps/chat-sql-data-demo Sorry for the delays!
@MarvinMarkhamBurgos
@MarvinMarkhamBurgos 11 күн бұрын
Is it possible to run this on my mac m3? How can I get it up on my localhost once I have the Azure DB and the Azure OpenAI service up?
@dipteshbose
@dipteshbose 9 күн бұрын
Awesome. Thanks
@Jake-td8nm
@Jake-td8nm 3 ай бұрын
AI has so much coverage, and 99% of it is either "here's a photorealistic image that has 13.5 fingers" or even worse the generic "You should be terrified because AI is coming!" both of which hold no value, provide no context, and don't show any use case that's valuable to 95% of individuals, and 100% of enterprise. Conversely, this video shows an actual coherent use of AI that could blow up and be super valuable - actually improving the productivity of people using it. Bravo!
@alexthecodewolf
@alexthecodewolf 3 ай бұрын
Thanks, I try to showcase real world demos instead of just flashy but useless concepts
@pwakabi
@pwakabi 7 күн бұрын
Excellent piece
@sindhupillai1354
@sindhupillai1354 15 күн бұрын
Good starting point for the people who are exploring more with Gen AI. Thanks for sharing valuable real time use-case. I am in 'Subscribed'. Hurray! waiting for more such use cases.
@511Burak
@511Burak 3 ай бұрын
Hi thank you for sharing. Is there a way to get the sample code?
@alexclark6777
@alexclark6777 9 күн бұрын
Remember Microsoft English Query? Pepperidge Farm Remembers...
@lshagh6045
@lshagh6045 2 ай бұрын
That was very useful and professional. Thank you indeed and thanks for sharing 👍
@alexthecodewolf
@alexthecodewolf 2 ай бұрын
Thanks I appreciate it!
@ShaharNardiaAllOverTheNet
@ShaharNardiaAllOverTheNet Ай бұрын
thank you very much wolf🙏 exactly what I am coding right now for my customer
@alexthecodewolf
@alexthecodewolf Ай бұрын
Thank you so much, generous!
@bengroseclose1795
@bengroseclose1795 3 ай бұрын
Your a helpful cheerful youtuber :D
@twenty4marc306
@twenty4marc306 Ай бұрын
Hi, do you have a public demo?
@andrewherrick879
@andrewherrick879 3 ай бұрын
hi this is pretty cool. is your code available open source? i checked your GH but didn't see it. thanks!
@mouradaissani8957
@mouradaissani8957 3 ай бұрын
very good, thank you 🐺
@alexthecodewolf
@alexthecodewolf 3 ай бұрын
Glad you enjoyed it
@mouradaissani8957
@mouradaissani8957 3 ай бұрын
BTW ; 11:00 warning , ur openaikey is exposed ;) @@alexthecodewolf
@liammcmullen4497
@liammcmullen4497 3 ай бұрын
Thanks
@alexthecodewolf
@alexthecodewolf 3 ай бұрын
Thanks so much for your support! It means a lot.
@sajjadmussani
@sajjadmussani Ай бұрын
very informative. can you please share the code of your Razor app?
@rubberuk
@rubberuk 3 ай бұрын
Excellent video! Have you got a link to source code? thank you.
@sinamohammadpourinaeim1058
@sinamohammadpourinaeim1058 26 күн бұрын
Hi Code Wolf Thanks for your useful video, Is there any offline AI Service to use the same thing in our local machine or our own sever?
@alexthecodewolf
@alexthecodewolf 19 күн бұрын
Hey, thanks for watching. There are definitely local AI models, but I haven't worked with them enough to recommend any sort of solution for this. Would probably be a good topic to research for another video :)
@applepeel1662
@applepeel1662 3 ай бұрын
Hey! Please share the source code! This is honestly really cool
@jyothirmaimachavaram4307
@jyothirmaimachavaram4307 Ай бұрын
Hello, Could you please let me know where can I get the source code for it?
@Joly0
@Joly0 4 күн бұрын
Is it possible to have a version, that works without azure? So using the normal openai api with a key and maybe other llm providers such as ollama?
@alexthecodewolf
@alexthecodewolf 4 күн бұрын
I actually just made a video about this using Ollama, hah. It shows this same setup at the end using codellama kzbin.info/www/bejne/Z2iaootsotWsg8k The concepts in this video should work with any model that is skilled at text to code (such as code llama) and a SQL database of some sort. You'll have to experiment with different models and prompts to see which works best.
@TellaTrix
@TellaTrix 3 ай бұрын
Wowo ! No more developer required to binding data and complex query.
@alexthecodewolf
@alexthecodewolf 3 ай бұрын
Yeah one of my favorite things about this is it can help devs as much as analysts because it can write your sql queries for you....to some extent :)
@aeromeme
@aeromeme Ай бұрын
Hi, could be possible to have database definition in azure storage file so that way we aboid large prompt, or is there any other solution.
@alexthecodewolf
@alexthecodewolf Ай бұрын
Hey, good question, this is something I'm also looking into myself - how to only have to send the schema once and be able to update and maintain that schema in an active context. So far I haven't found a solution I'm happy with yet but I'll respond here again if I do. The models are getting better at deconstructing large inputs all the time, but I understand from a cost perspective its not desirable.
@ShaharNardiaAllOverTheNet
@ShaharNardiaAllOverTheNet Ай бұрын
@@alexthecodewolf I tried using the assistant for that - sent him all the scheme in JSON files but it sucks 😔
@feelzzgaming6306
@feelzzgaming6306 Ай бұрын
Hi @alexthecodewolf ! Thanks for the video. I have two questions: Is there a way to use OpenAI with and SQL database, without using the Azure OpenAI Service? It is currently only for people and companies who have requested special access. So Im wondering if there is a workout where I can use the OpenAI's API directly towards my own Azure SQL Database, and not have to rely on the OpenAI service on Azure? Number 2: Do you have the source code anywhere? Hope you will reply ASAP as im currently working on a project that has come to a halt.. Thank you very much! :D
@alexthecodewolf
@alexthecodewolf Ай бұрын
Hey, thanks for watching. You should be able to use the regular OpenAI service (non Azure) with this exact same approach, there might just be some slight differences in the code and authentication. I'm not sure how pricing differs between them. Currently this code is part of a separate project I'm working on that I adjusted for this demo, so at this point I can't distribute the source code to for a few reasons, sorry!
@feelzzgaming6306
@feelzzgaming6306 Ай бұрын
@@alexthecodewolf any idea what the code for that approach would Look like? Spent all day today, but to no avail.. also, thanks for the response!!
@alexthecodewolf
@alexthecodewolf 26 күн бұрын
Due to the requests here I'm working on getting the source code available for this, it was tied to a project I couldn't release but am working that out.
@mukshobhit
@mukshobhit 24 күн бұрын
Thanks, did you get chance to get repo?
@user-wt5uy9pn5e
@user-wt5uy9pn5e 20 күн бұрын
Thank you Alex, looking forward to learn how to do it
@alexthecodewolf
@alexthecodewolf 20 күн бұрын
@@mukshobhit It's available now, thanks.
@alexthecodewolf
@alexthecodewolf 20 күн бұрын
It's available now, thanks.
@user-wt5uy9pn5e
@user-wt5uy9pn5e 19 күн бұрын
@@alexthecodewolf Thank you Alex, grateful for making it available
@mohan007ish
@mohan007ish 2 ай бұрын
Can we use GPT-35-Turbo instead of GPT 4?
@alexthecodewolf
@alexthecodewolf 2 ай бұрын
You can certainly try using GPT-35-turbo, but GPT-4 included major improvements to understanding and responding with structural content. However it'd be interesting to see how well 35-turbo does in comparison, I didn't actually try that myself.
@polly28-9
@polly28-9 17 күн бұрын
Thanks a lot! How about huge database? We send the whole schema with the initial prompt which costs a lot? How to solve this problem with huge database?
@alexthecodewolf
@alexthecodewolf 17 күн бұрын
This can be tricky - I'd recommend this solution for small to medium size databases, I have some other content coming for larger database solutions. However, theoretically this solution can also work with large databases if the table structure is consistent/standardized. You'd probably need to use one of the large GPT models though, such as the 32k GPT-4, which accept higher volumes of tokens. I've been trying to figure out if there's a way to have the AI Model "store" or remember the initial schema prompt, but I haven't been able to find an ideal solution for that.
@polly28-9
@polly28-9 17 күн бұрын
@@alexthecodewolf Thanks a lot! Please, if you find some ways to have the AI model "store" or remember the initial schema, make such a video or write to me. I'm looking forward to it. Thank you!😀
@hirenshekhda3567
@hirenshekhda3567 Ай бұрын
Hello sir can you please source code for education purposes? Its working universe database?
@goodtimeforever2035
@goodtimeforever2035 9 күн бұрын
Hey @alexthecodewolf - Can you able do the same video using AWS ?
@alexthecodewolf
@alexthecodewolf 8 күн бұрын
Hey, this should work using any powerful large language model and SQL based database, did you have a specific scenario in mind?
@THEDTSMAN
@THEDTSMAN 2 ай бұрын
What happens if someone says “delete all the data” ?
@alexthecodewolf
@alexthecodewolf 2 ай бұрын
That's a really valid concern, you'd want to make sure the app is running as a user that only has read permissions.
@Baraka-yl2dp
@Baraka-yl2dp Ай бұрын
Code Wolf, can you please share your source code?
@alexanderkamenev5529
@alexanderkamenev5529 2 ай бұрын
GIT REPO IF YOU DONT MIND PLEASE
Authenticate to Azure OpenAI the right way using Microsoft Entra ID
18:27
Hands-On Power BI Tutorial 📊 Beginner to Pro 2023 Edition [Full Course] ⚡
3:02:18
Cat story: from hate to love! 😻 #cat #cute #kitten
00:40
Stocat
Рет қаралды 14 МЛН
[Vowel]물고기는 물에서 살아야 해🐟🤣Fish have to live in the water #funny
00:53
WHY DOES SHE HAVE A REWARD? #youtubecreatorawards
00:41
Levsob
Рет қаралды 35 МЛН
Kubernetes Operator simply explained in 10 mins
10:09
TechWorld with Nana
Рет қаралды 208 М.
Chat with MySQL Database with Python | LangChain Tutorial
37:11
Alejandro AO - Software & Ai
Рет қаралды 29 М.
Microsoft Build 2024 - .NET Recap in 6 minutes!
6:40
The Code Wolf
Рет қаралды 10 М.
Chat with Your SQL Data Using ChatGPT
21:31
MG
Рет қаралды 76 М.
Unlimited AI Agents running locally with Ollama & AnythingLLM
15:21
How to train a model to generate image embeddings from scratch
51:44
Don't Buy a Honda CR-V or Toyota Rav-4 Before Watching This
10:11
Scotty Kilmer
Рет қаралды 2,1 МЛН
Chat with SQL and Tabular Databases using LLM Agents (DON'T USE RAG!)
58:54
Vector Databases simply explained! (Embeddings & Indexes)
4:23
AssemblyAI
Рет қаралды 276 М.
Куда пропал 3D Touch? #apple #iphone
0:51
Не шарю!
Рет қаралды 694 М.
как спасти усилитель?
0:35
KS Customs
Рет қаралды 506 М.
ПК с Авито за 3000р
0:58
ЖЕЛЕЗНЫЙ КОРОЛЬ
Рет қаралды 1,5 МЛН
МОЖНО ЛИ заряжать AirPods в чехле 🧐😱🧐 #airpods #applewatch #dyson
0:22
Apple_calls РЕПЛИКА №1 В РФ
Рет қаралды 21 М.
How To Unlock Your iphone With Your Voice
0:34
요루퐁 yorupong
Рет қаралды 14 МЛН
Обзор игрового компьютера Макса 2в1
23:34