Cube Core releases v0.33.0 thru v0.33.43 bring a few important integrations: DuckDB, one of the most performant and definitely the most hyped OLAP database, and LangChain, the toolkit of choice for many developers of AI applications.

Additionally, we deprecate the running_total measure type in favor of a more generic and powerful rolling_window option.

LangChain integration

Cube presents the integration with LangChain, the most popular toolset for building AI-based applications. It comes as the document loader that is intended to be used to populate a vector database with embeddings derived from the data model of the semantic layer. Later, this vector database can be queried to find best-matching entities of the semantic layer. This is useful to match free-form input, e.g., queries in a natural language, with the views and their members in the data model.

diagram

With this integration, builders of AI experiences can have a user-friendly, error-prone, and hallucination-free access to data. See the video for an example of experience one can build with this integration:

Read more in the announcement and check the documentation for details.

DuckDB support

Cube expands the list of supported query engines with DuckDB, an extremely performant in-process SQL OLAP database management system, and MotherDuck, a cloud service providing hybrid execution for DuckDB. With this integration, Cube can query data stored as Parquet, CSV, or JSON files at S3-compatible object storage servers, i.e., AWS S3, Google Cloud Storage, and Cloudflare R2.

You can easily go from local ad-hoc data exploration with DuckDB to building code-first data models and consistent metrics usable by everyone in an organization with Cube:

Read more in the announcement and check the documentation for details.

running_total deprecation

As of v0.33.39, the use of the running_total measure type is deprecated in favor of the rolling_window option that is more flexible and general-purpose. The semantics of running_total can be achieved by using rolling_window with the trailing option set to unbounded.

See the code example:

cubes:
- name: example
# ...
measures:
# Deprecated
- name: total_amount
sql: amount
type: running_total
# Recommended
- name: total_amount
sql: amount
type: sum
rolling_window:
trailing: unbounded

What’s next in Cube Core

We're just a few weeks away from Cube Core v0.34 with the support for snake_case in the configuration as well as writing the configuration entirely in Python in a cube.py file. Moreover, the v0.34 release will bring dynamic data models in YAML with Jinja and Python.

You can try Cube Core v0.33.43 today in Cube Core with our Docker distribution. It's also available on the latest release channel in Cube Cloud.

As always, please don't hesitate to get in touch with us and share your feedback in our Slack community of more than 8,500 data practitioners.