Web ToolLive

AI Prompt Generator & Optimizer

Intelligent prompt engineering middleware transforming casual inputs into structurally optimized AI instructions.

Launch Web Tool
React 18ViteTypeScriptOpenRouter APITailwind CSSAxiosGitHub Actions
prompt-generator.sh
CLI Telemetry
// Prompt Generator: Dual-Mode Pipeline
export async function optimizePrompt(input: string, mode: 'fast' | 'advanced') {
  const systemDirective = mode === 'advanced'
    ? 'Deconstruct input into: Persona, Context, Detailed Constraints, Output Format.'
    : 'Synthesize input into a single concise, punchy high-yield prompt under 500 chars.';

  const response = await openRouterClient.post('/chat/completions', {
    model: 'deepseek/deepseek-r1-distill-llama-70b',
    messages: [
      { role: 'system', content: systemDirective },
      { role: 'user', content: input }
    ]
  });
  return response.data.choices[0].message.content;
}
Architecture & Objective

Engineered with uncompromising integrity.

Prompt Generator acts as an intelligent abstraction layer between casual users and cutting-edge LLMs. Featuring dual generation modes (Fast Mode for concise prompts, Advanced Mode for multi-layered reasoning prompts with constraints), it offers real-time character telemetry, one-click clipboard copying, keyboard shortcuts, and dark glassmorphic styling.

System Specifications

  • Live deployed on GitHub Pages with zero server hosting costs
  • Dual-mode prompt generation tailored for standard and reasoning models
  • Instant clipboard integration and Ctrl+Enter keyboard workflow
  • Decoupled, modular React component architecture

Core Capabilities

Dual Optimization Modalities

Switch between Fast Mode (<500 chars for rapid Q&A) and Advanced Mode (500–1000 chars with role definitions, edge case constraints, and strict output schemas).

Real-Time Telemetry & Token Guard

Live character counting and length boundary validation to prevent runaway token expenditure.

DeepSeek R1 & LLM Integration

Direct OpenRouter API integration with robust try/catch exception handling and user-friendly toast notifications.

Automated GitHub Actions CI/CD

Continuous integration pipeline running Vite builds, environment secret injection, and automatic GitHub Pages deployment on push.