A real, verified, automated competitive-analysis pipeline for UAE consumer-tech — e-commerce, mobility, food delivery, and fintech/BNPL. Built for Better Than Busy.
Total cost to date: under $0.03. Runs weekly, on its own, for about a penny a week.
Careem is widely cited as holding ~90% of UAE ride-hailing market share. Its own customers tell a different story: 86.5% of recent App Store/Google Play reviews are negative — nearly 3x Uber's rate, measured the same way. Market dominance and customer sentiment are different metrics, and almost nobody checks the second one before repeating the first. See content/linkedin_post_reputation_vs_reality.md for the full write-up and content/competitive_analysis_2026-07-24.json for the raw findings across all four sectors.
Three real, first-party data sources — no market-research blogs, no guessed numbers:
| Source | What it gives | Coverage | Cost |
|---|---|---|---|
| Apple App Store reviews (public RSS) | Real customer sentiment | All 19+ companies, including private ones | Free |
| Google Play reviews | Real customer sentiment | Most companies | Free |
| SEC EDGAR filings | Real audited financials (revenue, assets, net income) | US-listed only: Amazon, Uber, DoorDash/Deliveroo | Free |
Everything lands in Google BigQuery, gets deduplicated to the latest snapshot, and is analyzed by Gemini 2.5 Flash-Lite into a structured, sourced report — separating what's verified from what's review-derived from what's global-not-local, never blending them.
Windows Task Scheduler (weekly)
│
▼
weekly_run.bat → run_pipeline.py
│
├─► data_layer.py ──► Apple RSS + Google Play + SEC EDGAR
│ │
│ ▼
│ BigQuery: raw_reviews, review_agg, raw_financials
│
└─► analyze_from_bigquery.py ──► reads latest snapshot per company
│
▼
Gemini 2.5 Flash-Lite (Vertex AI)
│
▼
competitive_analysis.json + history/
Dashboarding: Looker Studio (free) reads directly from the BigQuery tables. See docs/looker_studio_setup.md.
pipeline/ the actual working, running code
data_layer.py ingestion: reviews + financials → BigQuery
analyze_from_bigquery.py analysis: BigQuery → Gemini → report
run_pipeline.py runs both in sequence, keeps dated history
weekly_run.bat Task Scheduler entry point
companies.json 21-company roster with verified store IDs
content/ actual outputs
competitive_analysis_2026-07-24.json real analysis run
linkedin_post_reputation_vs_reality.md the content piece drawn from it
docs/ reference guides
DATA_LAYER.md data layer design (provenance, loopholes)
looker_studio_setup.md dashboard build guide
data_canvas_prompts.md BigQuery Data Canvas prompt checklist
archive/v1_blog_based/ the FIRST approach, abandoned - kept for the story
evidence_packs.json hand-compiled data from market-research blogs
run_analysis.py local Claude-based analysis script (pre-BigQuery)
main.py Cloud Run + Claude via Vertex Model Garden version
ARCHITECTURE_google.md that architecture's design doc
RUNBOOK.md its deployment runbook
Dubai_Competitor_Analysis_Sonnet_Handoff.md the original handoff spec
The first version of this project used blog-sourced market-share estimates and Claude via Vertex AI Model Garden. Two real problems killed that path:
- Data quality: blog-cited numbers (e.g. "Careem = 90% market share") were unsourced, contradictory across sources, and stale.
- Access friction: Claude via Vertex Model Garden is sold through Google Marketplace, which requires a full business-verification process and a non-trial billing account — a real wall for a solo, budget-capped project.
The fix for both: switch to first-party review and financial data (verifiable, free) and Gemini via native Vertex AI (no Marketplace, works under a free trial). The archive is kept because the pivot itself — and the reasons for it — are part of the honest story of building this.
cd pipeline
python -m venv venv
.\venv\Scripts\Activate.ps1
pip install requests google-play-scraper google-cloud-bigquery google-genai
gcloud auth application-default login
gcloud services enable bigquery.googleapis.com aiplatform.googleapis.com
bq mk --dataset --location=us-east5 YOUR-PROJECT-ID:competitor_intel
$env:SEC_UA="YourName YourProject your@email.com"
$env:PROJECT="YOUR-PROJECT-ID"
$env:REGION="us-east5"
python run_pipeline.pyFor weekly automation, point Windows Task Scheduler at weekly_run.bat (edit the project ID/email inside it first).
Bugs found and fixed along the way (kept for honesty, not hidden)
- Wrong-app matches: fuzzy App Store search silently matched "Spotii" → WhatsApp, and "Hala Taxi" → Careem, on generic word overlap. Fixed with a stopword filter and a manual-override system (
play_id_override,apple_id_override,trustpilot_slugincompanies.json) so every ID is either validated or explicitly verified by hand. - Cashew → wrong app: matched a language app on the shared word "Pay." Same fix.
- Duplicate rows in analysis:
review_aggcorrectly accumulates one row per weekly run (that's the point — it's a time-series table), but the analysis query wasn't deduplicating, so it fed Gemini two blended snapshots per company. Fixed withQUALIFY ROW_NUMBER() ... = 1to always read only the latest snapshot. - Windows encoding crash: a ⚠ emoji in a print statement crashed the scheduled run under Windows'
cp1252console encoding (worked fine interactively, broke when Task Scheduler redirected output to a log file). Fixed by using plain ASCII ([!]) and forcingPYTHONIOENCODING=utf-8as a backup. - Trustpilot: blocked by Cloudflare bot-protection (403) on every request. Not fixable via headers — accepted as a dead end; Apple + Google Play carry the review data instead.
- Spotii: genuinely unresolved by design. Sources conflict on its current ownership (NymCard acquisition vs. a reported "separation from Zip Co" and relaunch); no live official store listing was found. Treated as a real finding (a possibly declining/unstable brand), not a bug to paper over.
Total spend across the entire project, from first API call to today: under $0.03. Google Cloud infrastructure (BigQuery storage, load jobs, Cloud Scheduler equivalent) has cost $0 — all within free tiers.
MIT