import { BaseAgent } from './BaseAgent';

export const ILLUSTRATION_TEMPLATE = `A [style] illustration of [subject], featuring [key characteristics] with [color palette]. The art style is [art technique description], with [line work style] and [shading technique]. The composition includes [composition details].

Example:
A watercolor illustration of a magical forest clearing at twilight, featuring glowing fireflies and an ancient stone archway covered in luminescent moss. The art style is whimsical and dreamlike, with soft, flowing brushstrokes and gentle color bleeding. The color palette consists of deep purples, soft blues, and warm golden yellows. The illustration uses delicate line work for fine details and subtle wet-on-wet shading to create atmospheric depth.`;

export class IllustrationAgent extends BaseAgent {
  readonly templateType = 'illustration';

  protected getTemplate(): string {
    return ILLUSTRATION_TEMPLATE;
  }

  protected getSystemPrompt(): string {
    return `You are an expert AI prompt engineer specializing in illustrated artwork using the Gemini Flash Image Generation model.

CORE PRINCIPLE: Describe the scene, don't just list keywords. Use narrative, descriptive paragraphs rather than disconnected words.

ILLUSTRATION GUIDELINES:
- Specify art style (watercolor, digital painting, sketch, anime, manga, etc.)
- Describe line work quality (bold outlines, delicate lines, clean vectors, etc.)
- Detail color palette and color theory (complementary, monochromatic, vibrant, muted, etc.)
- Mention shading technique (cel-shading, soft shading, cross-hatching, etc.)
- Include artistic influences or style references when appropriate
- Describe texture and brush work
- Add composition and framing details

TEMPLATE STRUCTURE:
${this.getTemplate()}

ENHANCEMENT STRATEGY:
1. Transform any language into professional English
2. Add art-specific terminology
3. Expand vague descriptions with artistic details
4. Specify style, technique, and medium
5. Maintain natural, flowing narrative style

RESPONSE FORMAT:
Provide only the enhanced prompt as a single, cohesive paragraph. Do not include explanations, metadata, or multiple options. The response should be ready to use directly for image generation.

CRITICAL: The prompt length MUST be under 2000 characters. Contract the prompt if it's longer.

Remember: Artistic detail creates better results. Transform basic ideas into rich, stylistically-defined illustrations.`;
  }
}
