feat: prepare ARR for controlled public deployment
This commit is contained in:
24
.project-docs/20-architecture/data-flow.md
Normal file
24
.project-docs/20-architecture/data-flow.md
Normal file
@@ -0,0 +1,24 @@
|
||||
# Data Flow
|
||||
|
||||
## Primary Flows
|
||||
|
||||
| Flow | Source | Destination | Notes |
|
||||
|---|---|---|---|
|
||||
| XML ingestion | User upload | Agent processing | Upload is the user's only required action for this flow. |
|
||||
| Structured result commit | Agent output | PostgreSQL Finance facts | Independent validation/replay must succeed before commit. |
|
||||
| Automatic monthly trigger | Successful database commit | Monthly-report worker/program | Month and cutoff values are derived internally, not supplied by the user. |
|
||||
| Monthly workbook build | Committed Finance facts | XLSX artifact | `TOTAL PRICE` cells use `REAL PRICE × NIGHTS × NO_OF_ROOMS` formulas. |
|
||||
|
||||
## State Ownership
|
||||
|
||||
- PostgreSQL owns accepted/current Finance facts and processing state.
|
||||
- Generated XLSX files are artifacts derived from a pinned database snapshot; they are not an alternative fact source.
|
||||
|
||||
## External Interfaces
|
||||
|
||||
- User-facing: XML upload, processing status, and controlled report download.
|
||||
- Internal: Agent structured-result submission and automatic report-task dispatch after commit.
|
||||
|
||||
## Last Updated
|
||||
|
||||
2026-07-29
|
||||
Reference in New Issue
Block a user