This repository contains a distributed crawl -> process -> route -> embed -> search pipeline with a web UI.
go-crawlercrawls and publishes crawl events.go-processorcleans/enriches pages, writes MongoDB, indexes Meilisearch, and emits process events.go-pipelineroutes Kafka topics with Redis dedupe:crawl-events->process-eventsprocess-events->embed-events
embed/embed_worker.pyconsumesembed-eventsand writes embeddings to MongoDB.go-searchserves search APIs (/search,/search/images,/knowledge,/faq).search-uiserves the frontend.
- Docker Desktop (running)
- Go 1.22+
- Node.js 20+
- npm 10+
- Python 3.13 or 3.14
Recommended on Windows:
- Use Python 3.13 for
embed_server.pybecause older Torch pins may not support Python 3.14. embed_worker.pycan run on Python 3.14 with current compatible packages.
docker-compose.yml-> local infrago-crawler/-> crawler servicego-processor/-> cleaner/indexer servicego-pipeline/-> Kafka router/dedupe servicego-search/-> search API serviceembed/-> embedding server + embedding workersearch-ui/-> Next.js frontend
From repo root:
docker compose up -d redis redpanda mongodb meilisearchValidate broker health:
docker exec redpanda rpk cluster healthCreate app topics (safe to run repeatedly):
docker exec redpanda rpk topic create crawl-events process-events embed-events feedback-events --partitions 1 --replicas 1cd go-crawler; go mod tidy
cd ..\go-processor; go mod tidy
cd ..\go-pipeline; go mod tidy
cd ..\go-search; go mod tidycd ..\search-ui
npm installcd ..\embed
py -3.13 -m venv .venv313
.\.venv313\Scripts\activate
python -m pip install --upgrade pip
pip install -r requirements.txtIf Torch install fails on 3.14, run worker-only dependencies:
cd embed
py -m pip install kafka-python redis requests pymongoFrom repo root in PowerShell:
.\run.ps1This starts Docker infrastructure, creates Kafka topics, starts the always-on app services, and streams Docker + app logs in one terminal with service prefixes. Open:
http://localhost:3000
Optional data build jobs:
.\run.ps1 -WithCrawler
.\run.ps1 -WithProcessor
.\run.ps1 -WithCrawler -WithProcessorUseful launcher flags:
-Build-> rebuild Docker infrastructure images before starting.-SkipInfra-> skip Docker startup/topic creation when infra is already running.-CpuThreads 2-> raise the default low-CPU thread limit.
Press Ctrl+C to stop app processes. Docker infrastructure remains running.
Open separate terminals.
cd D:\work\org\google\embed
py .\embed_server.pyExpected:
- model loading logs
- server starts on
http://localhost:5000
cd D:\work\org\google\go-pipeline
$env:KAFKA_BROKERS="localhost:9092"
$env:REDIS_ADDR="localhost:6379"
go run .Expected:
Pipeline router starting mode=all- routing lines for both routes
cd D:\work\org\google\embed
py .\embed_worker.pyExpected:
Starting embed worker topic=embed-events brokers=['localhost:9092']
cd D:\work\org\google\go-search
go run .Expected:
- API running on
:8080 - inverted index ready message
cd D:\work\org\google\search-ui
npm run devOpen:
http://localhost:3000
Run these when you want fresh crawl/index data.
cd D:\work\org\google\go-crawler
$env:MONGO_URI="mongodb://admin:securepassword@localhost:27017"
go run .If running embed server during processing:
cd D:\work\org\google\go-processor
$env:MONGO_URI="mongodb://admin:securepassword@localhost:27017"
$env:SKIP_EMBEDDINGS="0"
go run .If embedding should be fully event-driven through embed_worker.py:
cd D:\work\org\google\go-processor
$env:MONGO_URI="mongodb://admin:securepassword@localhost:27017"
$env:SKIP_EMBEDDINGS="1"
go run .go-crawler: when you need to discover/fetch new pages.go-processor: after crawl, to clean/rank/index pages.go-pipeline: whenever distributed event routing is needed (usually always-on in dev).embed_worker.py: whenembed-eventsare used for async embeddings.embed_server.py: required if any component requests local embedding API.go-search: always needed for API endpoints.search-ui: always needed for browser interface.
docker exec redpanda rpk cluster health
docker exec redpanda rpk topic listcurl "http://localhost:8080/search?q=example"
curl "http://localhost:8080/knowledge?q=example"
curl "http://localhost:8080/faq?q=example"Cause:
- broker not running yet, or topic/coordinator not ready.
Fix:
docker compose up -d redpanda
docker exec redpanda rpk cluster health
docker exec redpanda rpk topic create crawl-events process-events embed-events feedback-events --partitions 1 --replicas 1
cd D:\work\org\google\go-pipeline
go run .Fix:
cd D:\work\org\google\embed
py -m pip install kafka-python redis requests pymongoCause:
- Torch pin may not support your Python version (commonly Python 3.14).
Fix:
- use Python 3.13 venv for
embed_server.py, or - upgrade Torch pins in requirements to versions supporting your runtime.
Meaning:
- common model-load warning when loading from a related architecture/task.
- often safe if model runs and output quality is acceptable.
- not safe only if you require exact architecture weight parity.
Meaning:
307on model files is normal CDN redirect behavior.404for optional paths likeadditional_chat_templatesis usually harmless.
Meaning:
- image embedding falls back to text-only mode.
Fix (optional):
cd D:\work\org\google\embed
py -m pip install openai-clipIf CLIP still fails, keep running text-only mode for images.
Windows interactive helper:
cd D:\work\org\google
.\pipeline.batThis script can run crawl/process/debug flows and starts MongoDB if needed.