
Query API (ask us to kick the tires)
Our new query API in alpha - take the Omni model anywhere you like. Still refining the API, but can start opening up early testers.
Transcript
This transcript is auto-generated. Names and product terms may be wrong.
I'll I'll go I've got uh one that's not a a terribly uh sexy demo but uh it's it's kind of cool um I was inspired by some of the stuff that Chris was showing off earlier this week and I you know with with basically Chris has done the hard work of making apis relatively straightforward to implement so I uh implemented a a query API and to to show it I basically implemented uh like a very very lightweight uh python SDK to query against omni's governed data so explicitly you know we are a semantic model and we enable folks to you know standardize metrics and the like too um the the API is pro probably going to change almost actually certainly going to change uh and
it's definitely not going to be a V1 you know stable kind of uh throughout throughout time but uh uh it's at least a first pass where we we take sort of a a query um we take the the API key um and we can run it and then just to show you uh what what it looks like here you know here's some of the the data that's coming back here's a visualization of the data coming back uh with a with a forecast applied to the to it too so you can use you know your your most familiar uh python python uh uh uh libraries and I I am complex forecast you got there yeah I uh just the last data point my my python notebooking
skills are definitely a little bit dated I need I needed Chris to help me like get me up get me up and running and it was it was it was trouble but uh but but exciting what is um Jamie what does it take as the input like is there a query ID or like do you have to create no it's a quer it's a query uh I looked actually at a handful of different apis uh ac across a variety of tools too right now and and this is subject to change and in fact actually Johnny Johnny's had uh good good thoughts on it right we basically have it's a get request with our Omni query object too so you can see for example uh it's
even inconsistently uh named so you have model ID in camel case and you've got you know these you know underscore properties too join paths from topic names probably not the right parameter for uh people quer topic right yes that's the topic yes that so or like even the even the it's like this is a maybe a good example too you we could probably make this simpler in an API format and probably have a translation even if we want to keep the internal Omni things I I'm probably going to make that followup work because it it is a little bit it could be potentially a little bit confusing to folks having like the inspector uh with like something that's inconsistent to what the API call would
be and like we probably want to have something like a you know grab the URL for the API uh to grab the to grab the query make it really easy for folks to be able to go uh you know insert these I think the most common use cases will be you know python notebook type or python or R whatever sort of more advanced analytics or you know potentially using uh uh JavaScript to you know construct kind of custom custom experiences and we'll want to have a seamless transition there too so this this think of this as a very early version of it we'll need to refine really what the the the interface looks like and is this r AP sorry sorry yeah is a run
API an existing endpoint or did you just create it's a new endpoint that effectively is reusing actually your multi your run queries uh logic too that I got like actually I should I will CCU on the pr I would love your your thoughts actually so it does the whole like handshake and ites it does the whole handshake and streams the data back too right now I basically made the a slightly constrained input so like it doesn't take cache entries it doesn't take actually multiple it doesn't take an array of queries it just takes a query then does the look up for the connection IDs and stuff too and then it will actually look at the streamed results and depending on what the type of the
streamed result like headers and Footers it ignores it waits for a completed or an error State and then for the completed State it'll basically wrap the arrow payload exclusively not like the metadata coming back from the server I I don't I think we'll want to have like a Json option too where we actually probably take more of the payloads but like in the in the simplest case like where someone's using it inside a a notebook you probably just want the arrow payload coming into Python and like you can go in um you know manipulate as a data frame but uh I don't know I there's it the the hard part definitely was not like stitching it all together I think the hard part is going
to be thinking about the interface design like what we actually really want to both from an input perspective and then from an output perspective like what people expect yeah very cool definitely tag me in it be curious to take a look yeah sounds sounds um are are we going to let anyone touch this or is this purely for our uh sort of play for now um I think we we could like so I I don't know once we feel good about like the vzero of of it I think we can release it uh and let people play with it with the very heavy caveat that this is definitely going to have breaking changes going forward so like yeah I I think there might be a
handful of people that would be willing to play with it even with breaking changes um we want them to so it's I think it's up to us but I don't I I think plenty of people would sign up still with that caveat yeah I think a a relationship where we want people to play with it but we want them to be talking to us about how they're using it and giving us feedback on it is great and yeah the heavy caveat of like this is going to change so be prepared for it to change okay I can write it with that caveat but I'll let people volunteer themselves yeah absolutely someone's brought up pivots right to you thought about pivot oh I didn't even think
about pivots you're actually we we we are getting we're getting the arrow payload uh right now you know what maybe I'm just gonna not allow you to specify a pivot pivot to start I mean there's going to be a lot of we you might want to think about not arrow and instead Jon CSV with our like post transform just definitely all the there's all these weird little they're going to get a bunch of and the totals and stuff I had I hadn't uh I had not thought about that yet you're you're totally right that's uh more complicated yeah I'll think about that I'm just I'm G to tag you into it too thank you sure h