@davoodmehraban89 / VELYQOR / commits / 4649149
Fork 0

Intelligence, Advanced Charting & Trading Platform

docs(stage1): reconcile ChartNova production evidence and gated risk plan (#31)

* docs(ops): add evidence-only versioned production manifest with rollback provenance and unknowns * docs(data): add official-source market feed rights, quota, cadence matrix with unknowns * docs(product): quantify free-tier cadence and explicitly unguaranteed alert latency * docs(product): replace six-module rollout with gated one-source one-alert one-channel vertical slice * docs(audit): evidence-register every Stage-0 finding with repo SHA, PR and unknown status * docs(ops): reconcile merged PR #29, recorded v26 rollback, root-cause unknown and future deployment gates * docs(readme): align project scope, deployed-source uncertainty and realistic free-tier service level * docs(state): supersede stale v27 live claim with recorded v26 rollback and seven-PR inventory * docs(ops): clearly archive v27 production rollout and link documented v26 rollback * docs(data): mark 2026-10-05 provider matrix as historical rather than deployed truth * docs(sources): replace uncertain TGJU deep link with confirmed official FAQ source * docs(manifest): distinguish original seven open PRs from new Stage-1 Draft PR #31 * docs(state): count Draft PR #31 separately from seven pre-existing open reviews

davoodmehraban89 committed Oct 15, 2026 at 19:24 UTC 4649149b1f920aecbe4c26597983d9bb35d90427
10 files changed +409 -20
PROJECT_STATE.md
+17 -1
@@ -1,7 +1,23 @@
1 # VELYQOR Project State
2
3 +## Latest Stage-1 checkpoint — 2026-10-15 (DOC-ONLY / not yet merged)
4
4 -## 2026-10-15 — ChartNova production performance hotfix (deployed, verified)
5 +**Review base:** [main 381ba284d47f284f034afacc7d6cc41fc31af8f9](https://github.com/davoodmehraban89/VELYQOR/commit/381ba284d47f284f034afacc7d6cc41fc31af8f9). This heading **supersedes all time-specific "current production" claims below** without falsifying the historical events.
6 +
7 +- **Production runtime last RECORDED, not live-rechecked in this documentation stage:** Cloudflare Worker v26 version ID **85177f9d-09c0-4763-b28c-2c6ba5ae5be5**, 100%; rollback deployment ID **78155d6f-11fc-4d1b-ab4f-7c0a97474406** (2026-10-15 05:59 UTC). The prior v27 release **2cbeb4e2-4a3e-414f-b3ad-035e2378650b** had been activated, then **rolled back after the user reported the site would not open**. The technical root cause is **تأییدنشده**. See [exact evidence and incident timeline](docs/operations/chartnova-stage1-production-reconciliation-2026-10-15.md), [versioned manifest](docs/operations/production-manifest.json), [rollback-branch record](https://github.com/davoodmehraban89/VELYQOR/blob/ops/chartnova-emergency-rollback-2026-10-15/PROJECT_STATE.md). **Current live version at this exact moment: تأییدنشده**, because Stage 1 made no Cloudflare inspection.
8 +- **Repository:** PR [#29](https://github.com/davoodmehraban89/VELYQOR/pull/29) was merged previously; its reviewed scripts/tests/docs do **not** provide an exact verified complete deployed Worker source for v26. **PR #29 cannot be "merged again".** The stale v27 heading below is retained solely as an archival account.
9 +- **PR inventory checked via GitHub (before creating Stage-1 documentation PR):** 7 OPEN: [#21](https://github.com/davoodmehraban89/VELYQOR/pull/21), [#22](https://github.com/davoodmehraban89/VELYQOR/pull/22), Draft [#23](https://github.com/davoodmehraban89/VELYQOR/pull/23) → Draft [#24](https://github.com/davoodmehraban89/VELYQOR/pull/24) → Draft [#27](https://github.com/davoodmehraban89/VELYQOR/pull/27), Draft [#28](https://github.com/davoodmehraban89/VELYQOR/pull/28), Draft [#30](https://github.com/davoodmehraban89/VELYQOR/pull/30). PR [#25](https://github.com/davoodmehraban89/VELYQOR/pull/25) and [#26](https://github.com/davoodmehraban89/VELYQOR/pull/26) had already merged. Old PR inventory and old source-secret blocker paragraphs below are **historical**, not current authorization. **Draft [PR #31](https://github.com/davoodmehraban89/VELYQOR/pull/31) is the new documentation-only review, so the open PR count became 8 at its creation; no merge or deploy was performed.**
10 +- **Provider/quote integrity:** Old development plans Navasan and Alpha Vantage, while later PR/deployment records mention Gheymat Online, Oanor/TGJU UI label and Gold API. **Exact production mapping, quote side, commercial redistribution/storage rights and time-bounded latency are تأییدنشده.** No OHLC source is promoted to production by this docs PR. [Official provider matrix](docs/data/provider-source-matrix-2026-10-15.md).
11 +- **Free service level:** Official Navasan 120/month, 2h vendor updates → sustainable 30-day one-call interval **6 hours minimum**; Gheymat Online 250/day → **5m45.6s minimum** for one request per snapshot. Neither can guarantee threshold-alert delivery latency. **Not acceptable as a time-critical day-trader alert SLA**; only optional non-urgent informational pilot after license/semantics verification. [Full assumptions and alternate k=2 model](docs/product/realistic-service-level-2026-10-15.md).
12 +- **Next implementation proposal (NOT authorized here):** one USD_IRT_FREE source, one ABOVE/BELOW informational alert, one opted-in **Bale Bot** notification channel, quote labeled **«قیمت فروش منبع X»** *only after provider-side SELL verification*, otherwise alerts disabled. [Gated minimal vertical slice](docs/product/vertical-slice-roadmap-2026-10-15.md). Additional ATR/OCO/Trailing, failover and Paper Trading explicitly follow actual pilot evidence.
13 +- **Security/no-change guarantees:** No merge, production Worker deploy, DNS/Cloudflare config, Neon/KV mutation, paid resource, API-key access, real trade or local Worktree action in Stage 1. Untracked **db/migrations/0005_navasan_private_daily_ohlc.sql** stays blocked; most recent local worktree audit (2026-10-12) remains **historical; present state تأییدنشده**. [Evidence index A–H](docs/operations/stage0-evidence-register-2026-10-15.md).
14 +- **Open acceptance gates:** current deployed-v26 versioned code source/hash, affected-device outage reproduction, written provider rights, exact quote side/unit, real-source cadence, actual quota consumption, and delivery-channel proof. Not complete.
15 +
16 +---
17 +
18 +
19 +
20 +## Historical 2026-10-15 — ChartNova v27 performance hotfix (deployed then ROLLED BACK)
21
22 - **User request:** fix delayed/blank-to-loaded ChartNova initial data, prioritizing visible quote cards and avoiding unnecessary waiting.
23 - **Actual live Worker fixed:** `velyqor-preview` Cloudflare **v27** `2cbeb4e2-4a3e-414f-b3ad-035e2378650b`, deployment `c68b8340-398a-462b-9fe0-c635aba405fe`, rolled out at 100% on `2026-10-15T05:22:32Z`. Original v26 `85177f9d-09c0-4763-b28c-2c6ba5ae5be5` is retained for immediate rollback.
README.md
+29 -19
@@ -1,30 +1,40 @@
1 -# VELYQOR
1 +# VELYQOR / ChartNova
2
3 -**Iran Market Intelligence, Advanced Charting & Trading Platform**
3 +**Iranian market information and *non-advisory* monitoring — development/review project, NOT an execution or brokerage platform.**
4
5 -VELYQOR is a market-intelligence platform focused first on Iranian free-market USD and domestic 18K gold, connected to global XAU/USD data and derived valuation analytics.
5 +Canonical targets: free-market USD/IRT, 18K Iranian gold (IRT/gram), global XAU/USD and explicitly sourced, time-aligned derived values. **No real-money order routing is permitted**; trading automation and guaranteed execution-grade alerts are not in scope.
6
7 -## MVP
7 +## Verified source-of-truth hierarchy (as of 2026-10-15)
8
9 -- `USD_IRT_FREE` — Iran free-market USD/IRT
10 -- `GOLD18_IRT` — Iran 18K gold market price
11 -- `XAU_USD` — global gold spot price
12 -- `GOLD18_THEORETICAL_IRT` — theoretical 18K gold value derived from XAU/USD × USD/IRT
13 -- `GOLD18_PREMIUM_IRT` and `GOLD18_PREMIUM_PCT` — market premium/discount
14 -- Professional charting, drawings, indicators, comparison overlays, and persistent workspaces
9 +1. **This GitHub repository** holds reviewed architecture, contracts, tests and historical release evidence; it does **not** automatically reproduce whatever Worker is deployed at Cloudflare.
10 +2. **[Production manifest](docs/operations/production-manifest.json)** records the latest *repository-documented* deployed Worker version, not a live metadata attestation. The last recorded rollback restored **v26** after a user-reported outage on v27. The **technical root cause is تأییدنشده**.
11 +3. **[PROJECT_STATE.md](PROJECT_STATE.md)** is the current review/work checkpoint. Historical paragraphs about v27 being deployed describe a past point in time, not current production status. Full [Stage-1 reconciliation and incident history](docs/operations/chartnova-stage1-production-reconciliation-2026-10-15.md).
12 +4. **Source rights, units, side and cadence:** see the [2026-10-15 official provider evidence matrix](docs/data/provider-source-matrix-2026-10-15.md). A provider being reachable, an API key existing, or a price having a "sellPrice" field does **not** prove redistribution rights or true bid/ask.
13 +5. **Realistic service level:** [free-tier quota calculations and no-guaranteed-latency verdict](docs/product/realistic-service-level-2026-10-15.md). Present free-tier candidates are **not acceptable for time-critical day-trading alerts**.
14 +6. **Next planned scope, not implemented:** [one-source, one-threshold, one-channel vertical slice](docs/product/vertical-slice-roadmap-2026-10-15.md); it remains gated by data rights, quote side, technical/recipient testing and separate merge/deploy approvals.
15 +7. **Complete evidence index:** [Stage-0 evidence register](docs/operations/stage0-evidence-register-2026-10-15.md), with links to immutable main SHA, PR IDs, earlier audits and explicitly unverified claims.
16 +
17 +## MVP contract (planned, not all active in production)
18 +
19 +- USD_IRT_FREE — free-market USD/IRT (price side/source must be verified before alert activation).
20 +- GOLD18_IRT — Iranian 18K gold/IRT per gram.
21 +- XAU_USD — global spot reference USD/troy ounce.
22 +- GOLD18_THEORETICAL_IRT, GOLD18_PREMIUM_IRT, GOLD18_PREMIUM_PCT — source-timestamp-aligned derived measures; never invented quotes.
23 +- Charts: reference/price-point line data must not be misrepresented as licensed source OHLC.
24 +- Information-only threshold alerts are **proposed**. Live alert/notification delivery and real-money orders are **not verified operational**.
25
26 ## Engineering principles
27
18 -- PostgreSQL is the market-data source of truth.
19 -- Raw provider observations are retained for auditability.
20 -- All normalized backend timestamps are UTC; Iran-facing presentation uses `Asia/Tehran`.
21 -- Derived prices retain source provenance and calculation version.
22 -- Provider-specific behavior stays behind adapters.
23 -- AI is not a market-price source and cannot directly execute orders.
24 -- The MVP begins as a modular monolith; services are extracted only when evidence requires it.
28 +- PostgreSQL is the **intended canonical market-data persistence architecture**. Live Cloudflare Worker → Neon direct read was **not established** by the reviewed PRs; current public runtime may rely on KV mirrors. Do not conflate historical database proofs with production wiring.
29 +- Retain canonical instrument mapping, raw/source units (IRR vs IRT), quote side (buy/sell), provider and receive timestamps in UTC; display Iran times in Asia/Tehran.
30 +- Derived values and data-quality checks must retain source provenance and version. STALE/INVALID must suppress downstream price alerts, never silently downgrade.
31 +- Source-specific behavior behind reviewed adapters; non-sponsored no-cost MVP and no paid deployment without separate authorization.
32 +- **No secrets in Git or chat; no order execution; no unapproved migration** of db/migrations/0005_navasan_private_daily_ohlc.sql.
33 +- Preserve uncommitted local files and dirty worktrees. All production changes require separately approved release, valid source artifact, security/CI gates and rollback.
34 +- The React/TypeScript + Vite market terminal is in **Draft PR #24** (stacked on #23); this is **not evidence Next.js or that UI is deployed**. Paper-only manual simulator is Draft PR #27. Lightweight catalog is Draft PR #30.
35
36 ## Current phase
37
28 -**Phase 0 — Foundation & Governance**
38 +**Phase 1 — Market Data Integrity & Data Proof; Stage-1 documentation and deployment-manifest reconciliation under review.** The earlier Phase-0 Foundation statement is archived as historical. **This documentation PR has no merge/deploy/runtime effect.**
39
30 -See `PROJECT_STATE.md` and `docs/architecture/` for the current execution state and architecture decisions.
40 +See [PROJECT_STATE.md](PROJECT_STATE.md), [market contracts](docs/data/market-contracts.md), and [release safety gates](docs/security/P0_RELEASE_GATES.md).
docs/data/provider-source-matrix-2026-10-15.md new
+32
@@ -0,0 +1,32 @@
1 +# Source evidence matrix — 2026-10-15 (review only)
2 +
3 +Status: **documentary research; zero provider credentials used, no production activation**. This is a **dated evidence snapshot**, not a market-data license grant or vendor SLA. Any field not verified on an official provider-owned source is **تأییدنشده**.
4 +
5 +## Reading rules
6 +
7 +1. "Instant / realtime" is a **vendor marketing/update-rate statement**, not an observed maximum end-to-end latency or bid/ask execution quote. Where timing of an actual source tick is not demonstrated, write **تأییدنشده**.
8 +2. A vendor's right to let an API *be accessed* or *embedded in websites* must not be equated with a written right to store, bulk-republish, resell or redistribute raw/history data. Those rights are independently reviewed.
9 +3. A sample response or free pricing page is not an entitlement for every instrument or price side. Raw **IRR→IRT /10** and **buy/sell** mappings require provider-verified evidence (see [Navasan adapter](../../packages/market-domain/src/adapters/navasan.mjs) and [P0 gate](../security/P0_RELEASE_GATES.md)).
10 +4. Relevant prior repository evidence: [initial provider matrix](provider-source-matrix.md) at [main 381ba284](https://github.com/davoodmehraban89/VELYQOR/blob/381ba284d47f284f034afacc7d6cc41fc31af8f9/docs/data/provider-source-matrix.md); [provider transition policy, PR #22](https://github.com/davoodmehraban89/VELYQOR/blob/phase-1/gold-api-fallback/docs/data/iran-provider-transition-policy.md); [PR #30 on-demand catalog proof](https://github.com/davoodmehraban89/VELYQOR/blob/95e1389ba313c14652cf380182e5ea4b34007b3e/docs/operations/chartnova-compact-catalog-stage1-2026-10-15.md).
11 +
12 +## Official-source evidence (checked 2026-10-15)
13 +
14 +| Provider / instrument | Free quota | Vendor update rate / historical support | Buy/sell side & unit | Redistribution / storage rights | Scraping risk, status and source |
15 +|---|---|---|---|---|---|
16 +| **Navasan** — domestic FX, gold | **120 API calls/month**. Official free plan states update **every 2h**; update cadence is not the call quota. | Daily history and OHLC endpoints advertised; maximum actual depth, live freshness and completeness by symbol **تأییدنشده**. | English vendor page calls its FX prices **IRR**; exact units/quote side of \`usd_sell\`, \`18ayar\` and \`ohlcSearch\` response **تأییدنشده**. Local IRR-vs-IRT conflict stays BLOCKED. | Explicit right to commercial storage/public redistribution **تأییدنشده**. | Use documented API; scraping consent **تأییدنشده**. [Official plan and web-service description](https://www.navasan.tech/en/api), [official webservice guide](https://www.navasan.tech/webserviceguide/). |
17 +| **Gheymat Online** — domestic market snapshots | **250 API requests/day**, official free plan. | Official site claims **لحظه‌ای** updates but expressly disclaims guaranteed correctness/freshness. Actual measured provider timestamp lag and historical entitlement **تأییدنشده**. PR #30 recorded up to 168 *numeric price points* per symbol from the deployed app, **not independently verified source OHLC or timestamps for each point**. | Exact buy/sell mapping per USD, gold18 and other symbols **تأییدنشده** from public official docs; do not infer from a \`sellPrice\` field in the existing app. | Explicit commercial archival/public redistribution permission **تأییدنشده**. The pricing page markets embedding data in products but does not establish a blanket redistribution license. | Non-official scraping rights **تأییدنشده**; API Swagger is linked, no authenticated account was used. [Official price API/free plan and disclaimer](https://gheymat.online/price-api); [official Swagger link](https://backend.gheymat.online/docs/api). |
18 +| **TGJU / Persian API** — domestic price feed | Free public API quota **تأییدنشده**; official support explains a *purchased* web-service token, plan-specific request count. | Product-dependent rate and frequency; any actual guaranteed update interval **تأییدنشده**. | Side/unit by purchased package **تأییدنشده**. | Official terms prohibit copying/reusing website content, prices and data without written agreement: **not authorized for unlicensed scraping/redistribution**. Separate purchased-API grant scope must be reviewed. | **HIGH scraping/republication risk**. [Official site terms, clause 18](https://gem.tgju.org/terms); [official API purchase guide](https://help.tgju.org/سئوالات-متداول/); [official API package/request limits explanation](https://help.tgju.org/سئوالات-متداول/). |
19 +| **BrsApi** — domestic | **تأییدنشده**. Official domain page \`https://brsapi.ir/free-api-gold-currency-webservice/\` could not be retrieved with available tools (timeout); do not use community reports of "1500/day" as official evidence. | **تأییدنشده**. | **تأییدنشده**. | **تأییدنشده**. | Scraping permission **تأییدنشده**. [Provider domain / attempted official page](https://brsapi.ir/free-api-gold-currency-webservice/) and [provider registration portal](https://api.brsapi.ir/Panel/register.html); inaccessible in this audit. |
20 +| **Bon-bast** — domestic | No free public developer tier confirmed on official docs; lowest listed **paid** Basic plan **$469/year, 10,000 calls/month**. | Near-real-time rates and historical series advertised; contractual maximum lag, history range and time standard **تأییدنشده**. | Official site displays toman/IRR; exact per-instrument bid/ask mapping for paid API **تأییدنشده**. | Commercial API access offered **by paid contract**; raw-data redistribution/archive terms **تأییدنشده**. | Scraping the public page is **not** equivalent to purchasing rights; high risk. [Official API docs/pricing](https://www.bon-bast.com/docs), [official support contact](https://www.bon-bast.com/contact). |
21 +| **Alpha Vantage** — gold spot candidate | **25 requests/day** on standard free API per official support/pricing. | Gold/silver spot endpoint and daily history documented; maximum XAU refresh/update delay under free tier **تأییدنشده**. | XAU/USD reference spot; explicit executable bid/ask **تأییدنشده**. | **Restricted**: [official Terms of Service §2](https://www.alphavantage.co/terms_of_service/) grants personal non-commercial use unless otherwise agreed in writing, including third-party access in its commercial-use definition. Do **not** assume a free key permits a public ChartNova market feed. | Use official authenticated API only. [Official free-plan support](https://www.alphavantage.co/support/), [official API documentation](https://www.alphavantage.co/documentation/), [official ToS](https://www.alphavantage.co/terms_of_service/). |
22 +| **Gold API** — XAU/USD | [Official pricing](https://gold-api.com/pricing): unlimited real-time price API calls; free historic/OHLC **10 requests/hour**. Abuse/multiple requests per second may trigger restriction. | "Realtime" is advertised; actual maximum feed age and latency **تأییدنشده**. History endpoints exist, but precise free retained depth **تأییدنشده**. | XAU price USD/oz; executable buy/sell spread **تأییدنشده**. | A newly indexed official [Terms page](https://gold-api.com/terms) (effective **2026-09-10**, §9) **states commercial API use is permitted for websites/apps**; older cached rendition of same URL lacks §9. **Conflicting snapshots**: commercial use appears described in newer index, but explicit raw-data archiving/sublicensing/redistribution remains **تأییدنشده**. Obtain the actual current contractual copy before asserting licensing. | API endpoints published for direct use; third-party scraping rights **تأییدنشده**. [Official price API docs](https://gold-api.com/docs), [pricing](https://gold-api.com/pricing), [terms](https://gold-api.com/terms). |
23 +
24 +### Rights and latency decision
25 +
26 +- **No domestic provider has documented, verified, no-cost public redistribution AND a tested bounded alert latency** in this review. Product activation and any bulk backfill are blocked until the relevant rights and quote-side semantics are confirmed.
27 +- **No pair is declared cross-checked**. The secondary source, if later authorized, must match *instrument, market, side, unit, timestamp and quality*.
28 +- Existing UI source **labels** ("Oanor/TGJU", "Gold API") are not sufficient to certify backend feed provenance for every displayed symbol; [PR #29 operational record](../operations/chartnova-production-progressive-loading-2026-10-15.md) and [PR #30 catalog documentation](https://github.com/davoodmehraban89/VELYQOR/blob/95e1389ba313c14652cf380182e5ea4b34007b3e/docs/operations/chartnova-compact-catalog-stage1-2026-10-15.md) describe divergent historical sources. Maintain **تأییدنشده** until a versioned Worker-source artifact and real response proof are available.
29 +
30 +### Required vendor evidence before any single-provider pilot
31 +
32 +Written/current official source confirmation of quote-side, IRR/IRT units and names for selected instrument; allowed public display, retention and derived alerts; actual quota/reset timezone and authentication limits; provider timestamp guarantees; a sanitized one-call sample; non-sensitive entitlement reference. Never put an API key or contract PDF containing credentials into this public repo.
docs/data/provider-source-matrix.md
+2
@@ -1,5 +1,7 @@
1 # Provider Source Matrix — Phase 1 Data Proof
2
3 +> **HISTORICAL / 2026-10-05 candidate matrix.** This file records development-era Navasan, Bon-bast and Alpha Vantage candidates, **not confirmed live ChartNova data provenance**. For up-to-date official-plan observations, licensing restrictions, vendor links, unknowns and Gheymat Online/TGJU/BrsApi/Gold API see [official-source review 2026-10-15](provider-source-matrix-2026-10-15.md). For recorded Worker/PR divergence see [Stage-1 reconciliation](../operations/chartnova-stage1-production-reconciliation-2026-10-15.md). No provider is approved by this documentary note.
4 +
5 Research date: 2026-10-05
6
7 This matrix is an engineering gate, not a provider endorsement. A provider is not promoted to production solely because an API is reachable. Licensing/commercial rights, timestamp quality, update frequency, history, reliability, and reproducibility must all be acceptable.
docs/operations/chartnova-production-progressive-loading-2026-10-15.md
+4
@@ -1,5 +1,9 @@
1 # ChartNova — Production Initial-Load Performance Fix (2026-10-15)
2
3 +
4 +> **ARCHIVAL / NOT CURRENT PRODUCTION STATE — 2026-10-15.** The v27 deployment described below was a real historical rollout but **was subsequently rolled back** after a user reported the site would not open. The repository last records v26 version ID **85177f9d-09c0-4763-b28c-2c6ba5ae5be5** at 100% in rollback deployment **78155d6f-11fc-4d1b-ab4f-7c0a97474406** at 05:59:12 UTC. This is repository evidence, **not a fresh Cloudflare inspection**. The *reason for the rollback decision* was the user-facing outage report; the *technical root cause* is **تأییدنشده** without affected-device traces. Do **NOT** redeploy v27 or treat this document's original "deployed" section as current. See [Stage-1 timeline / missing evidence](chartnova-stage1-production-reconciliation-2026-10-15.md), [rollback record](https://github.com/davoodmehraban89/VELYQOR/blob/ops/chartnova-emergency-rollback-2026-10-15/PROJECT_STATE.md), and [production manifest](production-manifest.json).
5 +
6 +
7 ## Verified incident and cause
8
9 User reported that `https://app.chartnova.ir/` eventually opened but initial prices loaded late. Direct external API checks confirmed successful market data with 58 symbols, but `/api/markets` returned approximately 85 KB and response durations fluctuated.
docs/operations/chartnova-stage1-production-reconciliation-2026-10-15.md new
+44
@@ -0,0 +1,44 @@
1 +# ChartNova Stage 1 — reconciliation of Git history and production records
2 +
3 +**Date:** 2026-10-15. **Type:** docs/manifest ONLY. **Base:** main at [381ba284d47f284f034afacc7d6cc41fc31af8f9](https://github.com/davoodmehraban89/VELYQOR/commit/381ba284d47f284f034afacc7d6cc41fc31af8f9). Not an operational change or real-time Cloudflare audit.
4 +
5 +**First-party repository evidence:** [Stage-0 indexed register](stage0-evidence-register-2026-10-15.md). **Machine-readable historical record:** [production-manifest.json](production-manifest.json). **Separate updated vendor evidence:** [official-source matrix](../data/provider-source-matrix-2026-10-15.md).
6 +
7 +## Version facts and incident timeline, not guessed root causes
8 +
9 +| Event | UTC time | version/deployment | Source of record | Verification scope |
10 +|---|---|---|---|---|
11 +| Before hotfix | Historical | v26, Worker version 85177f9d-09c0-4763-b28c-2c6ba5ae5be5 | [PR #29 production operations record](chartnova-production-progressive-loading-2026-10-15.md) | Snapshot of earlier production; raw source hash **تأییدنشده** |
12 +| Direct Cloudflare hotfix | **2026-10-15 05:22:32** | v27 / deployment c68b8340-398a-462b-9fe0-c635aba405fe | [PR #29 operations doc](chartnova-production-progressive-loading-2026-10-15.md) | Deployed then; not proof it remains live |
13 +| User report after hotfix | After v27 publication, before rollback | Site not opening on user device | [Rollback branch incident evidence](https://github.com/davoodmehraban89/VELYQOR/blob/ops/chartnova-emergency-rollback-2026-10-15/PROJECT_STATE.md) | **Reported incident**. No client JS trace, browser logs or network waterfall in the repo |
14 +| Emergency rollback | **2026-10-15 05:59:12** | Restored v26 / deployment 78155d6f-11fc-4d1b-ab4f-7c0a97474406, documented 100% | [Rollback branch state](https://github.com/davoodmehraban89/VELYQOR/blob/ops/chartnova-emergency-rollback-2026-10-15/PROJECT_STATE.md); [PR #30 state](https://github.com/davoodmehraban89/VELYQOR/blob/95e1389ba313c14652cf380182e5ea4b34007b3e/PROJECT_STATE.md) | **Last repository-recorded production state**; not rechecked live in Stage 1 |
15 +| Later user report | After rollback | Root URL chartnova.ir opens and speed improved | [PR #30 state](https://github.com/davoodmehraban89/VELYQOR/blob/95e1389ba313c14652cf380182e5ea4b34007b3e/PROJECT_STATE.md) | Reported by user; app subdomain resolution and device logs **تأییدنشده** |
16 +
17 +**WHY v26 was restored:** after the v27 frontend-loading hotfix was released, the user explicitly reported the site would **not open on their device**. The rollback was a **risk-containment response**, not a demonstrated causal attribution. The historical snapshot notes independent HTTP and API checks succeeded after rollback, but this is NOT proof that v27 JavaScript caused the outage.
18 +
19 +**What is missing to establish root cause:** browser console stack trace/line, affected device/browser/OS/version, capture of HTTP waterfall including Service Worker/cache, failing resource and status, actual bad HTML/bundle hash served to the affected browser, VPN/ISP routing, controlled A/B reproduction and timestamp correlation. **ROOT CAUSE = تأییدنشده.** Do not label the incident "fixed by progressive loader", and do not automatically redeploy v27.
20 +
21 +## GitHub synchronization — precise meaning
22 +
23 +- [PR #29](https://github.com/davoodmehraban89/VELYQOR/pull/29) was already **MERGED** into main; **never merge it again**. It committed a patcher/test/workflow/documentation, not the exact historical complete Worker source.
24 +- The main HEAD [381ba284](https://github.com/davoodmehraban89/VELYQOR/commit/381ba284d47f284f034afacc7d6cc41fc31af8f9) preserves stale descriptions: [README.md](../../README.md) describes "Phase 0", [PROJECT_STATE.md](../../PROJECT_STATE.md) still puts v27 in the leading hotfix section, and [provider-source-matrix.md](../data/provider-source-matrix.md) is an archived Oct-05 development-candidate plan.
25 +- PR [#30](https://github.com/davoodmehraban89/VELYQOR/pull/30) adds compact 58-symbol summaries and on-demand historic price points, is **DRAFT, UNMERGED, NOT DEPLOYED** and its v26 patcher explicitly warns that the Cloudflare Worker source-download endpoint was serving last-uploaded v27 even after rollback. There is no independently version-matched raw v26 Worker source manifest on main.
26 +- Proposed fix in this **docs-only PR**: top-level README and PROJECT_STATE use one authoritative [production-manifest.json](production-manifest.json), preserve historical v27 incident paragraphs as archived not current status, correct PR counts/bases, and link official provider rights/latency matrix. It does not move UI or API code, rerun PR #29, activate PR #30, write KV or migrate Neon.
27 +- Before **any future** Worker update: obtain the exact v26 source artifact and its cryptographic hash associated with Cloudflare's deployed version ID (not just "latest uploaded"), deterministic build recipe, current non-secret binding/cron metadata and a safe staging environment. Then unit + Chromium + WebKit + actual affected-device tests, independent signed-off rollback, owner approval for merge and a distinct approval for production deployment.
28 +
29 +## Explicit source-provider boundary
30 +
31 +- [README.md at main @381ba284](https://github.com/davoodmehraban89/VELYQOR/blob/381ba284d47f284f034afacc7d6cc41fc31af8f9/README.md) and [main provider matrix](https://github.com/davoodmehraban89/VELYQOR/blob/381ba284d47f284f034afacc7d6cc41fc31af8f9/docs/data/provider-source-matrix.md) describe **architecture/development candidates**; they do not attest that Navasan/Alpha Vantage supply every displayed production quote.
32 +- [PR #29 operational record](chartnova-production-progressive-loading-2026-10-15.md) names secret/binding metadata and Gold API; [PR #30 catalog proof](https://github.com/davoodmehraban89/VELYQOR/blob/95e1389ba313c14652cf380182e5ea4b34007b3e/docs/operations/chartnova-compact-catalog-stage1-2026-10-15.md) describes data fetched with attribution Gheymat Online. The exact path linking every UI label ("Oanor/TGJU", "Gold API") to upstream acquisition, quote side, rights and source timestamps is **تأییدنشده**.
33 +- Do not display a price with the label **«قیمت فروش منبع X»** until the exact source-field/symbol/side is authenticated. Do not infer USD_IRT_FREE or GOLD18_IRT units from magnitude or the presence of a "sellPrice" JSON key.
34 +
35 +## What still is NOT completed
36 +
37 +No exact raw-v26 source or SHA256, no current Cloudflare metadata comparison, no full client-side outage reproduction, no licensed public-data right, no server-side order-proof for any price quote, no historical OHLC for intraday ATR, no outgoing alert engine, and no real-user pilot. Source-rights, free-tier SLA and the planned [one-source, one-rule, one-channel vertical slice](../product/vertical-slice-roadmap-2026-10-15.md) are documented, not implemented.
38 +
39 +## Proposed evidence acceptance for the NEXT approved change
40 +
41 +1. Obtain and review metadata/source provenance without reading or logging any secret **values**.
42 +2. Document exact small pilot contract and receive provider permission; only then code one complete vertical slice.
43 +3. Do not mutate untracked db/migrations/0005_navasan_private_daily_ohlc.sql or the dirty Windows worktrees.
44 +4. Every future PR must report actual test job URLs/head SHA, roll-forward/back plan, unresolved risk and explicitly separate **review PR approval**, **merge approval** and **production deploy approval**.
docs/operations/production-manifest.json new
+107
@@ -0,0 +1,107 @@
1 +{
2 + "schemaVersion": 1,
3 + "recordDate": "2026-10-15",
4 + "recordType": "REPOSITORY_EVIDENCE_RECONCILIATION_ONLY",
5 + "productionChangeAuthorized": false,
6 + "checkedAgainstMainCommit": "381ba284d47f284f034afacc7d6cc41fc31af8f9",
7 + "runtime": {
8 + "hostname": "app.chartnova.ir",
9 + "rootHostname": "chartnova.ir",
10 + "workerName": "velyqor-preview",
11 + "currentDeploymentVerifiedThisStage": false,
12 + "latestRecordedDeployment": {
13 + "status": "RECORDED_IN_REPOSITORY_NOT_LIVE_RECHECKED",
14 + "reportedVersionNumber": 26,
15 + "versionId": "85177f9d-09c0-4763-b28c-2c6ba5ae5be5",
16 + "percentage": 100,
17 + "deploymentId": "78155d6f-11fc-4d1b-ab4f-7c0a97474406",
18 + "recordedUtc": "2026-10-15T05:59:12.013397Z",
19 + "evidence": [
20 + "https://github.com/davoodmehraban89/VELYQOR/blob/ops/chartnova-emergency-rollback-2026-10-15/PROJECT_STATE.md",
21 + "https://github.com/davoodmehraban89/VELYQOR/blob/feature/chartnova-light-catalog-lazy-series-2026-10-15/PROJECT_STATE.md"
22 + ]
23 + },
24 + "previousHotfix": {
25 + "versionNumber": 27,
26 + "versionId": "2cbeb4e2-4a3e-414f-b3ad-035e2378650b",
27 + "deploymentId": "c68b8340-398a-462b-9fe0-c635aba405fe",
28 + "deployedUtc": "2026-10-15T05:22:32.348955Z",
29 + "rolledBackAfterUserReportedSiteWouldNotOpen": true,
30 + "causality": "UNVERIFIED",
31 + "browserExceptionLog": "UNAVAILABLE",
32 + "reproducedFailure": "UNVERIFIED",
33 + "evidence": [
34 + "https://github.com/davoodmehraban89/VELYQOR/blob/main/docs/operations/chartnova-production-progressive-loading-2026-10-15.md",
35 + "https://github.com/davoodmehraban89/VELYQOR/blob/ops/chartnova-emergency-rollback-2026-10-15/PROJECT_STATE.md",
36 + "https://github.com/davoodmehraban89/VELYQOR/pull/29"
37 + ]
38 + },
39 + "deployedWorkerSourceArtifact": {
40 + "verifiedRawSourceForVersion26": "MISSING",
41 + "downloadedLatestVersionMayDifferFromDeployedVersion": true,
42 + "repositoryReproducibleArtifactMatch": "UNVERIFIED",
43 + "requirements": "Owner-provided sanitized deployment metadata/version-specific source hash; no keys, token values, or private URLs"
44 + },
45 + "labelToBackend": {
46 + "frontendLabels": [
47 + "Oanor/TGJU",
48 + "Gold API"
49 + ],
50 + "exactBackendProviderForEveryDisplayedSymbol": "UNVERIFIED",
51 + "runtimeSourceMapping": "UNVERIFIED",
52 + "evidence": [
53 + "https://github.com/davoodmehraban89/VELYQOR/blob/main/docs/operations/chartnova-production-progressive-loading-2026-10-15.md",
54 + "https://github.com/davoodmehraban89/VELYQOR/blob/feature/chartnova-light-catalog-lazy-series-2026-10-15/docs/operations/chartnova-compact-catalog-stage1-2026-10-15.md"
55 + ]
56 + }
57 + },
58 + "repository": {
59 + "main": {
60 + "commit": "381ba284d47f284f034afacc7d6cc41fc31af8f9",
61 + "docHistory": "STALE_V27_REFERENCE_BEFORE_THIS_UNMERGED_DOC_PR",
62 + "framework": "Vanilla Worker UI in production evidence; React/Vite UI only in Draft PR #24",
63 + "nextjsDeployed": "UNVERIFIED"
64 + },
65 + "prs": {
66 + "mergedHotfix": 29,
67 + "lightCatalogDraft": 30,
68 + "historyDraft": 23,
69 + "uiWsDraft": 24,
70 + "paperTradingDraft": 27,
71 + "diagnosticsDraft": 28,
72 + "independentProviderCandidates": [
73 + 21,
74 + 22
75 + ],
76 + "openCountAtReview": 7,
77 + "openCountAtReviewScope": "BEFORE_DOCS_PR_31",
78 + "stage1DocsReviewPr": 31,
79 + "openIncludingStage1DocsPrAtCreation": 8
80 + },
81 + "localWorktree": {
82 + "currentState": "UNVERIFIED",
83 + "historicalAudit": "9 tracked modified, 1085 untracked, 5 worktrees on 2026-10-12",
84 + "protectedUntrackedMigration": "db/migrations/0005_navasan_private_daily_ohlc.sql",
85 + "migrationMayExecute": false,
86 + "evidence": [
87 + "https://github.com/davoodmehraban89/VELYQOR/blob/main/docs/security/P0_TRIAGE_2026-10-12_FA.md"
88 + ]
89 + }
90 + },
91 + "providers": {
92 + "iranCandidate": "Gheymat Online; integration in latest historical Worker evidence, but source mapping and license unresolved",
93 + "navasan": "Reference/adapter candidate; free 120 requests/month, 2-hour update (official)",
94 + "xauCandidate": "Gold API (repo operational doc); quote-side and persistence/redistribution entitlements unresolved",
95 + "redistributionReviewed": false,
96 + "canonicalBidAskConfirmed": false,
97 + "primaryRightsStatus": "UNVERIFIED"
98 + },
99 + "operations": {
100 + "noRealOrders": true,
101 + "noPaidResources": true,
102 + "noProductionDeploy": true,
103 + "noMergeToMain": true,
104 + "phase1Scope": "DOCUMENTATION_AND_MANIFEST_ONLY",
105 + "currentProductionReadiness": "BLOCKED_BY_PROVENANCE_AND_ENTITLEMENT"
106 + }
107 +}
docs/operations/stage0-evidence-register-2026-10-15.md new
+54
@@ -0,0 +1,54 @@
1 +# Stage-0 finding register — evidence-indexed, 2026-10-15
2 +
3 +Status: DOCUMENTATION ONLY; this register maps the **previous Stage-0 assessment** to repository file paths, PR IDs and/or immutable commit SHAs. A statement from historical documentation is not reclassified as current live runtime proof. No secret values, broker actions, schema updates, local worktree modifications, merges or deployments occurred.
4 +
5 +**Review anchor:** [main @ 381ba284d47f284f034afacc7d6cc41fc31af8f9](https://github.com/davoodmehraban89/VELYQOR/commit/381ba284d47f284f034afacc7d6cc41fc31af8f9); the state before this unmerged docs-only PR. **No independent production runtime recheck in Stage 1**.
6 +
7 +| ID | Stage-0 finding, with actual scope | Precise repository evidence | Classification / absent proof |
8 +|---|---|---|---|
9 +| A-01 | README says **Phase 0**, PROJECT_STATE says **Phase 1** | [README.md](https://github.com/davoodmehraban89/VELYQOR/blob/381ba284d47f284f034afacc7d6cc41fc31af8f9/README.md) (Current phase); [PROJECT_STATE.md](https://github.com/davoodmehraban89/VELYQOR/blob/381ba284d47f284f034afacc7d6cc41fc31af8f9/PROJECT_STATE.md) (Current phase) | **CONFIRMED contradictory docs**. |
10 +| A-02 | 'main' state begins by asserting Worker **v27 active**, while later PR #30 state documents rollback to **v26** | [PROJECT_STATE.md](https://github.com/davoodmehraban89/VELYQOR/blob/381ba284d47f284f034afacc7d6cc41fc31af8f9/PROJECT_STATE.md) (2026-10-15 hotfix); [PROJECT_STATE.md @PR #30](https://github.com/davoodmehraban89/VELYQOR/blob/95e1389ba313c14652cf380182e5ea4b34007b3e/PROJECT_STATE.md) (first heading); [docs/operations/chartnova-compact-catalog-stage1-2026-10-15.md @PR #30](https://github.com/davoodmehraban89/VELYQOR/blob/95e1389ba313c14652cf380182e5ea4b34007b3e/docs/operations/chartnova-compact-catalog-stage1-2026-10-15.md) | **CONFIRMED documentary drift**. Real-time active Worker is **UNVERIFIED in this Stage-1 read-only repository review**. |
11 +| A-03 | v27 was uploaded **directly to Cloudflare**, not a reproducible Worker bundle committed to main; PR #29 contains script patch/tests/doc, not the exact Worker v26 source | [docs/operations/chartnova-production-progressive-loading-2026-10-15.md](https://github.com/davoodmehraban89/VELYQOR/blob/381ba284d47f284f034afacc7d6cc41fc31af8f9/docs/operations/chartnova-production-progressive-loading-2026-10-15.md) (Production change); [merged PR #29](https://github.com/davoodmehraban89/VELYQOR/pull/29); [scripts/optimize-chartnova-worker.mjs](https://github.com/davoodmehraban89/VELYQOR/blob/381ba284d47f284f034afacc7d6cc41fc31af8f9/scripts/optimize-chartnova-worker.mjs) | **CONFIRMED missing deployment-source provenance in main**. Verified sha256 for active raw v26: **UNVERIFIED/MISSING**. |
12 +| A-04 | Incident: v27 rollback was **a precaution after user reported site would not open**. Root-cause exception **not established**. | [rollback-branch PROJECT_STATE](https://github.com/davoodmehraban89/VELYQOR/blob/ops/chartnova-emergency-rollback-2026-10-15/PROJECT_STATE.md) (first incident heading); [PROJECT_STATE.md @PR #30](https://github.com/davoodmehraban89/VELYQOR/blob/95e1389ba313c14652cf380182e5ea4b34007b3e/PROJECT_STATE.md); [PR #28 diagnostic](https://github.com/davoodmehraban89/VELYQOR/pull/28) | **Incident trigger VERIFIED AS DOCUMENTED; CAUSALITY UNVERIFIED**. Missing console/network report from affected device, exact web origin, SW/cache state and cross-ISP repro. |
13 +| A-05 | 'main' README and provider source matrix retain Navasan/Alpha Vantage **development design**, while incident/handoff documents describe Gheymat Online, Oanor/TGJU UI label and Gold API | [README.md](https://github.com/davoodmehraban89/VELYQOR/blob/381ba284d47f284f034afacc7d6cc41fc31af8f9/README.md); [docs/data/provider-source-matrix.md](https://github.com/davoodmehraban89/VELYQOR/blob/381ba284d47f284f034afacc7d6cc41fc31af8f9/docs/data/provider-source-matrix.md); [#22 transition policy](https://github.com/davoodmehraban89/VELYQOR/blob/phase-1/gold-api-fallback/docs/data/iran-provider-transition-policy.md); [docs/operations/chartnova-production-progressive-loading-2026-10-15.md](https://github.com/davoodmehraban89/VELYQOR/blob/381ba284d47f284f034afacc7d6cc41fc31af8f9/docs/operations/chartnova-production-progressive-loading-2026-10-15.md); [docs/operations/chartnova-compact-catalog-stage1-2026-10-15.md @PR #30](https://github.com/davoodmehraban89/VELYQOR/blob/95e1389ba313c14652cf380182e5ea4b34007b3e/docs/operations/chartnova-compact-catalog-stage1-2026-10-15.md) | **DOCUMENTED naming/mapping drift**. Exact quote-side/provider origin of each running symbol **UNVERIFIED**. UI text alone is not provider proof. |
14 +| A-06 | Market contract is canonical USD_IRT_FREE/GOLD18_IRT/XAU_USD with IRR→IRT normalization; UI vendor ticker may differ | [docs/data/market-contracts.md](https://github.com/davoodmehraban89/VELYQOR/blob/381ba284d47f284f034afacc7d6cc41fc31af8f9/docs/data/market-contracts.md); [packages/market-domain/src/provider-contract.mjs](https://github.com/davoodmehraban89/VELYQOR/blob/381ba284d47f284f034afacc7d6cc41fc31af8f9/packages/market-domain/src/provider-contract.mjs); [packages/market-domain/src/adapters/navasan.mjs](https://github.com/davoodmehraban89/VELYQOR/blob/381ba284d47f284f034afacc7d6cc41fc31af8f9/packages/market-domain/src/adapters/navasan.mjs) | Canonical schema VERIFIED; deployed data mapping **UNVERIFIED**. |
15 +| A-07 | Source points and ECB daily references must not be presented as trading-grade OHLC | [docs/data/market-contracts.md](https://github.com/davoodmehraban89/VELYQOR/blob/381ba284d47f284f034afacc7d6cc41fc31af8f9/docs/data/market-contracts.md); [PR #23 licensing gate](https://github.com/davoodmehraban89/VELYQOR/blob/feature/chartnova-neon-direct-history/docs/data/ohlc-licensing-and-ingestion-gate.md); [docs/operations/chartnova-compact-catalog-stage1-2026-10-15.md @PR #30](https://github.com/davoodmehraban89/VELYQOR/blob/95e1389ba313c14652cf380182e5ea4b34007b3e/docs/operations/chartnova-compact-catalog-stage1-2026-10-15.md) | **CONFIRMED semantic rule**, OHLC trade-grade source rights **UNVERIFIED**. |
16 +| A-08 | Main is Node/pnpm market-domain .mjs; standalone TSX React/**Vite** app is staged in PR #24, not established as deployed Next.js | [package.json](https://github.com/davoodmehraban89/VELYQOR/blob/381ba284d47f284f034afacc7d6cc41fc31af8f9/package.json); [PR #24](https://github.com/davoodmehraban89/VELYQOR/pull/24); [staged UI README](https://github.com/davoodmehraban89/VELYQOR/blob/feature/chartnova-multimarket-chart-ws-foundation/apps/market-terminal/README.md) | **CONFIRMED repo distinction**; deployed Next.js **UNVERIFIED**. |
17 +| B-01 | Initial source matrix: no licensed, independently demonstrated second domestic source; Navasan free insufficient for minute alerts | [docs/data/provider-source-matrix.md](https://github.com/davoodmehraban89/VELYQOR/blob/381ba284d47f284f034afacc7d6cc41fc31af8f9/docs/data/provider-source-matrix.md); [docs/security/P0_RELEASE_GATES.md](https://github.com/davoodmehraban89/VELYQOR/blob/381ba284d47f284f034afacc7d6cc41fc31af8f9/docs/security/P0_RELEASE_GATES.md) | **CONFIRMED documented blocker**, current vendor rights updated in [official matrix](../data/provider-source-matrix-2026-10-15.md). |
18 +| B-02 | 'main' exposes candidate 1m/5m/15m/30m/1h/4h/1d candle intervals but UI should expose only cadence-validated intervals | [docs/data/market-contracts.md](https://github.com/davoodmehraban89/VELYQOR/blob/381ba284d47f284f034afacc7d6cc41fc31af8f9/docs/data/market-contracts.md); [packages/market-domain/src/candle-builder.mjs](https://github.com/davoodmehraban89/VELYQOR/blob/381ba284d47f284f034afacc7d6cc41fc31af8f9/packages/market-domain/src/candle-builder.mjs) | **CONFIRMED candidate definitions**; live support for each timeframe **UNVERIFIED**. |
19 +| B-03 | 168-element history is not proof of 168 validated timestamped hourly OHLC candles; compact snapshot Stage 1 prototype is PR #30 Draft | [docs/operations/chartnova-compact-catalog-stage1-2026-10-15.md @PR #30](https://github.com/davoodmehraban89/VELYQOR/blob/95e1389ba313c14652cf380182e5ea4b34007b3e/docs/operations/chartnova-compact-catalog-stage1-2026-10-15.md); [PR #30](https://github.com/davoodmehraban89/VELYQOR/pull/30) | **CONFIRMED limitation in staged docs**; supplier point timestamps and exact cadence **UNVERIFIED**. |
20 +| C-01 | Static quality evaluator flags STALE_SOURCE, PROVIDER_DIVERGENCE, PRICE_SPIKE and returns GOOD/DEGRADED/STALE/INVALID | [packages/market-domain/src/data-quality.mjs](https://github.com/davoodmehraban89/VELYQOR/blob/381ba284d47f284f034afacc7d6cc41fc31af8f9/packages/market-domain/src/data-quality.mjs); [packages/market-domain/src/pipeline.mjs](https://github.com/davoodmehraban89/VELYQOR/blob/381ba284d47f284f034afacc7d6cc41fc31af8f9/packages/market-domain/src/pipeline.mjs) | **CONFIRMED pure helper**, production-wide alert suspension/quarantine wiring **NOT DEMONSTRATED**. |
21 +| C-02 | Provider health and failure/down-recovery primitives exist, but no verified persistent live alert trigger integration | [packages/market-domain/src/provider-recovery.mjs](https://github.com/davoodmehraban89/VELYQOR/blob/381ba284d47f284f034afacc7d6cc41fc31af8f9/packages/market-domain/src/provider-recovery.mjs); [packages/market-domain/src/provider-contract.mjs](https://github.com/davoodmehraban89/VELYQOR/blob/381ba284d47f284f034afacc7d6cc41fc31af8f9/packages/market-domain/src/provider-contract.mjs); [PR #27](https://github.com/davoodmehraban89/VELYQOR/pull/27) | **CONFIRMED helpers**; live alert system **UNVERIFIED**. |
22 +| C-03 | Bid/ask & IRR/IRT of untracked Navasan OHLC migration do not match committed adapter assumptions | [packages/market-domain/src/adapters/navasan.mjs](https://github.com/davoodmehraban89/VELYQOR/blob/381ba284d47f284f034afacc7d6cc41fc31af8f9/packages/market-domain/src/adapters/navasan.mjs); [docs/security/P0_TRIAGE_2026-10-12_FA.md](https://github.com/davoodmehraban89/VELYQOR/blob/381ba284d47f284f034afacc7d6cc41fc31af8f9/docs/security/P0_TRIAGE_2026-10-12_FA.md); [docs/security/P0_RELEASE_GATES.md](https://github.com/davoodmehraban89/VELYQOR/blob/381ba284d47f284f034afacc7d6cc41fc31af8f9/docs/security/P0_RELEASE_GATES.md) | **P0 BLOCK_IMPORT**, untracked migration content evidenced only by older audit. |
23 +| D-01 | Calendar and candle building functions exist; not a complete stateful scheduler, idempotent OCO/ATR alert | [packages/market-domain/src/market-calendar.mjs](https://github.com/davoodmehraban89/VELYQOR/blob/381ba284d47f284f034afacc7d6cc41fc31af8f9/packages/market-domain/src/market-calendar.mjs); [packages/market-domain/src/candle-builder.mjs](https://github.com/davoodmehraban89/VELYQOR/blob/381ba284d47f284f034afacc7d6cc41fc31af8f9/packages/market-domain/src/candle-builder.mjs); [PR #27 stage 1 and 2](https://github.com/davoodmehraban89/VELYQOR/pull/27) | **CONFIRMED implementation scope**, production alert status **UNVERIFIED**. |
24 +| D-02 | Trailing and bracket logic under PR #27 is **manual paper scenario** and stacked on PR #24, not live order execution | [PR #27](https://github.com/davoodmehraban89/VELYQOR/pull/27); [paper-only Stage 2](https://github.com/davoodmehraban89/VELYQOR/blob/feature/paper-trading-risk-controls-2026-10-14/docs/trading/paper-trading-stage2.md) | **CONFIRMED draft**; live feed and server alert delivery **NOT COMPLETED**. |
25 +| E-01 | No reviewed/operational Bale/Eita/Web Push sender and durable outbox are evidenced in main; standalone SW does not prove Web Push | [main tree @381ba284](https://github.com/davoodmehraban89/VELYQOR/tree/381ba284d47f284f034afacc7d6cc41fc31af8f9); [PR #28 SW diagnostics](https://github.com/davoodmehraban89/VELYQOR/pull/28) | **NOT VERIFIED as implemented**; absence claim limited to reviewed tree and PRs, not user private infrastructure. |
26 +| F-01 | Existing Cloudflare KV and Cron deployment described, but current provider account quota/atomic idempotency budget not established by repo | [docs/operations/chartnova-production-progressive-loading-2026-10-15.md](https://github.com/davoodmehraban89/VELYQOR/blob/381ba284d47f284f034afacc7d6cc41fc31af8f9/docs/operations/chartnova-production-progressive-loading-2026-10-15.md); [PR #24 cloudflare realtime template](https://github.com/davoodmehraban89/VELYQOR/blob/feature/chartnova-multimarket-chart-ws-foundation/deploy/chartnova/wrangler.realtime.example.toml) | Live free-plan limits/actual usage **UNVERIFIED**; never assume KV is transactional dedupe. |
27 +| G-01 | Verified historical ECB example: 762 daily reference points; candles 0 as of 2026-10-11 audit, not live production counts now | [Neon handoff PR #23](https://github.com/davoodmehraban89/VELYQOR/blob/feature/chartnova-neon-direct-history/docs/data/neon-history-direct-handoff-2026-10-11.md); [docs/data/phase1-live-postgres-proof.md](https://github.com/davoodmehraban89/VELYQOR/blob/381ba284d47f284f034afacc7d6cc41fc31af8f9/docs/data/phase1-live-postgres-proof.md) | **HISTORICAL SNAPSHOT ONLY**. Current Neon state **UNVERIFIED**. |
28 +| G-02 | Backtest on true ATR from licensed source OHLC not shown; PR #27 paper-only tests do not constitute backtest or financial advice | [PR #27](https://github.com/davoodmehraban89/VELYQOR/pull/27); [PR #23 OHLC preflight](https://github.com/davoodmehraban89/VELYQOR/pull/23) | **OUT OF STAGE-1 SCOPE**. |
29 +| H-01 | Seven open PRs: #21, #22, #23, #24, #27, #28, #30; #25, #26, #29 already merged | [GitHub PR list](https://github.com/davoodmehraban89/VELYQOR/pulls?q=is%3Apr+is%3Aopen); [#25](https://github.com/davoodmehraban89/VELYQOR/pull/25); [#26](https://github.com/davoodmehraban89/VELYQOR/pull/26); [#29](https://github.com/davoodmehraban89/VELYQOR/pull/29) | **CONFIRMED via GitHub PR API on 2026-10-15**. |
30 +| H-02 | Branch stack #23 (history base) → #24 (PR #23 base) → #27 (PR #24 base), all Draft | [#23](https://github.com/davoodmehraban89/VELYQOR/pull/23); [#24](https://github.com/davoodmehraban89/VELYQOR/pull/24); [#27](https://github.com/davoodmehraban89/VELYQOR/pull/27) | **CONFIRMED from PR metadata**. |
31 +| H-03 | Latest head commit CI checks were green for all seven **before this docs PR**, but tests cannot establish licensing/provider SLA/live delivery | [#21 SHA fdaadeba](https://github.com/davoodmehraban89/VELYQOR/commit/fdaadeba7c6111296ea3bfeee3763326cc44224a/checks), [#22 SHA 3cce3a63](https://github.com/davoodmehraban89/VELYQOR/commit/3cce3a6334b00bca5364ca0485dd6229eaf17dd3/checks), [#23 SHA 39bb4419](https://github.com/davoodmehraban89/VELYQOR/commit/39bb44198c573d87660bfa9ea5f9c35edd2a1d86/checks), [#24 SHA b79b8712](https://github.com/davoodmehraban89/VELYQOR/commit/b79b87127d75a6c6585d690fd5a079e3594bafeb/checks), [#27 SHA 1416f4eb](https://github.com/davoodmehraban89/VELYQOR/commit/1416f4eb2d279ff79ce03ff64eeb63e849d53485/checks), [#28 SHA 4ed0b77c](https://github.com/davoodmehraban89/VELYQOR/commit/4ed0b77c60852a1594cfa6eb955b5c6484bf7231/checks), [#30 SHA 95e1389b](https://github.com/davoodmehraban89/VELYQOR/commit/95e1389ba313c14652cf380182e5ea4b34007b3e/checks) | **CONFIRMED checked successes**, not present-time external proof. |
32 +| H-04 | GitHub CI runs Node unit suite and ephemeral PostgreSQL, not real Neon production verification | [.github/workflows/ci.yml](https://github.com/davoodmehraban89/VELYQOR/blob/381ba284d47f284f034afacc7d6cc41fc31af8f9/.github/workflows/ci.yml); [package.json](https://github.com/davoodmehraban89/VELYQOR/blob/381ba284d47f284f034afacc7d6cc41fc31af8f9/package.json); [docs/data/phase1-live-postgres-proof.md](https://github.com/davoodmehraban89/VELYQOR/blob/381ba284d47f284f034afacc7d6cc41fc31af8f9/docs/data/phase1-live-postgres-proof.md) | **CONFIRMED CI scope**. |
33 +| H-05 | Previous local Windows snapshot: 9 tracked changed, 1085 untracked, 5 worktrees | [docs/security/P0_TRIAGE_2026-10-12_FA.md](https://github.com/davoodmehraban89/VELYQOR/blob/381ba284d47f284f034afacc7d6cc41fc31af8f9/docs/security/P0_TRIAGE_2026-10-12_FA.md) | **HISTORICAL**; local state TODAY **UNVERIFIED**. Never clean/reset/stash or commit migration 0005. |
34 +| H-06 | Production branch protection/required check enforcement | [docs/security/P0_RELEASE_GATES.md](https://github.com/davoodmehraban89/VELYQOR/blob/381ba284d47f284f034afacc7d6cc41fc31af8f9/docs/security/P0_RELEASE_GATES.md) | Current server-side enforcement **UNVERIFIED**; CI success does not establish it. |
35 +
36 +## Non-repository official documents (clearly separated from repository facts)
37 +
38 +- Navasan free allowance and refresh: [official plan](https://www.navasan.tech/en/api).
39 +- Gheymat 250/day and explicit vendor no-accuracy/no-freshness warranty: [official product API](https://gheymat.online/price-api).
40 +- TGJU clause 18 on copying prices without written consent: [official terms](https://gem.tgju.org/terms).
41 +- Alpha Vantage noncommercial default license: [official Terms §2](https://www.alphavantage.co/terms_of_service/).
42 +- Gold API: [official free plan](https://gold-api.com/pricing) and [terms](https://gold-api.com/terms), cached versions differ on newly listed commercial clause.
43 +- Bon-bast: [official paid-plan catalog](https://www.bon-bast.com/docs).
44 +- BrsApi official page requested but inaccessible during audit: [provider site](https://brsapi.ir/free-api-gold-currency-webservice/).
45 +
46 +References and unresolved provider permissions are expanded in [dated official-source matrix](../data/provider-source-matrix-2026-10-15.md). Quota calculations and clear no-day-trading-SLA verdict in [service level](../product/realistic-service-level-2026-10-15.md). Next-phase gated minimal plan in [one-channel vertical slice](../product/vertical-slice-roadmap-2026-10-15.md).
47 +
48 +## Evidence that cannot be derived from repository alone
49 +
50 +Real-time deployment version and exact raw v26 script hash; true backend upstream mapping to Oanor/TGJU/Gheymat; browser traces from affected device; current provider entitlement and sampling frequency; current Cloudflare free-account usage; present-day Windows worktrees; exact live Neon row counts; delivered push/Bale message latencies. All **تأییدنشده**, not implicitly passed.
51 +
52 +## Stage-1 DoD and outstanding
53 +
54 +Stage 1 is complete only when a PR from main contains (i) this evidence register, (ii) versioned non-secret deployment manifest, (iii) README/PROJECT_STATE reconciliation, (iv) rollback archive marking, (v) official-source + realistic-quota/SLO docs, and (vi) one vertical slice proposal. No production changes, no merge, no money/orders. **Next phase starts only with separate user approval.**
docs/product/realistic-service-level-2026-10-15.md new
+61
@@ -0,0 +1,61 @@
1 +# سطح خدمت واقع‌بینانه — 2026-10-15
2 +
3 +**STATUS: PLANNING ONLY / NO LIVE ALERT SLA.** These are mathematical *free-quota polling budgets*, not measured latency or a contractual vendor delivery guarantee. No new API/provider or alert is activated.
4 +
5 +## Official inputs and repository lineage
6 +
7 +| Factor | Navasan free | Gheymat Online free |
8 +|---|---|---|
9 +| Documented budget | **120 HTTP requests/month** | **250 HTTP requests/day** |
10 +| Advertised source update | **Every 2 hours** | "لحظه‌ای", but provider explicitly disclaims data timeliness/accuracy guarantees |
11 +| Official source | [Navasan free plan](https://www.navasan.tech/en/api) | [Gheymat Online free plan](https://gheymat.online/price-api) |
12 +| Existing repo evidence | [docs/data/provider-source-matrix.md, main @381ba284](https://github.com/davoodmehraban89/VELYQOR/blob/381ba284d47f284f034afacc7d6cc41fc31af8f9/docs/data/provider-source-matrix.md) | [docs/data/iran-provider-transition-policy.md, PR #22](https://github.com/davoodmehraban89/VELYQOR/blob/phase-1/gold-api-fallback/docs/data/iran-provider-transition-policy.md) |
13 +| Guaranteed upper bound on upstream delay | **تأییدنشده** | **تأییدنشده** |
14 +| End-user alert transport latency | **تأییدنشده** | **تأییدنشده** |
15 +
16 +"Every 2 hours" is a claimed provider data update rate; it does **not** override the 120/month API quota.
17 +
18 +## Quota math (24/7 periodic polling; no retries/failed calls)
19 +
20 +Definitions: B = number of allowed requests per quota window; D = quota window duration in minutes; k = HTTP requests required to get **all watched symbols** in one polling cycle.
21 +
22 +Formula: **minimum sustainable evenly distributed polling period P_min = D × k / B** minutes. This is an arithmetic lower bound on the *long-run average spacing of requests*, not the minimum possible delay for an individual notification.
23 +
24 +- **Navasan, 30-day accounting month, k=1:** 30×24×60/120 = **360 minutes = 6h**. 31 days: 31×24×60/120 = **372 minutes = 6h12m**. Polling every 2h for 30d consumes 360 calls, **3× above free quota**. If USD and gold require *two* endpoint requests (k=2): **12h** minimum on a 30-day month. Multi-symbol aggregation semantics for this specific account are **تأییدنشده**.
25 +- **Gheymat Online, k=1:** 24×60/250 = **5.76 minutes = 5m45.6s**. If two requests per cycle are required, **11.52 minutes = 11m31.2s**. Whether the desired USD and 18K-gold fields reliably fit one billed API request is **تأییدنشده** until account-level proof.
26 +- Cross-check every Gheymat poll using Navasan is **not sustainable** under Navasan's free 120/month. Additional discovery/history calls also consume quota.
27 +
28 +### Suggested operating headroom (planning, not an active Cron config)
29 +
30 +| Model | k | Conservative schedule | Calls within stated window | Free budget left | Ideal wait to next poll (not SLA) |
31 +|---|---:|---|---:|---:|---|
32 +| Navasan / 30 days | 1 | **Every 8 hours** | 90/month | 30/month | <8h |
33 +| Navasan / 31 days | 1 | **Every 8 hours** | 93/month | 27/month | <8h |
34 +| Gheymat / 24h | 1 | **Every 10 minutes** | 144/day | 106/day | <10min |
35 +| Gheymat / 24h | 2 | **Every 20 minutes** | 144/day | 106/day | <20min |
36 +
37 +At a 7-minute one-call Gheymat interval roughly 206 calls/day are used and only ~44 remain. A scheduled request can fail, be throttled or return unchanged/STALE data; actual observations may be much farther apart.
38 +
39 +## Realistic alert timing, and why it is NOT an SLA
40 +
41 +Conditional engineering model: **T_user_alert = T_upstream_publication + T_wait_next_poll + T_fetch + T_integrity_gate + T_queue + T_delivery**. Under perfect regular polling, the waiting term may approach P in the worst alignment; it may also be close to zero. Upstream publication delay and delivery time have **no verified upper bound** in either free plan, so a bounded end-to-end maximum cannot be asserted.
42 +
43 +| Model | Quota-derived sustainable polling floor | Prototype alert-latency *planning target*, conditional on fresh provider data | Verified end-to-end upper bound |
44 +|---|---|---|---|
45 +| Navasan k=1 | **6h** (30d) | No urgent alert target possible. Even with an 8h safe schedule a threshold can be detected hours late, plus source publication/transport delay. | **تأییدنشده** |
46 +| Gheymat k=1 | **5m45.6s** | Aim to **measure**, not promise, 10–15min from threshold crossing under 10min polling. Unobserved transient crossings may be missed. | **تأییدنشده** |
47 +| Gheymat k=2 | **11m31.2s** | Aim to **measure**, not promise, 20–25min under 20min polling. | **تأییدنشده** |
48 +
49 +This table's 10–15min and 20–25min figures are **unvalidated product targets, not observed performance, not guaranteed SLAs, and not universal minimum delivery times**. A crossing may occur immediately before a poll and arrive faster; a source outage may delay it indefinitely.
50 +
51 +## Trading-day product decision
52 +
53 +**Not acceptable as a time-critical day-trading alert product under free quotas and currently unverified data rights.** These sources cannot promise 1m/5m detection, reliable bid/ask, exact crossing time or execution-grade data.
54 +
55 +**Possibly acceptable ONLY as a voluntarily tested, non-urgent and clearly labeled educational/informational price monitor**, after public display and derived-alert rights and quote side are verified. UI must show **«قیمت فروش منبع X»** only when quote-side evidence confirms SELL; otherwise display **«سمت قیمت تأییدنشده — هشدار غیرفعال»**. Show provider timestamp, server receive time, stale state, and notification failure. No buy/sell advice and no money/order operations.
56 +
57 +Recommended pilot starting point: one USD_IRT_FREE symbol; one validated source (Gheymat Online only if licensed); one ABOVE/BELOW rule family; one authorized delivery channel. The new [vertical slice roadmap](vertical-slice-roadmap-2026-10-15.md) defines staged tests. All actual notifications are disabled until approved gates pass.
58 +
59 +## Incomplete / unverified
60 +
61 +No continuous cadence/lag/outage measurement, quota reset timezone, contractual publication bound, authenticated multi-symbol request proof, calendar proof, delivery SLO, channel test, cross-source matching, or public redistribution grant. Documenting suggested cadence does **not** modify production Cron or prices.
docs/product/vertical-slice-roadmap-2026-10-15.md new
+59
@@ -0,0 +1,59 @@
1 +# Minimum vertical slice: one source × one rule family × one delivery channel
2 +
3 +Status: DESIGN ONLY — **no code, webhook, cron change, real message, trade, payment, merge or deployment** as part of Stage 1. Subsequent implementation requires separate owner approval.
4 +
5 +## Pilot purpose and unambiguous scope
6 +
7 +Validate with **2–5 consenting real users** whether deliberately *non-urgent informational* Iranian-market threshold alerts have any value, before implementing ATR, OCO, multiple providers or Paper Trading.
8 +
9 +| Axis | ONE choice for initial vertical slice | Gated evidence |
10 +|---|---|---|
11 +| Instrument | **USD_IRT_FREE** only (one source-defined domestic USD quotation) | Repository canonical unit IRT_PER_USD: [market-contracts](../data/market-contracts.md) @ main 381ba284 |
12 +| Market-data provider | **Gheymat Online only**, *conditional* on explicit rights and verified exact market/side/units. Do not treat its reported sellPrice key as conclusive SELL proof. | [Official API/free plan](https://gheymat.online/price-api), [official-doc gap matrix](../data/provider-source-matrix-2026-10-15.md), [PR #30 data shape](https://github.com/davoodmehraban89/VELYQOR/pull/30) |
13 +| Alert family | **ABOVE** or **BELOW** a user-entered numeric threshold on one explicitly defined, verified quote side; no trailing/ATR/prediction, no AI strategy | Existing quality primitives [data-quality.mjs](../../packages/market-domain/src/data-quality.mjs), no production alert engine currently established in main |
14 +| Price side displayed | **«قیمت فروش منبع Gheymat Online»** ONLY IF provider contract identifies the observed field as selling quote for this exact instrument. Otherwise show **«سمت قیمت تأییدنشده — هشدار غیرفعال»** and do not send. | Bid/ask semantics and execution availability: **تأییدنشده** |
15 +| Delivery | **One Bale Bot message channel** to opted-in recipients, not Eita, Telegram or Web Push in the first cut | Official Bale Bot API response/send constraints, rate caps and availability: **تأییدنشده**. Must validate official documentation, sender identity, per-user opt-in and safe secret injection before activation. No tokens in GitHub or chat. |
16 +| Polling | **10min planned**, assuming ONE billed Gheymat API call per full snapshot; *if not*, recalculate and change contract prior to implementation | [Arithmetic and lack of SLA](realistic-service-level-2026-10-15.md): 144 calls/day, leaving 106/day headroom at k=1 |
17 +| UI wording | **«هشدار اطلاع‌رسانی غیرتوصیه‌ای»**; show provider name/quote side/timestamp and condition state. No "بخر" or "بفروش" instructions | Existing product rule [main README](../../README.md); this doc's acceptance |
18 +| Real-money orders | **None, prohibited** | [P0 release gates](../security/P0_RELEASE_GATES.md) |
19 +
20 +### User flow (one complete user journey)
21 +
22 +1. User sees one licensed, timestamped SELL quote; if unit, side, rights, timestamp or quality cannot be verified, UI says **«تأییدنشده — هشدار غیرفعال»**.
23 +2. User creates a single ABOVE/BELOW watch rule with amount and optional name, explicitly opts in to a Bale bot; server stores channel routing metadata with minimum access.
24 +3. A scheduled acquisition event validates symbol, **IRT vs IRR conversion**, provider quote side, monotonic source timestamp, max age, market session and sensible spike bounds. For stale, quality failure or invalid quote, **suspend** all dependent threshold evaluations and show reason; never generate a price alert from bad data.
25 +4. One source-valid crossing moves the event into durable triggered state. Minimal dedupe identifier: (user_id, rule_id, source_event_timestamp, transition) plus a semantic rule epoch/version. Prevent repeated processing, retry storms and duplicate notifications. Confirm triggering policy (e.g., two consecutive *valid* samples) before coding.
26 +5. Outbox records **PENDING → SENT / FAILED**, bounded retries and error identifiers; mark NOTIFIED only upon verified successful provider send response, not just attempted HTTP call. Receiver read/ack is **UNVERIFIED** unless Bale bot API provides a confirmed read receipt.
27 +6. UI shows the latest event and delivery outcome; no pseudo-live trading indicators or order execution.
28 +
29 +### Definition of Done for this SINGLE vertical-slice PR (after separate approval)
30 +
31 +- [ ] Written vendor rights for storing and displaying USD SELL quote and generating derived alerts; exact raw/canonical units, source timestamp and quote side reviewed and linked to a non-secret license record.
32 +- [ ] Source API quota authenticated and evaluated with a **sanitized single-response sample**, one-snapshot request count verified, no secret published.
33 +- [ ] Exact one-symbol, one-price-side contract; UI shows the provider and source timestamp; UI never shows financial advice.
34 +- [ ] No real-order code paths, network requests to brokers or AI-to-trade permissions.
35 +- [ ] Pure unit tests for ABOVE/BELOW boundaries, STALE, out-of-order, duplicate, source outage, spike quarantine, pause/recovery, and idempotency.
36 +- [ ] Integration tests for one Bale send adapter (mock), 429/500/timeouts, bounded retry, dedupe and persisted failure status; official API docs and non-sensitive callback proof.
37 +- [ ] Simulated lost connectivity and browser reload; UI clearly communicates stale/failed states.
38 +- [ ] GitHub CI green **on exact head SHA** plus full browser E2E with synthetic data; no newly invented quotes.
39 +- [ ] Real opted-in user delivery only after explicit, separate operational activation permission; any real send is an external action and requires the user's authorization.
40 +- [ ] Quota instrumentation, no secret values in logs; clear kill switch to disable all outgoing notifications and restore previous Worker without dropping rules.
41 +- [ ] Pilot measures provider refresh age, sample gaps, alert detection lag, transport delay, false positives and failures. **Do not promise a bounded SLA** without measurements.
42 +
43 +### Rollback and safety
44 +
45 +Feature flag **disabled by default**; deployment (if later approved) does not enable alerts automatically. Revert flag to disabled and cease outgoing delivery without deleting user preferences; leave events auditable. If old Worker contract regressions occur, restore the previous manifest-pinned version only after confirming actual active version, bindings and user approval. Never execute unreviewed migration 0005 or overwrite local worktrees.
46 +
47 +## Following work — ordered ONLY after pilot evidence
48 +
49 +| Next increment | Requires demonstrated need |
50 +|---|---|
51 +| (1) **Trailing Stop / ATR, take-profit, OCO** | License-valid source OHLC and source-high/low timestamps, stable delivered simple threshold alerts. No guessed ATR from 168 price points. |
52 +| (2) **Secondary provider + failover/cross-check** | Source-side verified symmetric quote units/sides and written rights, observed gap/outage incidents, cross-provider divergence bounds. |
53 +| (3) **Backtest + Paper Trading** | Verified historical OHLC and calendar; keep [PR #27](https://github.com/davoodmehraban89/VELYQOR/pull/27) draft in the stacked [#23→#24→#27] chain until independently reviewed; never connect any broker or order execution. |
54 +
55 +## Decision gate
56 +
57 +If no free provider grants documented rights for the exact pilot quotation/derived alerts, **the pilot stays data-disabled**; show only simulated fixtures in local/staging, clearly tagged SIMULATION. This is a genuine legal/product blocker, not something to bypass by scraping.
58 +
59 +**Not complete:** vendor license, final source-side sample, Bale official bot API capability, quota test, persistent engine, UI, sender, recipient opt-in, real delivery, measured usability. This document is a proposed vertical slice and no user-facing feature has been released.