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

[Bug]: Error Running Qwen2.5-7B-Instruct on CPU #9175

Open
1 task done
xiayouran opened this issue Oct 9, 2024 · 5 comments
Open
1 task done

[Bug]: Error Running Qwen2.5-7B-Instruct on CPU #9175

xiayouran opened this issue Oct 9, 2024 · 5 comments
Labels
bug Something isn't working

Comments

@xiayouran
Copy link

xiayouran commented Oct 9, 2024

Your current environment

The output of `python collect_env.py`
Collecting environment information...
INFO 10-09 02:11:31 importing.py:10] Triton not installed; certain GPU-related functions will not be available.
PyTorch version: 2.4.0+cpu
Is debug build: False
CUDA used to build PyTorch: None
ROCM used to build PyTorch: N/A

OS: Ubuntu 22.04.5 LTS (x86_64)
GCC version: (Ubuntu 12.3.0-1ubuntu1~22.04) 12.3.0
Clang version: Could not collect
CMake version: version 3.30.4
Libc version: glibc-2.35

Python version: 3.10.12 (main, Sep 11 2024, 15:47:36) [GCC 11.4.0] (64-bit runtime)
Python platform: Linux-5.15.0-94-generic-x86_64-with-glibc2.35
Is CUDA available: False
CUDA runtime version: No CUDA
CUDA_MODULE_LOADING set to: N/A
GPU models and configuration: No CUDA
Nvidia driver version: No CUDA
cuDNN version: No CUDA
HIP runtime version: N/A
MIOpen runtime version: N/A
Is XNNPACK available: True

CPU:
Architecture:                       x86_64
CPU op-mode(s):                     32-bit, 64-bit
Address sizes:                      46 bits physical, 48 bits virtual
Byte Order:                         Little Endian
CPU(s):                             64
On-line CPU(s) list:                0-63
Vendor ID:                          GenuineIntel
Model name:                         Intel(R) Xeon(R) Silver 4216 CPU @ 2.10GHz
CPU family:                         6
Model:                              85
Thread(s) per core:                 2
Core(s) per socket:                 16
Socket(s):                          2
Stepping:                           7
CPU max MHz:                        2100.0000
CPU min MHz:                        800.0000
BogoMIPS:                           4200.00
Flags:                              fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe syscall nx pdpe1gb rdtscp lm constant_tsc art arch_perfmon pebs bts rep_good nopl xtopology nonstop_tsc cpuid aperfmperf pni pclmulqdq dtes64 monitor ds_cpl vmx smx est tm2 ssse3 sdbg fma cx16 xtpr pdcm pcid dca sse4_1 sse4_2 x2apic movbe popcnt tsc_deadline_timer aes xsave avx f16c rdrand lahf_lm abm 3dnowprefetch cpuid_fault epb cat_l3 cdp_l3 invpcid_single intel_ppin ssbd mba ibrs ibpb stibp ibrs_enhanced tpr_shadow vnmi flexpriority ept vpid ept_ad fsgsbase tsc_adjust bmi1 avx2 smep bmi2 erms invpcid cqm mpx rdt_a avx512f avx512dq rdseed adx smap clflushopt clwb intel_pt avx512cd avx512bw avx512vl xsaveopt xsavec xgetbv1 xsaves cqm_llc cqm_occup_llc cqm_mbm_total cqm_mbm_local dtherm arat pln pts pku ospke avx512_vnni md_clear flush_l1d arch_capabilities
Virtualization:                     VT-x
L1d cache:                          1 MiB (32 instances)
L1i cache:                          1 MiB (32 instances)
L2 cache:                           32 MiB (32 instances)
L3 cache:                           44 MiB (2 instances)
NUMA node(s):                       2
NUMA node0 CPU(s):                  0-15,32-47
NUMA node1 CPU(s):                  16-31,48-63
Vulnerability Gather data sampling: Mitigation; Microcode
Vulnerability Itlb multihit:        KVM: Mitigation: VMX disabled
Vulnerability L1tf:                 Not affected
Vulnerability Mds:                  Not affected
Vulnerability Meltdown:             Not affected
Vulnerability Mmio stale data:      Mitigation; Clear CPU buffers; SMT vulnerable
Vulnerability Retbleed:             Mitigation; Enhanced IBRS
Vulnerability Spec rstack overflow: Not affected
Vulnerability Spec store bypass:    Mitigation; Speculative Store Bypass disabled via prctl and seccomp
Vulnerability Spectre v1:           Mitigation; usercopy/swapgs barriers and __user pointer sanitization
Vulnerability Spectre v2:           Mitigation; Enhanced IBRS, IBPB conditional, RSB filling, PBRSB-eIBRS SW sequence
Vulnerability Srbds:                Not affected
Vulnerability Tsx async abort:      Mitigation; TSX disabled

