How muratcanyusufoglu/noveltales-story-generator-ai works
Main Components
a. Client Layer:
• React Native Mobile Application (Frontend)
• Key features: Story Generation, Authentication, Subscription Management
• Components structure following screens (Welcome, Home, Selection, Story Detail)
• State Management using MobX stores (AuthenticationStore, CreateStoryStore, etc.)
b. Server Layer:
• Node.js Backend
• RESTful API endpoints
• Database Models and Migrations
• Authentication & Authorization services
c. Database Layer:
• SQL Database (likely PostgreSQL based on Sequelize migrations)
• Core entities: User, Story, Character, Topic, Content, Location, Timelapse
d. External Services:
• AI Integration (for story generation)
• RevenueCat for payment processing
• Image caching service
Relationships to Highlight
• User flows through the selection screens (Topic → Character → Location → Time → Content)
• Story generation pipeline
• Authentication flow
• Subscription and payment processing flow
• Data relationships between models (e.g., Story-Character, Story-Location)
[Mobile Client Layer]
• UI Components
• Navigation
• State Management
• Services
[API Layer]
• REST Endpoints
• Authentication
• Business Logic
[Data Layer]
• Database Models
• External Services
Important Architectural Patterns to Highlight
• MVC pattern in the backend
• Store-based state management in frontend
• Screen-based navigation structure
• Service-oriented architecture for business logic
• Multi-language support (i18n)
Key Flows to Illustrate
a. Story Generation Flow:
User Selection → Topic → Character → Location → Time → Content → AI Generation → Story Display
b. Authentication Flow:
Login/Signup → Token Generation → Protected Routes → User Session
c. Data Flow:
API Requests → Backend Routes → Controllers → Models → Database
Additional Elements
• Error handling and boundary components
• Caching mechanisms for images and data
• Subscription system integration
• Internationalization flow
• Development/production environment configurations
Technical Details to Note
• Expo framework usage
• Mobile-specific considerations
• API versioning
• Database migrations
• Testing infrastructure