{"slug": "how-sproutme-cut-integration-test-time-by-92-9-with-duckdb", "title": "How SproutMe Cut Integration Test Time by 92.9% with DuckDB", "summary": "SproutMe, an early-stage AI marketing startup, cut its integration test step per merge by 92.9 percent — from 10.65 minutes to 0.76 minutes — by adding DuckDB to its local development and CI workflow, according to data engineer Archit Dukhande. The pipeline uses Dagster to extract Google Ads, Meta Ads and GA4 data into DuckDB, where dbt runs bronze, silver and gold transformations, while production remains on BigQuery, where a full end-to-end run can take one to two hours. Dukhande said the transformation stage delivers most of the savings, letting the team ship two to three pull requests a day without disrupting existing customers.", "body_md": "# How SproutMe Cut Integration Test Time by 92.9% with DuckDB\n\n*TL;DR: At [SproutMe](https://sproutme.ai/), a fast-moving, early-stage AI marketing startup, data engineer [Archit Dukhande](https://www.linkedin.com/in/archit-dukhande/) added DuckDB to their local development and CI workflow for a data-heavy AI product. Running the integration tests on DuckDB cut the step per merge by 92.9 percent, from 10.65 minutes to 0.76 minutes, so the team can ship several changes a day without putting users at risk.*\n\n## \n[Why Iteration Speed Matters at SproutMe](#why-iteration-speed-matters-at-sproutme)\n\n[SproutMe](https://sproutme.ai/) is an AI workspace that gives marketers and agencies the playbooks large advertisers run in-house: competitive analysis, account audits, cross-channel optimization and more. AI agents do most of the work, leaving marketers free to focus on long-term strategy. SproutMe was founded by [Pulkit Khurana](https://pulkitkhurana.com/), who spent 13 years at Google, most recently as Engineering Director for Google Ads.\n\nArchit built SproutMe’s data platform from scratch. For a company moving this fast, development speed directly affects the business. **“Because we are a startup, we have to work very fast,”** he says. In practice, that means shipping two to three pull requests a day without breaking anything for the businesses already using the product. **“We don’t want the businesses to face problems when we push it,”** Archit explains, so every change runs end to end, both locally and in CI, before it reaches the main branch.\n\nLocal and CI runs were slow. The pipeline handles a lot of data. When a new customer joins, SproutMe pulls about 365 days of history across its ad and analytics sources, which means millions of rows to load and transform. On BigQuery, testing a change at that scale took long enough to disrupt the team’s daily rhythm.\n\n## \n[Where DuckDB Fits](#where-duckdb-fits)\n\nArchit first heard about DuckDB in LinkedIn posts about its speed. He decided to try it on a few small runs, and it soon became part of the daily workflow. SproutMe now uses DuckDB for local end-to-end testing and CI integration tests.\n\nThe pipeline looks like this:\n\n1. [Dagster](https://dagster.io/) orchestrates extraction from Google Ads, Meta Ads, and GA4.\n2. The extracted data lands in DuckDB, which acts as the analytical warehouse on the engineer’s local machine.\n3. [dbt](https://www.getdbt.com/) runs the transformations on DuckDB, following a medallion architecture: bronze for raw data, silver for cleaned and standardized data, and gold for the user-facing models.\n4. The same logic runs locally and in CI before any change is deployed.\n\nWhen the local Dagster dev server starts, it points the pipeline at a DuckDB file through environment variables, and dbt builds into it with the duckdb target. Production stays on BigQuery.\n\n``` php\nimport os\nfrom pathlib import Path\n\ndef use_local_duckdb(warehouse: Path) -> None:\n    \"\"\"Point the local pipeline at a DuckDB file instead of BigQuery.\"\"\"\n    warehouse.parent.mkdir(parents=True, exist_ok=True)\n    os.environ[\"WAREHOUSE\"] = \"duckdb\"\n    os.environ[\"DBT_DUCKDB_PATH\"] = str(warehouse)\n    # BigQuery compares timestamps in UTC; DuckDB uses the machine’s zone unless told otherwise.\n    os.environ[\"TZ\"] = \"UTC\"\n```\n\nThe transformation stage is where DuckDB saves the most time. **“This is where we are saving a lot of time, the transformation part,”** Archit says. Extraction benefits as well, because Dagster writes directly into DuckDB. The scope matters, though: **“It is part of the local development pipeline.”** Production still runs on BigQuery.\n\n## \n[The Numbers](#the-numbers)\n\nSproutMe chose BigQuery early because the team was already familiar with Google’s infrastructure. A full end-to-end run there can take one to two hours. That works for production, but it is too slow for a team pushing several changes a day and waiting on feedback from local and CI runs each time.\n\nRunning the same pipeline on DuckDB shortens the wait between changes. In SproutMe’s measurements, the same dbt project, command, and real data ran on both engines. The integration test step, which runs on every merge, fell from a median of 10.65 minutes (639.0 seconds) to **0.76 minutes (45.6 seconds)**. That is a 92.9 percent reduction across 88 CI/CD runs. The dbt runs also got faster. On local test accounts, a full backfill dropped from 180.2 seconds to 104.6 seconds, and a daily incremental build dropped from 300.3 seconds to 120.7 seconds. DuckDB times are medians of five runs. The table below lists all timings in seconds.\n\n| What we measured | BigQuery | DuckDB | Time saved | \n|---|---|---|---|\n| Integration test step, per merge | 639.0 s | 45.6 s | 92.9% | \n| Full dbt backfill | 180.2 s | 104.6 s | 42.0% | \n| Daily incremental dbt build | 300.3 s | 120.7 s | 59.8% | \n| Backfill and daily build together | 480.5 s | 225.3 s | 53.1% | \n\nSproutMe’s platform uses AI agents to generate recommendations like those shown in the dashboard below, which displays performance metrics, trends, and recommended actions across multiple channels.\n\nSproutMe’s AI companion can also run analysis tasks like competitor research, producing structured reports with executive summaries and actionable insights, as shown below.\n\nIn CI, dbt build runs with the duckdb target over the whole project, seeded from committed fixtures. The integration tests then compare selected models’ output with committed golden files, so a regression fails the build before it reaches main.\n\n``` python\nimport os\nimport subprocess\nfrom pathlib import Path\n\ndef build_test_warehouse(db_path: Path, project_dir: Path) -> None:\n    \"\"\"dbt build of the whole project on DuckDB, after the committed fixtures are loaded.\"\"\"\n    env = {**os.environ, \"DBT_DUCKDB_PATH\": str(db_path)}\n    subprocess.run(\n        [\"dbt\", \"build\", \"--target\", \"duckdb\",\n         \"--project-dir\", str(project_dir), \"--profiles-dir\", str(project_dir)],\n        env=env,\n        check=True,\n    )\n```\n\nThese results apply to SproutMe’s development and testing workflow. They do not show that one engine is faster in general.\n\nFor Archit, the main gain is faster debugging. Instead of spending hours reproducing an issue, he can find a bug in minutes. **“Development speed is super fast,”** he says, pointing to three advantages: rapid iteration locally, how easily DuckDB runs on local machines with AI coding assistants like Claude (which can inspect errors and help debug directly), and compatibility—the same setup works in both local development and CI without changes.\n\n## \n[What Comes Next](#what-comes-next)\n\nSproutMe has used DuckDB for only a month or two, but the results have made the team curious about going further. Archit is open to using DuckDB in production if more testing and benchmarking support it.\n\nHe also points out that moving a production workload that serves live customers needs its own evaluation. For now, the change is limited to development, and the production warehouse stays the same.\n\n## \n[The Takeaway](#the-takeaway)\n\nSproutMe shows that DuckDB can fit into an existing Cloud data architecture without replacing anything in production. The integration tests now finish in under a minute, which keeps pace with the team. Feedback arrives sooner, which lowers the risk of shipping a regression, and BigQuery keeps serving the live product.\n\nWe would like to thank Archit for the conversation. If you use DuckDB and want to share your story, email [\\[email protected\\]](https://duckdb.org/cdn-cgi/l/email-protection#ed8a88889f99878c83ad89988e86818c8f9ec38e8280).", "url": "https://wpnews.pro/news/how-sproutme-cut-integration-test-time-by-92-9-with-duckdb", "canonical_source": "https://duckdb.org/2026/11/24/sproutme-faster-pipeline-testing.html", "published_at": "2026-11-24 00:00:00+00:00", "updated_at": "2026-11-24 15:42:41.723533+00:00", "lang": "en", "topics": ["ai-startups", "ai-products", "developer-tools", "mlops"], "entities": ["SproutMe", "DuckDB", "Archit Dukhande", "BigQuery", "Dagster", "dbt", "Pulkit Khurana", "Google Ads"], "also_reported_by": [], "takeaway": "Pointing a Dagster-and-dbt pipeline at a local DuckDB file via environment variables, with TZ set to UTC to match BigQuery's timestamp behavior, cut the integration test step from 10.65 to 0.76 minutes per merge while production stayed on BigQuery.", "recommendation": {"advice": "Run local and CI integration tests against a DuckDB file instead of your production warehouse, and set TZ=UTC so timestamp comparisons match BigQuery; SproutMe cut test time 92.9 percent this way.", "playbook": "production-ops", "playbook_url": "https://wpnews.pro/playbooks/production-ops"}, "alternates": {"html": "https://wpnews.pro/news/how-sproutme-cut-integration-test-time-by-92-9-with-duckdb", "markdown": "https://wpnews.pro/news/how-sproutme-cut-integration-test-time-by-92-9-with-duckdb.md", "text": "https://wpnews.pro/news/how-sproutme-cut-integration-test-time-by-92-9-with-duckdb.txt", "jsonld": "https://wpnews.pro/news/how-sproutme-cut-integration-test-time-by-92-9-with-duckdb.jsonld"}}