Video wird geladen...

Video konnte nicht geladen werden

Zur Startseite

This is a very clever idea to use an LLM with your SQL data. SQL + AI has been tried before, but one of the best parts of this solution is getting the same exact OpenAI's completion API. In other words: You are now talking to an LLM that...

230,457 Aufrufe • vor 1 Jahr •via X (Twitter)

10 Kommentare

Profilbild von James Blackwell
James Blackwellvor 1 Jahr

Just dump your schema and open it in Cursor. Works brilliantly. I’ve got 20 large tables and Cursor automatically searches for relevant ones

Profilbild von Santiago
Santiagovor 1 Jahr

Well, that would work during development time when you want to explore a database. But I was thinking during runtime.

Profilbild von Petr Lazecky
Petr Lazeckyvor 1 Jahr

Do not waste time on this. Works only for demos.

Profilbild von Santiago
Santiagovor 1 Jahr

Does it? Please, say more.

Profilbild von Brandon Tyree
Brandon Tyreevor 1 Jahr

whenever I see sql and ai I mention @vannadotai and @zain_hoda

Profilbild von The Monk Dev
The Monk Devvor 1 Jahr

SQL + AI is gonna be revolutionary.

Profilbild von iDare e/acc
iDare e/accvor 1 Jahr

I'm using SQLite for an LLM payload. That's all I'll say at the moment.

Profilbild von Stu Frost
Stu Frostvor 1 Jahr

I can't see this working for anything but the simplest of databases. It's hard enough for humans to write efficient SQL that returns correct results for complex data structures. Letting an LLM loose is a recipe for disaster IMHO.

Profilbild von Jim
Jimvor 1 Jahr

Awesome use case, the course on database agents was my first exposure to this. Something I don’t fully get is how these are RAG use cases.

Profilbild von SuperBadGPT
SuperBadGPTvor 1 Jahr

I think there is something here, Declarative Languages and AI combo seems to be the sweet spot. Given the LLM is prediction machine - they are perhaps better at "what to do" (Declarative) than "how to do" (Imperative).

Ähnliche Videos

Your agents can't keep up with real-time data. Especially when it's scattered across dozens of sources. Most teams waste weeks building custom connectors for every database, API, and data warehouse. Then they build ETL pipelines to sync everything. By the time your agent retrieves the data, it's already outdated. Picture this: Your Postgres database updated 5 minutes ago. Your MongoDB collection changed 2 minutes ago. Your agent is still pulling from yesterday's snapshot. This is why most production RAG systems fail. There's a better approach: MindsDB is an open-source AI platform with a federated data engine that lets you query multiple data sources in real-time using SQL - without moving any data. Here's what makes it different: ↳ Your data stays in place. No ETL pipelines or data duplication ↳ Query Postgres, MongoDB, REST APIs, and more using consistent SQL ↳ JOIN across different sources in real-time with a unified interface ↳ Works with both structured and un-structured data And here's the best part: You don't even need to write SQL. Just describe what you want in plain English, and MindsDB converts it to SQL automatically. The system does all the heavy lifting. The breakthrough for AI agents is simple: When data updates at the source, your agent gets fresh results immediately. No sync delays. No stale embeddings. No custom code for each integration. You can literally write a SQL query that joins a Postgres table with a MongoDB collection and gets live results. This is what production AI applications need but rarely get. In this video, I give you a complete walkthrough of what we just discussed and how to actually do it. Make sure you watch this till the end. I've shared the link to MindsDB's GitHub repo in the next tweet!

Akshay 🚀

65,672 Aufrufe • vor 7 Monaten

