


























@@ -39,11 +39,11 @@ const DEFAULT_TIMEOUT_MS = 5 * 60_000;
39394040export const DEFAULT_COMFY_MODEL = "workflow";
414142-export type ComfyMode = "local" | "cloud";
43-export type ComfyCapability = "image" | "music" | "video";
44-export type ComfyOutputKind = "audio" | "gifs" | "images" | "videos";
45-export type ComfyWorkflow = Record<string, unknown>;
46-export type ComfyProviderConfig = Record<string, unknown>;
42+type ComfyMode = "local" | "cloud";
43+type ComfyCapability = "image" | "music" | "video";
44+type ComfyOutputKind = "audio" | "gifs" | "images" | "videos";
45+type ComfyWorkflow = Record<string, unknown>;
46+type ComfyProviderConfig = Record<string, unknown>;
4747type ComfyFetchGuardParams = Parameters<typeof fetchWithSsrFGuard>[0];
4848type ComfyDispatcherPolicy = ComfyFetchGuardParams["dispatcherPolicy"];
4949type ComfyPromptResponse = {
@@ -84,20 +84,20 @@ type ComfyApiKeyResolution =
8484status: "configured_unavailable";
8585};
868687-export type ComfySourceImage = {
87+type ComfySourceImage = {
8888buffer: Buffer;
8989mimeType: string;
9090fileName?: string;
9191};
929293-export type ComfyGeneratedAsset = {
93+type ComfyGeneratedAsset = {
9494buffer: Buffer;
9595mimeType: string;
9696fileName: string;
9797nodeId: string;
9898};
9999100-export type ComfyWorkflowResult = {
100+type ComfyWorkflowResult = {
101101assets: ComfyGeneratedAsset[];
102102model: string;
103103promptId: string;
@@ -137,7 +137,7 @@ function stripNestedCapabilityConfig(config: ComfyProviderConfig): ComfyProvider
137137return next;
138138}
139139140-export function getComfyCapabilityConfig(
140+function getComfyCapabilityConfig(
141141config: ComfyProviderConfig,
142142capability: ComfyCapability,
143143): ComfyProviderConfig {
@@ -149,7 +149,7 @@ export function getComfyCapabilityConfig(
149149return { ...shared, ...nested };
150150}
151151152-export function resolveComfyMode(config: ComfyProviderConfig): ComfyMode {
152+function resolveComfyMode(config: ComfyProviderConfig): ComfyMode {
153153return normalizeOptionalString(config.mode) === "cloud" ? "cloud" : "local";
154154}
155155此内容由惯性聚合(RSS阅读器)自动聚合整理,仅供阅读参考。 原文来自 — 版权归原作者所有。