{"record":{"id":"9d10a2e8cc7cfa6d","repo":"conductor-oss/conductor","slug":"not-supported-9d10a2","errorCode":null,"errorMessage":"Not supported","messagePattern":"Not supported","errorType":"exception","errorClass":"UnsupportedOperationException","httpStatus":null,"severity":"error","filePath":"ai/src/main/java/org/conductoross/conductor/ai/providers/litellm/LiteLLM.java","lineNumber":66,"sourceCode":"                        config.getApiKey(),\n                        config.getBaseURL(),\n                        \"/v1/chat/completions\");\n        this.chatModel = new OpenAICompatChatModel(api);\n    }\n\n    @Override\n    public String getModelProvider() {\n        return NAME;\n    }\n\n    @Override\n    public List<String> getProviderAliases() {\n        return List.of(\"LiteLLM\");\n    }\n\n    @Override\n    public List<Float> generateEmbeddings(EmbeddingGenRequest embeddingGenRequest) {\n        throw new UnsupportedOperationException(\"Not supported\");\n    }\n\n    @Override\n    public ChatOptions getChatOptions(ChatCompletion input) {\n        List<ToolCallback> toolCallbacks = getToolCallback(input);\n        Set<String> toolNames =\n                toolCallbacks.stream()\n                        .map(tc -> tc.getToolDefinition().name())\n                        .collect(Collectors.toSet());\n\n        return ToolCallingChatOptions.builder()\n                .model(input.getModel())\n                .temperature(input.getTemperature())\n                .topP(input.getTopP())\n                .maxTokens(input.getMaxTokens())\n                .stopSequences(input.getStopWords())\n                .frequencyPenalty(input.getFrequencyPenalty())\n                .presencePenalty(input.getPresencePenalty())","sourceCodeStart":48,"sourceCodeEnd":84,"githubUrl":"https://github.com/conductor-oss/conductor/blob/cf7c3e4a8adfb158be778ab1ec525323c363cd3a/ai/src/main/java/org/conductoross/conductor/ai/providers/litellm/LiteLLM.java#L48-L84","documentation":"LiteLLM.java throws UnsupportedOperationException from generateEmbeddings() with message \"Not supported\". LiteLLM is configured as an OpenAI-compatible chat proxy (ToolCallingChatOptions path) but does not wire an embeddings implementation. AIModel.generateEmbeddings() (line 97) is abstract, so LiteLLM must override it — it declines by throwing.","triggerScenarios":"An embedding-generation task (VectorDBWorkers or LLMWorkers.generateEmbeddings) is configured with llmProvider=\"litellm\" or alias \"LiteLLM\". The call reaches llm.generateEmbeddings() and throws immediately.","commonSituations":"Using LiteLLM as a unified proxy gateway for chat and assuming the same provider handles embeddings (LiteLLM does proxy embeddings upstream, but this Conductor provider does not implement that path); reusing a chat provider config for a vector-store indexing task.","solutions":["Route embedding tasks to openai, azureopenai, ollama, gemini, or cohere — providers that implement generateEmbeddings().","Subclass LiteLLM and implement generateEmbeddings() by calling LiteLLM's /v1/embeddings proxy endpoint.","Use LiteLLM only for chat-completion tasks in Conductor."],"exampleFix":"// before\n{\"llmProvider\": \"litellm\", \"model\": \"text-embedding-3-small\", \"text\": \"hello\"}\n// after\n{\"llmProvider\": \"openai\", \"model\": \"text-embedding-3-small\", \"text\": \"hello\"}","handlingStrategy":"validation","validationCode":"// Check provider supports embeddings\nprivate static final Set<String> EMBEDDING_CAPABLE = Set.of(\n    \"openai\", \"gemini\", \"azureopenai\", \"bedrock\", \"ollama\", \"cohere\", \"mistral\");\n\nif (!EMBEDDING_CAPABLE.contains(request.getLlmProvider())) {\n    throw new IllegalArgumentException(\n        \"LiteLLM does not support embeddings in Conductor. Use: \" + EMBEDDING_CAPABLE);\n}","typeGuard":"null","tryCatchPattern":"try {\n    List<Float> embeddings = llm.generateEmbeddings(request);\n} catch (UnsupportedOperationException e) {\n    throw new IllegalArgumentException(\"LiteLLM does not support embeddings\", e);\n}","preventionTips":["Use LiteLLM for chat-completion tasks only in Conductor.","Route embedding tasks to openai or ollama if using LiteLLM as a proxy.","If LiteLLM embeddings are needed, implement a subclass with generateEmbeddings()."],"tags":["litellm","embeddings","unsupported-operation","ai","provider"],"backgroundTag":null,"analyzedSha":"cf7c3e4a8adfb158be778ab1ec525323c363cd3a","analyzedAt":"2026-08-14T03:33:19.897Z","schemaVersion":2},"datasetVersion":"2026-08-14T05:17:29.042Z"}