Transform weak prompts into elite, production-ready prompts using NVIDIA Llama 3.1 70B
Paste a rough idea → Hit "Forge It" → Get an elite prompt with power scoring, technique breakdown, and Warrior Analysis ✨
Paste a weak prompt → Hit Forge It → Watch the magic ✨
| Layer | Technology |
|---|---|
| Frontend | Vanilla HTML / CSS / JavaScript (single file) |
| Backend | Python · Flask · python-dotenv · requests |
| AI Model | NVIDIA Llama 3.1 70B Instruct (meta/llama-3.1-70b-instruct) |
| API | NVIDIA NIM API |
| Fonts | Bebas Neue · DM Sans · DM Mono (Google Fonts) |
Prompt Forging Engine — Rewrites any weak prompt into a detailed, elite-grade version (3–8× longer) using Llama 3.1 70B Instruct via the NVIDIA NIM API.
8 Prompt Engineering Technique Tags — Detects and highlights which techniques were applied:
Context · Specificity · Constraints · Output Format · Persona · Examples · Chain-of-Thought · Negatives
Power Level Meter (1–10) — Scores the upgrade from 1–10, visualised as a 10-bar indicator.
Warrior Rank System — Earn a rank based on your power level: RECRUIT → BRONZE → SILVER → GOLD → LEGENDARY
Warrior Analysis Panel — A 2–3 sentence explanation of every key improvement made to your prompt.
Typewriter Output Animation — Forged prompt streams in character-by-character for dramatic effect.
One-Click Copy — Instantly copy the forged prompt to clipboard.
Quick-Fill Examples — Pre-loaded starters: blog post, explain ML, resume help, marketing ideas.
Keyboard Shortcut — Ctrl + Enter / Cmd + Enter to forge instantly.
Responsive Design — Fully usable on mobile and tablet screens.
prompt_forge/
├── prompt_warrior.html # Frontend — single-file UI (HTML + CSS + JS)
├── server.py # Backend — Flask proxy to the NVIDIA NIM API
├── .env # Your API key (never committed)
├── .env.example # Template for environment setup
├── .gitignore # Standard Python/IDE ignore rules
└── README.md # This file
git clone https://github.com/Divyansh0208/Prompt_Forge.git
cd Prompt_Forgepython -m venv venv
# macOS / Linux
source venv/bin/activate
# Windows
venv\Scripts\activatepip install flask python-dotenv requestscp .env.example .envOpen .env and add your NVIDIA API key:
NVIDIA_API_KEY=your-nvidia-api-key-here
Get your free API key at build.nvidia.com.
python server.pyVisit http://localhost:8000 in your browser.
| Variable | Required | Description |
|---|---|---|
NVIDIA_API_KEY |
✅ Yes | API key from build.nvidia.com |
The API key is loaded server-side via python-dotenv and is never exposed to the browser.
- Enter a weak or rough prompt in the left panel.
- Click Forge It — frontend sends
POST /api/forgeto the Flask server. - Flask forwards the request to the NVIDIA NIM API with a detailed system prompt instructing Llama 3.1 70B to act as a master prompt engineer.
- The model returns a structured JSON response:
forged_prompt— the upgraded prompt texttechniques_used— list of techniques appliedpower_level— integer score from 1 to 10analysis— explanation of improvements
- Frontend renders the forged prompt with typewriter animation, lights up technique tags, fills the power meter, assigns a Warrior Rank, and shows the Warrior Analysis.
Proxies a chat completion request to the NVIDIA NIM API.
Request Body:
{
"model": "meta/llama-3.1-70b-instruct",
"max_tokens": 1000,
"messages": [
{ "role": "system", "content": "..." },
{ "role": "user", "content": "Weak prompt to forge: \"...\"" }
]
}Response: Standard NVIDIA/OpenAI-compatible chat completion object.
| Power Level | Warrior Rank |
|---|---|
| 0 | — |
| 1 – 2 | 🪖 RECRUIT |
| 3 – 4 | 🥉 BRONZE |
| 5 – 6 | 🥈 SILVER |
| 7 – 8 | 🥇 GOLD |
| 9 – 10 | 🏆 LEGENDARY |
Contributions are welcome! Fork the repo, make your changes, and open a pull request. For major changes, open an issue first to discuss what you'd like to change.
This project is licensed under the MIT License.
Created for Google Prompt Wars 2026.
