Loading…
Agentic coding with ClickHouse. One person, one data stack, one full-stack application
Oussama Chakri
- Source
- Clickhouse
- Published
- Added to Yomu
Summary
A Solutions Architect at ClickHouse built ClickShop, a full-stack retail analytics platform, within a few days using Cursor to demonstrate production-level capabilities beyond static slides. The platform pairs ClickHouse for sub-second analytical queries across billions of rows with PostgreSQL for transactional workflows, using ClickPipes for real-time change data capture synchronization. LibreChat orchestrates 18 persona-tailored AI agents, while dual observability layers—ClickStack for OpenTelemetry infrastructure metrics and Langfuse for LLM prompt and cost tracking—store their telemetry directly in ClickHouse. Developing with an AI-assisted IDE was accelerated by open-source documentation and community skills, though it required continuous human review to handle unintended code refactoring and token consumption.
Context
Slides and architecture diagrams were insufficient for demonstrating ClickHouse capabilities to retail customers who required a realistic environment combining analytics, transactions, AI agents, and monitoring. Building such an application normally requires a full engineering team and several months, neither of which the author had.
Approach / What changed
Using Cursor, the author constructed ClickShop across three main layers. The Next.js frontend provides persona workspaces, ClickHouse handles analytical workloads alongside PostgreSQL for transactional data synchronized via ClickPipes CDC, and LibreChat powers 18 specialized AI agents. Observability is handled by ClickStack for OpenTelemetry infrastructure metrics and Langfuse for LLM evaluation, with both storing telemetry in ClickHouse.
Takeaways
- ClickShop separates data responsibilities by using ClickHouse for sub-second analytical queries over billions of rows and PostgreSQL for transactional workflows, synchronizing updates via ClickPipes CDC.
- The architecture implements dual observability on ClickHouse, tracking infrastructure health with OpenTelemetry via ClickStack while capturing LLM prompt latency, evaluations, and costs using Langfuse.
- Building with widely documented open-source tools improves AI code generation in IDEs like Cursor because public codebases reduce incorrect assumptions during prompt-driven development.