MCPcopy Create free account
hub / github.com/NVIDIA/TensorRT-LLM / is_llm_response

Function is_llm_response

tensorrt_llm/executor/utils.py:147–153  ·  view source on GitHub ↗
(instance)

Source from the content-addressed store, hash-verified

145
146
147def is_llm_response(instance):
148 # Duck typing, expect one of:
149 # tensorrt_llm.bindings.executor.Response
150 # tensorrt_llm._torch.pyexecutor.llm_request.LlmResponse
151 # Avoid testing for "result", because an error bindings.executor.Response
152 # throws when accessing its result property.
153 return hasattr(instance, "has_error")
154
155
156def print_alive_threads():

Callers 5

handle_single_inputMethod · 0.85
_handle_responseMethod · 0.85
process_resMethod · 0.85
_send_rspFunction · 0.85
process_resMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected