mirror of
https://github.com/crewAIInc/crewAI.git
synced 2026-07-02 13:48:09 +00:00
InternalInstructor._create_instructor_client() was discarding base_url and api_key when calling instructor.from_provider(), causing requests to go to api.openai.com instead of the configured endpoint. Added _get_llm_extra_kwargs() to extract base_url and api_key from the LLM object and forward them as kwargs to instructor.from_provider(). This fixes OpenAI-compatible endpoints (vLLM, Ollama, etc.) when using output_pydantic or output_json on tasks. Co-Authored-By: João <joao@crewai.com>