Interface: TextToImageProps
Defined in: types/tti.ts:16
Configuration properties for the useTextToImage hook.
Properties
inferenceCallback()?
optionalinferenceCallback: (stepIdx) =>void
Defined in: types/tti.ts:43
Optional callback function that is triggered after each diffusion inference step. Useful for updating a progress bar during image generation.
Parameters
stepIdx
number
The index of the current inference step.
Returns
void
model
model:
object
Defined in: types/tti.ts:20
Object containing the required model sources for the diffusion pipeline.
decoderSource
decoderSource:
ResourceSource
Source for the VAE decoder model binary, used to decode the final image.
encoderSource
encoderSource:
ResourceSource
Source for the text encoder model binary.
modelName
modelName:
TextToImageModelName
The built-in model name (e.g. 'bk-sdm-tiny-vpred-512'). Used for telemetry and hook reload triggers.
Pass one of the pre-built TTI constants (e.g. BK_SDM_TINY_VPRED_512) to populate all required fields.
schedulerSource
schedulerSource:
ResourceSource
Source for the diffusion scheduler binary/config.
tokenizerSource
tokenizerSource:
ResourceSource
Source for the text tokenizer binary/config.
unetSource
unetSource:
ResourceSource
Source for the UNet (noise predictor) model binary.
preventLoad?
optionalpreventLoad:boolean
Defined in: types/tti.ts:49
Boolean that can prevent automatic model loading (and downloading the data if loaded for the first time) after running the hook.
Defaults to false.