How sidarkincal/vitacoreai works
1. Repository shape
- This repo is a very small, front-end-only MVP with two independent HTML entry points: index.html for marketing/landing and app.html for the interactive demo.
- There is no backend, build pipeline, or source tree beyond these static pages.
2. Top-level architecture
- The product is split into two user experiences:
- a public landing site that explains the concept and captures leads
- a single-page interactive cockpit demo that simulates the health platform
- Both are delivered as static assets and depend on browser-side JavaScript plus CDN-hosted libraries.
3. index.html: marketing and acquisition surface
- This page is the narrative and conversion layer: hero section, personas, feature cards, user journey, and “smart system rules.”
- It also includes a contact form that sends submissions through Formspree, making it the only explicit external data handoff in the repo.
- It supports scroll animations, a mobile menu, and a persisted day/night theme toggle stored in localStorage.
4. app.html: interactive MVP cockpit
- This is the core product simulation, built as a React 18 single-page app rendered in the browser.
- It uses Babel Standalone for in-browser JSX transformation and Tailwind CSS for styling, all loaded from CDNs.
- The page is state-driven: modules react to user input and update shared UI state without a server round trip.
5. Runtime and library boundaries
- The interactive demo runs entirely in the client using React UMD bundles; window.react = window.React is an intentional compatibility shim for lucide-react.
- Icons come from lucide / lucide-react, and typography uses Inter.
- Because everything is CDN-backed, the app assumes network access unless served locally.
6. Consent and access control boundary
- The first meaningful boundary in app.html is the legal consent wall.
- The cockpit remains blurred/locked until the disclaimer is accepted, so the app has an explicit “gated access” state before the health modules become available.
7. User profile and health-state inputs
- The demo collects basic profile data such as height, weight, and age, then computes BMI live in the UI.
- These inputs feed the rest of the dashboard state and act as the baseline for the simulated health cockpit.
8. Behavioral tracking modules
- Several modules update a shared “streak”/progress concept:
- Water tracking increments via +250ml actions and awards streak points when the target is met.
- Medication checklist marks adherence and visually strengthens the streak flame.
- Pain map captures a 1–10 pain rating on a body silhouette.
- These modules are independent inputs, but they converge into the same health-status feedback loop.
9. Rules-based coach logic
- The exercise coach is not generative AI; it is a prescription player that executes the user’s uploaded RECETE sequence in order.
- It uses per-move duration/reps, set rest, move rest, sequence rail, voice guidance, and a completion card.
- The pain map can influence this module: lower back pain ≥ 7 triggers a caution state in the workout coach.
10. Document and analytics pipeline
- The AI document reader simulates drag-and-drop ingestion, a scan animation, and sample lab-result output.
- The analytics section aggregates trends such as weight, medication adherence, and pain, then surfaces an AI-style weekly summary report.
- In the current MVP, these are presentation-side simulations rather than real OCR or ML services.
11. Voice and accessibility features
- The roadmap and feature set indicate a Web Speech API voice coach (speechSynthesis, TR-TR) that delivers spoken guidance inside the browser.
- This is a client-side capability, not an external service, and it reinforces the “coach” role of the interactive module.
12. Persistence and state scope
- The only persistence explicitly mentioned is theme preference in localStorage on the landing page.
- Most of the interactive demo state appears ephemeral and session-bound, which keeps the architecture simple and fully client-rendered.
13. External integrations and future boundaries
- Current external touchpoints are limited to:
- CDN libraries for React/Tailwind/icons
- Formspree for lead capture
- Planned but not yet implemented boundaries include OCR, user accounts, real data persistence, camera/pose estimation, and file upload parsing.
14. Diagramming takeaway
- An accurate architecture diagram should show two static browser applications:
- index.html as the public marketing/contact surface
- app.html as the interactive client-side simulation
- Both run entirely in the browser, with only light external dependencies and no server-side application tier in this repository.
Main entry points: app.html Cockpit app · index.html Landing page
Components 16
Public site
Marketing and lead-capture surface
- Landing page · Public marketing entrypoint
index.html - Story sections · Hero, personas, features, journey, and rules
- Contact form · Submits inquiry data to Formspree
- Theme toggle · Day/night switch persisted in localStorage
Interactive demo
Client-side cockpit simulation
- Cockpit app · Interactive browser demo entrypoint
app.html - Consent wall · Locks the cockpit until disclaimer acceptance
- Profile & BMI · Collects height, weight, age, and computes BMI
- Health state · Session-scoped dashboard state for the cockpit
- Behavior trackers · Water, medication, and pain inputs feeding streak/progress
- Exercise coach · Plays the uploaded RECETE sequence with rest and cautions
- Doc reader · Simulated drag-drop scan and lab-result output
- Analytics report · Trend aggregation and weekly AI-style summary
- Voice coach · Browser speech guidance in TR-TR
External services
CDNs and third-party handoffs
- CDN libs · React UMD, Babel Standalone, Tailwind, Lucide, Inter
- Formspree · Receives landing page submissions
- Local storage · Stores landing page theme preference
Connections 16
- Landing page → Story sections: renders · Displays the narrative landing sections
- Landing page → Contact form: contains · Provides lead capture on the public site
- Landing page → Theme toggle: uses · Allows day/night switching
- Theme toggle → Local storage: persists · Stores the selected theme in the browser
- Contact form → Formspree: submits to · Sends contact submissions externally
- Cockpit app → CDN libs: loads · Uses CDN-hosted client libraries
- Cockpit app → Consent wall: starts with · Requires disclaimer acceptance before use
- Consent wall → Profile & BMI: unlocks · Allows access to the main cockpit inputs
- Profile & BMI → Health state: updates · Seeds shared health state from user profile
- Behavior trackers → Health state: updates · Feeds streak and progress feedback
- Exercise coach → Health state: reads · Uses current state and pain level for cautions
- Doc reader → Health state: adds · Contributes simulated document findings
- Analytics report → Health state: summarizes · Aggregates trends into a weekly report
- Voice coach → Exercise coach: guides · Provides spoken workout guidance
- Cockpit app → Health state: drives · Renders the session-bound cockpit from shared state
- Cockpit app → Voice coach: enables · Binds browser speech support into the demo