Versions of relevant libraries:
[pip3] intel_extension_for_pytorch==2.4.0+gitfbaa4bc
[pip3] numpy==1.26.4
[pip3] pyzmq==26.2.0
[pip3] torch==2.4.0+cpu
[pip3] torchvision==0.19.0+cpu
[pip3] transformers==4.45.2
[conda] Could not collect
ROCM Version: Could not collect
Neuron SDK Version: N/A
vLLM Version: 0.6.3.dev125+g8c746226.d20241008
vLLM Build Flags:
CUDA Archs: Not Set; ROCm: Disabled; Neuron: Disabled
GPU Topology:
Could not collect

Model Input Dumps

No response

🐛 Describe the bug

Installed vllm for CPU as mentioned in https://docs.vllm.ai/en/latest/getting_started/cpu-installation.html#

I run the docker by docker compose:

  qwen2dot5_7b_instruct_cpu:
    image: vllm-cpu:latest
    container_name: qwen2dot5-7b-instruct-cpu
    restart: always
    volumes:
      - /home/liyanpeng/huggingface:/data/liyanpeng/huggingface
    ports:
      - "11055:8000"
    environment:
      VLLM_CPU_KVCACHE_SPACE: "8"
    command: >
      --model /data/liyanpeng/huggingface/Qwen/Qwen2.5-7B-Instruct --trust-remote-code --max-model-len 8192
      --served-model-name qwen2dot5-7b-instruct --dtype auto --disable-log-stats
    shm_size: '8g'
    networks:
      - chatqa_net

Error:

INFO:     192.168.3.21:61851 - "POST /v1/chat/completions HTTP/1.1" 200 OK
INFO 10-09 02:13:24 engine.py:288] Added request chat-f0a743a5ff9145ea9af94c9c686cfb77.
ERROR 10-09 02:13:55 client.py:250] RuntimeError('Engine loop has died')
ERROR 10-09 02:13:55 client.py:250] Traceback (most recent call last):
ERROR 10-09 02:13:55 client.py:250]   File "/usr/local/lib/python3.10/dist-packages/vllm/engine/multiprocessing/client.py", line 150, in run_heartbeat_loop
ERROR 10-09 02:13:55 client.py:250]     await self._check_success(
ERROR 10-09 02:13:55 client.py:250]   File "/usr/local/lib/python3.10/dist-packages/vllm/engine/multiprocessing/client.py", line 314, in _check_success
ERROR 10-09 02:13:55 client.py:250]     raise response
ERROR 10-09 02:13:55 client.py:250] RuntimeError: Engine loop has died
ERROR:    Exception in ASGI application
Traceback (most recent call last):
  File "/usr/local/lib/python3.10/dist-packages/starlette/responses.py", line 257, in __call__
    await wrap(partial(self.listen_for_disconnect, receive))
  File "/usr/local/lib/python3.10/dist-packages/starlette/responses.py", line 253, in wrap
    await func()
  File "/usr/local/lib/python3.10/dist-packages/starlette/responses.py", line 230, in listen_for_disconnect
    message = await receive()
  File "/usr/local/lib/python3.10/dist-packages/uvicorn/protocols/http/httptools_impl.py", line 555, in receive
    await self.message_event.wait()
  File "/usr/lib/python3.10/asyncio/locks.py", line 214, in wait
    await fut
