Skip to main content

The Problem

At Awaaz.AI, our voice agents are powered by carefully crafted prompts โ€” system instructions that define how an agent behaves on a call. Today, these prompts live in Google Docs and Drive folders. This creates real problems:
  • No version history you can actually use โ€” Google Docs tracks character-level edits, not meaningful prompt versions. Rolling back to โ€œthe version that worked well last Tuesdayโ€ is a nightmare.
  • No structure โ€” Prompts have variables like {{user_name}}, {{language}}, {{loan_amount}} but thereโ€™s no way to test them with real values without copy-pasting into a playground.
Youโ€™re going to fix this.

Your Mission

Build a Prompt Library โ€” a full-stack web app where the team can:
  1. Create and organize prompt templates with metadata
  2. Fill in variables and preview the rendered prompt
  3. Test prompts against an LLM and see the response instantly
  4. Track versions so we know what changed and when

Time Budget

You have 4 hours.

Technical Requirements

Database Layer (PostgreSQL)

Design a schema that stores:
prompts
โ”œโ”€โ”€ id (uuid)
โ”œโ”€โ”€ name (e.g., "Loan Reminder Agent โ€” Hindi")
โ”œโ”€โ”€ description
โ”œโ”€โ”€ category (e.g., "collections", "onboarding", "survey", "verification")
โ”œโ”€โ”€ language (e.g., "hi", "en", "es", "mr")
โ”œโ”€โ”€ template_body (the prompt text with {{variables}})
โ”œโ”€โ”€ variables (JSON array of variable definitions)
โ”œโ”€โ”€ version (integer, auto-incrementing per prompt)
โ”œโ”€โ”€ is_active (boolean)
โ”œโ”€โ”€ created_at
โ””โ”€โ”€ updated_at

prompt_versions
โ”œโ”€โ”€ id (uuid)
โ”œโ”€โ”€ prompt_id (foreign key)
โ”œโ”€โ”€ version (integer)
โ”œโ”€โ”€ template_body (snapshot of the prompt at this version)
โ”œโ”€โ”€ change_note (e.g., "Made tone more polite for rural users")
โ”œโ”€โ”€ created_by
โ””โ”€โ”€ created_at

Backend Layer

Build the following API endpoints: CRUD
  • GET /prompts โ€” List all prompts (with filters: category, language, search by name)
  • GET /prompts/:id โ€” Get a single prompt with its version history
  • POST /prompts โ€” Create a new prompt
  • PUT /prompts/:id โ€” Update a prompt (auto-creates a new version)
  • DELETE /prompts/:id โ€” Soft delete (set is_active = false)
Render & Test
  • POST /prompts/:id/render โ€” Accept variable values, return the rendered prompt with all {{variables}} filled in
  • POST /prompts/:id/test โ€” Render the prompt, send it to an LLM API, return the modelโ€™s response
Versions
  • GET /prompts/:id/versions โ€” List all versions of a prompt
  • GET /prompts/:id/versions/:version โ€” Get a specific version
  • POST /prompts/:id/rollback/:version โ€” Rollback to a previous version (creates a new version with the old body)

Frontend Layer (React or HTML + JS)

Build a single-page app with these views: Prompt List Page
  • Searchable, filterable table/grid of all prompts
  • Show name, category, language, version number, last updated
  • Filter by category and language
Prompt Editor Page
  • Text editor for the prompt template body
  • Auto-detect {{variables}} from the template and show input fields for each
  • Live preview panel showing the rendered prompt as you type variable values
  • โ€œSaveโ€ button that creates a new version with an optional change note
Test Panel
  • Fill in variables โ†’ click โ€œTest with LLMโ€ โ†’ see the modelโ€™s response
  • Show latency and token count of the LLM response
Version History
  • List of past versions with timestamps and change notes
  • Click to view any version
  • โ€œRollback to this versionโ€ button

Example Prompt Template

Hereโ€™s what a prompt in the library might look like: Name: Loan Reminder โ€” Hindi Category: Collections Language: hi Template:
You are a polite loan reminder agent for {{company_name}}.
You are calling {{user_name}} regarding their pending EMI payment.

Details:
- Loan ID: {{loan_id}}
- EMI Amount: โ‚น{{emi_amount}}
- Due Date: {{due_date}}
- Days Overdue: {{days_overdue}}

Instructions:
- Speak in Hindi (Hinglish is okay)
- Be polite but firm
- If the user says they will pay, ask for a specific date
- If the user says they cannot pay, ask about their situation empathetically
- Never threaten or use aggressive language
Variables:
[
  {"name": "company_name", "type": "string", "default": "Awaaz Financial"},
  {"name": "user_name", "type": "string"},
  {"name": "loan_id", "type": "string"},
  {"name": "emi_amount", "type": "number"},
  {"name": "due_date", "type": "date"},
  {"name": "days_overdue", "type": "number"}
]

Constraints & Ground Rules

ConstraintRequirement
BackendPython + FastAPI/Django
DatabasePostgreSQL
FrontendReact or Angular
LLM APIUse OpenAI or Gemini API for the test feature (API key will be provided)
AuthSkip authentication
DeploymentRun locally. No need to deploy.

Evaluation Criteria

CriteriaWeightWhat Weโ€™re Looking For
Working CRUD25%Can you create, read, update, and list prompts end-to-end?
Variable Rendering20%Does the template engine correctly fill in {{variables}}? Live preview works?
LLM Test Feature20%Can you render a prompt and get an LLM response from the UI?
Version History15%Are versions tracked? Can you view and rollback?
UI/UX10%Is the interface clean and usable? (Doesnโ€™t need to be pretty โ€” needs to be functional)
Code Quality10%Clean structure, error handling, separation of concerns

Bonus Challenges ๐Ÿ†

  • Diff View: Show a side-by-side diff between two prompt versions (use a library like diff-match-patch or jsdiff)
  • Prompt Duplication: โ€œClone this promptโ€ button to quickly create a variant (e.g., same prompt but for a different language)
  • Tag System: Add freeform tags to prompts for more flexible organization
  • Response Rating: After testing with an LLM, let the user rate the response (๐Ÿ‘/๐Ÿ‘Ž) and store it โ€” helps track which prompt versions perform best
  • Export: Export a prompt as JSON or Markdown for sharing

๐Ÿ† Hackathon Prize

The winner receives a USD $20 one-time credit towards a course or book of their choice.