elmeg-demo/.specify/plan.md

48 lines
2.1 KiB
Markdown

# Technical Plan
## Architecture
- **MVP**: Scalable, modular cloud-native architecture (API-first, microservices recommended).
- **Backend**: Python/Node.js (TBD based on specific needs, likely Python for data/graph heavy lifting).
- **Frontend**: Modern web framework (React/Next.js).
## Data
- **Storage**: Flexible graph-based or relational database with advanced indexing (e.g., Neo4j + PostgreSQL).
## Authentication & Security
- **Auth**: OAuth2, multi-factor auth (MFA), end-to-end encryption for private data.
- **Privacy**: Robust user privacy controls.
## New Feature Implementation
- **Social**:
- **Reviews**: `Review` table with `blurb` (short text), `content` (long text), `score` (int), and FKs.
- **Comments**: Polymorphic association (Comment -> EntityID, EntityType) or separate tables per entity.
- **Ratings**: `UserRating` table linking User -> Performance/Show.
- **Gamification**:
- **Stats**: Async jobs (Celery/ARQ) to recalculate stats on data changes.
- **Badges**: Rule engine to award badges based on user activity events.
- **Advanced Content**:
- **Nicknames**: `PerformanceNickname` table with `status` (suggested, approved) for moderation.
- **Moderation**:
- **RBAC**: Role-Based Access Control in API dependencies.
## Moderation System
- **Layered Model**:
- Automated AI filtering for high-volume content.
- User reporting mechanisms.
- Human review tools with clear guidelines.
## Core Entities (Data Architecture)
- **Core**: `Vertical` -> `Show` -> `Performance` -> `Song`.
- **Common Fields**: All entities include `notes` (Text) for flexible metadata (guests, trivia).
- **Grouping**: `Tour` (one-to-many with Show).
- **User Data**: `UserAttendance` (User <-> Show), `UserPreferences` (JSON or table for settings like "Wiki Mode").
- **Metadata**: `Tag` and `EntityTag` (Polymorphic tagging).
- **Entities**: `Venue`, `Artist` (Musicians/Guests), `Character` (for non-music verticals).
## Integrations
- **Launch**: Setlist.fm APIs, TV meta providers.
- **Future**: Event hooks for external integrations.
## Accessibility
- **Standards**: WCAG 2.2 compliance.
- **Design**: Mobile-first responsive design.