Automatically scrape the OptiSigns Zendesk Help Center, convert articles to Markdown, detect changes, and synchronize only new or updated articles to an OpenAI Vector Store for Retrieval-Augmented Generation (RAG).
- Scrape OptiSigns Zendesk Help Center
- Convert HTML articles to Markdown
- Store article metadata locally
- Detect new and updated articles using content hashing
- Upload only changed articles to OpenAI Vector Store
- Configurable chunking strategy
- Daily execution via Railway Cron
- Dockerized deployment
- Structured logging
The Assistant Playground screenshot is not included because the OpenAI Playground requires a billing-enabled account.
app/
│
├── config/
├── openai/
├── scraper/
├── storage/
├── utils/
│
├── main.py
│
data/
│
├── html/
├── markdown/
├── metadata/
└── state/
Dockerfile
requirements.txt
README.md
Zendesk API
│
▼
Fetch Articles
│
▼
Detect Changes
(Hash Comparison)
│
▼
Save HTML
│
▼
Convert Markdown
│
▼
Upload Delta Files
│
▼
OpenAI Vector Store
Clone the repository
git clone https://github.com/VoHuan/ChatBot.git
cd ChatBotCreate virtual environment
python -m venv .venvActivate
Windows
.venv\Scripts\activateLinux / macOS
source .venv/bin/activateInstall dependencies
pip install -r requirements.txtCreate a .env file
OPENAI_API_KEY=your_api_keypython -m app.mainBuild
docker build -t optisigns-sync .Run
docker run --rm \
-e OPENAI_API_KEY=YOUR_KEY \
optisigns-syncEach execution performs:
- Fetch latest Zendesk articles
- Calculate content hash
- Compare with previous hashes
- Detect
- Added
- Updated
- Skipped
Only added and updated articles are uploaded to OpenAI.
OpenAI Vector Store performs automatic embedding.
Static chunking configuration:
chunking_strategy={
"type": "static",
"static": {
"max_chunk_size_tokens": 1200,
"chunk_overlap_tokens": 400
}
}Each execution generates a summary similar to:
============================================================
OptiSigns Daily Sync Summary
============================================================
Fetched : 404
Added : 2
Updated : 1
Skipped : 401
Uploaded Files : 3
Vector Store : vs_xxxxxxxxx
============================================================
The application is deployed as a Railway Cron Job.
Execution schedule:
0 1 * * *
(Every day at 01:00 UTC)
The project maintains several local state files.
data/state/
Includes
- hashes.json
- vector_store.json
- vector_files.json
These files allow incremental synchronization between executions.
- Python 3.13
- OpenAI SDK 2.x
- OpenAI Vector Store
- BeautifulSoup
- Markdownify
- Docker
- Railway
- Zendesk Help Center API
Vo Van Huan