How can you solve complex tasks using a Large Language Model? Here is a 2-minute introduction to everything you need to know to 10x the quality of your results. Let's talk about three techniques, in order of complexity, starting with the easiest one: • In-Context Learning • Indexing + In-Context Learning • Fine-tuning In-Context Learning The team that trained GPT-3 found something they couldn't explain: You can condition a model using examples of how you want it to behave. I included an example prompt in the attached video. You can "teach" the model how you want it to interpret questions, select the correct answers, and format the results by giving a few examples. You can also give specific knowledge to the model that will be helpful when formulating answers. We call this approach "grounding the model." There's another example in the video. Indexing + In-Context Learning Unfortunately, there is a limit to how much data you can include in a prompt. We call this the "context size." One version of GPT-4 supports a context of approximately 6,000 words, while the other supports 25,000 words. Although this sounds like a lot, many applications need more than that. Imagine you wrote a book and want to build an application to answer any questions about your story. What happens if your book is longer than the context? That's where Indexing comes in. Using a model, you can turn every book passage into an embedding. These are vectors, numbers that "encode" the passage's text. You can then store these embeddings in a particular database that supports fast retrieval of these vectors. You can then turn any question into an embedding and search the database for the list of passages that are similar to that query. Instead of using the entire book to ask the model, you can now use the relevant passages as in-context information, effectively working around the context size limitation. Fine-tuning Fine-tuning can give you an extra boost to get reliable outputs from your LLM. It is, however, the most complex approach on the list. There are different approaches to fine-tuning a model with your data. A popular technique is to process your data with your LLM and use the outputs to train a new classifier that solves your specific task. Notice that here you aren't modifying the LLM. Instead, you are chaining it with your trained classifier. Another approach is to modify the parameters of the LLM using your data. Think of this as "rewiring" the model in a way that solves your particular task. The results and costs will vary depending on how many layers you want to fine-tune from the original model. Many companies think that fine-tuning is the solution to their problems. In my experience, many will benefit from exploring the other two approaches. I love explaining Machine Learning and Artificial Intelligence ideas. If you enjoy in-depth content like this, follow me Santiago so you don't miss what comes next.

Santiago

384,495 Aufrufe • vor 3 Jahren

Here is how you can install an open-source, enterprise-grade RAG system on your server (with the best document understanding I've seen.) First, something obvious to anyone trying to sell RAG in the market: You are crazy if you think companies will let their data travel to a hosted model. No one wants to send their data anywhere (those who do haven't found an alternative.) Every single company would rather have an air-gapped system with no internet access. GroundX is an open-source RAG system that you can run on your servers (or any cloud provider, as long as you have access to GPUs) and works without a network. (If the military wants to do RAG, this is precisely what they will be looking for.) I installed GroundX on my AWS account and recorded a video to show you how to use it. There are two services you can use: 1. Ingest: This service uses a pretrained vision model to ingest and understand your knowledge base. 2. Search: This service combines text and vector search with a fine-tuned re-ranker model to retrieve information from your knowledge base. A quick note about the Ingest service: 99% of people think they need better "retrieval" mechanisms. I think they need better "ingestion." That's where this service comes in! Ingest "understands" your documents in a way I haven't seen before. After you try it, you'll realize why showing your LLM your raw documents is a bad idea. In the video, I use a free tool called X-Ray to test a document and understand how the Ingest service breaks it down. You can access this tool by signing up for a free GroundX cloud account and uploading your documents. You'll see a bit more about this in the video.

Santiago

89,624 Aufrufe • vor 1 Jahr

"You can either produce excellence or you can avoid criticism. But you cannot do both of those. The reason that you don't have certain excellence that you want is because you are afraid of getting criticized. You are afraid of the judgment that comes with it. You are afraid of standing out. You are afraid of being alone. You are afraid of people looking at you. You are worried about what people think of you. There are 2 categories of things in this world: 1) Things that are up to you 2) Things that are not up to you Which category does your reputation sit in? Your reputation is not up to you. I'm the one who associates your reputation with something, not you. You just do things. What's up to you? How you act. Your decisions. Your actions. That is up to you. Your reputation is not up to you. Here's how I know that: You all have a reputation about me and it's not in my control. I get to say and do whatever I say and do up here. I am in control of saying it. I am in control of doing it. The moment words leave my lips, who has control over what is done with those words? You! You are in control of what you think of me. And there's no way everybody in this room is going to think the exact same thing about me. No way. When it comes to exceptional, what we've got to understand is you can spend your whole life trying to avoid criticism and earn reputation, and it still won't be in your control. We can waste a lot of time missing out on excellence we could have been producing if we were just simply LESS trying to engineer what we wanted other people to think about us."

Brian Kight

308,812 Aufrufe • vor 1 Jahr