Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

breaks when dealing with dates or no params tool #7711

Open
eddwinpaz opened this issue Jan 12, 2025 · 0 comments
Open

breaks when dealing with dates or no params tool #7711

eddwinpaz opened this issue Jan 12, 2025 · 0 comments

Comments

@eddwinpaz
Copy link

eddwinpaz commented Jan 12, 2025

Currently this code. breaks when executing using model.

model = LiteLLMModel(
    model_id="ollama/llama3-groq-tool-use",
    api_base="http://localhost:11434",
)
@tool
def uf_daily_value(date: str) -> str:
    """
    Get the daily uf value.
    Args:
        date: the date
    """
    return "The daily uf value is 38.500 CLP"

also fails at this

@tool
def uf_daily_value() -> str:
    """
    Get the daily uf value.
    Args:
    """
    return "The daily uf value is 38.500 CLP"

this is the error message

LiteLLM.Info: If you need to debug this error, use `litellm.set_verbose=True'.

Error in generating tool call with model:
litellm.APIConnectionError: 'name'
Traceback (most recent call last):
  File "/home/eddwinpaz/Documents/work/langchain-llm-app/venv/lib/python3.10/site-packages/litellm/main.py", line 2680, in completion
    response = base_llm_http_handler.completion(
  File "/home/eddwinpaz/Documents/work/langchain-llm-app/venv/lib/python3.10/site-packages/litellm/llms/custom_httpx/llm_http_handler.py", line 334, in completion
    return provider_config.transform_response(
  File "/home/eddwinpaz/Documents/work/langchain-llm-app/venv/lib/python3.10/site-packages/litellm/llms/ollama/completion/transformation.py", line 263, in transform_response
    "name": function_call["name"],
KeyError: 'name'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant