···11-import {DEFAULT_ALT_TEXT_AI_MODEL, MAX_ALT_TEXT} from '#/lib/constants'
11+import {
22+ DEFAULT_ALT_TEXT_AI_MODEL,
33+ DEFAULT_ALT_TEXT_AI_PROMPT,
44+ MAX_ALT_TEXT,
55+} from '#/lib/constants'
26import {logger} from '#/logger'
3748export async function generateAltText(
···610 model: string,
711 imageBase64: string,
812 imageMimeType: string,
1313+ customPrompt?: string,
914): Promise<string> {
1015 const response = await fetch(
1116 'https://openrouter.ai/api/v1/chat/completions',
···2530 content: [
2631 {
2732 type: 'text',
2828- text: `Generate a concise, descriptive alt text for this image, also extract text if needed. The alt text should be clear and helpful for screen readers. Keep it under ${MAX_ALT_TEXT} characters. Only respond with the alt text itself, no explanations or quotes.`,
3333+ text: customPrompt || DEFAULT_ALT_TEXT_AI_PROMPT,
2934 },
3035 {
3136 type: 'image_url',