asyncio.exceptions.CancelledError: Cancelled by cancel scope 7fbe03c27790

During handling of the above exception, another exception occurred:

  + Exception Group Traceback (most recent call last):
  |   File "/usr/local/lib/python3.10/dist-packages/uvicorn/protocols/http/httptools_impl.py", line 401, in run_asgi
  |     result = await app(  # type: ignore[func-returns-value]
  |   File "/usr/local/lib/python3.10/dist-packages/uvicorn/middleware/proxy_headers.py", line 60, in __call__
  |     return await self.app(scope, receive, send)
  |   File "/usr/local/lib/python3.10/dist-packages/fastapi/applications.py", line 1054, in __call__
  |     await super().__call__(scope, receive, send)
  |   File "/usr/local/lib/python3.10/dist-packages/starlette/applications.py", line 113, in __call__
  |     await self.middleware_stack(scope, receive, send)
  |   File "/usr/local/lib/python3.10/dist-packages/starlette/middleware/errors.py", line 187, in __call__
  |     raise exc
  |   File "/usr/local/lib/python3.10/dist-packages/starlette/middleware/errors.py", line 165, in __call__
  |     await self.app(scope, receive, _send)
  |   File "/usr/local/lib/python3.10/dist-packages/starlette/middleware/cors.py", line 85, in __call__
  |     await self.app(scope, receive, send)
  |   File "/usr/local/lib/python3.10/dist-packages/starlette/middleware/exceptions.py", line 62, in __call__
  |     await wrap_app_handling_exceptions(self.app, conn)(scope, receive, send)
  |   File "/usr/local/lib/python3.10/dist-packages/starlette/_exception_handler.py", line 62, in wrapped_app
  |     raise exc
  |   File "/usr/local/lib/python3.10/dist-packages/starlette/_exception_handler.py", line 51, in wrapped_app
  |     await app(scope, receive, sender)
  |   File "/usr/local/lib/python3.10/dist-packages/starlette/routing.py", line 715, in __call__
  |     await self.middleware_stack(scope, receive, send)
  |   File "/usr/local/lib/python3.10/dist-packages/starlette/routing.py", line 735, in app
  |     await route.handle(scope, receive, send)
  |   File "/usr/local/lib/python3.10/dist-packages/starlette/routing.py", line 288, in handle
  |     await self.app(scope, receive, send)
  |   File "/usr/local/lib/python3.10/dist-packages/starlette/routing.py", line 76, in app
  |     await wrap_app_handling_exceptions(app, request)(scope, receive, send)
  |   File "/usr/local/lib/python3.10/dist-packages/starlette/_exception_handler.py", line 62, in wrapped_app
  |     raise exc
  |   File "/usr/local/lib/python3.10/dist-packages/starlette/_exception_handler.py", line 51, in wrapped_app
  |     await app(scope, receive, sender)
  |   File "/usr/local/lib/python3.10/dist-packages/starlette/routing.py", line 74, in app
  |     await response(scope, receive, send)
  |   File "/usr/local/lib/python3.10/dist-packages/starlette/responses.py", line 250, in __call__
  |     async with anyio.create_task_group() as task_group:
  |   File "/usr/local/lib/python3.10/dist-packages/anyio/_backends/_asyncio.py", line 736, in __aexit__
  |     raise BaseExceptionGroup(
  | exceptiongroup.ExceptionGroup: unhandled errors in a TaskGroup (1 sub-exception)
  +-+---------------- 1 ----------------
    | Traceback (most recent call last):
    |   File "/usr/local/lib/python3.10/dist-packages/starlette/responses.py", line 253, in wrap
    |     await func()
    |   File "/usr/local/lib/python3.10/dist-packages/starlette/responses.py", line 242, in stream_response
    |     async for chunk in self.body_iterator:
    |   File "/usr/local/lib/python3.10/dist-packages/vllm/entrypoints/openai/serving_chat.py", line 341, in chat_completion_stream_generator
    |     async for res in result_generator:
    |   File "/usr/local/lib/python3.10/dist-packages/vllm/utils.py", line 455, in iterate_with_cancellation
    |     item = await awaits[0]
    |   File "/usr/local/lib/python3.10/dist-packages/vllm/engine/multiprocessing/client.py", line 682, in _process_request
    |     raise request_output
    | vllm.engine.multiprocessing.MQEngineDeadError: Engine loop is not running. Inspect the stacktrace to find the original error: RuntimeError('Engine loop has died').
    +------------------------------------

Qwen2-7B-Instruct has the same issue. (The strange thing is that the first request of Qwen2.5-7B-Instruct was fine, and the second request was wrong. Qwen2-7B-Instruct has an error occurred on the first request.)

I have tried #9044 , that pull not solved my problem.

Before submitting a new issue...

  • Make sure you already searched for relevant issues, and asked the chatbot living at the bottom right corner of the documentation page, which can answer lots of frequently asked questions.
@xiayouran xiayouran added the bug Something isn't working label Oct 9, 2024
@LuckLittleBoy
Copy link

I run the docker with the main branch Dockerfile.cpu: "docker build -f Dockerfile.cpu -t vllm-cpu-env ."
and set the tool call enable: "docker run -v /home/vllm/vllm-model/modelscope:/root/.cache/modelscope --env "VLLM_USE_MODELSCOPE=True" --env "VLLM_LOGGING_LEVEL=DEBUG" -p 8001:8000 --ipc host -d --name vllm vllm-cpu-env --model Qwen/Qwen2.5-7B-Instruct --trust-remote-code --enable-auto-tool-choice --tool-call-parser hermes"

but it request wrong, I don't know reason, why???

request example:
url: 127.0.0.1:8001/v1/chat/completions
body: {
"model": "Qwen/Qwen2.5-7B-Instruct",
"temperature": 0.01,
"max_tokens": 2000,
"stream": true,
"messages": [
{
"role": "user",
"content": "系统状态"
}
],
"tools": [
{
"type": "function",
"function": {
"name": "cInBMXzQGq58",
"description": "系统状态方面",
"parameters": {
"type": "object",
"properties": {},
"required": []
}
}
}
],
"tool_choice": "auto"
}

debug logging:

INFO 10-09 02:47:14 logger.py:37] Received request chat-6e6b6292da0e43efafa4a55db7260b38: prompt: '<|im_start|>system\nYou are Qwen, created by Alibaba Cloud. You are a helpful assistant.\n\n# Tools\n\nYou may call one or more functions to assist with the user query.\n\nYou are provided with function signatures within XML tags:\n\n{"type": "function", "function": {"name": "cInBMXzQGq58", "description": "系统状态方面", "parameters": {"type": "object", "properties": {}, "required": []}}}\n\n\nFor each function call, return a json object with function name and arguments within <tool_call></tool_call> XML tags:\n<tool_call>\n{"name": , "arguments": }\n</tool_call><|im_end|>\n<|im_start|>user\n系统状态<|im_end|>\n<|im_start|>assistant\n', params: SamplingParams(n=1, best_of=1, presence_penalty=0.0, frequency_penalty=0.0, repetition_penalty=1.0, temperature=0.01, top_p=1.0, top_k=-1, min_p=0.0, seed=None, stop=[], stop_token_ids=[], include_stop_str_in_output=False, ignore_eos=False, max_tokens=8000, min_tokens=0, logprobs=None, prompt_logprobs=None, skip_special_tokens=True, spaces_between_special_tokens=True, truncate_prompt_tokens=None), guided_decoding=GuidedDecodingParams(json=None, regex=None, choice=None, grammar=None, json_object=None, backend=None, whitespace_pattern=None), prompt_token_ids: [151644, 8948, 198, 2610, 525, 1207, 16948, 11, 3465, 553, 54364, 14817, 13, 1446, 525, 264, 10950, 17847, 382, 2, 13852, 271, 2610, 1231, 1618, 825, 476, 803, 5746, 311, 7789, 448, 279, 1196, 3239, 382, 2610, 525, 3897, 448, 729, 32628, 2878, 366, 15918, 1472, 15918, 29, 11874, 9492, 510, 27, 15918, 397, 4913, 1313, 788, 330, 1688, 497, 330, 1688, 788, 5212, 606, 788, 330, 66, 641, 28942, 55, 89, 48, 38, 80, 20, 23, 497, 330, 4684, 788, 330, 72448, 44091, 99522, 497, 330, 13786, 788, 5212, 1313, 788, 330, 1700, 497, 330, 13193, 788, 16452, 330, 6279, 788, 3056, 3417, 532, 522, 15918, 1339, 2461, 1817, 729, 1618, 11, 470, 264, 2951, 1633, 448, 729, 829, 323, 5977, 2878, 220, 151657, 151658, 11874, 9492, 510, 151657, 198, 4913, 606, 788, 366, 1688, 11494, 8066, 330, 16370, 788, 366, 2116, 56080, 40432, 31296, 151658, 151645, 198, 151644, 872, 198, 72448, 44091, 151645, 198, 151644, 77091, 198], lora_request: None, prompt_adapter_request: None.
INFO: 192.168.10.77:49714 - "POST /v1/chat/completions HTTP/1.1" 200 OK
DEBUG 10-09 02:47:15 async_llm_engine.py:525] Building guided decoding logits processor. Params: GuidedDecodingParams(json=None, regex=None, choice=None, grammar=None, json_object=None, backend=None, whitespace_pattern=None)
INFO 10-09 02:47:18 metrics.py:351] Avg prompt throughput: 0.0 tokens/s, Avg generation throughput: 0.0 tokens/s, Running: 0 reqs, Swapped: 0 reqs, Pending: 0 reqs, GPU KV cache usage: 0.0%, CPU KV cache usage: 0.0%.
DEBUG 10-09 02:47:18 engine.py:212] Waiting for new requests in engine loop.
DEBUG 10-09 02:47:21 client.py:154] Heartbeat successful.
DEBUG 10-09 02:47:21 client.py:154] Heartbeat successful.
INFO 10-09 02:47:21 engine.py:288] Added request chat-6e6b6292da0e43efafa4a55db7260b38.
DEBUG 10-09 02:47:21 client.py:154] Heartbeat successful.
DEBUG 10-09 02:47:22 client.py:154] Heartbeat successful.
DEBUG 10-09 02:47:22 client.py:170] Waiting for output from MQLLMEngine.
DEBUG 10-09 02:47:24 client.py:154] Heartbeat successful.
DEBUG 10-09 02:47:26 client.py:154] Heartbeat successful.
DEBUG 10-09 02:47:28 client.py:154] Heartbeat successful.
DEBUG 10-09 02:47:30 client.py:154] Heartbeat successful.
DEBUG 10-09 02:47:32 client.py:154] Heartbeat successful.
DEBUG 10-09 02:47:32 client.py:170] Waiting for output from MQLLMEngine.
DEBUG 10-09 02:47:34 client.py:154] Heartbeat successful.
DEBUG 10-09 02:47:36 client.py:154] Heartbeat successful.
DEBUG 10-09 02:47:38 client.py:154] Heartbeat successful.
DEBUG 10-09 02:47:40 client.py:154] Heartbeat successful.
DEBUG 10-09 02:47:42 client.py:154] Heartbeat successful.
DEBUG 10-09 02:47:42 client.py:170] Waiting for output from MQLLMEngine.
DEBUG 10-09 02:47:44 client.py:154] Heartbeat successful.
DEBUG 10-09 02:47:46 client.py:154] Heartbeat successful.

