Home / Function/ test_reasoning_effort_levels() — langchain Function Reference

test_reasoning_effort_levels() — langchain Function Reference

Architecture documentation for the test_reasoning_effort_levels() function in test_chat_models.py from the langchain codebase.

Entity Profile

Dependency Diagram

graph TD
  acb8b945_fcf2_7414_9164_fcad76b16eb8["test_reasoning_effort_levels()"]
  af57ae60_607e_c138_9ab0_fb8bb1c5916a["test_chat_models.py"]
  acb8b945_fcf2_7414_9164_fcad76b16eb8 -->|defined in| af57ae60_607e_c138_9ab0_fb8bb1c5916a
  style acb8b945_fcf2_7414_9164_fcad76b16eb8 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

libs/partners/groq/tests/integration_tests/test_chat_models.py lines 291–303

def test_reasoning_effort_levels(effort: str) -> None:
    """Test reasoning effort options for different levels."""
    # As of now, only the new gpt-oss models support `'low'`, `'medium'`, and `'high'`
    chat = ChatGroq(
        model=DEFAULT_MODEL_NAME,
        reasoning_effort=effort,
    )
    message = HumanMessage(content="What is the capital of France?")
    response = chat.invoke([message])
    assert isinstance(response, AIMessage)
    assert isinstance(response.content, str)
    assert len(response.content) > 0
    assert response.response_metadata.get("reasoning_effort") == effort

Domain

Subdomains

Frequently Asked Questions

What does test_reasoning_effort_levels() do?
test_reasoning_effort_levels() is a function in the langchain codebase, defined in libs/partners/groq/tests/integration_tests/test_chat_models.py.
Where is test_reasoning_effort_levels() defined?
test_reasoning_effort_levels() is defined in libs/partners/groq/tests/integration_tests/test_chat_models.py at line 291.

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free