test_invoke_streaming() — langchain Function Reference
Architecture documentation for the test_invoke_streaming() function in test_chat_models.py from the langchain codebase.
Entity Profile
Dependency Diagram
graph TD 5dfa3cc3_82a2_a427_3577_7ad1b3f91bd1["test_invoke_streaming()"] af57ae60_607e_c138_9ab0_fb8bb1c5916a["test_chat_models.py"] 5dfa3cc3_82a2_a427_3577_7ad1b3f91bd1 -->|defined in| af57ae60_607e_c138_9ab0_fb8bb1c5916a style 5dfa3cc3_82a2_a427_3577_7ad1b3f91bd1 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
libs/partners/groq/tests/integration_tests/test_chat_models.py lines 182–195
def test_invoke_streaming() -> None:
"""Test that streaming correctly invokes on_llm_new_token callback."""
callback_handler = FakeCallbackHandler()
chat = ChatGroq(
model=DEFAULT_MODEL_NAME,
max_tokens=2,
streaming=True,
temperature=0,
callbacks=[callback_handler],
)
message = HumanMessage(content="Welcome to the Groqetship")
response = chat.invoke([message])
assert callback_handler.llm_streams > 0
assert isinstance(response, BaseMessage)
Domain
Subdomains
Source
Frequently Asked Questions
What does test_invoke_streaming() do?
test_invoke_streaming() is a function in the langchain codebase, defined in libs/partners/groq/tests/integration_tests/test_chat_models.py.
Where is test_invoke_streaming() defined?
test_invoke_streaming() is defined in libs/partners/groq/tests/integration_tests/test_chat_models.py at line 182.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free