Spaces:
Sleeping
Sleeping
File size: 37,101 Bytes
f19d5b6 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 |
------------------------------------------------------------
TS: 2026-04-26 10:35:27
CTX: Agent Link Failure
MSG: Error response 401 while fetching https://api.mistral.ai/v1/chat/completions: {"detail":"Unauthorized"}
TRACE:
Traceback (most recent call last):
File "C:\Users\Reyansh\OneDrive\Desktop\project_sp\app.py", line 299, in invoke_analysis_agent
agent_result = agent.invoke({"messages": [{"role": "user", "content": user_query}]}, config=runtime_config)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\pregel\main.py", line 3309, in invoke
for chunk in self.stream(
^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\pregel\main.py", line 2736, in stream
for _ in runner.tick(
^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\pregel\_runner.py", line 167, in tick
run_with_retry(
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\pregel\_retry.py", line 126, in run_with_retry
return task.proc.invoke(task.input, config)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\_internal\_runnable.py", line 656, in invoke
input = context.run(step.invoke, input, config, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\_internal\_runnable.py", line 393, in invoke
ret = context.run(self.func, *args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\prebuilt\chat_agent_executor.py", line 679, in call_model
response = cast(AIMessage, static_model.invoke(model_input, config)) # type: ignore[union-attr]
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langchain_core\runnables\base.py", line 3157, in invoke
input_ = context.run(step.invoke, input_, config)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langchain_core\runnables\base.py", line 5695, in invoke
return self.bound.invoke(
^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langchain_core\language_models\chat_models.py", line 454, in invoke
self.generate_prompt(
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langchain_core\language_models\chat_models.py", line 1185, in generate_prompt
return self.generate(prompt_messages, stop=stop, callbacks=callbacks, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langchain_core\language_models\chat_models.py", line 995, in generate
self._generate_with_cache(
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langchain_core\language_models\chat_models.py", line 1297, in _generate_with_cache
result = self._generate(
^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langchain_mistralai\chat_models.py", line 666, in _generate
response = self.completion_with_retry(
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langchain_mistralai\chat_models.py", line 583, in completion_with_retry
return _completion_with_retry(**kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\tenacity\__init__.py", line 338, in wrapped_f
return copy(f, *args, **kw)
^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\tenacity\__init__.py", line 477, in __call__
do = self.iter(retry_state=retry_state)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\tenacity\__init__.py", line 378, in iter
result = action(retry_state)
^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\tenacity\__init__.py", line 400, in <lambda>
self._add_action_func(lambda rs: rs.outcome.result())
^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\concurrent\futures\_base.py", line 449, in result
return self.__get_result()
^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\concurrent\futures\_base.py", line 401, in __get_result
raise self._exception
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\tenacity\__init__.py", line 480, in __call__
result = fn(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langchain_mistralai\chat_models.py", line 580, in _completion_with_retry
_raise_on_error(response)
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langchain_mistralai\chat_models.py", line 186, in _raise_on_error
raise httpx.HTTPStatusError(
httpx.HTTPStatusError: Error response 401 while fetching https://api.mistral.ai/v1/chat/completions: {"detail":"Unauthorized"}
During task with name 'agent' and id 'a356d83a-1c7e-a11b-16dd-abfb8e9bec66'
------------------------------------------------------------
TS: 2026-04-26 10:36:04
CTX: Agent Link Failure
MSG: Error response 401 while fetching https://api.mistral.ai/v1/chat/completions: {"detail":"Unauthorized"}
TRACE:
Traceback (most recent call last):
File "C:\Users\Reyansh\OneDrive\Desktop\project_sp\app.py", line 299, in invoke_analysis_agent
agent_result = agent.invoke({"messages": [{"role": "user", "content": user_query}]}, config=runtime_config)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\pregel\main.py", line 3309, in invoke
for chunk in self.stream(
^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\pregel\main.py", line 2736, in stream
for _ in runner.tick(
^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\pregel\_runner.py", line 167, in tick
run_with_retry(
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\pregel\_retry.py", line 126, in run_with_retry
return task.proc.invoke(task.input, config)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\_internal\_runnable.py", line 656, in invoke
input = context.run(step.invoke, input, config, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\_internal\_runnable.py", line 393, in invoke
ret = context.run(self.func, *args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\prebuilt\chat_agent_executor.py", line 679, in call_model
response = cast(AIMessage, static_model.invoke(model_input, config)) # type: ignore[union-attr]
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langchain_core\runnables\base.py", line 3157, in invoke
input_ = context.run(step.invoke, input_, config)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langchain_core\runnables\base.py", line 5695, in invoke
return self.bound.invoke(
^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langchain_core\language_models\chat_models.py", line 454, in invoke
self.generate_prompt(
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langchain_core\language_models\chat_models.py", line 1185, in generate_prompt
return self.generate(prompt_messages, stop=stop, callbacks=callbacks, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langchain_core\language_models\chat_models.py", line 995, in generate
self._generate_with_cache(
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langchain_core\language_models\chat_models.py", line 1297, in _generate_with_cache
result = self._generate(
^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langchain_mistralai\chat_models.py", line 666, in _generate
response = self.completion_with_retry(
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langchain_mistralai\chat_models.py", line 583, in completion_with_retry
return _completion_with_retry(**kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\tenacity\__init__.py", line 338, in wrapped_f
return copy(f, *args, **kw)
^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\tenacity\__init__.py", line 477, in __call__
do = self.iter(retry_state=retry_state)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\tenacity\__init__.py", line 378, in iter
result = action(retry_state)
^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\tenacity\__init__.py", line 400, in <lambda>
self._add_action_func(lambda rs: rs.outcome.result())
^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\concurrent\futures\_base.py", line 449, in result
return self.__get_result()
^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\concurrent\futures\_base.py", line 401, in __get_result
raise self._exception
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\tenacity\__init__.py", line 480, in __call__
result = fn(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langchain_mistralai\chat_models.py", line 580, in _completion_with_retry
_raise_on_error(response)
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langchain_mistralai\chat_models.py", line 186, in _raise_on_error
raise httpx.HTTPStatusError(
httpx.HTTPStatusError: Error response 401 while fetching https://api.mistral.ai/v1/chat/completions: {"detail":"Unauthorized"}
During task with name 'agent' and id '219ec02f-c83a-73b0-984b-94d004b55aa6'
------------------------------------------------------------
TS: 2026-04-26 10:36:48
CTX: Agent Link Failure
MSG: Error response 401 while fetching https://api.mistral.ai/v1/chat/completions: {"detail":"Unauthorized"}
TRACE:
Traceback (most recent call last):
File "C:\Users\Reyansh\OneDrive\Desktop\project_sp\app.py", line 299, in invoke_analysis_agent
agent_result = agent.invoke({"messages": [{"role": "user", "content": user_query}]}, config=runtime_config)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\pregel\main.py", line 3309, in invoke
for chunk in self.stream(
^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\pregel\main.py", line 2736, in stream
for _ in runner.tick(
^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\pregel\_runner.py", line 167, in tick
run_with_retry(
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\pregel\_retry.py", line 126, in run_with_retry
return task.proc.invoke(task.input, config)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\_internal\_runnable.py", line 656, in invoke
input = context.run(step.invoke, input, config, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\_internal\_runnable.py", line 393, in invoke
ret = context.run(self.func, *args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\prebuilt\chat_agent_executor.py", line 679, in call_model
response = cast(AIMessage, static_model.invoke(model_input, config)) # type: ignore[union-attr]
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langchain_core\runnables\base.py", line 3157, in invoke
input_ = context.run(step.invoke, input_, config)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langchain_core\runnables\base.py", line 5695, in invoke
return self.bound.invoke(
^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langchain_core\language_models\chat_models.py", line 454, in invoke
self.generate_prompt(
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langchain_core\language_models\chat_models.py", line 1185, in generate_prompt
return self.generate(prompt_messages, stop=stop, callbacks=callbacks, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langchain_core\language_models\chat_models.py", line 995, in generate
self._generate_with_cache(
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langchain_core\language_models\chat_models.py", line 1297, in _generate_with_cache
result = self._generate(
^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langchain_mistralai\chat_models.py", line 666, in _generate
response = self.completion_with_retry(
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langchain_mistralai\chat_models.py", line 583, in completion_with_retry
return _completion_with_retry(**kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\tenacity\__init__.py", line 338, in wrapped_f
return copy(f, *args, **kw)
^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\tenacity\__init__.py", line 477, in __call__
do = self.iter(retry_state=retry_state)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\tenacity\__init__.py", line 378, in iter
result = action(retry_state)
^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\tenacity\__init__.py", line 400, in <lambda>
self._add_action_func(lambda rs: rs.outcome.result())
^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\concurrent\futures\_base.py", line 449, in result
return self.__get_result()
^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\concurrent\futures\_base.py", line 401, in __get_result
raise self._exception
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\tenacity\__init__.py", line 480, in __call__
result = fn(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langchain_mistralai\chat_models.py", line 580, in _completion_with_retry
_raise_on_error(response)
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langchain_mistralai\chat_models.py", line 186, in _raise_on_error
raise httpx.HTTPStatusError(
httpx.HTTPStatusError: Error response 401 while fetching https://api.mistral.ai/v1/chat/completions: {"detail":"Unauthorized"}
During task with name 'agent' and id '1bb0306f-1ae0-c605-167a-f4e469090b8f'
------------------------------------------------------------
TS: 2026-04-26 14:58:38
CTX: Agent Link Failure
MSG: [Errno 2] No such file or directory: 'labels_abstract.json'
TRACE:
Traceback (most recent call last):
File "C:\Users\Reyansh\OneDrive\Desktop\project_sp\app.py", line 302, in invoke_analysis_agent
agent_result = agent.invoke({"messages": [{"role": "user", "content": user_query}]}, config=runtime_config)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\pregel\main.py", line 3309, in invoke
for chunk in self.stream(
^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\pregel\main.py", line 2736, in stream
for _ in runner.tick(
^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\pregel\_runner.py", line 167, in tick
run_with_retry(
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\pregel\_retry.py", line 126, in run_with_retry
return task.proc.invoke(task.input, config)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\_internal\_runnable.py", line 656, in invoke
input = context.run(step.invoke, input, config, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\_internal\_runnable.py", line 400, in invoke
ret = self.func(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\prebuilt\tool_node.py", line 818, in _func
outputs = list(
^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\concurrent\futures\_base.py", line 619, in result_iterator
yield _result_or_cancel(fs.pop())
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\concurrent\futures\_base.py", line 317, in _result_or_cancel
return fut.result(timeout)
^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\concurrent\futures\_base.py", line 449, in result
return self.__get_result()
^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\concurrent\futures\_base.py", line 401, in __get_result
raise self._exception
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\concurrent\futures\thread.py", line 59, in run
result = self.fn(*self.args, **self.kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langchain_core\runnables\config.py", line 579, in _wrapped_fn
return contexts.pop().run(fn, *args)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\prebuilt\tool_node.py", line 1031, in _run_one
return self._execute_tool_sync(tool_request, input_type, config)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\prebuilt\tool_node.py", line 980, in _execute_tool_sync
content = _handle_tool_error(e, flag=self._handle_tool_errors)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\prebuilt\tool_node.py", line 432, in _handle_tool_error
content = flag(e) # type: ignore [assignment, call-arg]
^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\prebuilt\tool_node.py", line 389, in _default_handle_tool_errors
raise e
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\prebuilt\tool_node.py", line 937, in _execute_tool_sync
response = tool.invoke(call_args, config)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langchain_core\tools\base.py", line 642, in invoke
return self.run(tool_input, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langchain_core\tools\base.py", line 1001, in run
raise error_to_raise
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langchain_core\tools\base.py", line 967, in run
response = context.run(self._run, *tool_args, **tool_kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langchain_core\tools\structured.py", line 97, in _run
return self.func(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\OneDrive\Desktop\project_sp\tools.py", line 405, in consolidate_into_themes
with open(f"labels_{run_key}.json", encoding="utf-8") as raw_data:
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
FileNotFoundError: [Errno 2] No such file or directory: 'labels_abstract.json'
During task with name 'tools' and id 'b8ed4fbe-5f8d-f3f8-0811-2a0c22a5faca'
------------------------------------------------------------
TS: 2026-04-26 14:58:58
CTX: Session Migration [ee5baf -> 781d0d]
MSG: Found AIMessages with tool_calls that do not have a corresponding ToolMessage. Here are the first few of those tool calls: [{'name': 'consolidate_into_themes', 'args': {'run_key': 'abstract'}, 'id': 'qhuJma4xp', 'type': 'tool_call'}].
Every tool call (LLM requesting to call a tool) in the message history MUST have a corresponding ToolMessage (result of a tool invocation to return to the LLM) - this is required by most LLM providers.
For troubleshooting, visit: https://docs.langchain.com/oss/python/langgraph/errors/INVALID_CHAT_HISTORY
TRACE:
Traceback (most recent call last):
File "C:\Users\Reyansh\OneDrive\Desktop\project_sp\app.py", line 302, in invoke_analysis_agent
agent_result = agent.invoke({"messages": [{"role": "user", "content": user_query}]}, config=runtime_config)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\pregel\main.py", line 3309, in invoke
for chunk in self.stream(
^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\pregel\main.py", line 2736, in stream
for _ in runner.tick(
^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\pregel\_runner.py", line 167, in tick
run_with_retry(
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\pregel\_retry.py", line 126, in run_with_retry
return task.proc.invoke(task.input, config)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\_internal\_runnable.py", line 656, in invoke
input = context.run(step.invoke, input, config, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\_internal\_runnable.py", line 393, in invoke
ret = context.run(self.func, *args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\prebuilt\chat_agent_executor.py", line 672, in call_model
model_input = _get_model_input_state(state)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\prebuilt\chat_agent_executor.py", line 651, in _get_model_input_state
_validate_chat_history(messages)
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\prebuilt\chat_agent_executor.py", line 271, in _validate_chat_history
raise ValueError(error_message)
ValueError: Found AIMessages with tool_calls that do not have a corresponding ToolMessage. Here are the first few of those tool calls: [{'name': 'consolidate_into_themes', 'args': {'run_key': 'abstract'}, 'id': 'qhuJma4xp', 'type': 'tool_call'}].
Every tool call (LLM requesting to call a tool) in the message history MUST have a corresponding ToolMessage (result of a tool invocation to return to the LLM) - this is required by most LLM providers.
For troubleshooting, visit: https://docs.langchain.com/oss/python/langgraph/errors/INVALID_CHAT_HISTORY
During task with name 'agent' and id 'e2431c16-6dfe-2585-df7a-f14a1cd06bb3'
------------------------------------------------------------
TS: 2026-04-26 14:59:38
CTX: Agent Link Failure
MSG: [Errno 2] No such file or directory: 'scopus_data.csv'
TRACE:
Traceback (most recent call last):
File "C:\Users\Reyansh\OneDrive\Desktop\project_sp\app.py", line 302, in invoke_analysis_agent
agent_result = agent.invoke({"messages": [{"role": "user", "content": user_query}]}, config=runtime_config)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\pregel\main.py", line 3309, in invoke
for chunk in self.stream(
^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\pregel\main.py", line 2736, in stream
for _ in runner.tick(
^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\pregel\_runner.py", line 167, in tick
run_with_retry(
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\pregel\_retry.py", line 126, in run_with_retry
return task.proc.invoke(task.input, config)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\_internal\_runnable.py", line 656, in invoke
input = context.run(step.invoke, input, config, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\_internal\_runnable.py", line 400, in invoke
ret = self.func(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\prebuilt\tool_node.py", line 818, in _func
outputs = list(
^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\concurrent\futures\_base.py", line 619, in result_iterator
yield _result_or_cancel(fs.pop())
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\concurrent\futures\_base.py", line 317, in _result_or_cancel
return fut.result(timeout)
^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\concurrent\futures\_base.py", line 449, in result
return self.__get_result()
^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\concurrent\futures\_base.py", line 401, in __get_result
raise self._exception
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\concurrent\futures\thread.py", line 59, in run
result = self.fn(*self.args, **self.kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langchain_core\runnables\config.py", line 579, in _wrapped_fn
return contexts.pop().run(fn, *args)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\prebuilt\tool_node.py", line 1031, in _run_one
return self._execute_tool_sync(tool_request, input_type, config)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\prebuilt\tool_node.py", line 980, in _execute_tool_sync
content = _handle_tool_error(e, flag=self._handle_tool_errors)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\prebuilt\tool_node.py", line 432, in _handle_tool_error
content = flag(e) # type: ignore [assignment, call-arg]
^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\prebuilt\tool_node.py", line 389, in _default_handle_tool_errors
raise e
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\prebuilt\tool_node.py", line 937, in _execute_tool_sync
response = tool.invoke(call_args, config)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langchain_core\tools\base.py", line 642, in invoke
return self.run(tool_input, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langchain_core\tools\base.py", line 1001, in run
raise error_to_raise
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langchain_core\tools\base.py", line 967, in run
response = context.run(self._run, *tool_args, **tool_kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langchain_core\tools\structured.py", line 97, in _run
return self.func(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\OneDrive\Desktop\project_sp\tools.py", line 177, in load_scopus_csv
source_df = pd.read_csv(
^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\pandas\io\parsers\readers.py", line 1026, in read_csv
return _read(filepath_or_buffer, kwds)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\pandas\io\parsers\readers.py", line 620, in _read
parser = TextFileReader(filepath_or_buffer, **kwds)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\pandas\io\parsers\readers.py", line 1620, in __init__
self._engine = self._make_engine(f, self.engine)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\pandas\io\parsers\readers.py", line 1880, in _make_engine
self.handles = get_handle(
^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\pandas\io\common.py", line 873, in get_handle
handle = open(
^^^^^
FileNotFoundError: [Errno 2] No such file or directory: 'scopus_data.csv'
During task with name 'tools' and id '9a34b14d-032f-5f7a-d90b-fbde4de60766'
------------------------------------------------------------
TS: 2026-04-26 14:59:46
CTX: Session Migration [781d0d -> 80a60b]
MSG: Found AIMessages with tool_calls that do not have a corresponding ToolMessage. Here are the first few of those tool calls: [{'name': 'load_scopus_csv', 'args': {'file_path': 'scopus_data.csv'}, 'id': 'JrfgG54k6', 'type': 'tool_call'}].
Every tool call (LLM requesting to call a tool) in the message history MUST have a corresponding ToolMessage (result of a tool invocation to return to the LLM) - this is required by most LLM providers.
For troubleshooting, visit: https://docs.langchain.com/oss/python/langgraph/errors/INVALID_CHAT_HISTORY
TRACE:
Traceback (most recent call last):
File "C:\Users\Reyansh\OneDrive\Desktop\project_sp\app.py", line 302, in invoke_analysis_agent
agent_result = agent.invoke({"messages": [{"role": "user", "content": user_query}]}, config=runtime_config)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\pregel\main.py", line 3309, in invoke
for chunk in self.stream(
^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\pregel\main.py", line 2736, in stream
for _ in runner.tick(
^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\pregel\_runner.py", line 167, in tick
run_with_retry(
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\pregel\_retry.py", line 126, in run_with_retry
return task.proc.invoke(task.input, config)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\_internal\_runnable.py", line 656, in invoke
input = context.run(step.invoke, input, config, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\_internal\_runnable.py", line 393, in invoke
ret = context.run(self.func, *args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\prebuilt\chat_agent_executor.py", line 672, in call_model
model_input = _get_model_input_state(state)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\prebuilt\chat_agent_executor.py", line 651, in _get_model_input_state
_validate_chat_history(messages)
File "C:\Users\Reyansh\AppData\Local\Programs\Python\Python312\Lib\site-packages\langgraph\prebuilt\chat_agent_executor.py", line 271, in _validate_chat_history
raise ValueError(error_message)
ValueError: Found AIMessages with tool_calls that do not have a corresponding ToolMessage. Here are the first few of those tool calls: [{'name': 'load_scopus_csv', 'args': {'file_path': 'scopus_data.csv'}, 'id': 'JrfgG54k6', 'type': 'tool_call'}].
Every tool call (LLM requesting to call a tool) in the message history MUST have a corresponding ToolMessage (result of a tool invocation to return to the LLM) - this is required by most LLM providers.
For troubleshooting, visit: https://docs.langchain.com/oss/python/langgraph/errors/INVALID_CHAT_HISTORY
During task with name 'agent' and id 'b1607601-ef5c-ab3b-44dc-b00f1969baf2'
|