[verified] build tourism signal dashboard
This commit is contained in:
47
docs/HANDOFF.md
Normal file
47
docs/HANDOFF.md
Normal file
@@ -0,0 +1,47 @@
|
||||
# Handoff — Tourism Vertical Slice
|
||||
|
||||
## Project
|
||||
|
||||
- Path: `/Users/kunthawat/Gitea/set50-alternative-data-platform`
|
||||
- Mode: research + paper only
|
||||
- Frontend: Vue 3 + Vite
|
||||
- Backend: Flask
|
||||
- Current data: deterministic fixture with lineage metadata
|
||||
|
||||
## Completed
|
||||
|
||||
- Tourism snapshot schema with source, publication, retrieval and vintage fields.
|
||||
- Deterministic Tourism Pulse score: standardized surprise × exposure × confidence.
|
||||
- Ranked target weights and LONG/SHORT/NEUTRAL classification.
|
||||
- Flask endpoints for health, summary, observations, signals and paper ledger.
|
||||
- English dashboard with live API data, lineage panel, signal table and paper-entry form.
|
||||
- No external webhook or MT5 integration.
|
||||
|
||||
## Verified commands
|
||||
|
||||
```text
|
||||
PYTHONPATH=backend .venv/bin/python -m unittest discover -s backend/tests -v
|
||||
Ran 10 tests ... OK
|
||||
|
||||
Paper writes use a server-side token exchange and HttpOnly `paper_session` cookie; the token is not embedded in the frontend bundle.
|
||||
|
||||
npm run build
|
||||
Vite build completed successfully.
|
||||
|
||||
GET /api/v1/health
|
||||
{"mode":"research","status":"ok","version":"0.1.0"}
|
||||
|
||||
POST /api/v1/paper/ledger + GET /api/v1/paper/ledger
|
||||
PAPER_RECORDED and readback verified.
|
||||
|
||||
Independent review
|
||||
PASSED — no concrete security or logic blockers.
|
||||
```
|
||||
|
||||
## Known limitation
|
||||
|
||||
The data adapter is a fixture. It demonstrates the contract and calculation, not live tourism data quality. Browser visual screenshot verification was blocked by a Chrome remote-debugging permission prompt; served HTML, API response and frontend build were verified instead.
|
||||
|
||||
## Next action
|
||||
|
||||
Implement one replayable Tourism source adapter without changing the snapshot contract. Add parser fixture tests, publication timestamp handling, raw snapshot hash, and a data-health failure state before adding LLM analysis.
|
||||
32
docs/engineering-log.md
Normal file
32
docs/engineering-log.md
Normal file
@@ -0,0 +1,32 @@
|
||||
# Engineering Log — SET50 Alternative Data Platform
|
||||
|
||||
## Current status
|
||||
|
||||
| Milestone | Status | Evidence | Next action |
|
||||
|---|---|---|---|
|
||||
| M0 repo foundation | complete | Flask API, Vue/Vite shell | replace fixture with source adapter |
|
||||
| Tourism deterministic signal | complete | 7 backend tests pass | add replayable real source |
|
||||
| Internal paper ledger | complete | POST/readback through live API | persist in PostgreSQL later |
|
||||
| Dashboard | complete | Vite build + live HTML/API checks | visual browser capture after permission is available |
|
||||
| LLM analysis | deferred | intentionally no LLM dependency in M0 | add after signal lineage is stable |
|
||||
| Webhook receiver | deferred | contract only, no external receiver | choose after core app is usable |
|
||||
| MT5 bridge | deferred | not started | paper bridge after webhook decision |
|
||||
|
||||
## Guardrails
|
||||
|
||||
- Research and paper modes only.
|
||||
- No live orders, external webhook receiver, broker credentials, or MT5 connection.
|
||||
- Deterministic signal is authoritative; LLM will remain downstream.
|
||||
- Fixture source is clearly marked and must be replaced before investment use.
|
||||
- `target_weight` is recorded in the internal paper ledger; it is not an order.
|
||||
|
||||
## Verification
|
||||
|
||||
- Backend: 10 unittest tests pass.
|
||||
- Independent review: **PASSED**; no concrete security or logic blockers.
|
||||
- Reviewer suggestions: set `PAPER_COOKIE_SECURE=1` outside local HTTP; replace in-memory sessions before multi-worker deployment.
|
||||
- Frontend: `npm run build` passes with Vite.
|
||||
- Backend health endpoint returns HTTP 200 JSON.
|
||||
- Dashboard served HTML contains the current title, Vue mount point and Vite entry.
|
||||
- Paper ledger POST and readback work through the live API.
|
||||
- Browser visual capture was blocked by Chrome remote-debugging permission; no permission dialog was clicked.
|
||||
Reference in New Issue
Block a user