Appearance
Install & Run
This page explains how to run the weekly analytics package on a laptop, VM, container, or scheduled cloud job.
Download
Requirements
| Requirement | Purpose |
|---|---|
| Python 3 | Runs the report pipeline. |
| Node.js 18+ | Required only for Cloudflare publishing through Wrangler/Staticrypt. |
| Pylon API key | Pulls accounts, issues, and custom fields. |
| Ollama | Optional but required for narrative summaries. |
| Cloudflare credentials | Optional; required for publishing the password-protected report archive. |
Install Pipeline
bash
tar -xzf freighttiger-weekly-analytics-pipeline.tar.gz
cd report-pipeline
python3 -m venv .venv
.venv/bin/pip install -r requirements.txt
cp .env.example .envEdit .env:
bash
PYLON_API_KEY=...Enable Summaries
The summary step expects Ollama locally:
bash
ollama serve
ollama pull qwen3:8bIf summaries are not required, or Ollama is unavailable, run only the deterministic steps against an existing snapshot.
Run The Weekly Report
Full run:
bash
make allManual staged run:
bash
.venv/bin/python scripts/01_pull_pylon.py --date YYYY-MM-DD
.venv/bin/python scripts/02_compute_metrics.py --date YYYY-MM-DD
.venv/bin/python scripts/03_generate_summaries.py --date YYYY-MM-DD
.venv/bin/python scripts/04_render_report.py --date YYYY-MM-DDExpected output:
text
data/weekly_snapshots/{date}/...
reports/{date}/report.html
reports/{date}/report.mdPublish
One-time login:
bash
make cf-loginPublish:
bash
make publish REPORT_PASSWORD='...' PAGES_PROJECT='ft-tms-weekly'Publishing creates:
text
publish/{date}/index.html
publish/latest/index.html
publish/index.htmland deploys publish/ to Cloudflare Pages.
Cron Shape
Recommended weekly cron:
bash
cd /opt/ft-weekly-analytics
make all
make publish REPORT_PASSWORD="$REPORT_PASSWORD" PAGES_PROJECT="ft-tms-weekly"Store these outside source control:
PYLON_API_KEYREPORT_PASSWORD- Cloudflare/Wrangler credentials
Validation
After installation:
bash
make all
test -f reports/$(date -u +%Y-%m-%d)/report.html
test -f reports/$(date -u +%Y-%m-%d)/report.mdFor package-only validation:
bash
python3 /path/to/skill-creator/scripts/quick_validate.py skills/freighttiger-weekly-analyticsExisting snapshot protection
01_pull_pylon.py refuses to overwrite a non-empty dated snapshot folder. Use a new --date or intentionally remove the incomplete generated folder.