Skip to content

fixed cast error#300

Merged
nicoloboschi merged 1 commit intovectorize-io:mainfrom
haydenrear:fix-cast-ollama
Feb 5, 2026
Merged

fixed cast error#300
nicoloboschi merged 1 commit intovectorize-io:mainfrom
haydenrear:fix-cast-ollama

Conversation

@haydenrear
Copy link
Contributor

A casting error happened when running with ollama on reflect.

2026-02-04 16:13:01 2026-02-04 21:13:01,571 - ERROR - hindsight_api.mcp_tools - Error reflecting: '>' not supported between instances of 'int' and 'str'
2026-02-04 16:13:01 Traceback (most recent call last):
2026-02-04 16:13:01   File "/app/api/hindsight_api/mcp_tools.py", line 386, in reflect
2026-02-04 16:13:01     reflect_result = await memory.reflect_async(
2026-02-04 16:13:01                      ^^^^^^^^^^^^^^^^^^^^^^^^^^^
2026-02-04 16:13:01   File "/app/api/hindsight_api/engine/memory_engine.py", line 3707, in reflect_async
2026-02-04 16:13:01     agent_result = await run_reflect_agent(
2026-02-04 16:13:01                    ^^^^^^^^^^^^^^^^^^^^^^^^
2026-02-04 16:13:01   File "/app/api/hindsight_api/engine/reflect/agent.py", line 718, in run_reflect_agent
2026-02-04 16:13:01     input_summary = _summarize_input(tc.name, tc.arguments)
2026-02-04 16:13:01                     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
2026-02-04 16:13:01   File "/app/api/hindsight_api/engine/reflect/agent.py", line 912, in _summarize_input
2026-02-04 16:13:01     max_tokens = max(args.get("max_tokens") or 5000, 1000)
2026-02-04 16:13:01                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
2026-02-04 16:13:01 TypeError: '>' not supported between instances of 'int' and 'str'
2026-02-04 16:13:01 2026-02-04 21:13:01,573 - INFO - mcp.server.streamable_http - Terminating session: None
2026-02-04 16:13:03 2026-02-04 21:13:03,033 - INFO - mcp.server.lowlevel.server - Processing request of type CallToolRequest
2026-02-04 16:13:03 2026-02-04 21:13:03,033 - INFO - hindsight_api.engine.memory_engine - [RECAL

Signed-off-by: hayden.rear <hayden.rear@gmail.com>
@nicoloboschi nicoloboschi merged commit 093ecff into vectorize-io:main Feb 5, 2026
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

Successfully merging this pull request may close these issues.

2 participants