In this article
The prior produces semantic image-conditioning embeddings; the decoder still performs its own image-generation process from those conditions.
Identify the versioned architecture
The official Kandinsky repository describes a family whose versions have different conditioning paths. This guide concerns Kandinsky 2.2. Its prior maps text toward an image-embedding representation used by a separate generation decoder. Do not transfer this interface automatically to another Kandinsky generation. A common family name does not establish whether a selected decoder consumes text directly, expects image embeddings, or uses a different text encoder and architecture.
Distinguish embeddings from spatial latents
The published prior artifact demonstrates positive and negative image embeddings passed onward to image generation. These embeddings condition semantic content; they are not the decoder’s final image and are not a spatial noisy latent ready for ordinary VAE decoding. A tensor’s floating-point dtype is insufficient to identify its role. Label the artifact with its producer, field name, shape, and intended consumer rather than storing every intermediate under an ambiguous latent filename.
Preserve both conditioning branches
The library’s Kandinsky guide explains the prior’s image_embeds and negative_image_embeds and the decoder interface. Changing a negative instruction requires changing the corresponding upstream conditioning, not merely attaching a new text field to a decoder call that does not accept it. Cache the paired conditions with the prior revision and actual prompt inputs. Reusing a positive result with an unrelated negative embedding silently creates a different guidance configuration.
Diagnose an ineffective prompt change
Imagine retaining a cached embedding while changing the visible prompt from a wooden object to a metallic one. If the decoder receives the unchanged condition, the interface’s new text may never affect the actual generation. Trace the prior invocation and cache key before adjusting decoder steps. The combined pipeline can hide these boundaries for convenience, but a custom split deployment must preserve them explicitly. Each stage’s result should identify the conditioning that actually produced it.
Measure the complete generation path
Record prior sampling configuration, embedding provenance, decoder revision, decoder sampling settings, and generated image. Time both stages when reporting end-to-end latency; a cached-prior result measures a different workload from a fresh request. Existing guides on contrastive image-text spaces and tensor-axis meaning provide background. Kandinsky 2.2’s distinctive handoff is a versioned semantic image-embedding bundle, which must remain separate from spatial generation latents and final pixels.
Earn rental income from GPUs
Have idle GPUs or looking to fund AI infrastructure? Retrivium finds a rental platform, sets up the server and helps you assess income and costs with a pilot.