The reality check you didn't ask for.
slap. is a minimalist, pastel-aesthetic web application that uses Google's Gemini 3 API to analyze your complaints and return a brutally honest assessment of your cognitive biases.
- Brutally Honest AI: Analyzes user input for cognitive biases (e.g., emotional reasoning, catastrophizing) using a "clinical and unsympathetic" persona.
- The Three-Part Slap:
- Reality Check: A harsh call-out of your bias.
- Philosophical Slap: A quote from realist philosophers like Nietzsche or Cioran.
- Prescription: A book recommendation to fix your mindset.
- Minimalist Aesthetic: Clean, pastel design with sharp typography.
- Security & Safety:
- Authentication: Integrated via Clerk (Google/Email).
- Rate Limiting: Limited to 5 requests per 24 hours per user via Upstash Redis.
- Framework: Next.js 15 (App Router)
- Styling: Tailwind CSS
- AI: Google Gemini API (
gemini-3-flash-preview) - Auth: Clerk
- Database/Rate Limit: Upstash Redis
- Deployment: Vercel
- Node.js 18+
- Google Gemini API Key
- Clerk Publishable/Secret Keys
- Upstash Redis URL/Token
-
Clone the repository:
git clone https://github.com/adityachauhan0/slap-app.git cd slap-app -
Install dependencies:
npm install
-
Configure Environment: Create a
.env.localfile with the following keys:GEMINI_API_KEY=AIzaSy... NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY=pk_test_... CLERK_SECRET_KEY=sk_test_... UPSTASH_REDIS_REST_URL=https://... UPSTASH_REDIS_REST_TOKEN=...
-
Run Locally:
npm run dev
To prevent abuse, the API enforces a strict limit of 5 requests per 24 hours per user using a sliding window algorithm implemented with @upstash/ratelimit.
MIT
