conductor-oss/conductor · error · UnsupportedOperationException
Image generation not supported by the model yet
Error message
Image generation not supported by the model yet
What it means
Thrown by PerplexityAI.getImageModel as UnsupportedOperationException. Perplexity is a text/chat-only provider and has no image generation capability; getImageModel is intentionally unimplemented.
Source
Thrown at ai/src/main/java/org/conductoross/conductor/ai/providers/perplexity/PerplexityAI.java:80
.maxTokens(input.getMaxTokens())
.topP(input.getTopP())
.temperature(input.getTemperature())
.toolCallbacks(getToolCallback(input))
.internalToolExecutionEnabled(false)
.frequencyPenalty(input.getFrequencyPenalty())
.topK(input.getTopK())
.presencePenalty(input.getPresencePenalty())
.build();
}
@Override
public ChatModel getChatModel() {
return this.chatModel;
}
@Override
public ImageModel getImageModel() {
throw new UnsupportedOperationException("Image generation not supported by the model yet");
}
}
View on GitHub (pinned to cf7c3e4a8a)
Solutions
- Route image generation to an image-capable provider (StabilityAI, OpenAI).
- Guard getImageModel() calls with a capability check (e.g. getModelProvider()) before invocation.
- Correct the llmProvider on the image task input.
Defensive patterns
Strategy: validation
Validate before calling
if ("perplexity".equals(model.getModelProvider())) {
throw new IllegalArgumentException(
"Perplexity does not support image generation");
}
ImageModel img = model.getImageModel(); Type guard
boolean supportsImages(AIModel m) {
return !"perplexity".equals(m.getModelProvider());
} Try / catch
try {
ImageModel img = model.getImageModel();
} catch (UnsupportedOperationException e) {
// provider lacks image generation; switch provider
} Prevention
- Check getModelProvider() before calling getImageModel().
- Route image tasks to StabilityAI or OpenAI.
- Maintain a capability registry per provider.
When it happens
Trigger: Calling getImageModel() on a PerplexityAI instance, or routing an image-generation task to the perplexity provider.
Common situations: An image task configured with llmProvider=perplexity, or generic code that calls getImageModel() on every AIModel without checking capabilities.
Related errors
- Not supported
- Image generation not supported by the model yet
- Image generation not supported by the model yet
- Image generation not supported by Cohere
- Image generation not supported by the model yet
AI-assisted analysis of conductor-oss/conductor@cf7c3e4a8a (2026-08-14).
Data as JSON: /api/errors/490054fb3f0b0911.
Report an issue: GitHub.