We're excited to announce the latest addition to Waii's powerful Text to SQL conversion capabilities: Semantic Context. This feature brings a deeper level of understanding to your database structures, ensuring that the API isn't just executing SQL but truly understanding the essence of your data.
- Enhanced Accuracy: By incorporating semantic details into your database structures, Waii crafts SQL queries that align better with your data model, ensuring more precise results.
- Consistent Queries Across Organization: Encourage a standard business vocabulary in your organization. With Semantic Context, different teams can request data in their language, but get results that adhere to predefined business definitions.
How it Works:
You can now attach semantic information to your database objects, from schemas to individual columns. This added context helps Waii's engine to discern the real-world meaning behind your data structure.
Let's say you have a star schema with a date dimension, specifically designed to encode the 'current date'. With Semantic Context, you can add the following semantic description to the date dimension table:
"The current date, i.e., 'today' in the context of the warehouse is stored in this table. It corresponds to the record that has the column 'current_date' set to true."
Now, when a user queries: "Give me a monthly sales total for the last year", Waii understands that 'last year' should be calculated from the aforementioned 'current date'. Your resulting SQL query might look something like:
The beauty lies in Waii's ability to map the user's request with the semantic information, thus producing a relevant and precise query. We're always eager to hear feedback from our community. Let us know how Semantic Context enhances your querying experience! As always, thank you for being a part of the Waii community. We look forward to bringing even more robust features in future updates. Happy querying!