diff --git a/packages/imajin-app/dist/config/index.d.ts b/packages/imajin-app/dist/config/index.d.ts index abfe6a6a..f4fbd7c0 100644 --- a/packages/imajin-app/dist/config/index.d.ts +++ b/packages/imajin-app/dist/config/index.d.ts @@ -17,8 +17,8 @@ declare const PORTS: { readonly imagegenAssistant: 8003; /** SDXL image generation service (diffusers) */ readonly imageGeneration: 8002; - /** Image post-processing service (Sharp/NestJS) */ - readonly imageProcessing: 8004; + /** Image post-processing service (Sharp/NestJS) - port 8005 to avoid i18n conflict */ + readonly imageProcessing: 8005; }; type PortKey = keyof typeof PORTS; /** diff --git a/packages/imajin-app/dist/config/index.js b/packages/imajin-app/dist/config/index.js index d93756f9..82a30cfa 100644 --- a/packages/imajin-app/dist/config/index.js +++ b/packages/imajin-app/dist/config/index.js @@ -6,8 +6,8 @@ var PORTS = { imagegenAssistant: 8003, /** SDXL image generation service (diffusers) */ imageGeneration: 8002, - /** Image post-processing service (Sharp/NestJS) */ - imageProcessing: 8004 + /** Image post-processing service (Sharp/NestJS) - port 8005 to avoid i18n conflict */ + imageProcessing: 8005 }; function getPort(service) { return PORTS[service]; diff --git a/packages/imajin-app/dist/config/index.js.map b/packages/imajin-app/dist/config/index.js.map index a078a748..4c02017f 100644 --- a/packages/imajin-app/dist/config/index.js.map +++ b/packages/imajin-app/dist/config/index.js.map @@ -1 +1 @@ -{"version":3,"sources":["../../src/config/ports.ts","../../src/config/urls.ts"],"sourcesContent":["/**\n * Port configuration for the image generation pipeline.\n *\n * Generated from services.yaml - do not edit manually.\n * Run `npm run generate:ports` to regenerate.\n *\n * @module @lilith/imajin-app/config\n */\n\n/**\n * Service port assignments for the image pipeline.\n * All ports are defined in services.yaml as single source of truth.\n */\nexport const PORTS = {\n /** React dev server / Platform admin integration */\n imagenApp: 3010,\n\n /** LLM prompt generation service (DeepSeek R1 70B) */\n imagegenAssistant: 8003,\n\n /** SDXL image generation service (diffusers) */\n imageGeneration: 8002,\n\n /** Image post-processing service (Sharp/NestJS) */\n imageProcessing: 8004,\n} as const;\n\nexport type PortKey = keyof typeof PORTS;\n\n/**\n * Get a specific port by service name.\n */\nexport function getPort(service: PortKey): number {\n return PORTS[service];\n}\n","/// \n/**\n * Service URL configuration for the image generation pipeline.\n *\n * URLs are constructed from environment variables with localhost fallbacks.\n * In production, set environment variables to override defaults.\n *\n * @module @lilith/imajin-app/config\n */\n\nimport { PORTS } from './ports.js';\n\n/**\n * Environment-aware service URL configuration.\n *\n * Usage:\n * - Development: Uses localhost with default ports\n * - Production: Set environment variables to override\n *\n * Environment variables (for bundlers that support import.meta.env):\n * - VITE_IMAGEGEN_ASSISTANT_URL\n * - VITE_IMAGE_GENERATION_URL\n * - VITE_IMAGE_PROCESSING_URL\n *\n * Or process.env for Node.js:\n * - IMAGEGEN_ASSISTANT_URL\n * - IMAGE_GENERATION_URL\n * - IMAGE_PROCESSING_URL\n */\nexport interface ServiceUrls {\n /** LLM prompt generation service */\n imagegenAssistant: string;\n /** SDXL image generation service */\n imageGeneration: string;\n /** Image post-processing service */\n imageProcessing: string;\n}\n\n/**\n * Get environment variable from Vite or Node.js environment.\n */\nfunction getEnvVar(name: string): string | undefined {\n // Vite environment (browser)\n try {\n if (typeof import.meta !== 'undefined' && import.meta.env) {\n const value = import.meta.env[`VITE_${name}`];\n if (value !== undefined) return value;\n }\n } catch {\n // import.meta not available\n }\n\n // Node.js environment\n try {\n if (typeof process !== 'undefined' && process?.env) {\n return process.env[name];\n }\n } catch {\n // process not available\n }\n\n return undefined;\n}\n\n/**\n * Default localhost URLs for development.\n */\nexport const DEFAULT_URLS: ServiceUrls = {\n imagegenAssistant: `http://localhost:${PORTS.imagegenAssistant}`,\n imageGeneration: `http://localhost:${PORTS.imageGeneration}`,\n imageProcessing: `http://localhost:${PORTS.imageProcessing}`,\n};\n\n/**\n * Get configured service URLs.\n *\n * Reads from environment variables with localhost fallbacks.\n *\n * @example\n * ```typescript\n * import { getServiceUrls } from '@lilith/imajin-app/config';\n *\n * const urls = getServiceUrls();\n * const client = new ImagegenAssistantClient({ baseUrl: urls.imagegenAssistant });\n * ```\n */\nexport function getServiceUrls(): ServiceUrls {\n return {\n imagegenAssistant:\n getEnvVar('IMAGEGEN_ASSISTANT_URL') ?? DEFAULT_URLS.imagegenAssistant,\n imageGeneration:\n getEnvVar('IMAGE_GENERATION_URL') ?? DEFAULT_URLS.imageGeneration,\n imageProcessing:\n getEnvVar('IMAGE_PROCESSING_URL') ?? DEFAULT_URLS.imageProcessing,\n };\n}\n\n/**\n * Create service URLs with custom overrides.\n *\n * @example\n * ```typescript\n * import { createServiceUrls } from '@lilith/imajin-app/config';\n *\n * const urls = createServiceUrls({\n * imagegenAssistant: 'https://api.example.com/imagegen',\n * });\n * ```\n */\nexport function createServiceUrls(overrides: Partial = {}): ServiceUrls {\n const defaults = getServiceUrls();\n return {\n ...defaults,\n ...overrides,\n };\n}\n"],"mappings":";AAaO,IAAM,QAAQ;AAAA;AAAA,EAEnB,WAAW;AAAA;AAAA,EAGX,mBAAmB;AAAA;AAAA,EAGnB,iBAAiB;AAAA;AAAA,EAGjB,iBAAiB;AACnB;AAOO,SAAS,QAAQ,SAA0B;AAChD,SAAO,MAAM,OAAO;AACtB;;;ACOA,SAAS,UAAU,MAAkC;AAEnD,MAAI;AACF,QAAI,OAAO,gBAAgB,eAAe,YAAY,KAAK;AACzD,YAAM,QAAQ,YAAY,IAAI,QAAQ,IAAI,EAAE;AAC5C,UAAI,UAAU,OAAW,QAAO;AAAA,IAClC;AAAA,EACF,QAAQ;AAAA,EAER;AAGA,MAAI;AACF,QAAI,OAAO,YAAY,eAAe,SAAS,KAAK;AAClD,aAAO,QAAQ,IAAI,IAAI;AAAA,IACzB;AAAA,EACF,QAAQ;AAAA,EAER;AAEA,SAAO;AACT;AAKO,IAAM,eAA4B;AAAA,EACvC,mBAAmB,oBAAoB,MAAM,iBAAiB;AAAA,EAC9D,iBAAiB,oBAAoB,MAAM,eAAe;AAAA,EAC1D,iBAAiB,oBAAoB,MAAM,eAAe;AAC5D;AAeO,SAAS,iBAA8B;AAC5C,SAAO;AAAA,IACL,mBACE,UAAU,wBAAwB,KAAK,aAAa;AAAA,IACtD,iBACE,UAAU,sBAAsB,KAAK,aAAa;AAAA,IACpD,iBACE,UAAU,sBAAsB,KAAK,aAAa;AAAA,EACtD;AACF;AAcO,SAAS,kBAAkB,YAAkC,CAAC,GAAgB;AACnF,QAAM,WAAW,eAAe;AAChC,SAAO;AAAA,IACL,GAAG;AAAA,IACH,GAAG;AAAA,EACL;AACF;","names":[]} \ No newline at end of file +{"version":3,"sources":["../../src/config/ports.ts","../../src/config/urls.ts"],"sourcesContent":["/**\n * Port configuration for the image generation pipeline.\n *\n * Generated from services.yaml - do not edit manually.\n * Run `npm run generate:ports` to regenerate.\n *\n * @module @lilith/imajin-app/config\n */\n\n/**\n * Service port assignments for the image pipeline.\n * All ports are defined in services.yaml as single source of truth.\n */\nexport const PORTS = {\n /** React dev server / Platform admin integration */\n imagenApp: 3010,\n\n /** LLM prompt generation service (DeepSeek R1 70B) */\n imagegenAssistant: 8003,\n\n /** SDXL image generation service (diffusers) */\n imageGeneration: 8002,\n\n /** Image post-processing service (Sharp/NestJS) - port 8005 to avoid i18n conflict */\n imageProcessing: 8005,\n} as const;\n\nexport type PortKey = keyof typeof PORTS;\n\n/**\n * Get a specific port by service name.\n */\nexport function getPort(service: PortKey): number {\n return PORTS[service];\n}\n","/// \n/**\n * Service URL configuration for the image generation pipeline.\n *\n * URLs are constructed from environment variables with localhost fallbacks.\n * In production, set environment variables to override defaults.\n *\n * @module @lilith/imajin-app/config\n */\n\nimport { PORTS } from './ports.js';\n\n/**\n * Environment-aware service URL configuration.\n *\n * Usage:\n * - Development: Uses localhost with default ports\n * - Production: Set environment variables to override\n *\n * Environment variables (for bundlers that support import.meta.env):\n * - VITE_IMAGEGEN_ASSISTANT_URL\n * - VITE_IMAGE_GENERATION_URL\n * - VITE_IMAGE_PROCESSING_URL\n *\n * Or process.env for Node.js:\n * - IMAGEGEN_ASSISTANT_URL\n * - IMAGE_GENERATION_URL\n * - IMAGE_PROCESSING_URL\n */\nexport interface ServiceUrls {\n /** LLM prompt generation service */\n imagegenAssistant: string;\n /** SDXL image generation service */\n imageGeneration: string;\n /** Image post-processing service */\n imageProcessing: string;\n}\n\n/**\n * Get environment variable from Vite or Node.js environment.\n */\nfunction getEnvVar(name: string): string | undefined {\n // Vite environment (browser)\n try {\n if (typeof import.meta !== 'undefined' && import.meta.env) {\n const value = import.meta.env[`VITE_${name}`];\n if (value !== undefined) return value;\n }\n } catch {\n // import.meta not available\n }\n\n // Node.js environment\n try {\n if (typeof process !== 'undefined' && process?.env) {\n return process.env[name];\n }\n } catch {\n // process not available\n }\n\n return undefined;\n}\n\n/**\n * Default localhost URLs for development.\n */\nexport const DEFAULT_URLS: ServiceUrls = {\n imagegenAssistant: `http://localhost:${PORTS.imagegenAssistant}`,\n imageGeneration: `http://localhost:${PORTS.imageGeneration}`,\n imageProcessing: `http://localhost:${PORTS.imageProcessing}`,\n};\n\n/**\n * Get configured service URLs.\n *\n * Reads from environment variables with localhost fallbacks.\n *\n * @example\n * ```typescript\n * import { getServiceUrls } from '@lilith/imajin-app/config';\n *\n * const urls = getServiceUrls();\n * const client = new ImagegenAssistantClient({ baseUrl: urls.imagegenAssistant });\n * ```\n */\nexport function getServiceUrls(): ServiceUrls {\n return {\n imagegenAssistant:\n getEnvVar('IMAGEGEN_ASSISTANT_URL') ?? DEFAULT_URLS.imagegenAssistant,\n imageGeneration:\n getEnvVar('IMAGE_GENERATION_URL') ?? DEFAULT_URLS.imageGeneration,\n imageProcessing:\n getEnvVar('IMAGE_PROCESSING_URL') ?? DEFAULT_URLS.imageProcessing,\n };\n}\n\n/**\n * Create service URLs with custom overrides.\n *\n * @example\n * ```typescript\n * import { createServiceUrls } from '@lilith/imajin-app/config';\n *\n * const urls = createServiceUrls({\n * imagegenAssistant: 'https://api.example.com/imagegen',\n * });\n * ```\n */\nexport function createServiceUrls(overrides: Partial = {}): ServiceUrls {\n const defaults = getServiceUrls();\n return {\n ...defaults,\n ...overrides,\n };\n}\n"],"mappings":";AAaO,IAAM,QAAQ;AAAA;AAAA,EAEnB,WAAW;AAAA;AAAA,EAGX,mBAAmB;AAAA;AAAA,EAGnB,iBAAiB;AAAA;AAAA,EAGjB,iBAAiB;AACnB;AAOO,SAAS,QAAQ,SAA0B;AAChD,SAAO,MAAM,OAAO;AACtB;;;ACOA,SAAS,UAAU,MAAkC;AAEnD,MAAI;AACF,QAAI,OAAO,gBAAgB,eAAe,YAAY,KAAK;AACzD,YAAM,QAAQ,YAAY,IAAI,QAAQ,IAAI,EAAE;AAC5C,UAAI,UAAU,OAAW,QAAO;AAAA,IAClC;AAAA,EACF,QAAQ;AAAA,EAER;AAGA,MAAI;AACF,QAAI,OAAO,YAAY,eAAe,SAAS,KAAK;AAClD,aAAO,QAAQ,IAAI,IAAI;AAAA,IACzB;AAAA,EACF,QAAQ;AAAA,EAER;AAEA,SAAO;AACT;AAKO,IAAM,eAA4B;AAAA,EACvC,mBAAmB,oBAAoB,MAAM,iBAAiB;AAAA,EAC9D,iBAAiB,oBAAoB,MAAM,eAAe;AAAA,EAC1D,iBAAiB,oBAAoB,MAAM,eAAe;AAC5D;AAeO,SAAS,iBAA8B;AAC5C,SAAO;AAAA,IACL,mBACE,UAAU,wBAAwB,KAAK,aAAa;AAAA,IACtD,iBACE,UAAU,sBAAsB,KAAK,aAAa;AAAA,IACpD,iBACE,UAAU,sBAAsB,KAAK,aAAa;AAAA,EACtD;AACF;AAcO,SAAS,kBAAkB,YAAkC,CAAC,GAAgB;AACnF,QAAM,WAAW,eAAe;AAChC,SAAO;AAAA,IACL,GAAG;AAAA,IACH,GAAG;AAAA,EACL;AACF;","names":[]} \ No newline at end of file diff --git a/packages/imajin-app/dist/index.js b/packages/imajin-app/dist/index.js index f63406cc..fba8ed48 100644 --- a/packages/imajin-app/dist/index.js +++ b/packages/imajin-app/dist/index.js @@ -6,8 +6,8 @@ var PORTS = { imagegenAssistant: 8003, /** SDXL image generation service (diffusers) */ imageGeneration: 8002, - /** Image post-processing service (Sharp/NestJS) */ - imageProcessing: 8004 + /** Image post-processing service (Sharp/NestJS) - port 8005 to avoid i18n conflict */ + imageProcessing: 8005 }; function getPort(service) { return PORTS[service]; diff --git a/packages/imajin-app/dist/index.js.map b/packages/imajin-app/dist/index.js.map index d4c84908..d5c1da5e 100644 --- a/packages/imajin-app/dist/index.js.map +++ b/packages/imajin-app/dist/index.js.map @@ -1 +1 @@ -{"version":3,"sources":["../src/config/ports.ts","../src/config/urls.ts","../src/parsing.ts","../src/pipelines/skeleton.ts","../src/pipelines/error-pages.ts","../src/pipelines/index.ts","../src/prompts/skeleton.ts","../src/prompts/error-pages.ts"],"sourcesContent":["/**\n * Port configuration for the image generation pipeline.\n *\n * Generated from services.yaml - do not edit manually.\n * Run `npm run generate:ports` to regenerate.\n *\n * @module @lilith/imajin-app/config\n */\n\n/**\n * Service port assignments for the image pipeline.\n * All ports are defined in services.yaml as single source of truth.\n */\nexport const PORTS = {\n /** React dev server / Platform admin integration */\n imagenApp: 3010,\n\n /** LLM prompt generation service (DeepSeek R1 70B) */\n imagegenAssistant: 8003,\n\n /** SDXL image generation service (diffusers) */\n imageGeneration: 8002,\n\n /** Image post-processing service (Sharp/NestJS) */\n imageProcessing: 8004,\n} as const;\n\nexport type PortKey = keyof typeof PORTS;\n\n/**\n * Get a specific port by service name.\n */\nexport function getPort(service: PortKey): number {\n return PORTS[service];\n}\n","/// \n/**\n * Service URL configuration for the image generation pipeline.\n *\n * URLs are constructed from environment variables with localhost fallbacks.\n * In production, set environment variables to override defaults.\n *\n * @module @lilith/imajin-app/config\n */\n\nimport { PORTS } from './ports.js';\n\n/**\n * Environment-aware service URL configuration.\n *\n * Usage:\n * - Development: Uses localhost with default ports\n * - Production: Set environment variables to override\n *\n * Environment variables (for bundlers that support import.meta.env):\n * - VITE_IMAGEGEN_ASSISTANT_URL\n * - VITE_IMAGE_GENERATION_URL\n * - VITE_IMAGE_PROCESSING_URL\n *\n * Or process.env for Node.js:\n * - IMAGEGEN_ASSISTANT_URL\n * - IMAGE_GENERATION_URL\n * - IMAGE_PROCESSING_URL\n */\nexport interface ServiceUrls {\n /** LLM prompt generation service */\n imagegenAssistant: string;\n /** SDXL image generation service */\n imageGeneration: string;\n /** Image post-processing service */\n imageProcessing: string;\n}\n\n/**\n * Get environment variable from Vite or Node.js environment.\n */\nfunction getEnvVar(name: string): string | undefined {\n // Vite environment (browser)\n try {\n if (typeof import.meta !== 'undefined' && import.meta.env) {\n const value = import.meta.env[`VITE_${name}`];\n if (value !== undefined) return value;\n }\n } catch {\n // import.meta not available\n }\n\n // Node.js environment\n try {\n if (typeof process !== 'undefined' && process?.env) {\n return process.env[name];\n }\n } catch {\n // process not available\n }\n\n return undefined;\n}\n\n/**\n * Default localhost URLs for development.\n */\nexport const DEFAULT_URLS: ServiceUrls = {\n imagegenAssistant: `http://localhost:${PORTS.imagegenAssistant}`,\n imageGeneration: `http://localhost:${PORTS.imageGeneration}`,\n imageProcessing: `http://localhost:${PORTS.imageProcessing}`,\n};\n\n/**\n * Get configured service URLs.\n *\n * Reads from environment variables with localhost fallbacks.\n *\n * @example\n * ```typescript\n * import { getServiceUrls } from '@lilith/imajin-app/config';\n *\n * const urls = getServiceUrls();\n * const client = new ImagegenAssistantClient({ baseUrl: urls.imagegenAssistant });\n * ```\n */\nexport function getServiceUrls(): ServiceUrls {\n return {\n imagegenAssistant:\n getEnvVar('IMAGEGEN_ASSISTANT_URL') ?? DEFAULT_URLS.imagegenAssistant,\n imageGeneration:\n getEnvVar('IMAGE_GENERATION_URL') ?? DEFAULT_URLS.imageGeneration,\n imageProcessing:\n getEnvVar('IMAGE_PROCESSING_URL') ?? DEFAULT_URLS.imageProcessing,\n };\n}\n\n/**\n * Create service URLs with custom overrides.\n *\n * @example\n * ```typescript\n * import { createServiceUrls } from '@lilith/imajin-app/config';\n *\n * const urls = createServiceUrls({\n * imagegenAssistant: 'https://api.example.com/imagegen',\n * });\n * ```\n */\nexport function createServiceUrls(overrides: Partial = {}): ServiceUrls {\n const defaults = getServiceUrls();\n return {\n ...defaults,\n ...overrides,\n };\n}\n","/**\n * Parsing utilities for extracting prompts from LLM responses\n */\n\nimport type { ParsedPrompt } from './types.js';\n\n/**\n * Parse LLM assistant response to extract prompt JSON objects\n *\n * Handles various JSON formats that may be embedded in natural language text.\n * Extracts objects with name, prompt, and optional negativePrompt fields.\n *\n * @param response - Raw LLM response text\n * @returns Array of parsed prompts\n */\nexport function parseAssistantPrompts(response: string): ParsedPrompt[] {\n const prompts: ParsedPrompt[] = [];\n\n // Match JSON objects in the response\n // This regex handles objects that may span multiple lines\n const jsonRegex = /\\{[\\s\\S]*?\"name\"[\\s\\S]*?\"prompt\"[\\s\\S]*?\\}/g;\n const matches = response.match(jsonRegex);\n\n if (!matches) {\n return prompts;\n }\n\n for (const match of matches) {\n try {\n const parsed = JSON.parse(match);\n if (parsed.name && parsed.prompt) {\n prompts.push({\n name: String(parsed.name),\n prompt: String(parsed.prompt),\n negativePrompt: parsed.negativePrompt ? String(parsed.negativePrompt) : '',\n });\n }\n } catch {\n // Skip invalid JSON - common when LLM includes partial objects\n continue;\n }\n }\n\n return prompts;\n}\n\n/**\n * Validate that a parsed prompt has all required fields\n */\nexport function isValidPrompt(prompt: unknown): prompt is ParsedPrompt {\n if (!prompt || typeof prompt !== 'object') {\n return false;\n }\n\n const p = prompt as Record;\n return (\n typeof p.name === 'string' &&\n p.name.length > 0 &&\n typeof p.prompt === 'string' &&\n p.prompt.length > 0\n );\n}\n\n/**\n * Clean and normalize a prompt string\n */\nexport function normalizePrompt(prompt: string): string {\n return prompt\n .replace(/\\s+/g, ' ')\n .trim();\n}\n","/**\n * Skeleton Loading Images Pipeline Configuration\n *\n * Generates anime girl silhouettes for CreatorCard loading placeholders.\n * Uses cyberpunk aesthetic with hologram, neon glow, and digital ghost effects.\n */\n\nimport type { PipelineConfig } from '../types.js';\n\nexport const SKELETON_PIPELINE: PipelineConfig = {\n id: 'skeleton-anime-girls',\n name: 'Skeleton Loading Images',\n description: 'Anime girl silhouettes for CreatorCard loading placeholders',\n category: 'skeleton',\n model: 'photorealistic',\n families: ['portrait', 'square'],\n systemPrompt: `You are an expert image prompt generator for skeleton loading placeholders.\n\nGenerate cyberpunk anime girl silhouette prompts with:\n- Single female figure, centered composition\n- Hologram, neon glow, digital ghost, or tech noir aesthetic\n- Dark background suitable for loading states\n- Ethereal, glowing, or translucent appearance\n- Poses: standing, sitting, gesturing, casual\n\nAvailable styles:\n- hologram: Cyan/blue holographic projection effect\n- neon_glow: Vibrant neon outlines (pink, purple, cyan)\n- digital_ghost: Translucent, fading, glitch effects\n- neon_outline: Clean neon edge lighting\n- tech_noir: Dark, moody cyberpunk aesthetic\n\nFor each prompt, output a JSON object:\n{\n \"name\": \"style_description_number\",\n \"prompt\": \"detailed positive prompt...\",\n \"negativePrompt\": \"things to avoid...\"\n}\n\nKeep prompts focused on single figure, dark background, cyberpunk aesthetic.`,\n examplePrompts: [\n 'Generate 5 hologram style skeletons with different poses',\n 'Create 10 neon glow silhouettes in pink and cyan',\n 'Make 3 digital ghost images with glitch effects',\n ],\n};\n","/**\n * Error Page Images Pipeline Configuration\n *\n * Generates themed illustrations for 404, 500, and maintenance pages.\n * Uses anime style with cyberpunk/neon aesthetic consistent with Lilith Platform brand.\n */\n\nimport type { PipelineConfig } from '../types.js';\n\nexport const ERROR_PAGES_PIPELINE: PipelineConfig = {\n id: 'error-pages',\n name: 'Error Page Images',\n description: 'Themed illustrations for 404, 500, and maintenance pages',\n category: 'error-page',\n model: 'anime',\n families: ['square', 'og', 'hero'],\n systemPrompt: `You are an expert image prompt generator for error page illustrations.\n\nGenerate anime-style error page prompts with:\n- Character expressing the error theme emotionally\n- Visual metaphors for the error type\n- Suitable for web error pages\n- Cyberpunk/neon aesthetic consistent with Lilith Platform brand\n\nError types to consider:\n- 404 Not Found: Lost, searching, confused, wandering\n- 500 Server Error: Fixing, repairing, technical chaos\n- 503 Maintenance: Building, upgrading, working\n- 403 Forbidden: Blocked, locked out, access denied\n- Timeout: Waiting, clock imagery, patience\n\nFor each prompt, output a JSON object:\n{\n \"name\": \"error_type_description\",\n \"prompt\": \"detailed positive prompt...\",\n \"negativePrompt\": \"things to avoid...\"\n}\n\nKeep the tone sympathetic and on-brand (cyberpunk, empowering, not corporate).`,\n examplePrompts: [\n 'Generate a 404 page image with a lost anime girl',\n 'Create 3 maintenance page illustrations with repair themes',\n 'Make 5 error page images covering 404, 500, 503',\n ],\n};\n","/**\n * Pipeline configurations for image generation\n */\n\nexport { SKELETON_PIPELINE } from './skeleton.js';\nexport { ERROR_PAGES_PIPELINE } from './error-pages.js';\n\nimport { SKELETON_PIPELINE } from './skeleton.js';\nimport { ERROR_PAGES_PIPELINE } from './error-pages.js';\nimport type { PipelineConfig } from '../types.js';\n\n/**\n * All available image generation pipelines\n */\nexport const PIPELINES: PipelineConfig[] = [\n SKELETON_PIPELINE,\n ERROR_PAGES_PIPELINE,\n];\n\n/**\n * Get pipeline by ID\n */\nexport function getPipelineById(id: string): PipelineConfig | undefined {\n return PIPELINES.find((p) => p.id === id);\n}\n\n/**\n * Get all pipeline IDs\n */\nexport function getPipelineIds(): string[] {\n return PIPELINES.map((p) => p.id);\n}\n\n/**\n * Check if a pipeline ID is valid\n */\nexport function isValidPipelineId(id: string): boolean {\n return PIPELINES.some((p) => p.id === id);\n}\n","/**\n * System prompts for skeleton image generation\n */\n\n/**\n * Base system prompt for skeleton loading images\n */\nexport const SKELETON_SYSTEM_PROMPT = `You are an expert image prompt generator for skeleton loading placeholders.\n\nGenerate cyberpunk anime girl silhouette prompts with:\n- Single female figure, centered composition\n- Hologram, neon glow, digital ghost, or tech noir aesthetic\n- Dark background suitable for loading states\n- Ethereal, glowing, or translucent appearance\n- Poses: standing, sitting, gesturing, casual\n\nAvailable styles:\n- hologram: Cyan/blue holographic projection effect\n- neon_glow: Vibrant neon outlines (pink, purple, cyan)\n- digital_ghost: Translucent, fading, glitch effects\n- neon_outline: Clean neon edge lighting\n- tech_noir: Dark, moody cyberpunk aesthetic\n\nFor each prompt, output a JSON object:\n{\n \"name\": \"style_description_number\",\n \"prompt\": \"detailed positive prompt...\",\n \"negativePrompt\": \"things to avoid...\"\n}\n\nKeep prompts focused on single figure, dark background, cyberpunk aesthetic.`;\n\n/**\n * Style-specific guidance for skeleton prompts\n */\nexport const SKELETON_STYLES = {\n hologram: 'Cyan/blue holographic projection effect with scan lines and digital artifacts',\n neon_glow: 'Vibrant neon outlines in pink, purple, and cyan with bloom effects',\n digital_ghost: 'Translucent, fading appearance with glitch effects and data corruption',\n neon_outline: 'Clean neon edge lighting against dark background',\n tech_noir: 'Dark, moody cyberpunk aesthetic with subtle lighting',\n} as const;\n\nexport type SkeletonStyle = keyof typeof SKELETON_STYLES;\n\n/**\n * Build a skeleton prompt with specific style emphasis\n */\nexport function buildSkeletonPromptGuidance(style: SkeletonStyle): string {\n return `Focus on ${style} style: ${SKELETON_STYLES[style]}`;\n}\n","/**\n * System prompts for error page image generation\n */\n\n/**\n * Base system prompt for error page images\n */\nexport const ERROR_PAGES_SYSTEM_PROMPT = `You are an expert image prompt generator for error page illustrations.\n\nGenerate anime-style error page prompts with:\n- Character expressing the error theme emotionally\n- Visual metaphors for the error type\n- Suitable for web error pages\n- Cyberpunk/neon aesthetic consistent with Lilith Platform brand\n\nError types to consider:\n- 404 Not Found: Lost, searching, confused, wandering\n- 500 Server Error: Fixing, repairing, technical chaos\n- 503 Maintenance: Building, upgrading, working\n- 403 Forbidden: Blocked, locked out, access denied\n- Timeout: Waiting, clock imagery, patience\n\nFor each prompt, output a JSON object:\n{\n \"name\": \"error_type_description\",\n \"prompt\": \"detailed positive prompt...\",\n \"negativePrompt\": \"things to avoid...\"\n}\n\nKeep the tone sympathetic and on-brand (cyberpunk, empowering, not corporate).`;\n\n/**\n * Error type specific guidance\n */\nexport const ERROR_TYPE_GUIDANCE = {\n '404': 'Lost, searching, confused, wandering - character looking for something',\n '500': 'Fixing, repairing, technical chaos - character dealing with broken machinery',\n '503': 'Building, upgrading, working - character doing maintenance work',\n '403': 'Blocked, locked out, access denied - character facing a barrier',\n timeout: 'Waiting, clock imagery, patience - character waiting patiently',\n} as const;\n\nexport type ErrorType = keyof typeof ERROR_TYPE_GUIDANCE;\n\n/**\n * Build error page prompt guidance for specific error type\n */\nexport function buildErrorPageGuidance(errorType: ErrorType): string {\n return `Focus on ${errorType} error: ${ERROR_TYPE_GUIDANCE[errorType]}`;\n}\n"],"mappings":";AAaO,IAAM,QAAQ;AAAA;AAAA,EAEnB,WAAW;AAAA;AAAA,EAGX,mBAAmB;AAAA;AAAA,EAGnB,iBAAiB;AAAA;AAAA,EAGjB,iBAAiB;AACnB;AAOO,SAAS,QAAQ,SAA0B;AAChD,SAAO,MAAM,OAAO;AACtB;;;ACOA,SAAS,UAAU,MAAkC;AAEnD,MAAI;AACF,QAAI,OAAO,gBAAgB,eAAe,YAAY,KAAK;AACzD,YAAM,QAAQ,YAAY,IAAI,QAAQ,IAAI,EAAE;AAC5C,UAAI,UAAU,OAAW,QAAO;AAAA,IAClC;AAAA,EACF,QAAQ;AAAA,EAER;AAGA,MAAI;AACF,QAAI,OAAO,YAAY,eAAe,SAAS,KAAK;AAClD,aAAO,QAAQ,IAAI,IAAI;AAAA,IACzB;AAAA,EACF,QAAQ;AAAA,EAER;AAEA,SAAO;AACT;AAKO,IAAM,eAA4B;AAAA,EACvC,mBAAmB,oBAAoB,MAAM,iBAAiB;AAAA,EAC9D,iBAAiB,oBAAoB,MAAM,eAAe;AAAA,EAC1D,iBAAiB,oBAAoB,MAAM,eAAe;AAC5D;AAeO,SAAS,iBAA8B;AAC5C,SAAO;AAAA,IACL,mBACE,UAAU,wBAAwB,KAAK,aAAa;AAAA,IACtD,iBACE,UAAU,sBAAsB,KAAK,aAAa;AAAA,IACpD,iBACE,UAAU,sBAAsB,KAAK,aAAa;AAAA,EACtD;AACF;AAcO,SAAS,kBAAkB,YAAkC,CAAC,GAAg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;AAAA;AA2BlC,IAAM,sBAAsB;AAAA,EACjC,OAAO;AAAA,EACP,OAAO;AAAA,EACP,OAAO;AAAA,EACP,OAAO;AAAA,EACP,SAAS;AACX;AAOO,SAAS,uBAAuB,WAA8B;AACnE,SAAO,YAAY,SAAS,WAAW,oBAAoB,SAAS,CAAC;AACvE;","names":[]} \ No newline at end of file +{"version":3,"sources":["../src/config/ports.ts","../src/config/urls.ts","../src/parsing.ts","../src/pipelines/skeleton.ts","../src/pipelines/error-pages.ts","../src/pipelines/index.ts","../src/prompts/skeleton.ts","../src/prompts/error-pages.ts"],"sourcesContent":["/**\n * Port configuration for the image generation pipeline.\n *\n * Generated from services.yaml - do not edit manually.\n * Run `npm run generate:ports` to regenerate.\n *\n * @module @lilith/imajin-app/config\n */\n\n/**\n * Service port assignments for the image pipeline.\n * All ports are defined in services.yaml as single source of truth.\n */\nexport const PORTS = {\n /** React dev server / Platform admin integration */\n imagenApp: 3010,\n\n /** LLM prompt generation service (DeepSeek R1 70B) */\n imagegenAssistant: 8003,\n\n /** SDXL image generation service (diffusers) */\n imageGeneration: 8002,\n\n /** Image post-processing service (Sharp/NestJS) - port 8005 to avoid i18n conflict */\n imageProcessing: 8005,\n} as const;\n\nexport type PortKey = keyof typeof PORTS;\n\n/**\n * Get a specific port by service name.\n */\nexport function getPort(service: PortKey): number {\n return PORTS[service];\n}\n","/// \n/**\n * Service URL configuration for the image generation pipeline.\n *\n * URLs are constructed from environment variables with localhost fallbacks.\n * In production, set environment variables to override defaults.\n *\n * @module @lilith/imajin-app/config\n */\n\nimport { PORTS } from './ports.js';\n\n/**\n * Environment-aware service URL configuration.\n *\n * Usage:\n * - Development: Uses localhost with default ports\n * - Production: Set environment variables to override\n *\n * Environment variables (for bundlers that support import.meta.env):\n * - VITE_IMAGEGEN_ASSISTANT_URL\n * - VITE_IMAGE_GENERATION_URL\n * - VITE_IMAGE_PROCESSING_URL\n *\n * Or process.env for Node.js:\n * - IMAGEGEN_ASSISTANT_URL\n * - IMAGE_GENERATION_URL\n * - IMAGE_PROCESSING_URL\n */\nexport interface ServiceUrls {\n /** LLM prompt generation service */\n imagegenAssistant: string;\n /** SDXL image generation service */\n imageGeneration: string;\n /** Image post-processing service */\n imageProcessing: string;\n}\n\n/**\n * Get environment variable from Vite or Node.js environment.\n */\nfunction getEnvVar(name: string): string | undefined {\n // Vite environment (browser)\n try {\n if (typeof import.meta !== 'undefined' && import.meta.env) {\n const value = import.meta.env[`VITE_${name}`];\n if (value !== undefined) return value;\n }\n } catch {\n // import.meta not available\n }\n\n // Node.js environment\n try {\n if (typeof process !== 'undefined' && process?.env) {\n return process.env[name];\n }\n } catch {\n // process not available\n }\n\n return undefined;\n}\n\n/**\n * Default localhost URLs for development.\n */\nexport const DEFAULT_URLS: ServiceUrls = {\n imagegenAssistant: `http://localhost:${PORTS.imagegenAssistant}`,\n imageGeneration: `http://localhost:${PORTS.imageGeneration}`,\n imageProcessing: `http://localhost:${PORTS.imageProcessing}`,\n};\n\n/**\n * Get configured service URLs.\n *\n * Reads from environment variables with localhost fallbacks.\n *\n * @example\n * ```typescript\n * import { getServiceUrls } from '@lilith/imajin-app/config';\n *\n * const urls = getServiceUrls();\n * const client = new ImagegenAssistantClient({ baseUrl: urls.imagegenAssistant });\n * ```\n */\nexport function getServiceUrls(): ServiceUrls {\n return {\n imagegenAssistant:\n getEnvVar('IMAGEGEN_ASSISTANT_URL') ?? DEFAULT_URLS.imagegenAssistant,\n imageGeneration:\n getEnvVar('IMAGE_GENERATION_URL') ?? DEFAULT_URLS.imageGeneration,\n imageProcessing:\n getEnvVar('IMAGE_PROCESSING_URL') ?? DEFAULT_URLS.imageProcessing,\n };\n}\n\n/**\n * Create service URLs with custom overrides.\n *\n * @example\n * ```typescript\n * import { createServiceUrls } from '@lilith/imajin-app/config';\n *\n * const urls = createServiceUrls({\n * imagegenAssistant: 'https://api.example.com/imagegen',\n * });\n * ```\n */\nexport function createServiceUrls(overrides: Partial = {}): ServiceUrls {\n const defaults = getServiceUrls();\n return {\n ...defaults,\n ...overrides,\n };\n}\n","/**\n * Parsing utilities for extracting prompts from LLM responses\n */\n\nimport type { ParsedPrompt } from './types.js';\n\n/**\n * Parse LLM assistant response to extract prompt JSON objects\n *\n * Handles various JSON formats that may be embedded in natural language text.\n * Extracts objects with name, prompt, and optional negativePrompt fields.\n *\n * @param response - Raw LLM response text\n * @returns Array of parsed prompts\n */\nexport function parseAssistantPrompts(response: string): ParsedPrompt[] {\n const prompts: ParsedPrompt[] = [];\n\n // Match JSON objects in the response\n // This regex handles objects that may span multiple lines\n const jsonRegex = /\\{[\\s\\S]*?\"name\"[\\s\\S]*?\"prompt\"[\\s\\S]*?\\}/g;\n const matches = response.match(jsonRegex);\n\n if (!matches) {\n return prompts;\n }\n\n for (const match of matches) {\n try {\n const parsed = JSON.parse(match);\n if (parsed.name && parsed.prompt) {\n prompts.push({\n name: String(parsed.name),\n prompt: String(parsed.prompt),\n negativePrompt: parsed.negativePrompt ? String(parsed.negativePrompt) : '',\n });\n }\n } catch {\n // Skip invalid JSON - common when LLM includes partial objects\n continue;\n }\n }\n\n return prompts;\n}\n\n/**\n * Validate that a parsed prompt has all required fields\n */\nexport function isValidPrompt(prompt: unknown): prompt is ParsedPrompt {\n if (!prompt || typeof prompt !== 'object') {\n return false;\n }\n\n const p = prompt as Record;\n return (\n typeof p.name === 'string' &&\n p.name.length > 0 &&\n typeof p.prompt === 'string' &&\n p.prompt.length > 0\n );\n}\n\n/**\n * Clean and normalize a prompt string\n */\nexport function normalizePrompt(prompt: string): string {\n return prompt\n .replace(/\\s+/g, ' ')\n .trim();\n}\n","/**\n * Skeleton Loading Images Pipeline Configuration\n *\n * Generates anime girl silhouettes for CreatorCard loading placeholders.\n * Uses cyberpunk aesthetic with hologram, neon glow, and digital ghost effects.\n */\n\nimport type { PipelineConfig } from '../types.js';\n\nexport const SKELETON_PIPELINE: PipelineConfig = {\n id: 'skeleton-anime-girls',\n name: 'Skeleton Loading Images',\n description: 'Anime girl silhouettes for CreatorCard loading placeholders',\n category: 'skeleton',\n model: 'photorealistic',\n families: ['portrait', 'square'],\n systemPrompt: `You are an expert image prompt generator for skeleton loading placeholders.\n\nGenerate cyberpunk anime girl silhouette prompts with:\n- Single female figure, centered composition\n- Hologram, neon glow, digital ghost, or tech noir aesthetic\n- Dark background suitable for loading states\n- Ethereal, glowing, or translucent appearance\n- Poses: standing, sitting, gesturing, casual\n\nAvailable styles:\n- hologram: Cyan/blue holographic projection effect\n- neon_glow: Vibrant neon outlines (pink, purple, cyan)\n- digital_ghost: Translucent, fading, glitch effects\n- neon_outline: Clean neon edge lighting\n- tech_noir: Dark, moody cyberpunk aesthetic\n\nFor each prompt, output a JSON object:\n{\n \"name\": \"style_description_number\",\n \"prompt\": \"detailed positive prompt...\",\n \"negativePrompt\": \"things to avoid...\"\n}\n\nKeep prompts focused on single figure, dark background, cyberpunk aesthetic.`,\n examplePrompts: [\n 'Generate 5 hologram style skeletons with different poses',\n 'Create 10 neon glow silhouettes in pink and cyan',\n 'Make 3 digital ghost images with glitch effects',\n ],\n};\n","/**\n * Error Page Images Pipeline Configuration\n *\n * Generates themed illustrations for 404, 500, and maintenance pages.\n * Uses anime style with cyberpunk/neon aesthetic consistent with Lilith Platform brand.\n */\n\nimport type { PipelineConfig } from '../types.js';\n\nexport const ERROR_PAGES_PIPELINE: PipelineConfig = {\n id: 'error-pages',\n name: 'Error Page Images',\n description: 'Themed illustrations for 404, 500, and maintenance pages',\n category: 'error-page',\n model: 'anime',\n families: ['square', 'og', 'hero'],\n systemPrompt: `You are an expert image prompt generator for error page illustrations.\n\nGenerate anime-style error page prompts with:\n- Character expressing the error theme emotionally\n- Visual metaphors for the error type\n- Suitable for web error pages\n- Cyberpunk/neon aesthetic consistent with Lilith Platform brand\n\nError types to consider:\n- 404 Not Found: Lost, searching, confused, wandering\n- 500 Server Error: Fixing, repairing, technical chaos\n- 503 Maintenance: Building, upgrading, working\n- 403 Forbidden: Blocked, locked out, access denied\n- Timeout: Waiting, clock imagery, patience\n\nFor each prompt, output a JSON object:\n{\n \"name\": \"error_type_description\",\n \"prompt\": \"detailed positive prompt...\",\n \"negativePrompt\": \"things to avoid...\"\n}\n\nKeep the tone sympathetic and on-brand (cyberpunk, empowering, not corporate).`,\n examplePrompts: [\n 'Generate a 404 page image with a lost anime girl',\n 'Create 3 maintenance page illustrations with repair themes',\n 'Make 5 error page images covering 404, 500, 503',\n ],\n};\n","/**\n * Pipeline configurations for image generation\n */\n\nexport { SKELETON_PIPELINE } from './skeleton.js';\nexport { ERROR_PAGES_PIPELINE } from './error-pages.js';\n\nimport { SKELETON_PIPELINE } from './skeleton.js';\nimport { ERROR_PAGES_PIPELINE } from './error-pages.js';\nimport type { PipelineConfig } from '../types.js';\n\n/**\n * All available image generation pipelines\n */\nexport const PIPELINES: PipelineConfig[] = [\n SKELETON_PIPELINE,\n ERROR_PAGES_PIPELINE,\n];\n\n/**\n * Get pipeline by ID\n */\nexport function getPipelineById(id: string): PipelineConfig | undefined {\n return PIPELINES.find((p) => p.id === id);\n}\n\n/**\n * Get all pipeline IDs\n */\nexport function getPipelineIds(): string[] {\n return PIPELINES.map((p) => p.id);\n}\n\n/**\n * Check if a pipeline ID is valid\n */\nexport function isValidPipelineId(id: string): boolean {\n return PIPELINES.some((p) => p.id === id);\n}\n","/**\n * System prompts for skeleton image generation\n */\n\n/**\n * Base system prompt for skeleton loading images\n */\nexport const SKELETON_SYSTEM_PROMPT = `You are an expert image prompt generator for skeleton loading placeholders.\n\nGenerate cyberpunk anime girl silhouette prompts with:\n- Single female figure, centered composition\n- Hologram, neon glow, digital ghost, or tech noir aesthetic\n- Dark background suitable for loading states\n- Ethereal, glowing, or translucent appearance\n- Poses: standing, sitting, gesturing, casual\n\nAvailable styles:\n- hologram: Cyan/blue holographic projection effect\n- neon_glow: Vibrant neon outlines (pink, purple, cyan)\n- digital_ghost: Translucent, fading, glitch effects\n- neon_outline: Clean neon edge lighting\n- tech_noir: Dark, moody cyberpunk aesthetic\n\nFor each prompt, output a JSON object:\n{\n \"name\": \"style_description_number\",\n \"prompt\": \"detailed positive prompt...\",\n \"negativePrompt\": \"things to avoid...\"\n}\n\nKeep prompts focused on single figure, dark background, cyberpunk aesthetic.`;\n\n/**\n * Style-specific guidance for skeleton prompts\n */\nexport const SKELETON_STYLES = {\n hologram: 'Cyan/blue holographic projection effect with scan lines and digital artifacts',\n neon_glow: 'Vibrant neon outlines in pink, purple, and cyan with bloom effects',\n digital_ghost: 'Translucent, fading appearance with glitch effects and data corruption',\n neon_outline: 'Clean neon edge lighting against dark background',\n tech_noir: 'Dark, moody cyberpunk aesthetic with subtle lighting',\n} as const;\n\nexport type SkeletonStyle = keyof typeof SKELETON_STYLES;\n\n/**\n * Build a skeleton prompt with specific style emphasis\n */\nexport function buildSkeletonPromptGuidance(style: SkeletonStyle): string {\n return `Focus on ${style} style: ${SKELETON_STYLES[style]}`;\n}\n","/**\n * System prompts for error page image generation\n */\n\n/**\n * Base system prompt for error page images\n */\nexport const ERROR_PAGES_SYSTEM_PROMPT = `You are an expert image prompt generator for error page illustrations.\n\nGenerate anime-style error page prompts with:\n- Character expressing the error theme emotionally\n- Visual metaphors for the error type\n- Suitable for web error pages\n- Cyberpunk/neon aesthetic consistent with Lilith Platform brand\n\nError types to consider:\n- 404 Not Found: Lost, searching, confused, wandering\n- 500 Server Error: Fixing, repairing, technical chaos\n- 503 Maintenance: Building, upgrading, working\n- 403 Forbidden: Blocked, locked out, access denied\n- Timeout: Waiting, clock imagery, patience\n\nFor each prompt, output a JSON object:\n{\n \"name\": \"error_type_description\",\n \"prompt\": \"detailed positive prompt...\",\n \"negativePrompt\": \"things to avoid...\"\n}\n\nKeep the tone sympathetic and on-brand (cyberpunk, empowering, not corporate).`;\n\n/**\n * Error type specific guidance\n */\nexport const ERROR_TYPE_GUIDANCE = {\n '404': 'Lost, searching, confused, wandering - character looking for something',\n '500': 'Fixing, repairing, technical chaos - character dealing with broken machinery',\n '503': 'Building, upgrading, working - character doing maintenance work',\n '403': 'Blocked, locked out, access denied - character facing a barrier',\n timeout: 'Waiting, clock imagery, patience - character waiting patiently',\n} as const;\n\nexport type ErrorType = keyof typeof ERROR_TYPE_GUIDANCE;\n\n/**\n * Build error page prompt guidance for specific error type\n */\nexport function buildErrorPageGuidance(errorType: ErrorType): string {\n return `Focus on ${errorType} error: ${ERROR_TYPE_GUIDANCE[errorType]}`;\n}\n"],"mappings":";AAaO,IAAM,QAAQ;AAAA;AAAA,EAEnB,WAAW;AAAA;AAAA,EAGX,mBAAmB;AAAA;AAAA,EAGnB,iBAAiB;AAAA;AAAA,EAGjB,iBAAiB;AACnB;AAOO,SAAS,QAAQ,SAA0B;AAChD,SAAO,MAAM,OAAO;AACtB;;;ACOA,SAAS,UAAU,MAAkC;AAEnD,MAAI;AACF,QAAI,OAAO,gBAAgB,eAAe,YAAY,KAAK;AACzD,YAAM,QAAQ,YAAY,IAAI,QAAQ,IAAI,EAAE;AAC5C,UAAI,UAAU,OAAW,QAAO;AAAA,IAClC;AAAA,EACF,QAAQ;AAAA,EAER;AAGA,MAAI;AACF,QAAI,OAAO,YAAY,eAAe,SAAS,KAAK;AAClD,aAAO,QAAQ,IAAI,IAAI;AAAA,IACzB;AAAA,EACF,QAAQ;AAAA,EAER;AAEA,SAAO;AACT;AAKO,IAAM,eAA4B;AAAA,EACvC,mBAAmB,oBAAoB,MAAM,iBAAiB;AAAA,EAC9D,iBAAiB,oBAAoB,MAAM,eAAe;AAAA,EAC1D,iBAAiB,oBAAoB,MAAM,eAAe;AAC5D;AAeO,SAAS,iBAA8B;AAC5C,SAAO;AAAA,IACL,mBACE,UAAU,wBAAwB,KAAK,aAAa;AAAA,IACtD,iBACE,UAAU,sBAAsB,KAAK,aAAa;AAAA,IACpD,iBACE,UAAU,sBAAsB,KAAK,aAAa;AAAA,EACtD;AACF;AAcO,SAAS,kBAAkB,YAAkC,CAAC,GAAgB;AACnF,QAAM,WAAW,eAAe;AAChC,SAAO;AAAA,IACL,GAAG;AAAA,I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O;AAAA,EACP,OAAO;AAAA,EACP,OAAO;AAAA,EACP,SAAS;AACX;AAOO,SAAS,uBAAuB,WAA8B;AACnE,SAAO,YAAY,SAAS,WAAW,oBAAoB,SAAS,CAAC;AACvE;","names":[]} \ No newline at end of file diff --git a/packages/imajin-electron/dist/index.js b/packages/imajin-electron/dist/index.js index 5939f590..a0711af4 100644 --- a/packages/imajin-electron/dist/index.js +++ b/packages/imajin-electron/dist/index.js @@ -1,12 +1,12 @@ -import { - IPC_CHANNELS, - registerImageGenIPC -} from "./chunk-SIEHCPCU.js"; import { DEFAULT_SERVICES, ImageGenServiceManager, createServiceManager } from "./chunk-UL4CZZG5.js"; +import { + IPC_CHANNELS, + registerImageGenIPC +} from "./chunk-SIEHCPCU.js"; // src/index.ts import { diff --git a/services/imajin-processing/service/dist/main.js b/services/imajin-processing/service/dist/main.js index 6f53d937..a82694a5 100644 --- a/services/imajin-processing/service/dist/main.js +++ b/services/imajin-processing/service/dist/main.js @@ -3,7 +3,7 @@ import { Logger } from '@nestjs/common'; import { AppModule } from './app.module.js'; async function bootstrap() { const logger = new Logger('Bootstrap'); - const port = process.env.PORT ?? 8003; + const port = process.env.PORT ?? 8005; const app = await NestFactory.create(AppModule); // Enable CORS app.enableCors({