Skip to main content

Setup

Run ClickHouse with Docker:
Set your OpenAI API key. The examples below use the default OpenAI embedder and model.

Example

agent_with_knowledge.py

Async Support ⚡

ClickHouse also supports asynchronous operations, enabling concurrency and leading to better performance.

async_clickhouse.py
Use ainsert() and aprint_response() to integrate these operations into an async application. Await both in the same event loop.

ClickHouse Params