Your AI Agent Wants Your Data. Here's How to Lock It Down - Jeff Smith, Oracle

AI Engineer · 21 min · 253 sentences · from YouTube's caption track

Each timecode opens YouTube at the start of that sentence. Line anchors (#s42) are the cue ids in the WebVTT, and every line carries its start and end seconds. All transcripts has every talk, and the whole corpus as one file.

  1. 00:01[music]
  2. 00:12I'm Jeff.
  3. 00:13I'm from Oracle.
  4. 00:14I'm almost
  5. 00:15[snorts]
  6. 00:15the exact same age as Oracle.
  7. 00:17Does anyone know what year Oracle was founded?
  8. 00:22Same year Star Wars came out.
  9. 00:25Yeah.
  10. 00:26Um and I've been working with database tools um for about 25 years.
  11. 00:33And I learned a truth very early on that no matter how good of a tool you build, at the end of the day what people want are Excel spreadsheets.
  12. 00:41Is that still true?
  13. 00:43Has the agent killed Excel yet?
  14. 00:48Well, they published the reverse engineer anything, right?
  15. 00:50And then they immediately reverse engineered Excel.
  16. 00:52So, maybe Excel's still a thing.
  17. 00:55Um the biggest question we've got at our booth and from random people on the street that see my Oracle jacket, other than can I have your jacket, um is like what is the Oracle AI database?
  18. 01:06So, who in here has worked with or studied or seen an Oracle database before?
  19. 01:12Who in here is currently using Oracle?
  20. 01:16Cool.
  21. 01:16Thank you.
  22. 01:17Um so, what's an Oracle AI database?
  23. 01:20Well, the only real way to answer this question today is to ask Claude.
  24. 01:25Um my agent's very well trained and behaved.
  25. 01:28So, it actually had a pretty good answer.
  26. 01:31The nutshell is the database is now able to participate in all of your rag pipelines because we natively support vectors inside the database.
  27. 01:41So, if you've got financial data, HR data, ERP, shipping, um retail, government, healthcare, whatever, if you want to look for information in that data warehouse, that data lake, that data sewer, that
  28. 01:58beautifully curated database.
  29. 02:00We can vectorize your information alongside the data inside the database, and we give you a single SQL interface across all of that.
  30. 02:09So, you don't have to replicate data across eight or nine different platforms just for your Did you see that?
  31. 02:17That was like Spider-Man.
  32. 02:19Um So, that means one MCP server um into the database, and I'm here to talk about MCP.
  33. 02:31So, um just see Oh, missed it that time.
  34. 02:37It's not just vector that we've added to the database.
  35. 02:40So, in addition to your relational tables and columns, thank you so much.
  36. 02:43Would you like a complimentary pair of socks?
  37. 02:47Yeah.
  38. 02:47[laughter]
  39. 02:49Feel like you should have won a prize for that.
  40. 02:51Um Yes, thank you.
  41. 02:55For 30 years, we've been adding um data types and data workloads to the database.
  42. 03:01So, we support all of these things.
  43. 03:03Um also, graph.
  44. 03:04So, if you're a fan of graph rag, um we can do that as well inside the single instance of Oracle.
  45. 03:11So, people like to dig on Oracle cuz we're old, that doesn't mean we've stopped innovating.
  46. 03:16I mean, we we're inventing, building, publishing new stuff uh every month.
  47. 03:21We have to because people are giving us lots of money, they expect value in return for that.
  48. 03:28All right.
  49. 03:28So, what I want to actually talk about today MCP, we're going to cover some uh real-life use cases cuz that's the biggest question I get is like agents, LLMs,
  50. 03:39MCP great, who cares about databases?
  51. 03:41Like, what what's the point here?
  52. 03:42It And for me, it's very obvious.
  53. 03:44I mean, like all of your data, information, knowledge is inside a database, and the agents thrive on on data.
  54. 03:50So, how can we get that information to them safely without bringing the company down because we've leaked PII or done something horrible and end up in front of Congress testifying about it.
  55. 04:02I want to talk about uh the advancements that we're pushing.
  56. 04:05You know, MCP is brand new protocol, but they add stuff almost every 3 months.
  57. 04:09So, Oracle is there having these conversations with the board and we're trying to pick up the new features as they come out.
  58. 04:18And we don't have time for Q&A today, but I do I did bring some swag.
  59. 04:23I think most of it's gone.
  60. 04:24If you want a bag or socks, oh, we have some DB stuffies in the back.
  61. 04:28We can throw those at you.
  62. 04:31Um I'll share some roadmap stuff as well.
  63. 04:36So, this is an hour talk and I was told I have 20 minutes and then not really just 18.
  64. 04:41Let's see how fast we can go cuz I've wasted 2 minutes on the podium.
  65. 04:45All right.
  66. 04:47So, the three things I want you to be able to walk away with, what we've built, um the problems with natural language to SQL, and some things that we're trying to make that more trustworthy,
  67. 04:59and then anything I can share with you folks that might help with token optimization.
  68. 05:07All right, use cases.
  69. 05:09I think this is the last use case that businesses end up undertaking, but I also think it is the biggest return for your buck.
  70. 05:18Um generally the people managing the infrastructure around the database are the ones that get to hook up the new technology.
  71. 05:25So, when I say, "Hey, do you want to try an MCP server?"
  72. 05:29It's usually a database administrator, a network administrator, a sysadmin, a DevOps engineer that's going to have the ability to do that in the first place.
  73. 05:37So, they'll use these tools to make their lives easier.
  74. 05:41But if you look in a company, there are way more of these types of people, the people that get the questions from the SVP, the EVP, God forbid the CXO
  75. 05:52saying, "How many widgets did we sell last month?
  76. 05:56How are we performing in this region?
  77. 05:58Um what discount rate should we run to maximize um people closing out their carts?
  78. 06:04All all that fun stuff that I pretend to understand."
  79. 06:07And so, what generally what happens, they go into their BI Publisher, they go into their data marts, they they start building their spreadsheets, they they pop out the answer, and that ends up in a
  80. 06:18in a meeting somewhere, and someone makes very important decisions based on the pivot tables and Excel spreadsheets that have been compiled.
  81. 06:26And these questions are endless.
  82. 06:30Like it's not that people run out of questions [clears throat] to ask.
  83. 06:33They don't have enough time and people to answer those questions.
  84. 06:37Like every second there's like, "Oh, there's What if we try this?
  85. 06:39What if we try that?"
  86. 06:41So, the beauty of generative AI is like it's a force multiplier, right?
  87. 06:45So, we had now have the time and the resources to ask these endless questions.
  88. 06:51The problem is the data's in the database, and the people putting together these spreadsheets,
  89. 06:57[snorts]
  90. 06:58they're not necessarily SQL experts, data model architects.
  91. 07:03They understand the business, but they wouldn't recognize that a cross join doesn't make sense for this scenario.
  92. 07:09So, natural language to SQL is amazing, but I think it's dangerous.
  93. 07:15Have you ever heard the phrase, "If it compiles, ship it?"
  94. 07:19Engineers laugh about this.
  95. 07:21We pretend to laugh along.
  96. 07:23Um I wrote a SQL query, data came back.
  97. 07:26Awesome, I got it right.
  98. 07:27No. You didn't actually ask what you thought you asked.
  99. 07:30The LLMs are going to frequently run queries that look like they're returning the right data, but they're not.
  100. 07:35And there are various reasons why the LLMs, although they're getting better and better at this, are still going to fall short.
  101. 07:40Like I would not trust Codex or Claude or Gemini or any of these two decide what business branch that we're going to invest in XYZ just based on a prompt and a and a thing that pops back.
  102. 07:56It's also expensive to ask them to do this stuff, too, cuz they're going to brute force your dictionary your your database looking for the right data to answer these questions.
  103. 08:04So, not only is going to be unreliable and the people using this these tools don't necessarily understand what the the agents and MCPs are doing on our behalf, but it's going to take a lot of tokens and time
  104. 08:15to get that data.
  105. 08:16So, one of the things we've done at Oracle is said, "Hey, as a business, as a team, as a group, you've got a SharePoint, you've got a network drive, you've got something where there's
  106. 08:27folders and folders and folders of reports that you've compiled over the years.
  107. 08:32And these are the things that you look at when people ask these questions.
  108. 08:36So, why not find a way to pipeline them into the database and/or MCP server and present those almost as like tools or APIs that the agent can call.
  109. 08:48So, instead of the agent tasking an LLM to generate a query, you say, "Hey, these are the reports available to you.
  110. 08:55Which of these would you like to look at?"
  111. 08:58So, that's what we've done at Oracle.
  112. 09:00We allow you to take as many of these as you want.
  113. 09:03Now, you do have to put some time into this.
  114. 09:06You'll need to describe the reports and I like to include like, "Hey, here's sample questions."
  115. 09:12You know, the agent can say, "Hey, if you got a question about this, this is a good report to run."
  116. 09:16I describe what the report means.
  117. 09:17I describe all the inputs, so of course they're parameterized.
  118. 09:21But, the code underneath the report is more or less hard-coded.
  119. 09:25So, the LLM might screw up by picking the wrong report, but the LLM's not going to screw up by generating the wrong SQL.
  120. 09:32So, it's just one less plus place it can mess up.
  121. 09:37Now, in terms of MCP tools, I present I present a tool called list reports and execute reports.
  122. 09:47So, I could have 500 reports, that's not 500 tools.
  123. 09:51That would That would blow out context and then agent would be like, "This is This is too much.
  124. 09:56This isn't useful."
  125. 09:58So, when I ask a question, it can say, "Using this key phrase, give me any report that looks like this."
  126. 10:03I'll get a report list back and then I can execute one of those reports to get the data back.
  127. 10:08This is an option above natural language to SQL.
  128. 10:12So, our MCP servers definitely support taking arbitrary ad-hoc SQL stored procedure code and executing it on the fly against the database, but they also support turning that off and limiting you to custom tools
  129. 10:26and reports.
  130. 10:28And there's another mode for the context engineers out there.
  131. 10:32These reports represent like the blueprint for how the the business works, for how the data model works.
  132. 10:37So, if you have the proper scope or role in your OAuth 2 authenticated session, the tool will also offer to show the agent the SQL behind the report.
  133. 10:49So, it can learn how your data is organized in the system and then it's going to have a much better chance at one-shotting the right query when it goes to generate it.
  134. 10:59So, you're basically say, "Here's some markdown explaining how we find out the number of widgets we sold last month."
  135. 11:08And of course, here comes the results back and our agent nicely formats that.
  136. 11:14Who in here started playing with MCP apps?
  137. 11:19Yeah.
  138. 11:20So, that was I think you're introduced in the spec in July.
  139. 11:22That's something I'm going to talk about later on, like 5 minutes based on this little clock.
  140. 11:29Um Okay.
  141. 11:31Use case number two.
  142. 11:33So, for DevOps engineers, support folks, our platform is very well known.
  143. 11:38It's been around for a long time.
  144. 11:40The docs, the PDFs, the GitHub projects, the Stack Overflow questions, my blog posts, they're all out there.
  145. 11:46The LLM's been trained on it.
  146. 11:48They know what to look at if a query is slow.
  147. 11:50But, I don't trust an LLM to drop an index, to build an index even, to do anything in the database for me.
  148. 12:01I want it to give me advice and then I'll action that advice.
  149. 12:05And then if anything, I'm not going to let the LLM or the agent into production at all if I don't have to.
  150. 12:11Does that sound crazy?
  151. 12:13So, how do I use an agent or LLM to get help with a production system that's running slow?
  152. 12:19Everyone here has a test environment that mirrors production, right?
  153. 12:24No?
  154. 12:28Um we have a technology at Oracle called Data Guard that allows you to have a read-only standby instance where you can offload like reports and read-only queries to.
  155. 12:37So, there's a good chance your performance issue would replicate over there.
  156. 12:41You can have your agent go attack, not attack, that's not the right word.
  157. 12:45That's the right word actually sometimes.
  158. 12:46You can have your agent go interrogate that safer environment to investigate and try out different performance um tricks.
  159. 12:56So, I am looking to give the LLM's read-only access, but that's not enough.
  160. 13:00I also need to lock down what they can do once they're in there cuz even if you can only read the data, you might be able to read the data you don't want them to see.
  161. 13:08Um we can do that a couple different ways, but for me, the best place to always implement security for the database is where?
  162. 13:18At the database.
  163. 13:20If you build security only into your tools, what happens when a zealous engineer decides to go pick up another tool and point it at your database, they just go straight in,
  164. 13:30right?
  165. 13:30But if you put security at the database layer, more times than not you're going to be okay.
  166. 13:35The agents and LLMs are really, really good at finding and fixing performance issues.
  167. 13:41This is probably the easiest demo for me to do.
  168. 13:43I don't have time to do demo, but I've written a custom tool.
  169. 13:47This tool has six different actions that I'm a cool with it to do on my behalf, and one of those is to collect statistics that basically profiles the data.
  170. 13:58We have something called a cost-based optimizer.
  171. 14:00So, when you ask queries, the plans that get generated, they don't get generated based on rules of thumb.
  172. 14:06We look at the profile of the data, like how many unique values are in this column.
  173. 14:11Yada yada yada.
  174. 14:12The fresher and the better the statistics are, the better chance it's going to generate a good execution plan and have a good performance profile runtime.
  175. 14:19So, I'm not generating 15 tools that are single-use tools.
  176. 14:24I'll generate three or four tools that cross categories, and each of those tools have options.
  177. 14:29So, my agent can see, oh, here's a performance tuning tool.
  178. 14:31It can do six things.
  179. 14:33One of those is like generating uh a performance profile report.
  180. 14:36We have a feature called um AWR.
  181. 14:39I'll let it generate a report.
  182. 14:41One of the other things I'll let it do is is generate statistics.
  183. 14:47This ties in closely to the first use case, schema exploration and documentation.
  184. 14:54Man, I'm running out of time.
  185. 14:56So, natural language to SQL is really awesome.
  186. 15:00It's where most of the excitement around AI and databases lie, which makes sense cuz SQL's the most popular way to get stuff out of a database.
  187. 15:09We need that data, but it's a nightmare for a lot of these systems.
  188. 15:14Has anyone started a job in the last 6 months?
  189. 15:20Is there like a place in the break room where they put on the corner like a a diagram where all of the hard stuff is defined, all of the code words are listed,
  190. 15:30all of the all of the inside jokes are documented, where the data model is explained.
  191. 15:37Hey, our sales aren't in a sales table, they're in a table called XHR_123 because an engineer 30 years ago thought that would be cool.
  192. 15:47Yeah, it's a big Confluence page.
  193. 15:50We have tools now that will let you consume those Confluence pages and generate context and document uh schema metadata over top of the metadata that's already in your database.
  194. 16:03So, it's another context engineering exercise.
  195. 16:07We want to be able to deliver to the LLM the information about the database environment you're talking to instead of relying on it to generate queries to reverse engineer hack your database to look for data.
  196. 16:18It will find the data if you ask it, it'll just take a long time, and it'll look for it multiple times, and unless you have shared team enterprise memory across everyone's agents and LLMs,
  197. 16:30it's just a it's just just a huge waste.
  198. 16:32So, what we're like with for some reason it wasn't a big problem to let new employees suffer when they joined an org.
  199. 16:41Like it wasn't it wasn't a big enough problem to fix this issue 30 years ago, but now that AI is a thing, we can't let the poor bots suffer.
  200. 16:49So, we got to get them the information they need to to make it easier to use our databases.
  201. 16:53The The nice thing about this feature is it's all in plain English, it's in the database, it it's going to help the humans, too.
  202. 17:03So, when you go look at our tools, we have something called schema information.
  203. 17:08So, I'll say, "Hey, Codex, Claude, whatever, I've got a new um environment.
  204. 17:14I need you to go look into it and see how laid out, find this, and let's go summarize the information.
  205. 17:21It'll see that it has a schema info tool, and it'll start using that, and that returns back a compressed dictionary a set of attributes in JSON versus it running queries.
  206. 17:33Hey, show me all the tables, show me all the columns, show me all of the comments.
  207. 17:38Let's go read five rows out of each table to see if the data has what we looks like.
  208. 17:42You know, we just kind of built that into the tool, optimized it, and it always returns the same data, and it has multiple modes.
  209. 17:51You can go verbose, slim, medium, just like my pants, and uh it's got filtering.
  210. 17:57So, you can give it keywords, and it just looks for specific things in the data.
  211. 18:02[snorts]
  212. 18:02And then I can pull that back out with another tool called retrieve context, where I can use that information to do AI vector search, but I have another new tool called generate annotations.
  213. 18:13So, I can point it to that SharePoint site that you have, scan in your PDFs, your PowerPoints, your Excel, your Word docs, um and store those in um or pull the text out,
  214. 18:26organize it, and and put it back into the database.
  215. 18:30This is also it's easier to one-shot SQL queries when you have natural language to SQL exercises.
  216. 18:39This is what the data looks like in the database after I've properly annotated a table.
  217. 18:44So, anytime I do a run or a bike ride or whatever, it goes into my Strava account.
  218. 18:50I'm a nerd, so I have an API on that data, and I store it in my database.
  219. 18:54And their schema is fairly well described, but it jumps between like units of measure and time, and some of the columns don't have what you think they do.
  220. 19:03So, I just have that all annotated, and so when I start asking questions about, "Hey, what kind of workout should I do next week?"
  221. 19:09and it looks at my personal workout history, it it gets to that much easier with this with this info.
  222. 19:15And the nice thing about this with MCP is AI and LLM agnostic.
  223. 19:19It's going to work for everything as long as the MCP server and the tools are there.
  224. 19:27Okay, so this might be the most important thing I talk about, security.
  225. 19:30So, I got 40 seconds.
  226. 19:31We'll just end on this.
  227. 19:33Um we need to know who is looking at the information in the database before we return any data back to them.
  228. 19:42The information I'm allowed to see is going to be much different than what the data my colleague Tara is going to be able to see.
  229. 19:48And when I'm in the database using Claude or Codex or Gemini or my own homegrown LangChain framework, we don't use database authentication to let the agent go in and do stuff.
  230. 19:59We pipe you through your organization single sign-on.
  231. 20:03So, like Azure AD, which is going to return a list of scopes, which is going to return a list of roles that describe your role in the organization, and the database can be coded to say, "Oh,
  232. 20:13Jeff is an HR manager.
  233. 20:14He's allowed to see everyone's salary."
  234. 20:19But no one else outside that org can.
  235. 20:22So, when we the natural language questions get generated to SQL, when that SQL runs against the database, the database dynamically strips data from the result set before it comes back down
  236. 20:33to the agent.
  237. 20:34We call that deep data security.
  238. 20:36I'm out of time.
  239. 20:38I covered the big stuff.
  240. 20:42We thought a lot about security at Oracle.
  241. 20:44We want this stuff to be easy, but we want it to be safe.
  242. 20:48We are building MCP apps, so you can have the database interface GUI directly in your agent.
  243. 20:54That's coming later this year.
  244. 20:55[snorts]
  245. 20:56We have skills.
  246. 20:58The skills can be delivered via tools.
  247. 21:02We support automated rag pipelines.
  248. 21:03You can use a command line to suck documents in and then an MCP tool pipe the the vectors and the the snippets of the the documents back to your agents.
  249. 21:15And when you want to learn more about any of this stuff, we have the easiest URL oracle.com/mcp.
  250. 21:21I'm leaving to get on a plane to fly back to Raleigh, North Carolina, but if you find me on LinkedIn, I'm that Jeff Smith and my colleagues are down at the Oracle booth and they have more swags.
  251. 21:28If you missed out on the plushy, we have more.
  252. 21:31Thanks, everyone.
  253. 21:32[applause and music]