ERROR 10-09 02:47:48 client.py:250] RuntimeError('Engine loop has died')
ERROR 10-09 02:47:48 client.py:250] Traceback (most recent call last):
ERROR 10-09 02:47:48 client.py:250] File "/usr/local/lib/python3.10/dist-packages/vllm/engine/multiprocessing/client.py", line 150, in run_heartbeat_loop
ERROR 10-09 02:47:48 client.py:250] await self._check_success(
ERROR 10-09 02:47:48 client.py:250] File "/usr/local/lib/python3.10/dist-packages/vllm/engine/multiprocessing/client.py", line 314, in _check_success
ERROR 10-09 02:47:48 client.py:250] raise response
ERROR 10-09 02:47:48 client.py:250] RuntimeError: Engine loop has died

INFO 10-09 02:47:49 metrics.py:351] Avg prompt throughput: 5.1 tokens/s, Avg generation throughput: 0.0 tokens/s, Running: 1 reqs, Swapped: 0 reqs, Pending: 0 reqs, GPU KV cache usage: 0.2%, CPU KV cache usage: 0.0%.
DEBUG 10-09 02:47:49 hermes_tool_parser.py:125] delta_text: <tool_call>
DEBUG 10-09 02:47:49 hermes_tool_parser.py:126] delta_token_ids: [151657]
DEBUG 10-09 02:47:49 hermes_tool_parser.py:176] Starting on a new tool 0
DEBUG 10-09 02:47:49 hermes_tool_parser.py:219] Parsed tool call None
ERROR 10-09 02:47:49 hermes_tool_parser.py:338] Error trying to handle streaming tool call: 'NoneType' object has no attribute 'get'

