Spaces:
Running
Running
| ts | |
| /** | |
| * Type definitions for Prompt Enhancer application | |
| */ | |
| /** | |
| * Available AI categories for prompt optimization | |
| */ | |
| export type AICategory = 'llm' | 'code' | 'image' | 'special' | |
| /** | |
| * Supported AI models and tools | |
| */ | |
| export type AIModel = | |
| // LLM Models | |
| | 'gpt-5' | |
| | 'gpt-5.1' | |
| | 'claude-4.5-opus' | |
| | 'claude-4.5-sonnet' | |
| | 'claude-4.5-haiku' | |
| | 'gemini-3-pro' | |
| | 'llama-3' | |
| | 'mistral-large' | |
| | 'mixtral' | |
| | 'minimax2' | |
| | 'kimik2' | |
| | 'deepseek' | |
| | 'qwen3' | |
| // Development Tools | |
| | 'manus' | |
| | 'replit-agent' | |
| | 'bolt-new' | |
| | 'v0-dev' | |
| | 'cursor-ai' | |
| | 'github-copilot' | |
| | 'google-antigravity' | |
| | 'kiro' | |
| | 'minimax-agent' | |
| // Specialized Tools | |
| | 'base44' | |
| | 'midjourney' | |
| | 'dall-e-3' | |
| | 'stable-diffusion' | |
| | 'runwayml' | |
| /** | |
| * AI model metadata | |
| */ | |
| export interface AIModelInfo { | |
| id: AIModel | |
| name: string | |
| category: AICategory | |
| description: string | |
| maxTokens?: number | |
| supportsStreaming?: boolean | |
| } | |
| /** | |
| * Prompt optimization request | |
| */ | |
| export interface OptimizationRequest { | |
| prompt: string | |
| targetModel: AIModel | |
| options?: OptimizationOptions | |
| } | |
| /** | |
| * Prompt optimization options | |
| */ | |
| export interface OptimizationOptions { | |
| preserveOriginalStructure?: boolean | |
| addExamples?: boolean | |
| specifyOutputFormat?: boolean | |
| enhanceClarity?: boolean | |
| addConstraints?: boolean | |
| } | |
| /** | |
| * Prompt optimization result | |
| */ | |
| export interface OptimizationResult { | |
| originalPrompt: string | |
| optimizedPrompt: string | |
| targetModel: AIModel | |
| improvements: string[] | |
| executionTime: number | |
| tokenEstimate?: number | |
| } | |
| /** | |
| * Application state interface | |
| */ | |
| export interface AppState { | |
| // Current prompt input | |
| prompt: string | |
| selectedModel: AIModel | null | |
| isOptimizing: boolean | |
| result: OptimizationResult | null | |
| error: string | null | |
| showComparison: boolean | |
| characterCount: number | |
| // UI state | |
| isLoading: boolean | |
| copiedStates: { | |
| original: boolean | |
| optimized: boolean | |
| } | |
| } | |
| /** | |
| * Character count warnings | |
| */ | |
| export interface CharacterWarning { | |
| type: 'warning' | 'error' | |
| message: string | |
| threshold?: number | |
| } | |
| /** | |
| * Validation result for prompt input | |
| */ | |
| export interface PromptValidation { | |
| isValid: boolean | |
| errors: string[] | |
| warnings: string[] | |
| suggestions: string[] | |
| } | |
| </html> |