Document search mini app (internal)

Chris Merrick · Friday Demos · June 6, 2025 · 3:05

We demo an internal mini app for searching and parsing documents in Omni via Snowflake Cortex. This use case is for contract lookup, but could be extended to any document based analysis.…

Try it yourselfThe full week on docsappinternalmini

Transcript

This transcript is auto-generated. Names and product terms may be wrong.

  1. different. Uh, this one is actually in production. So, I'm going to go into our AI assistant and I'm going to say, uh, find me our CSA with guitar center. So, Blobby now has access in our instance to a document search. Uh, the document search contains all of our customer agreements currently. So, um, this search found the agreement with Guitar Center.

  2. Unfortunately, the linking capability doesn't work in lobby right now. So, I I'll just pop over to the uh to the workbook and go, like I said, uh, currently just customer agreements. Uh, but I think the possibilities here are endless. Um, this is leveraging. So, I'll show you a little bit about how this is working right now. Um, well, first I wrote uh I wrote this ETL script to pull all of our agreement PDFs out of common paper.

  3. Uh, then I came over here to Snowflake. Um, I loaded those into a Snowflake stage. Uh, I use Snowflake's cortex parse document to parse them all into text. Uh, and then I loaded them all into a table and then and actually chunk them. So, it's like I don't know 500 word chunks and then I created a cortex search service on top of that chunk table uh to enable a search.

  4. So, uh it's actually really cool. I I I did uh you know the searching for a specific contract is super cool. I'm also in the process of like trying to find all of the emails referenced in all of our agreements and t cortex search is actually not great for that but I have all the chunks of text in a table now so I can just run a reax for all the emails.

  5. So uh kind of having that parse PDF is super valuable uh for a variety of reasons. Um this is currently kind of hacked into Omni. Um, it is a query view. Here, I'll show you what it actually looks like. Um, just super quick, it is oops, sorry, that is So, here's the query view. Uh, and it uses a templated filter um to actually parse the query or excuse me, to pass the query in to um this kind of gnarly snowflake uh special call.

  6. So, uh I I think there may be some ways that we want to make this more of a first class thing down the line. Uh but this proof of concept like I I think uh you know, we've talked sort of about building kind of a DIY glean. Um it's basically what I did here and and honestly it was not hard at all.

  7. So, I think there's some real interesting uh opportunities