DEBUG 10-09 02:47:50 hermes_tool_parser.py:125] delta_text:
DEBUG 10-09 02:47:50 hermes_tool_parser.py:125]
DEBUG 10-09 02:47:50 hermes_tool_parser.py:126] delta_token_ids: [198]
DEBUG 10-09 02:47:50 hermes_tool_parser.py:221] not enough tokens to parse into JSON yet
DEBUG 10-09 02:47:51 hermes_tool_parser.py:125] delta_text: {"
DEBUG 10-09 02:47:51 hermes_tool_parser.py:126] delta_token_ids: [4913]
DEBUG 10-09 02:47:51 hermes_tool_parser.py:219] Parsed tool call {}
DEBUG 10-09 02:47:52 hermes_tool_parser.py:125] delta_text: name
DEBUG 10-09 02:47:52 hermes_tool_parser.py:126] delta_token_ids: [606]
DEBUG 10-09 02:47:52 hermes_tool_parser.py:219] Parsed tool call {}
DEBUG 10-09 02:47:53 hermes_tool_parser.py:125] delta_text: ":
DEBUG 10-09 02:47:53 hermes_tool_parser.py:126] delta_token_ids: [788]
DEBUG 10-09 02:47:53 hermes_tool_parser.py:219] Parsed tool call {}
DEBUG 10-09 02:47:54 hermes_tool_parser.py:125] delta_text: "
DEBUG 10-09 02:47:54 hermes_tool_parser.py:126] delta_token_ids: [330]
DEBUG 10-09 02:47:54 hermes_tool_parser.py:219] Parsed tool call {}
INFO 10-09 02:47:55 metrics.py:351] Avg prompt throughput: 0.0 tokens/s, Avg generation throughput: 1.0 tokens/s, Running: 1 reqs, Swapped: 0 reqs, Pending: 0 reqs, GPU KV cache usage: 0.2%, CPU KV cache usage: 0.0%.
DEBUG 10-09 02:47:55 hermes_tool_parser.py:125] delta_text: c
DEBUG 10-09 02:47:55 hermes_tool_parser.py:126] delta_token_ids: [66]
DEBUG 10-09 02:47:55 hermes_tool_parser.py:219] Parsed tool call {}
DEBUG 10-09 02:47:56 hermes_tool_parser.py:125] delta_text: In
DEBUG 10-09 02:47:56 hermes_tool_parser.py:126] delta_token_ids: [641]
DEBUG 10-09 02:47:56 hermes_tool_parser.py:219] Parsed tool call {}
DEBUG 10-09 02:47:57 hermes_tool_parser.py:125] delta_text: BM
DEBUG 10-09 02:47:57 hermes_tool_parser.py:126] delta_token_ids: [28942]
DEBUG 10-09 02:47:57 hermes_tool_parser.py:219] Parsed tool call {}
DEBUG 10-09 02:47:58 hermes_tool_parser.py:125] delta_text: X
DEBUG 10-09 02:47:58 hermes_tool_parser.py:126] delta_token_ids: [55]
DEBUG 10-09 02:47:58 hermes_tool_parser.py:219] Parsed tool call {}
DEBUG 10-09 02:47:58 hermes_tool_parser.py:125] delta_text: z
DEBUG 10-09 02:47:58 hermes_tool_parser.py:126] delta_token_ids: [89]
DEBUG 10-09 02:47:58 hermes_tool_parser.py:219] Parsed tool call {}
DEBUG 10-09 02:47:59 hermes_tool_parser.py:125] delta_text: Q
DEBUG 10-09 02:47:59 hermes_tool_parser.py:126] delta_token_ids: [48]
DEBUG 10-09 02:47:59 hermes_tool_parser.py:219] Parsed tool call {}
INFO 10-09 02:48:00 metrics.py:351] Avg prompt throughput: 0.0 tokens/s, Avg generation throughput: 1.0 tokens/s, Running: 1 reqs, Swapped: 0 reqs, Pending: 0 reqs, GPU KV cache usage: 0.2%, CPU KV cache usage: 0.0%.
DEBUG 10-09 02:48:00 hermes_tool_parser.py:125] delta_text: z
DEBUG 10-09 02:48:00 hermes_tool_parser.py:126] delta_token_ids: [89]
DEBUG 10-09 02:48:00 hermes_tool_parser.py:219] Parsed tool call {}
DEBUG 10-09 02:48:01 hermes_tool_parser.py:125] delta_text: 5
DEBUG 10-09 02:48:01 hermes_tool_parser.py:126] delta_token_ids: [20]
DEBUG 10-09 02:48:01 hermes_tool_parser.py:219] Parsed tool call {}
DEBUG 10-09 02:48:02 hermes_tool_parser.py:125] delta_text: 8
DEBUG 10-09 02:48:02 hermes_tool_parser.py:126] delta_token_ids: [23]
DEBUG 10-09 02:48:02 hermes_tool_parser.py:219] Parsed tool call {}
DEBUG 10-09 02:48:03 hermes_tool_parser.py:125] delta_text: ",
DEBUG 10-09 02:48:03 hermes_tool_parser.py:126] delta_token_ids: [497]
DEBUG 10-09 02:48:03 hermes_tool_parser.py:219] Parsed tool call {'name': 'cInBMXzQz58'}
DEBUG 10-09 02:48:04 hermes_tool_parser.py:125] delta_text: "
DEBUG 10-09 02:48:04 hermes_tool_parser.py:126] delta_token_ids: [330]
DEBUG 10-09 02:48:04 hermes_tool_parser.py:219] Parsed tool call {'name': 'cInBMXzQz58'}
DEBUG 10-09 02:48:04 hermes_tool_parser.py:253] Trying to parse current tool call with ID 0
DEBUG 10-09 02:48:04 hermes_tool_parser.py:267] diffing old arguments: None
DEBUG 10-09 02:48:04 hermes_tool_parser.py:268] against new ones: None
DEBUG 10-09 02:48:04 hermes_tool_parser.py:272] Skipping text " - no arguments
INFO 10-09 02:48:05 metrics.py:351] Avg prompt throughput: 0.0 tokens/s, Avg generation throughput: 1.0 tokens/s, Running: 1 reqs, Swapped: 0 reqs, Pending: 0 reqs, GPU KV cache usage: 0.2%, CPU KV cache usage: 0.0%.
DEBUG 10-09 02:48:05 hermes_tool_parser.py:125] delta_text: arguments
DEBUG 10-09 02:48:05 hermes_tool_parser.py:126] delta_token_ids: [16370]
DEBUG 10-09 02:48:05 hermes_tool_parser.py:219] Parsed tool call {'name': 'cInBMXzQz58'}
DEBUG 10-09 02:48:05 hermes_tool_parser.py:253] Trying to parse current tool call with ID 0
DEBUG 10-09 02:48:05 hermes_tool_parser.py:267] diffing old arguments: None
DEBUG 10-09 02:48:05 hermes_tool_parser.py:268] against new ones: None
DEBUG 10-09 02:48:05 hermes_tool_parser.py:272] Skipping text arguments - no arguments
DEBUG 10-09 02:48:06 hermes_tool_parser.py:125] delta_text: ":
DEBUG 10-09 02:48:06 hermes_tool_parser.py:126] delta_token_ids: [788]
DEBUG 10-09 02:48:06 hermes_tool_parser.py:219] Parsed tool call {'name': 'cInBMXzQz58'}
DEBUG 10-09 02:48:06 hermes_tool_parser.py:253] Trying to parse current tool call with ID 0
DEBUG 10-09 02:48:06 hermes_tool_parser.py:267] diffing old arguments: None
DEBUG 10-09 02:48:06 hermes_tool_parser.py:268] against new ones: None
DEBUG 10-09 02:48:06 hermes_tool_parser.py:272] Skipping text ": - no arguments
DEBUG 10-09 02:48:07 hermes_tool_parser.py:125] delta_text: {}
DEBUG 10-09 02:48:07 hermes_tool_parser.py:126] delta_token_ids: [4687]
DEBUG 10-09 02:48:07 hermes_tool_parser.py:219] Parsed tool call {'name': 'cInBMXzQz58', 'arguments': {}}
DEBUG 10-09 02:48:07 hermes_tool_parser.py:253] Trying to parse current tool call with ID 0
DEBUG 10-09 02:48:07 hermes_tool_parser.py:267] diffing old arguments: None
DEBUG 10-09 02:48:07 hermes_tool_parser.py:268] against new ones: {}
DEBUG 10-09 02:48:07 hermes_tool_parser.py:272] Skipping text {} - no arguments
DEBUG 10-09 02:48:08 hermes_tool_parser.py:125] delta_text: }
DEBUG 10-09 02:48:08 hermes_tool_parser.py:125]
DEBUG 10-09 02:48:08 hermes_tool_parser.py:126] delta_token_ids: [532]
DEBUG 10-09 02:48:08 hermes_tool_parser.py:219] Parsed tool call {'name': 'cInBMXzQz58', 'arguments': {}}
DEBUG 10-09 02:48:08 hermes_tool_parser.py:253] Trying to parse current tool call with ID 0
DEBUG 10-09 02:48:08 hermes_tool_parser.py:267] diffing old arguments: {}
DEBUG 10-09 02:48:08 hermes_tool_parser.py:268] against new ones: {}
DEBUG 10-09 02:48:08 hermes_tool_parser.py:272] Skipping text }
DEBUG 10-09 02:48:08 hermes_tool_parser.py:272] - no arguments
DEBUG 10-09 02:48:09 hermes_tool_parser.py:125] delta_text: </tool_call>
DEBUG 10-09 02:48:09 hermes_tool_parser.py:126] delta_token_ids: [151658]
ERROR 10-09 02:48:09 hermes_tool_parser.py:338] Error trying to handle streaming tool call: local variable 'tool_call_portion' referenced before assignment
DEBUG 10-09 02:48:10 llm_engine.py:1451] Stopping remote worker execution loop.
DEBUG 10-09 02:48:10 hermes_tool_parser.py:125] delta_text:
DEBUG 10-09 02:48:10 hermes_tool_parser.py:126] delta_token_ids: [151645]
DEBUG 10-09 02:48:10 hermes_tool_parser.py:148] Generating text content! skipping tool parsing.

@DarkLight1337
Copy link
Member

DarkLight1337 commented Oct 9, 2024

@K-Mistele can you help look into the second issue?

@DarkLight1337
Copy link
Member

@njhill @robertgshaw2-neuralmagic the first issue is another case where the real exception cannot be seen from the stack trace.

@njhill
Copy link
Member

njhill commented Oct 15, 2024

@DarkLight1337 I'll try to take a look soon re the error suppression.

@robertgshaw2-neuralmagic
Copy link
Collaborator

@njhill - took a quick look into these issues. Basically I think if we raise an error / exception anywhere outside the LLMEngine class, we are not propagating the full stack trace back (since we are just sending the exception itself over zmq)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

5 participants