Fetch with timeout
TypeScriptcode
export async function fetchWithTimeout(url: string, ms = 8000) {
const controller = new AbortController()
const timer = setTimeout(() => controller.abort(), ms)
try {
const res = await fetch(url, { signal: controller.signal })
return res
} finally {
clearTimeout(timer)
}
}
Safe JSON parse
TypeScriptcode
export function safeJsonParse<T>(value: string, fallback: T): T {
try {
return JSON.parse(value) as T
} catch {
return fallback
}
}
export function debounce<T extends (...args: unknown[]) => void>(
fn: T,
wait: number
): (...args: Parameters<T>) => void {
let timer: ReturnType<typeof setTimeout>
return (...args: Parameters<T>) => {
clearTimeout(timer)
timer = setTimeout(() => fn(...args), wait)
}
}
Retry with exponential backoff
TypeScriptcode
export async function retryWithBackoff<T>(
fn: () => Promise<T>,
retries = 3,
baseDelayMs = 400
): Promise<T> {
let attempt = 0
while (true) {
try {
return await fn()
} catch (err) {
if (attempt >= retries) throw err
const delay = baseDelayMs * 2 ** attempt + Math.random() * 100
await new Promise((r) => setTimeout(r, delay))
attempt++
}
}
}
Slugify string
TypeScriptcode
export function slugify(input: string): string {
return input
.toLowerCase()
.trim()
.replace(/[^a-z0-9]+/g, "-")
.replace(/^-+|-+$/g, "")
}
Format bytes to human-readable
TypeScriptcode
export function formatBytes(bytes: number, decimals = 1): string {
if (bytes === 0) return "0 B"
const k = 1024
const sizes = ["B", "KB", "MB", "GB", "TB"]
const i = Math.floor(Math.log(bytes) / Math.log(k))
return `${parseFloat((bytes / k ** i).toFixed(decimals))} ${sizes[i]}`
}
Chunk array into batches
TypeScriptcode
export function chunk<T>(array: T[], size: number): T[][] {
const chunks: T[][] = []
for (let i = 0; i < array.length; i += size) {
chunks.push(array.slice(i, i + size))
}
return chunks
}
Group array by key
TypeScriptcode
export function groupBy<T>(
array: T[],
key: (item: T) => string
): Record<string, T[]> {
return array.reduce<Record<string, T[]>>((acc, item) => {
const k = key(item)
if (!acc[k]) acc[k] = []
acc[k].push(item)
return acc
}, {})
}
Deep merge objects
TypeScriptcode
export function deepMerge<T extends Record<string, unknown>>(
target: T,
source: Partial<T>
): T {
const output = { ...target }
for (const key in source) {
const srcVal = source[key]
const tgtVal = target[key]
if (
srcVal !== null &&
typeof srcVal === "object" &&
!Array.isArray(srcVal) &&
typeof tgtVal === "object" &&
tgtVal !== null
) {
output[key] = deepMerge(
tgtVal as Record<string, unknown>,
srcVal as Record<string, unknown>
) as T[typeof key]
} else {
output[key] = srcVal as T[typeof key]
}
}
return output
}
Format date as relative time
TypeScriptcode
export function relativeTime(date: Date | string): string {
const d = typeof date === "string" ? new Date(date) : date
const seconds = Math.floor((Date.now() - d.getTime()) / 1000)
const rtf = new Intl.RelativeTimeFormat("en", { numeric: "auto" })
const ranges: [number, Intl.RelativeTimeFormatUnit][] = [
[60, "second"],
[3600, "minute"],
[86400, "hour"],
[2592000, "day"],
[31536000, "month"],
[Infinity, "year"],
]
let prev = 1
for (const [limit, unit] of ranges) {
if (seconds < limit) {
return rtf.format(-Math.floor(seconds / prev), unit)
}
prev = limit
}
return d.toLocaleDateString()
}
Truncate string with ellipsis
TypeScriptcode
export function truncate(str: string, maxLength: number): string {
if (str.length <= maxLength) return str
return str.slice(0, maxLength - 3).trimEnd() + "..."
}
Class names helper (cn)
TypeScriptcode
import { clsx, type ClassValue } from "clsx"
import { twMerge } from "tailwind-merge"
export function cn(...inputs: ClassValue[]) {
return twMerge(clsx(inputs))
}
useLocalStorage hook
TypeScript / Reactcode
import { useEffect, useState } from "react"
export function useLocalStorage<T>(key: string, initial: T) {
const [value, setValue] = useState<T>(initial)
const [mounted, setMounted] = useState(false)
useEffect(() => {
setMounted(true)
try {
const stored = localStorage.getItem(key)
if (stored !== null) setValue(JSON.parse(stored) as T)
} catch {}
}, [key])
function set(next: T) {
setValue(next)
try {
localStorage.setItem(key, JSON.stringify(next))
} catch {}
}
return [mounted ? value : initial, set] as const
}
useDebounce hook
TypeScript / Reactcode
import { useEffect, useState } from "react"
export function useDebounce<T>(value: T, delay: number): T {
const [debounced, setDebounced] = useState(value)
useEffect(() => {
const timer = setTimeout(() => setDebounced(value), delay)
return () => clearTimeout(timer)
}, [value, delay])
return debounced
}
Clamp a number
TypeScriptcode
export function clamp(value: number, min: number, max: number): number {
return Math.min(Math.max(value, min), max)
}
Unique array items by key
TypeScriptcode
export function uniqueBy<T>(items: T[], getKey: (item: T) => string): T[] {
const seen = new Set<string>()
return items.filter((item) => {
const key = getKey(item)
if (seen.has(key)) return false
seen.add(key)
return true
})
}
Sleep helper
TypeScriptcode
export function sleep(ms: number): Promise<void> {
return new Promise((resolve) => setTimeout(resolve, ms))
}
Remove empty object values
TypeScriptcode
export function omitEmpty<T extends Record<string, unknown>>(obj: T): Partial<T> {
return Object.fromEntries(
Object.entries(obj).filter(([, value]) => value !== "" && value !== null && value !== undefined)
) as Partial<T>
}
Map object values
TypeScriptcode
export function mapValues<T extends Record<string, unknown>, R>(
obj: T,
transform: (value: T[keyof T], key: keyof T) => R
): Record<keyof T, R> {
const entries = Object.entries(obj).map(([key, value]) => [
key,
transform(value as T[keyof T], key as keyof T),
])
return Object.fromEntries(entries) as Record<keyof T, R>
}
Pick object keys
TypeScriptcode
export function pick<T extends Record<string, unknown>, K extends keyof T>(
obj: T,
keys: K[]
): Pick<T, K> {
return keys.reduce((acc, key) => {
acc[key] = obj[key]
return acc
}, {} as Pick<T, K>)
}
Build query string
TypeScriptcode
export function toQueryString(params: Record<string, string | number | boolean | null | undefined>) {
const search = new URLSearchParams()
for (const [key, value] of Object.entries(params)) {
if (value !== null && value !== undefined && value !== "") {
search.set(key, String(value))
}
}
return search.toString()
}
Parse a CSV line
TypeScriptcode
export function parseCsvLine(line: string): string[] {
const result: string[] = []
let current = ""
let inQuotes = false
for (let i = 0; i < line.length; i++) {
const char = line[i]
if (char === '"') {
if (inQuotes && line[i + 1] === '"') {
current += '"'
i++
} else {
inQuotes = !inQuotes
}
} else if (char === "," && !inQuotes) {
result.push(current)
current = ""
} else {
current += char
}
}
result.push(current)
return result
}
Ensure value is an array
TypeScriptcode
export function ensureArray<T>(value: T | T[] | null | undefined): T[] {
if (value === null || value === undefined) return []
return Array.isArray(value) ? value : [value]
}
Sort by mapper
TypeScriptcode
export function sortBy<T>(
items: T[],
getValue: (item: T) => string | number,
direction: "asc" | "desc" = "asc"
) {
return [...items].sort((a, b) => {
const left = getValue(a)
const right = getValue(b)
if (left === right) return 0
const order = left > right ? 1 : -1
return direction === "asc" ? order : order * -1
})
}
Create numeric range
TypeScriptcode
export function range(length: number, start = 0): number[] {
return Array.from({ length }, (_, index) => index + start)
}
Calculate percentage
TypeScriptcode
export function percent(part: number, total: number, decimals = 0): number {
if (total === 0) return 0
return Number(((part / total) * 100).toFixed(decimals))
}
Copy text to clipboard
TypeScriptcode
export async function copyToClipboard(text: string): Promise<boolean> {
try {
await navigator.clipboard.writeText(text)
return true
} catch {
return false
}
}
Download text as file
TypeScriptcode
export function downloadTextFile(filename: string, content: string) {
const blob = new Blob([content], { type: "text/plain;charset=utf-8" })
const url = URL.createObjectURL(blob)
const link = document.createElement("a")
link.href = url
link.download = filename
link.click()
URL.revokeObjectURL(url)
}
Basic email validator
TypeScriptcode
export function isEmail(value: string): boolean {
return /^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(value)
}
Convert string to title case
TypeScriptcode
export function toTitleCase(value: string): string {
return value
.toLowerCase()
.split(" ")
.filter(Boolean)
.map((word) => word[0].toUpperCase() + word.slice(1))
.join(" ")
}
Compose async functions
TypeScriptcode
export function pipeAsync<T>(...fns: Array<(value: T) => T | Promise<T>>) {
return async (input: T) => {
let current = input
for (const fn of fns) {
current = await fn(current)
}
return current
}
}
Run tasks with limited concurrency
TypeScriptcode
export async function promisePool<T, R>(
items: T[],
worker: (item: T, index: number) => Promise<R>,
concurrency = 3
): Promise<R[]> {
const results: R[] = []
let nextIndex = 0
async function run() {
while (nextIndex < items.length) {
const index = nextIndex++
results[index] = await worker(items[index], index)
}
}
await Promise.all(Array.from({ length: concurrency }, run))
return results
}
Poll until condition passes
TypeScriptcode
export async function waitFor(
check: () => boolean | Promise<boolean>,
timeoutMs = 5000,
intervalMs = 100
) {
const start = Date.now()
while (Date.now() - start < timeoutMs) {
if (await check()) return true
await new Promise((resolve) => setTimeout(resolve, intervalMs))
}
throw new Error("Timed out waiting for condition")
}
useEventListener hook
TypeScript / Reactcode
import { useEffect, useRef } from "react"
export function useEventListener<K extends keyof WindowEventMap>(
eventName: K,
handler: (event: WindowEventMap[K]) => void
) {
const savedHandler = useRef(handler)
useEffect(() => {
savedHandler.current = handler
}, [handler])
useEffect(() => {
const listener = (event: WindowEventMap[K]) => savedHandler.current(event)
window.addEventListener(eventName, listener)
return () => window.removeEventListener(eventName, listener)
}, [eventName])
}
usePrevious hook
TypeScript / Reactcode
import { useEffect, useRef } from "react"
export function usePrevious<T>(value: T): T | undefined {
const ref = useRef<T>()
useEffect(() => {
ref.current = value
}, [value])
return ref.current
}
useToggle hook
TypeScript / Reactcode
import { useState } from "react"
export function useToggle(initial = false) {
const [value, setValue] = useState(initial)
const toggle = () => setValue((current) => !current)
return { value, setValue, toggle }
}
useMediaQuery hook
TypeScript / Reactcode
import { useEffect, useState } from "react"
export function useMediaQuery(query: string) {
const [matches, setMatches] = useState(false)
useEffect(() => {
const media = window.matchMedia(query)
const onChange = () => setMatches(media.matches)
onChange()
media.addEventListener("change", onChange)
return () => media.removeEventListener("change", onChange)
}, [query])
return matches
}
useOnClickOutside hook
TypeScript / Reactcode
import { RefObject, useEffect } from "react"
export function useOnClickOutside<T extends HTMLElement>(
ref: RefObject<T | null>,
onOutside: () => void
) {
useEffect(() => {
function handle(event: MouseEvent) {
const target = event.target as Node | null
if (!ref.current || !target || ref.current.contains(target)) return
onOutside()
}
document.addEventListener("mousedown", handle)
return () => document.removeEventListener("mousedown", handle)
}, [onOutside, ref])
}
Format currency
TypeScriptcode
export function formatCurrency(amount: number, currency = "USD", locale = "en-US") {
return new Intl.NumberFormat(locale, {
style: "currency",
currency,
maximumFractionDigits: 2,
}).format(amount)
}
Format date for input[type=date]
TypeScriptcode
export function toDateInputValue(date: Date): string {
const offset = date.getTimezoneOffset()
const localDate = new Date(date.getTime() - offset * 60_000)
return localDate.toISOString().slice(0, 10)
}
Days between dates
TypeScriptcode
export function daysBetween(a: Date | string, b: Date | string): number {
const left = new Date(a).getTime()
const right = new Date(b).getTime()
return Math.round(Math.abs(right - left) / 86_400_000)
}
Get file extension
TypeScriptcode
export function getFileExtension(filename: string): string {
const parts = filename.split(".")
return parts.length > 1 ? parts.at(-1)?.toLowerCase() ?? "" : ""
}
Rename object keys
TypeScriptcode
export function renameKeys<T extends Record<string, unknown>>(
obj: T,
map: Record<string, string>
): Record<string, unknown> {
return Object.fromEntries(
Object.entries(obj).map(([key, value]) => [map[key] ?? key, value])
)
}
Redact email address
TypeScriptcode
export function redactEmail(email: string): string {
const [name, domain] = email.split("@")
if (!name || !domain) return email
const visible = name.slice(0, 2)
return `${visible}${"*".repeat(Math.max(name.length - 2, 1))}@${domain}`
}
Generate initials
TypeScriptcode
export function getInitials(name: string): string {
return name
.split(" ")
.filter(Boolean)
.slice(0, 2)
.map((part) => part[0]?.toUpperCase() ?? "")
.join("")
}
Flatten tree nodes
TypeScriptcode
type TreeNode<T> = T & { children?: TreeNode<T>[] }
export function flattenTree<T>(nodes: TreeNode<T>[]): TreeNode<T>[] {
return nodes.flatMap((node) => [node, ...flattenTree(node.children ?? [])])
}
Build tree from flat list
TypeScriptcode
type FlatNode = {
id: string
parentId: string | null
[key: string]: unknown
}
export function treeFromFlat<T extends FlatNode>(items: T[]) {
const map = new Map<string, T & { children: Array<T & { children: unknown[] }> }>()
const roots: Array<T & { children: unknown[] }> = []
for (const item of items) {
map.set(item.id, { ...item, children: [] })
}
for (const item of items) {
const node = map.get(item.id)!
if (!item.parentId) {
roots.push(node)
} else {
map.get(item.parentId)?.children.push(node)
}
}
return roots
}
Loose text match
TypeScriptcode
export function fuzzyIncludes(text: string, query: string): boolean {
return text.toLowerCase().replace(/\s+/g, " ").includes(query.toLowerCase().trim())
}
No-op function
TypeScriptcode
export function noop(): void {}
assertNever helper
TypeScriptcode
export function assertNever(value: never): never {
throw new Error(`Unexpected value: ${String(value)}`)
}
Project proposal writer
Promptprompt
You are a senior project consultant writing proposals for freelance and agency projects.
Create a concise, professional proposal using this structure:
1. Problem summary in the client's language, focused on impact
2. Recommended approach in plain language
3. Scope and deliverables with inclusions and exclusions
4. Timeline with milestones and target dates
5. Investment with total price, payment schedule, and terms
6. Assumptions and risks
Keep it clear, practical, and client-ready. Avoid filler.
Project context: [describe the project]
Debug analysis
Promptprompt
Analyze this issue and return:
1. Root cause hypothesis
2. Reproduction steps
3. Minimal fix
4. Side effects and regression risks
5. Verification checklist
Keep the answer implementation-focused. No generic advice.
Error or issue: [paste error]
Context: [relevant code or system description]
Automation design
Promptprompt
You are an automation architect. Design a workflow for this scenario.
Provide:
1. Trigger
2. Conditions or filters
3. Numbered steps
4. Output
5. Failure handling
6. Best-fit platform and why
Be specific about field names, data types, and edge cases.
Scenario: [describe the workflow to automate]
Requirements extraction
Promptprompt
Extract and structure the project requirements from the description below.
Return:
1. Core objective
2. Functional requirements
3. Non-functional requirements
4. Assumptions
5. Open questions
6. Out-of-scope items
Convert vague language into measurable criteria where possible.
Project description: [paste description or notes]
User story writer
Promptprompt
Convert the feature into well-structured user stories.
Format each story as:
- Title
- Story: As a [user], I want to [action] so that [outcome]
- Acceptance criteria: 3 to 5 specific, testable bullets
- Notes: edge cases, dependencies, or open questions
Write stories at a task level. Break large features into multiple stories.
Feature or requirement: [describe the feature]
API integration review
Promptprompt
Review this API integration plan or code and assess:
1. Authentication
2. Error handling
3. Rate limiting
4. Data validation
5. Edge cases
6. Security risks
7. Prioritized improvements
Be direct. Flag real problems, not hypothetical ones.
Integration code or plan: [paste code or describe the integration]
Scope validation
Promptprompt
Review the following project scope and identify risks before work begins.
Check for:
1. Ambiguous deliverables
2. Missing exclusions
3. Undefined dependencies
4. Timeline risks
5. Pricing risks
6. Acceptance criteria gaps
For each issue, suggest a specific fix to the scope language.
Scope or proposal: [paste the scope or proposal text]
Client onboarding email
Promptprompt
Write a professional client onboarding email to send after a project is signed.
The email should:
- Welcome the client and confirm the project is starting
- Summarize next steps in a numbered list
- State what you need before work begins
- Include kickoff details if available
- Set communication channel and response expectations
- Stay under 200 words
Project context: [brief project description]
Client name: [name]
Kickoff date: [date if known]
What you need from the client: [list]
Project idea from job description
Promptprompt
You are a practical technical mentor helping me choose a project to build for my portfolio.
I will give you:
1. A job description
2. My current capabilities, technologies, and skills
Your task:
1. Extract the main responsibilities, tools, and skill signals from the job description
2. Compare them against my current capabilities
3. Suggest 3 realistic project ideas I can build now or with a small stretch
4. Rank the ideas by portfolio value and feasibility
5. For the best idea, provide:
- Project title
- Why it fits the role
- Core features
- Recommended tech stack based on my current skills
- Stretch features if I want to level up
- A 7-day implementation plan
- Resume bullet I could write after finishing it
Rules:
- Do not suggest projects that require skills far beyond my current level unless marked as stretch
- Favor projects that clearly demonstrate the same technologies or workflows mentioned in the job description
- Be specific and practical, not inspirational
Job description:
[paste the job description]
My current capabilities and tech stack:
[paste your current skills, tools, and experience]
Feature spec writer
Promptprompt
Turn the feature request into a concise implementation spec.
Include:
1. Goal
2. User flow
3. Business rules
4. Data inputs and outputs
5. Edge cases
6. Dependencies
7. Done criteria
Feature request: [paste request]
Test case generator
Promptprompt
Generate a QA test plan for this feature.
Return:
1. Happy path cases
2. Validation and error cases
3. Permission or auth cases
4. Browser or device concerns
5. Regression risks
Feature details: [paste feature description]
Bug report rewriter
Promptprompt
Rewrite the raw bug report into a developer-ready issue.
Use this format:
1. Summary
2. Environment
3. Steps to reproduce
4. Expected behavior
5. Actual behavior
6. Evidence or logs
7. Suspected area
Raw report: [paste notes or chat message]
Code review request draft
Promptprompt
Draft a concise code review request for teammates.
Include:
1. What changed
2. Why the change was needed
3. Areas where feedback is most needed
4. Risks or known tradeoffs
5. How to test it
Change summary: [paste PR summary or notes]
Refactor plan
Promptprompt
Create a safe refactor plan for this code or module.
Return:
1. Current problems
2. Refactor goals
3. Step-by-step sequence
4. Risks and rollback notes
5. Tests to add before and after
Code or module context: [paste code or describe module]
SQL query helper
Promptprompt
Write or improve a SQL query for the task below.
Provide:
1. Final query
2. Short explanation
3. Assumptions about schema
4. Performance considerations
5. Index suggestions if relevant
Task: [describe the data question]
Schema: [paste tables and columns]
API endpoint designer
Promptprompt
Design an API endpoint for this use case.
Include:
1. Method and route
2. Request schema
3. Response schema
4. Validation rules
5. Error codes
6. Auth requirements
7. Example requests and responses
Use case: [describe the feature]
UI and UX critique
Promptprompt
Review this screen, wireframe, or UI description.
Give feedback on:
1. Clarity
2. Visual hierarchy
3. Actionability
4. Friction points
5. Accessibility concerns
6. Suggested improvements in order of impact
UI context: [paste screenshot notes or description]
Landing page copy
Promptprompt
Write landing page copy for this product or service.
Return:
1. Hero headline
2. Hero subheadline
3. Three benefits
4. Features section copy
5. CTA text
6. FAQ with 4 questions
Audience: [who it is for]
Offer: [what you sell]
Tone: [desired voice]
Cold outreach email
Promptprompt
Write a short cold outreach email for this service offer.
Constraints:
- 120 words max
- Personalized opening
- One clear problem
- One clear solution
- One CTA
- No hype
Target company or person: [describe]
Offer: [describe service]
Proof or credibility: [optional]
Discovery call questions
Promptprompt
Generate discovery call questions for this project.
Group them into:
1. Goals
2. Current process
3. Constraints
4. Stakeholders
5. Budget and timeline
6. Success metrics
Project type: [describe project]
Create a one-week sprint plan from the backlog below.
Return:
1. Sprint goal
2. Prioritized items
3. Daily sequencing
4. Dependencies
5. Risks
6. Stretch items
Backlog: [paste backlog items]
Retrospective summary
Promptprompt
Turn the raw retrospective notes into a clear team summary.
Use sections:
1. What went well
2. What did not go well
3. Patterns observed
4. Action items
5. Owners and next review date
Raw notes: [paste notes]
Changelog generator
Promptprompt
Write a release changelog from the changes below.
Organize into:
1. Added
2. Improved
3. Fixed
4. Breaking changes
5. Upgrade notes if needed
Changes: [paste commits, PRs, or release notes]
Commit message writer
Promptprompt
Write 5 strong commit message options for this change.
Requirements:
- Imperative mood
- Specific
- No vague wording
- Include scope if useful
Change summary: [describe the change]
Risk register
Promptprompt
Create a project risk register from the context below.
For each risk, include:
1. Risk statement
2. Impact
3. Likelihood
4. Mitigation
5. Owner
6. Early warning sign
Project context: [paste project details]
Estimation breakdown
Promptprompt
Break this project into estimated work items.
Return a table with:
1. Task
2. Estimate in hours
3. Dependency
4. Risk level
5. Notes
Also include total baseline estimate and a buffered estimate.
Project scope: [paste scope]
Interview answer coach
Promptprompt
Help me answer this interview question strongly.
Provide:
1. Best answer structure
2. A polished sample answer
3. What to avoid saying
4. One follow-up story I can mention
Role: [job title]
Question: [paste interview question]
My background: [paste relevant experience]
Resume bullet rewriter
Promptprompt
Rewrite these resume bullets to be clearer and more outcome-focused.
Rules:
- Start with strong verbs
- Show impact where possible
- Remove fluff
- Keep each bullet concise
Current bullets: [paste bullets]
Target role: [paste role]
Case study outline
Promptprompt
Create a portfolio case study outline for this project.
Use:
1. Context
2. Problem
3. Constraints
4. Approach
5. Technical decisions
6. Results
7. Lessons learned
Project summary: [paste details]
Technical doc summary
Promptprompt
Summarize this technical document for a working engineer.
Return:
1. What it is about
2. Key concepts
3. Important implementation details
4. Caveats
5. Action items or decisions
Document text: [paste content]
Project handoff note
Promptprompt
Write a handoff note for the next developer or team.
Include:
1. Current status
2. What was completed
3. Known issues
4. Important files or systems
5. Next recommended actions
Project context: [paste notes]
Root cause postmortem
Promptprompt
Turn this incident information into a concise postmortem.
Include:
1. Incident summary
2. Customer impact
3. Timeline
4. Root cause
5. Contributing factors
6. Remediation
7. Prevention items
Incident details: [paste details]
Create a pre-release QA checklist for this product area.
Cover:
1. Functional checks
2. Validation cases
3. Permissions
4. Performance
5. Accessibility
6. Analytics or tracking
Feature or page: [describe it]
Stakeholder update
Promptprompt
Write a concise status update for stakeholders.
Use:
1. Progress this week
2. Current blockers
3. Risks
4. Next steps
5. Decisions needed
Audience: [who it is for]
Project notes: [paste notes]
Prompt improver
Promptprompt
Improve the prompt below so it produces better, more specific outputs.
Return:
1. Revised prompt
2. Why it is stronger
3. Optional input placeholders to add
Original prompt: [paste prompt]
Acceptance criteria polisher
Promptprompt
Turn the rough requirement into testable acceptance criteria.
Rules:
- Use clear pass/fail language
- Cover edge cases that matter
- Avoid implementation details unless required
Requirement: [paste requirement]
Data model review
Promptprompt
Review this data model and suggest improvements.
Assess:
1. Normalization
2. Naming clarity
3. Query patterns
4. Missing constraints
5. Index recommendations
6. Future scaling concerns
Schema: [paste tables or models]
Migration plan
Promptprompt
Create a migration plan for moving from the current system to the target system.
Include:
1. Scope
2. Prep work
3. Data migration steps
4. Cutover plan
5. Rollback strategy
6. Verification checklist
Current system: [describe]
Target system: [describe]
Pricing options draft
Promptprompt
Draft 3 pricing options for this service.
For each option include:
1. Package name
2. What is included
3. What is excluded
4. Ideal client fit
5. Pricing rationale
Service context: [describe service]
Contract scope outline
Promptprompt
Create a contract-ready scope outline for this project.
Include:
1. Objectives
2. Deliverables
3. Client responsibilities
4. Assumptions
5. Exclusions
6. Change request handling
7. Acceptance terms
Project details: [paste details]
Meeting notes to action items
Promptprompt
Convert these meeting notes into clear action items.
Return:
1. Decisions made
2. Open questions
3. Action items
4. Owners
5. Deadlines
Meeting notes: [paste notes]
Support reply drafter
Promptprompt
Write a customer support reply for the case below.
Constraints:
- Empathetic but direct
- Clear next step
- No blame
- No unnecessary jargon
Customer message: [paste message]
Policy or known fix: [paste relevant details]
Knowledge base article
Promptprompt
Write a help center article for this workflow.
Use:
1. Overview
2. When to use this
3. Step-by-step instructions
4. Common errors
5. FAQ
Workflow: [describe it]
Turn this process into a standard operating procedure.
Include:
1. Purpose
2. Trigger
3. Required inputs
4. Steps
5. Quality checks
6. Escalation path
Process notes: [paste notes]
Dashboard requirements
Promptprompt
Define the requirements for a dashboard based on the business need below.
Return:
1. Primary users
2. Key decisions this dashboard should support
3. Required metrics
4. Filters and drill-downs
5. Data sources
6. Refresh frequency
7. Risks or data gaps
Business need: [paste details]
AI agent task brief
Promptprompt
Write a strong task brief for an AI coding or ops agent.
Include:
1. Objective
2. Constraints
3. Inputs and file paths
4. Expected output
5. Verification steps
6. Failure handling
Task context: [paste the assignment]
Build vs buy analysis
Promptprompt
Analyze whether we should build this in-house or buy an existing solution.
Compare:
1. Cost
2. Time to value
3. Maintenance burden
4. Integration complexity
5. Flexibility
6. Risks
7. Recommendation with reasoning
Problem to solve: [describe]
Constraints: [budget, timeline, team capability]
Database seed data generator
Promptprompt
Generate realistic seed data ideas for the following app.
Provide:
1. Core entities to seed
2. Example records for each
3. Relationships between entities
4. Edge-case data to include
5. Tips for keeping data realistic
App context: [describe app]
Environment variable audit
Promptprompt
Review this list of environment variables and configuration needs.
Return:
1. Variables grouped by purpose
2. Which are server-only
3. Which are safe for client exposure
4. Missing variables
5. Naming improvements
6. Security concerns
Current env setup: [paste variables and usage notes]
Tool selection advisor
Promptprompt
Recommend the best tool or platform for this job.
Compare at least 3 options on:
1. Fit for requirements
2. Ease of implementation
3. Cost
4. Scalability
5. Lock-in risk
6. Learning curve
Use case: [describe the problem]
Constraints: [team size, budget, existing stack]