ValueError: Expected at least one tool call, but got 0 tool calls.
from every query. What am I supposed to be doing? The changelog doesn't mention a migration path to fix your code.from typing import List from pydantic.v1 import BaseModel class Biography(BaseModel): """Data model for a biography.""" name: str best_known_for: List[str] extra_info: str from llama_index.core import VectorStoreIndex from llama_index.llms.ollama import Ollama llm = Ollama(model="mistral:latest", is_function_calling_model=False, json_mode=True) index = VectorStoreIndex.from_documents( documents, ) query_engine = index.as_query_engine( output_cls=Biography, response_mode="compact", llm=llm ) response = query_engine.query("Who is Paul Graham?")
json_mode=True
, I was getting parsing errors (becasue mistral wasn't writing json)is_function_calling_model
at all?is_function_calling_model
because I get [reportCallIssue]: No parameter named "is_function_calling_model"
ValueError: Expected at least one tool call, but got 0 tool calls. /usr/local/lib/python3.11/site-packages/weaviate/warnings.py:303: ResourceWarning: Con004: The connection to Weaviate was not closed properly. This can lead to memory leaks. Please make sure to close the connection using `client.close()`. Traceback (most recent call last): File "src/python/grpcio/grpc/_cython/_cygrpc/aio/grpc_aio.pyx.pxi", line 110, in grpc._cython.cygrpc.shutdown_grpc_aio File "src/python/grpcio/grpc/_cython/_cygrpc/aio/grpc_aio.pyx.pxi", line 114, in grpc._cython.cygrpc.shutdown_grpc_aio File "src/python/grpcio/grpc/_cython/_cygrpc/aio/grpc_aio.pyx.pxi", line 78, in grpc._cython.cygrpc._actual_aio_shutdown AttributeError: 'NoneType' object has no attribute 'POLLER' Exception ignored in: 'grpc._cython.cygrpc.AioChannel.__dealloc__' Traceback (most recent call last): File "src/python/grpcio/grpc/_cython/_cygrpc/aio/grpc_aio.pyx.pxi", line 110, in grpc._cython.cygrpc.shutdown_grpc_aio File "src/python/grpcio/grpc/_cython/_cygrpc/aio/grpc_aio.pyx.pxi", line 114, in grpc._cython.cygrpc.shutdown_grpc_aio File "src/python/grpcio/grpc/_cython/_cygrpc/aio/grpc_aio.pyx.pxi", line 78, in grpc._cython.cygrpc._actual_aio_shutdown AttributeError: 'NoneType' object has no attribute 'POLLER'