Spaces:
Runtime error
Download README.md from thisrudrapatel/WhatTheCode: direct link, hf CLI and curl.
- Browser
- Download file 3 kB
-
https://huggingface.co/spaces/thisrudrapatel/WhatTheCode/resolve/main/README.md
- Command line
-
hf download hf://spaces/thisrudrapatel/WhatTheCode/README.md
-
curl -L -o README.md https://huggingface.co/spaces/thisrudrapatel/WhatTheCode/resolve/main/README.md
A newer version of the Gradio SDK is available: 6.32.0
title: WhatTheCode
emoji: π»
colorFrom: gray
colorTo: indigo
sdk: gradio
app_file: app.py
pinned: false
license: mit
short_description: WhatTheCode π is a fun, dev-centric solution explainer
WhatTheCode π»π€―
βBecause sometimes your own code feels like decoding an encrypted puzzle.β
π― Overview
WhatTheCode π is a fun, dev-centric Leetcode solution explainer that turns your raw code or problem description into clean, structured, and markdown-ready explanations β perfect for:
- Future self-reviews π§
- Leetcode Discuss posts π¬
- Understanding alien π½ code
- Teaching others (or learning from your past logic)
No fluff. No academic jargon. Just structured, fun, markdown-formatted explanations that feel like a dev wrote them at 2 AM with pizza in hand and Stack Overflow tabs open.
π Features
βοΈ Instant Markdown Explanations
Paste your Leetcode code or problem, click a button β get a full explanation with:## Intuition π‘## Approach πͺ## Complexity β³## Code π¨π½βπ»- Optional:
## Alternate π
π€ Prompt Engineered Output
Built on top of Groq + Meta-LLaMA 4, carefully tuned with a cheeky, dev-friendly tone.π Alternate Solution Generator
Got time? Ask it to cook up a different approach with one click.π¦ Copy-Paste Ready Markdown Tab
Designed for fast Leetcode Discuss uploads.
π οΈ Tech Stack
Gradioβ Frontend & interactivityPythonβ Core logicGroq APIβ LLM backend (Meta LLaMA-4).env& HuggingFace Secrets β for secure prompt/key handling
βοΈ How to Use Locally
Clone the repo
git clone https://huggingface.co/spaces/<your-username>/WhatTheCode cd WhatTheCodeInstall dependencies
pip install -r requirements.txtAdd a
.envfile:GROQ_API_KEY=your_groq_key_here MAGIC_PROMPT="Your prompt string..."Run it locally:
python app.py
π‘ Deploy on Hugging Face Spaces
- Push your repo to Hugging Face
- Go to
Settings > Secretsand add:GROQ_API_KEYPROMPT_ADVANCE(optional)
- Hit βRestart Spaceβ β and you're live!
π¨ App Metadata
title: WhatTheCode
emoji: π
colorFrom: gray
colorTo: purple
sdk: gradio
app_file: app.py
license: mit
Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference