diff --git a/src/views/ai/image/index/components/other/index.vue b/src/views/ai/image/index/components/other/index.vue new file mode 100644 index 00000000..7a01fe7e --- /dev/null +++ b/src/views/ai/image/index/components/other/index.vue @@ -0,0 +1,295 @@ + + + + diff --git a/src/views/ai/image/index/index.vue b/src/views/ai/image/index/index.vue index a2207be8..16732707 100644 --- a/src/views/ai/image/index/index.vue +++ b/src/views/ai/image/index/index.vue @@ -18,6 +18,12 @@ ref="stableDiffusionRef" @on-draw-complete="handleDrawComplete" /> + +
@@ -33,11 +39,13 @@ import { ImageVO } from '@/api/ai/image' import Dall3 from './components/dall3/index.vue' import Midjourney from './components/midjourney/index.vue' import StableDiffusion from './components/stableDiffusion/index.vue' +import Other from './components/other/index.vue' const imageListRef = ref() // image 列表 ref const dall3Ref = ref() // dall3(openai) ref const midjourneyRef = ref() // midjourney ref const stableDiffusionRef = ref() // stable diffusion ref +const otherRef = ref() // stable diffusion ref // 定义属性 const selectPlatform = ref(AiPlatformEnum.MIDJOURNEY) @@ -53,6 +61,10 @@ const platformOptions = [ { label: 'Stable Diffusion', value: AiPlatformEnum.STABLE_DIFFUSION + }, + { + label: '其他', + value: 'other' } ] diff --git a/src/views/ai/utils/constants.ts b/src/views/ai/utils/constants.ts index 3fadb8bb..cef92964 100644 --- a/src/views/ai/utils/constants.ts +++ b/src/views/ai/utils/constants.ts @@ -20,9 +20,23 @@ export const AiPlatformEnum = { Ollama: 'Ollama', STABLE_DIFFUSION: 'StableDiffusion', // Stability AI MIDJOURNEY: 'Midjourney', // Midjourney - SUNO: 'Suno' // Suno AI + SUNO: 'Suno', // Suno AI + TONG_YI_WAN_XIANG: 'TongYiWanXiang', //// 通义万相 + YI_YAN_IMAGE: 'YiYanImage' //// 百度 image } +export const OtherPlatformEnum:ImageModelVO [] = [ + { + key: AiPlatformEnum.TONG_YI_WAN_XIANG, + name: '通义万相' + }, + { + key: AiPlatformEnum.YI_YAN_IMAGE, + name: '百度图片' + } +] + + /** * AI 图像生成状态的枚举 */ @@ -189,6 +203,64 @@ export const StableDiffusionStylePresets: ImageModelVO[] = [ } ] +export const TongYiWanXiangStylePresets: ImageModelVO[] = [ + { + key: '-1', + name: '上传图像风格' + }, + { + key: '0', + name: '复古漫画' + }, + { + key: '1', + name: '3D童话' + }, + { + key: '2', + name: '二次元' + }, + { + key: '3', + name: '小清新' + }, + { + key: '4', + name: '未来科技' + }, + { + key: '5', + name: '国画古风' + }, + { + key: '6', + name: '将军百战' + }, + { + key: '7', + name: '炫彩卡通' + }, + { + key: '8', + name: '清雅国风' + }, + { + key: '9', + name: '喜迎新年' + } +] + +export const TongYiWanXiangModels: ImageModelVO[] = [ + { + key: 'wanx-v1', + name: 'wanx-v1' + }, + { + key: 'wanx-sketch-to-image-v1', + name: 'wanx-sketch-to-image-v1' + } +] + export const StableDiffusionClipGuidancePresets: ImageModelVO[] = [ { key: 'NONE',