How aswin0603/domain-specific-relational-schema-framework-for-heterogeneous-transactions-in-small-creative-firms works
Creative Ledger is a Flask demonstration application backed by a PostgreSQL schema for heterogeneous creative-business income. Users enter typed transactions or settlements; PostgreSQL stores the normalized core and subtype details and enforces integrity, while a materialized view supports dashboard reads. The app also exposes integrity and benchmark pages. The schema’s major design capabilities are represented as distinct components, though their detailed implementation is not sampled. Edges are limited to calls visible in the app excerpt or relationships explicitly described in the README.
Main entry points: schema.sql Integrity constraints · app.py Flask application
Components 15
Application workflows
- Flask application
code/app/app.py - Transaction entry
code/app/app.py - Settlement allocation
code/app/app.py - Integrity tests
code/app/app.py - Benchmark page
code/app/app.py
Transaction model
- Transaction core
code/sql/schema.sql - Typed subtypes
code/sql/schema.sql - Constrained JSONB
code/sql/schema.sql - Runtime fields
code/sql/schema.sql - Settlement model
code/sql/schema.sql
Database integrity
- PostgreSQL
- Integrity constraints
code/sql/schema.sql - Allocation locking
code/sql/schema.sql
Read and evaluation
- Materialized read model
code/sql/schema.sql
Other components
- Creative business user
Connections 14
- Creative business user → Flask application: uses
README.md - Flask application → PostgreSQL: queries and writes
code/app/app.py - Transaction entry → Transaction core: inserts transaction
code/app/app.py - Transaction entry → Typed subtypes: inserts subtype
code/app/app.py - Settlement allocation → Settlement model: records allocation
code/app/app.py - Integrity tests → Integrity constraints: tests constraints
README.md - Integrity constraints → Transaction core: constrains
README.md - Integrity constraints → Typed subtypes: guards subtype rows
README.md - Integrity constraints → Constrained JSONB: constrains metadata
README.md - Integrity constraints → Runtime fields: validates fields
README.md - Integrity constraints → Settlement model: checks allocations
README.md - Allocation locking → Settlement model: locks allocations
README.md - Flask application → Materialized read model: refreshes view
code/app/app.py - Benchmark page → PostgreSQL: compares schema performance
README.md