Skip to content

SarmaHighOnCode/Proximity

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

248 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

██████╗ ██████╗  ██████╗ ██╗  ██╗██╗███╗   ███╗██╗████████╗██╗   ██╗
██╔══██╗██╔══██╗██╔═══██╗╚██╗██╔╝██║████╗ ████║██║╚══██╔══╝╚██╗ ██╔╝
██████╔╝██████╔╝██║   ██║ ╚███╔╝ ██║██╔████╔██║██║   ██║    ╚████╔╝ 
██╔═══╝ ██╔══██╗██║   ██║ ██╔██╗ ██║██║╚██╔╝██║██║   ██║     ╚██╔╝  
██║     ██║  ██║╚██████╔╝██╔╝ ██╗██║██║ ╚═╝ ██║██║   ██║      ██║   
╚═╝     ╚═╝  ╚═╝ ╚═════╝ ╚═╝  ╚═╝╚═╝╚═╝     ╚═╝╚═╝   ╚═╝      ╚═╝   

Earn your voice.

Anonymous, location-verified campus discussions — powered by trust, not followers.

Live Site Contact

================================================================

🌐 Access the Platform

Jump straight in — no setup, no installs. Works on any modern browser (desktop & mobile).

How to Get Started

  1. Open the link → You'll land on the login/register page
  2. Register a new account → Pick any username & password (no email needed)
  3. Select your campus → Choose "Manipal University Jaipur" or any listed campus
  4. Allow location access → The app will verify your GPS position
  5. Explore! → Browse the feed, vote on posts, check the jury system

⚠️ For Judges / Reviewers Not on Campus

Temporary hackathon workaround — these options will be removed in production.

Since GPS verification is required and you may not be at a supported campus, here's how to still access everything:

Method Steps
Test Account Username: testuser · Password: test1234
New Account Register normally — the hackathon build has relaxed GPS checks so evaluators outside campus can still get full access
Demo Mode Append ?demo=true to the Feed URL to inject live visual simulations of the 3-Tier AI moderation pipeline directly into the feed.

📖 What is Proximity?

Proximity is an anonymous, real-time campus discussion platform where your physical presence on campus earns you the right to speak. No emails, no phone numbers, no usernames tied to your identity — just GPS-verified trust.

Think of it as the campus bulletin board reimagined for the digital age: a space where students can share thoughts, confessions, questions, and events — completely anonymously — while a multi-layered moderation system keeps the community healthy.

Why Proximity?

Problem Proximity's Answer
Trolls flood anonymous platforms Trust Tiers — newcomers earn participation over time through verified check-ins
Harassment goes unchecked 3-Tier AI Moderation — keyword filters → ML toxicity scoring → LLM contextual analysis
Moderation is opaque & biased Jury System — community members vote blindly on flagged content
Fake accounts from off-campus GPS Geofencing — only verified campus residents gain full access
Privilege never expires Trust Decay — stop showing up, lose your voice

✨ Core Features

🔒 Trust Engine

Tiered access based on campus presence:

  • Ghost → Read-only
  • Observer → Vote & report
  • Voice → Full posting access
  • Moderator → Community moderation

📍 GPS Verified Check-Ins

Geofenced polygons validate campus attendance using the Ray Casting algorithm — no third-party location APIs, fully self-contained.

⚖️ Jury Moderation

Flagged posts go to a blind jury of verified campus members. 3 votes, majority wins. No single person decides what stays or goes.

🤖 3-Tier AI Pipeline

  1. Regex — instant keyword filter
  2. Detoxify ML — toxicity scoring (0–1)
  3. Gemini 2.0 Flash — contextual LLM analysis for edge cases

💬 Threaded Comments

Nested reply chains with voting, color-coded depth indicators, and GIF support via Tenor.

🗳️ Polls, Events & Search

Create polls, browse campus events, search across all posts — all anonymous, all verified.


🌍 Geo-Zones — How It Works

Proximity uses GPS polygon geofencing to verify that users are physically present on campus before granting participation rights.

📍 User checks in → Ray Casting Algorithm → ✅ Inside polygon · Check-in recorded / ❌ Outside · Denied

Rule Detail
Check-in cooldown Max 1 check-in per 4 hours
GPS accuracy Must be < 500m
Campus zones Each campus is a unique polygon

Currently Active Campuses

Campus Location Status
Manipal University Jaipur (MUJ) Jaipur, Rajasthan, India ✅ Live

🗺️ More Campuses Coming Soon

Proximity is built to scale. Adding a new campus is as simple as defining a polygon of GPS coordinates — no code changes needed, just configuration. We plan to onboard more universities and colleges in the near future. If you'd like your campus added, reach out to us!


🏗️ Tech Stack

Layer Technology
Frontend Next.js 16 · React 19 · TailwindCSS · Framer Motion · GSAP · Three.js/R3F
Backend Python · FastAPI · Uvicorn
Database Firebase Firestore
Auth Firebase Anonymous Auth
AI/ML Detoxify (HuggingFace) · Google Gemini 2.0 Flash
Hosting Firebase Hosting (Frontend) · Render (Backend)
DevOps Docker · Nginx · GitHub Actions

📂 Project Structure

Proximity/ ├── frontend/ # Next.js 16 web application │ ├── app/ # App Router (pages & layouts) │ ├── components/ # UI components (feed, jury, 3D, auth, mod) │ ├── lib/ # API clients, Zustand stores, hooks, utils │ └── types/ # TypeScript type definitions ├── backend/ # Python FastAPI server │ ├── api/ # Route handlers (posts, jury, verify, mod, etc.) │ ├── services/ # Business logic layer (19 services) │ ├── middleware/ # Auth & rate limiting │ ├── models/ # Pydantic request/response schemas │ └── tests/ # Unit & integration tests ├── hf_detoxify/ # Hugging Face Spaces ML model ├── nginx/ # Reverse proxy config └── docs/ # Feature documentation


🚀 Local Development

Prerequisites

  • Node.js 18+ · Python 3.11+ · Firebase project

Frontend

�ash cd frontend npm install npm run dev # → http://localhost:3000

Backend

�ash cd backend pip install -r requirements.txt python main.py # → http://localhost:8000

Docker (both services)

�ash docker compose up --build # Frontend + Backend with hot-reload


🎮 Trust Tier System

Tier Access How to Reach
👻 Ghost (Stage 0) Read only New account — default tier
👁️ Observer (Stage 1) Vote + Report 7+ days, 10+ check-ins
🗣️ Voice (Stage 2) Full posting access 14+ days, 20+ check-ins
🛡️ Moderator Jury + Mod queue Appointed by admins

Trust Decay ("Use It or Lose It")

Condition Action
Last ping < 14 days ✅ Active
Last ping > 14 days ⚠️ Downgraded to read-only
Last ping > 28 days 🔒 Account locked

🔗 Live URLs

Service URL
🌐 Platform proximity.strawhats.co.in
⚡ Backend API proximityweb.strawhats.co.in
📚 API Docs proximityweb.strawhats.co.in/docs

📬 Contact

Have questions, feedback, or want your campus added?


👥 Team Strawhats

Built with ❤️ and a lot of ☕

MIT License

AI Moderation Impact Dashboard

Access the AI Moderation dashboard on the /impact\ route to view live AI content moderation impacts across all campuses.

About

No description, website, or topics provided.

Resources

License

Contributing

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages

  • Python 54.7%
  • TypeScript 43.6%
  • JavaScript 0.6%
  • CSS 0.5%
  • Dockerfile 0.3%
  • HTML 0.2%
  • Other 0.1%