Skip to content

Repository files navigation

🎬 CineGraph

Track films. Discover stories. Build your cinematic identity.

A premium movie tracking and social platform inspired by the magic of cinema β€” built with a cinematic design language that treats every screen like a dark theater illuminated by a projector beam.

React FastAPI Tailwind CSS PostgreSQL TMDB


✨ Features

πŸŽ₯ Movie Discovery

  • Browse & Search β€” explore trending, popular, and top-rated movies powered by the TMDB API
  • Detailed Movie Pages β€” full cast & crew, OTT availability, ratings, and recommendations
  • Smart Recommendations β€” personalized movie suggestions based on your watch history

πŸ““ Personal Tracking

  • Watch Diary β€” log every film you watch with dates, ratings, and personal notes
  • Star Ratings β€” rate movies on a granular scale
  • Curated Lists β€” create, manage, and share custom movie collections
  • List Discovery β€” explore lists created by other users in the community

πŸ“Š Analytics & Insights

  • Viewing Analytics β€” charts and stats on your watching habits (genres, ratings distribution, watch frequency)
  • Year in Review β€” a cinematic, scroll-driven recap of your year in film (powered by GSAP + ScrollTrigger)
  • Achievements β€” unlock badges and milestones as you track your journey

🀝 Social

  • Activity Feed β€” see what friends are watching, rating, and adding to lists
  • User Profiles β€” public profiles showcasing watch stats, favorites, and activity
  • Follow System β€” follow other cinephiles and build your community
  • Comments & Likes β€” discuss films and engage with diary entries and lists

🎨 Design Language β€” "PROJECTION"

  • Cinematic UI β€” warm near-black palette with tungsten & daylight accent lighting
  • 3D Poster Wall β€” interactive Three.js landing hero with floating movie posters
  • Film Grain Overlay β€” subtle SVG noise for a celluloid texture
  • Smooth Animations β€” Framer Motion page transitions, Lenis smooth scrolling
  • Accessible β€” full prefers-reduced-motion support with opacity-only fallbacks

πŸ› οΈ Tech Stack

Frontend

Technology Purpose
React 19 + TypeScript UI framework
Vite 7 Build tool & dev server
Tailwind CSS v4 Styling (CSS-first @theme)
Framer Motion Page transitions & micro-animations
React Three Fiber + Three.js 3D poster wall on landing page
Lenis Smooth scroll
Chart.js Analytics visualizations
React Router v7 Client-side routing

Backend

Technology Purpose
FastAPI REST API framework
SQLAlchemy ORM & database modeling
PostgreSQL 15 Primary database
Redis 7 Caching layer
PyJWT Authentication tokens
Uvicorn ASGI server

Infrastructure

Technology Purpose
Docker Compose Container orchestration (Postgres + Redis)
TMDB API Movie metadata, posters, and discovery

πŸš€ Getting Started

Prerequisites

  • Node.js β‰₯ 18
  • Python β‰₯ 3.10
  • Docker (for PostgreSQL & Redis)
  • TMDB API Key β€” get one free here

1. Clone the repo

git clone https://github.com/Ayush971/CineGraph.git
cd CineGraph

2. Start the database services

docker-compose up -d

This spins up PostgreSQL (port 5432) and Redis (port 6379).

3. Set up the backend

cd backend

# Create and activate a virtual environment
python -m venv venv
# Windows
venv\Scripts\activate
# macOS/Linux
source venv/bin/activate

# Install dependencies
pip install -r requirements.txt

Create a .env file in backend/ with:

TMDB_API_READ_ACCESS_TOKEN=your_tmdb_read_access_token
TMDB_API_KEY=your_tmdb_api_key
TMDB_BASE_URL=https://api.themoviedb.org/3
TMDB_IMAGE_BASE_URL=https://image.tmdb.org/t/p

Start the server:

python app/main.py

The API will be live at http://localhost:8000 β€” interactive docs at /docs.

4. Set up the frontend

cd frontend

# Install dependencies
npm install

# Start the dev server
npm run dev

The app will be live at http://localhost:5173.


πŸ“‘ API Reference

The backend exposes a RESTful API at http://localhost:8000. Key endpoint groups:

Endpoint Description
/auth Registration, login, JWT token management
/movies Search, trending, popular, movie details (via TMDB)
/diary Log, edit, and retrieve personal watch diary entries
/lists Create, manage, and discover curated movie lists
/comments Add and retrieve comments on diary entries and lists
/social Follow/unfollow users, activity feed
/likes Like/unlike diary entries, lists, and comments
/achievements User milestones and badges
/analytics Watch statistics, genre breakdowns, rating distributions
/recommendations Personalized movie suggestions

πŸ“– Full interactive API docs available at http://localhost:8000/docs (Swagger UI)


πŸ“ Project Structure

CineGraph/
β”œβ”€β”€ frontend/                   # React + Vite frontend
β”‚   β”œβ”€β”€ src/
β”‚   β”‚   β”œβ”€β”€ components/         # Reusable UI components
β”‚   β”‚   β”‚   β”œβ”€β”€ landing/        # 3D poster wall hero
β”‚   β”‚   β”‚   └── ui/             # Design system primitives
β”‚   β”‚   β”œβ”€β”€ pages/              # Route-level page components
β”‚   β”‚   β”œβ”€β”€ context/            # React context (Auth, etc.)
β”‚   β”‚   β”œβ”€β”€ hooks/              # Custom React hooks
β”‚   β”‚   β”œβ”€β”€ services/           # API client & service layer
β”‚   β”‚   β”œβ”€β”€ types/              # TypeScript type definitions
β”‚   β”‚   └── utils/              # Utility functions
β”‚   └── package.json
β”‚
β”œβ”€β”€ backend/                    # FastAPI backend
β”‚   β”œβ”€β”€ app/
β”‚   β”‚   β”œβ”€β”€ routes/             # API route handlers
β”‚   β”‚   β”œβ”€β”€ models/             # SQLAlchemy database models
β”‚   β”‚   β”œβ”€β”€ schemas/            # Pydantic request/response schemas
β”‚   β”‚   β”œβ”€β”€ services/           # Business logic layer
β”‚   β”‚   β”œβ”€β”€ config/             # Database & app configuration
β”‚   β”‚   β”œβ”€β”€ utils/              # Helper utilities
β”‚   β”‚   └── main.py             # Application entry point
β”‚   └── requirements.txt
β”‚
β”œβ”€β”€ docker-compose.yml          # PostgreSQL + Redis containers
β”œβ”€β”€ DESIGN_LANGUAGE.md          # "PROJECTION" design system spec
└── README.md

🎞️ Design Philosophy

CineGraph follows the "PROJECTION" design language β€” the UI is a dark auditorium, and content is the light:

  • Posters are the light source β€” the UI recedes so imagery can project
  • Tungsten acts, Daylight navigates β€” two accent colors with strict roles (warm gold for actions, cool blue for wayfinding)
  • Motion is projection β€” elements fade up from dark and settle like a film reel stopping, no bouncy cartoon springs

Read the full design spec in DESIGN_LANGUAGE.md


🀝 Contributing

Contributions are welcome! Feel free to open issues or submit pull requests.

  1. Fork the repository
  2. Create a feature branch (git checkout -b feature/amazing-feature)
  3. Commit your changes (git commit -m 'feat: add amazing feature')
  4. Push to the branch (git push origin feature/amazing-feature)
  5. Open a Pull Request

πŸ“„ License

This project is open source and available under the MIT License.


πŸ™ Acknowledgments


Built with 🍿 and a love for cinema

About

Website Link

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages