@davoodmehraban89 / Aram-2 Mirror · read-only
Fork 0

Mirrored from https://github.com/davoodmehraban89/Aram.git

Synced Dec 3, 17:00 UTC

source-data-cleanup
add-index-html-10623938925177053894 arena/094f314c-aram chatgpt-phase1b2-autopilot codex/adr-future-connectors-pi-v1 codex/aram-account-note-source-trace-20261031 codex/aram-actions-node24-maintenance-20261031 codex/aram-analyst-review-workbook-20261031 codex/aram-bs-candidate-statement-20261031 codex/aram-cash-flow-direct-candidate-20261031 codex/aram-clean-reference-year-integrity-20261030 codex/aram-cross-statement-controls-20261031 codex/aram-equity-changes-candidate-20261031 codex/aram-five-statement-cli-20261031 codex/aram-five-statement-integration-20261031 codex/aram-five-statement-orchestrator-20261031 codex/aram-gate3-coverage-target-guard-20261030 codex/aram-gate3-hidden-xlsx-guard-20261030 codex/aram-gate3-integration-validation-20261030 codex/aram-gate3-mapping-change-preview-20261030 codex/aram-gate3-stale-note-guard-20261030 codex/aram-income-statement-candidate-20261031 codex/aram-manifest-referential-integrity-20261031 codex/aram-mapping-source-parser-20261101 codex/aram-multidimensional-mapping-20261101 codex/aram-multistatement-mapping-20261031 codex/aram-pipeline-manifest-schema-20261031 codex/aram-readonly-mapping-coverage-20261031 codex/aram-reconciliation-review-gate-20261031 codex/aram-same-flush-fiscal-lock-20261030 codex/aram-synthetic-windows-demo-20261031 codex/aram-trial-balance-diagnostic-20261031 codex/aram-windows-background-detail-search-20261031 codex/aram-windows-detail-review-20261031 codex/aram-windows-five-statement-pilot-20261031 codex/aram-windows-statement-figures-20261031 codex/gate-2a-pilot-workbook codex/gate-2a-pilot-workbook-6864754244772568979 codex/gate3-authenticated-principal-boundary-20261030 codex/gate3-authored-draft-staging-20261030 codex/gate3-carry-forward-preview-20261023 codex/gate3-draft-staging-audit-20261030 codex/gate3-mapping-batch-freshness-20261030 codex/gate3-mapping-batch-review-20261030 codex/gate3-mapping-core codex/gate3-mapping-coverage-20261023 codex/gate3-mapping-excel-20261023 codex/gate3-note-mapping-review-20261023 codex/gate3-signed-year-scope-20261030 codex/gate3-unapproved-proposal-storage-20261030 codex/payvast-mapping-discovery-20261023 codex/phase-2a-backend-foundation codex/phase-2b-post-merge-record codex/phase-2b-source-registration codex/phase-2b-source-registration-12955190277775369594 codex/post-gate2a-control-reconciliation codex/post-pr18-acceptance-record codex/project-control-foundation codex/t1-repo-hygiene-20261023 codex/t2-ci-hardening-20261023 codex/t3-explicit-migrations-20261023 codex/t6a-readonly-diagnostics-20261023 codex/v1-01-safety-gate-hardening codex/v1-year-isolation-followup-20261023 codex/windows-native-pilot-shell-20261030 docs/aram-master-control-plan-20261111 docs/aram-roadmap-dashboard-20261030 docs/financial-statement-reconciliation-1402-1404-20261110 feat/gate3-governed-mapping-20261101 feat/gate3-package9-1-security-20261103 feat/gate3-package9-isolated-20261103 fix/password-unicode-validation-20261111 governance/aram-5-1-3-controls-20261030 governance/role-based-operating-model jules-1168663913887856558-73b8a885 jules-gate-2b-mapping-workflow-foundation-4137724387867065330 phase-1b1-audit-report-7365389436990903239 phase-2a-backend-foundation-10237597358138521261 phase1b2-postmerge-metadata-fix refactor/drg-parent-year-id-15088443704684163304 source-data-cleanup
md 158 lines 14.9 KB
Rendered Raw
1 # Aram Project Status
2
3 > Canonical status entry point. Update this file in every meaningful pull request. Always fetch the live accepted-branch head before acting; a committed snapshot is not a substitute for GitHub remote evidence.
4
5 ## Repository baseline
6
7 - Repository: [davoodmehraban89/Aram](https://github.com/davoodmehraban89/Aram)
8 - Accepted branch: source-data-cleanup
9 - Recorded accepted control event: [PR #18](https://github.com/davoodmehraban89/Aram/pull/18), reviewed head `fcbeb7387218e9ab294318ae462ed59de717fc95`, squash merge [f213d321ff4cd7d3d6fa65ba78dc48f090ee846b](https://github.com/davoodmehraban89/Aram/commit/f213d321ff4cd7d3d6fa65ba78dc48f090ee846b)
10 - Durable post-merge acceptance record: [PR #19](https://github.com/davoodmehraban89/Aram/pull/19), reviewed head `b9059592409606a0a4f11a71c30778cff158b6b6`, squash merge [77f9f595ccfe67a87b11024ff0f6143629dba438](https://github.com/davoodmehraban89/Aram/commit/77f9f595ccfe67a87b11024ff0f6143629dba438)
11 - Before starting new work, fetch the live `source-data-cleanup` head; this record intentionally avoids a self-referential current-head claim
12 - Product objective: a controlled, auditable accounting and financial-statement workflow that preserves canonical source data.
13
14 ## Status vocabulary
15
16 | State | Meaning |
17 |---|---|
18 | VERIFIED_AND_MERGED | Present on the accepted branch with Git evidence. |
19 | VERIFIED_BUT_UNMERGED | Present in a remote commit or PR, but not accepted. |
20 | PRESENT_BUT_UNVERIFIED | Present, but required tests or evidence are missing. |
21 | CLAIMED_BUT_NOT_PROVEN | Reported by an actor, with no sufficient GitHub evidence. |
22 | NOT_IMPLEMENTED | Required capability is absent. |
23 | IN_PROGRESS | Work is in an open PR and is not accepted. |
24 | BLOCKED | Work cannot proceed until the recorded blocker is resolved. |
25
26 ## Verified state
27
28 | Area | State | Evidence / note |
29 |---|---|---|
30 | Phase 1B-1 source inventory | VERIFIED_AND_MERGED | [PR #1](https://github.com/davoodmehraban89/Aram/pull/1) |
31 | Phase 1B-2 audit corrections | VERIFIED_AND_MERGED | [PR #4](https://github.com/davoodmehraban89/Aram/pull/4) |
32 | Phase 2A backend foundation | VERIFIED_AND_MERGED | [PR #6](https://github.com/davoodmehraban89/Aram/pull/6) |
33 | One-file model refactor | VERIFIED_AND_MERGED | [PR #8](https://github.com/davoodmehraban89/Aram/pull/8) |
34 | Project-control foundation | VERIFIED_AND_MERGED | [PR #10](https://github.com/davoodmehraban89/Aram/pull/10) |
35 | Phase 2B ingestion foundation | VERIFIED_AND_MERGED | [PR #12](https://github.com/davoodmehraban89/Aram/pull/12), squash merge 7b5bd79b760d534dad34b3162f770e838616ebe9 |
36 | Phase 2B control reconciliation | VERIFIED_AND_MERGED | [PR #13](https://github.com/davoodmehraban89/Aram/pull/13), squash merge 7c7533ee87146dc8fc78b46ebf423be55532c7eb |
37 | Gate 2A Pilot workbook contract/preflight | VERIFIED_AND_MERGED | [PR #15](https://github.com/davoodmehraban89/Aram/pull/15), reviewed head 74b6a6397a2a2c9199a5c7bcf818bb661b2ebe06, squash merge 4ab54f4a3cf666827fa1ed30c4e43259ea79f2d4, [Backend CI #24](https://github.com/davoodmehraban89/Aram/actions/runs/32712900800) |
38 | V1-01 safety-gate hardening | IN_PROGRESS | Draft [PR #21](https://github.com/davoodmehraban89/Aram/pull/21) from exact base `b1ddee87d31ee73b3a5aeac8f9953d0a604c206a`; independently reviewed implementation head `700d800dbd9c657f6bd510faafedcbde4847fafd`; CI-verified stabilized candidate `b3dc8b3a18934ffe63f615e4f650248be21a5f9c`; [Backend CI #39](https://github.com/davoodmehraban89/Aram/actions/runs/33015277194) succeeded with 67 tests, migration round-trip, and compile after broadening one reparent-rejection assertion to accept either valid protection message; code, scope, and protected-data boundary remain unchanged; final independent acceptance is pending this durable-document reconciliation |
39 | Post-Gate-2A control reconciliation | VERIFIED_AND_MERGED | [PR #18](https://github.com/davoodmehraban89/Aram/pull/18), reviewed head `fcbeb7387218e9ab294318ae462ed59de717fc95`, squash merge `f213d321ff4cd7d3d6fa65ba78dc48f090ee846b`; documentation only |
40 | Durable post-merge acceptance record | VERIFIED_AND_MERGED | [PR #19](https://github.com/davoodmehraban89/Aram/pull/19), reviewed head `b9059592409606a0a4f11a71c30778cff158b6b6`, squash merge `77f9f595ccfe67a87b11024ff0f6143629dba438`; documentation only |
41 | Role-based project operating model | VERIFIED_AND_MERGED | Permanent responsibilities and current assignments are defined in `docs/handoff/MASTER_RECOVERY_PROMPT.md` and ADR-011; introduced through [PR #20](https://github.com/davoodmehraban89/Aram/pull/20) |
42 | Parallel V1 prototype | VERIFIED_BUT_UNMERGED | Closed, unmerged [PR #7](https://github.com/davoodmehraban89/Aram/pull/7); reference/recovery source only |
43 | Superseded Phase 2B candidate | VERIFIED_BUT_UNMERGED | Closed, unmerged [PR #9](https://github.com/davoodmehraban89/Aram/pull/9) |
44 | Duplicate Gate 2A candidate | VERIFIED_BUT_UNMERGED | [PR #16](https://github.com/davoodmehraban89/Aram/pull/16) closed without merge on 2026-08-25; no content accepted |
45 | Gate 2B Mapping foundation candidate | VERIFIED_BUT_UNMERGED | [PR #17](https://github.com/davoodmehraban89/Aram/pull/17) closed without merge on 2026-08-25; stale-base reference only; no content accepted |
46 | Official V1 release | NOT_IMPLEMENTED | No accepted tag, release, retained release artifact, ZIP, or EXE |
47 | Comprehensive Mapping Excel import/export | NOT_IMPLEMENTED | Mandatory before V1 acceptance |
48 | Unknown-account queue and mapping carry-forward | NOT_IMPLEMENTED | Mandatory before V1 acceptance |
49 | Note and sub-note mapping workflow/UI | NOT_IMPLEMENTED | Mandatory before V1 acceptance |
50 | Minimal Pilot application and reviewable output | NOT_IMPLEMENTED | Required before packaging |
51 | Reproducible Windows package and clean-environment test | NOT_IMPLEMENTED | Required before V1 acceptance |
52
53 ## Accepted product capabilities
54
55 - Read-only source inventory and workbook audit evidence.
56 - Persistent backend/data-model foundation with fiscal-year mutation controls.
57 - Metadata-only source registration, structural XLSX inspection, and typed in-memory ledger parsing.
58 - Governed Pilot workbook v0.1 contract, reproducible blank template generator, and deterministic read-only preflight.
59 - Approved Pilot template path: samples/Aram_Pilot_Input_and_Mapping_Template_v0.1.xlsx.
60 - Independently verified template SHA-256: e14a7feb80a216d79ed9cb6dde2b0df3e55317f3da6b26efc77f7118f4702b6f.
61
62 The accepted branch does not include PR #7 desktop/release work, PR #16 alternate Pilot implementation, or PR #17 Mapping implementation. Green CI on an unmerged stale-base PR is not acceptance evidence.
63
64 ## Current risks and blockers
65
66 - The accepted branch is not protected by GitHub branch protection.
67 - The accepted branch still permits direct identity mutation/deletion of approved or locked fiscal years and parent-company deletion; the V1-01 candidate fixes this but is not accepted yet.
68 - The accepted Pilot preflight can still accept targetless or structurally invalid mappings and can ignore a declared closing-delta mismatch; the V1-01 candidate fixes this but is not accepted yet.
69 - The accepted root `index.html` is still a disconnected hard-coded prototype; the V1-01 candidate replaces it with an explicit quarantine page.
70 - PR #17 was closed without merge; its stale-base 12-file diff is reference material only, and its narrative listed only 9 files.
71 - PR #17 CI was green on its own stale head, but compatibility with accepted Gate 2A was never proven.
72 - Binary execution, release provenance, and clean Windows verification do not exist.
73 - Mapping, notes/sub-notes, Pilot UI, and end-to-end user acceptance remain incomplete.
74
75 ## Next approved action
76
77 1. Publish this two-file durable-document reconciliation on Draft PR #21; [Backend CI #39](https://github.com/davoodmehraban89/Aram/actions/runs/33015277194) succeeded on stabilized candidate `b3dc8b3a18934ffe63f615e4f650248be21a5f9c` with 67 tests, migration round-trip, and compile.
78 2. The independent reviewer re-fetches the resulting documentation-only head, confirms that its comparison with `b3dc8b3a18934ffe63f615e4f650248be21a5f9c` changes only `PROJECT_STATUS.md` and `docs/handoff/LATEST_HANDOFF.md`, verifies the final workflow result, then marks the PR ready and squash-merges it.
79 3. Only after V1-01 is accepted, start the first focused Gate 3 Mapping import/persistence task from the new accepted head.
80
81 ## Booklet v1.0 — Phase 0 (execution work order)
82
83 Authoritative work order: «کتابچهٔ اجرایی تکمیل Aram» v1.0 (base head `7dc864fd032f0c4ae4d650d89304a01286a6d914`, PR #21 merge). Branch `arena/094f314c-aram`. Per §17 the agent resolves ambiguities by default + real-data proof + ADR and never queries the owner; the owner's sole role is Phase-9 final acceptance.
84
85 | Debt | State | Evidence |
86 |---|---|---|
87 | D-01 LedgerBalance model | VERIFIED_BUT_UNMERGED | commit `a3c330b`; exact-rial round-trip + aggregation tests |
88 | D-02 controls in preflight | VERIFIED_BUT_UNMERGED | commit `8f2f902`; C-01..C-04 preflight tests |
89 | D-03 Rial money column | VERIFIED_BUT_UNMERGED | commit `a3c330b`; BIGINT storage >2^53 via ORM; ADR-012 |
90 | D-04 numeric code normalization | VERIFIED_BUT_UNMERGED | commit `ac565e9`; integral-numeric exact, leading zeros preserved |
91 | D-05 Persian header matching | VERIFIED_BUT_UNMERGED | commit `ac565e9`; normalize_fa header matching |
92 | D-06 source bytes + CSV | VERIFIED_BUT_UNMERGED | commit `a661423`; content-addressed store + CSV encodings/delimiters |
93 | D-07 immutability + audit + reopen | VERIFIED_BUT_UNMERGED | commit `00ca58e`; raw-SQL locked-year guards, hash chain, ADR-016 |
94 | D-08 status/log refresh | IN_PROGRESS | this entry |
95 | D-09 git-history rewrite | BLOCKED | owner-only; requires explicit owner approval (§19) |
96 | D-10 hierarchy mapping | VERIFIED_BUT_UNMERGED | commit `ac565e9`; ADR-014 (general=kol, subsidiary=حساب) |
97 | D-11 inspection guards | VERIFIED_BUT_UNMERGED | commit `ac565e9`; max_column None guard |
98 | D-12 CI quality gates | VERIFIED_BUT_UNMERGED | commit `8412c56`; ruff/mypy/coverage/pip-audit/PG matrix; ADR-017 |
99
100 Phase-0 local evidence: 201 tests passed; ruff clean; mypy domain strict clean; coverage total 92% / domain 97%; pip-audit no known vulnerabilities; SQLite migration up/down/up clean. PostgreSQL migration path is exercised by the CI matrix (no local PG). Real-data evidence (source_1404.xlsx, 252,898 rows): debit-positive C-01 holds 252,892/252,898; Σdebit=Σcredit=10,823,163,409,740,108; OD-01 refuted (T1..T4 concat ≠ حساب), ADR-014 adopted. No canonical `data/` or `samples/` file changed.
101
102 ADRs added: 012 (money scale/rounding), 013 (sign contract), 014 (T1..T4 hierarchy), 016 (reopen/immutability), 017 (CI gates/tooling).
103
104 ## Booklet v1.0 — Phases 1–4 + owner priority fixes (execution work order)
105
106 Continuation on branch `arena/094f314c-aram` (base `7dc864fd`). Per §17 the agent resolves by default + real-data proof + ADR and never queries the owner.
107
108 | Phase / item | State | Evidence |
109 |---|---|---|
110 | Phase 1 statements + drill-down | VERIFIED_BUT_UNMERGED | commit `9c33586`; build_statements BS/IS, drill_down source{filename,file_hash,sheet,row} |
111 | Phase 2 mapping import/export | VERIFIED_BUT_UNMERGED | commit `cfbd879`; mapping_io Mappings sheet, fail-closed, idempotent |
112 | Phase 3 note formula engine | VERIFIED_BUT_UNMERGED | commit `9fba3c6`; AST formula (no eval), acct/row/note/sum/abs, cycle detection |
113 | Phase 4 golden comparison | VERIFIED_BUT_UNMERGED | commit `225a38c`; golden.py header-name columns; 1403+1404 real-data tests pass |
114 | Fix 1 money/P-02 (ADR-012) | VERIFIED_BUT_UNMERGED | commit `a00b0dc`; 457,074 rows, 0 fractional rial; 7 guard tests |
115 | Fix 2 raw-row drill-down (D3/P-01) | VERIFIED_BUT_UNMERGED | commit `f7c3b4a`; one LedgerBalance per source row; ledger_aggregate service; migration 20261203_05 round-trip |
116 | Fix 3 approval gate (D5/C-03) | VERIFIED_BUT_UNMERGED | commit `1844a62`; evaluate_controls explicit; hard ERROR gate; 13 tests |
117 | Fix 4 tests + CI (D-12/§14) | VERIFIED_BUT_UNMERGED | commits `225a38c`,`be08192`; mypy services gate; frontend eslint/tsc/vitest/Playwright |
118 | Phase 5 UI + Playwright | VERIFIED_BUT_UNMERGED | commits `fa64baf`,`77fbe70`; RTL workbench (setup/import/mapping/statements/drill-down/approval/admin); eslint/tsc/vitest/build + Playwright gates |
119 | Phase 6 reviewable outputs | VERIFIED_BUT_UNMERGED | commit `c4c37c0`; statement_export XLSX+JSON with exact rial + lineage; ADR-022 |
120 | Phase 7 users/audit/reopen/backup | VERIFIED_BUT_UNMERGED | commit `e20572d`; roles+PBKDF2, controlled reopen/lock, verifiable backup; migration 20261203_07; ADR-023 |
121 | Phase 8 desktop packaging | VERIFIED_BUT_UNMERGED | commit `ffc9888`; desktop entrypoint (127.0.0.1) + PyInstaller recipe; ADR-024; no binary committed (§19) |
122 | Phase 9 UAT + release prep | VERIFIED_BUT_UNMERGED | `scripts/uat_real_data.py`; real-1404 UAT evidence below; tag v1.0.0 is the owner's post-acceptance action |
123
124 Local evidence at head `dafb559`: backend **308 tests passed**; ruff clean; mypy domain strict + services clean; frontend lint/tsc/vitest/build pass; Playwright smoke + workflow specs valid. Migrations 20261203_05/06/07 up/down/up verified (SQLite). No canonical `data/` or `samples/` file changed.
125
126 ### Phase 9 UAT evidence (real source_1404.xlsx, read-only)
127
128 `python scripts/uat_real_data.py --year 1404` on a fresh local DB:
129 - Import: **131,280 raw rows** preserved (4 anomalous rows skipped + reported).
130 - Auto-mapping from embedded note numbers: 22 notes, 244 mappings.
131 - Build: BS/IS/CF/EQ persisted; 1 unmapped ordinary account surfaced.
132 - Golden reconciliation: core balance-sheet notes match official **rial-for-rial**
133 (÷10⁶ half-up): 10→673,740,637 · 11→242,194 · 12-1→13,386,398 · 12-2→8,310,168 ·
134 13→6,839,535 · 14→11,273,650 · 15→19,951,136 (plus zero notes 17-1/17-2). Remaining
135 BS/IS differences are surfaced as discrepancies (OD-08), never silently corrected.
136 - Approval gate: correctly **blocks** on real-data control failures (C-01/C-03/C-04) —
137 fail-loud, no bypass.
138 - Export: XLSX (6.27 MB) + JSON with **158,050 lineage rows** (file/SHA-256/sheet/row).
139 - Backup: created + verified (hashes + audit chain); audit chain valid.
140
141 ADRs added in this stretch: 021 (golden scale/columns), 022 (outputs), 023 (users/reopen/backup), 024 (desktop packaging).
142
143 ### Release procedure (owner, after independent review)
144
145 The implementation author does **not** merge or tag (§19). After independent GitHub
146 review approves PR #96 and it is merged into `source-data-cleanup`, the owner creates
147 the release tag `v1.0.0` on the accepted head and builds the Windows package from
148 `packaging/build_desktop.py` (artifact retained in the release, not committed).
149
150 ## Control documents
151
152 - [Project log](docs/PROJECT_LOG.md)
153 - [Decision log](docs/DECISION_LOG.md)
154 - [Acceptance policy](docs/ACCEPTANCE_POLICY.md)
155 - [Jules task template](docs/JULES_TASK_TEMPLATE.md)
156 - [Master recovery prompt](docs/handoff/MASTER_RECOVERY_PROMPT.md)
157 - [Latest handoff snapshot](docs/handoff/LATEST_HANDOFF.md)
158 - [Saveable ChatGPT bootstrap prompt](docs/handoff/CHATGPT_BOOTSTRAP_PROMPT.txt)