Home / Function/ test_model_params() — langchain Function Reference

test_model_params() — langchain Function Reference

Architecture documentation for the test_model_params() function in test_llms.py from the langchain codebase.

Entity Profile

Dependency Diagram

graph TD
  b6bee9f8_8ef9_574a_fd5d_5657255be69a["test_model_params()"]
  92c74082_b175_00d9_ee08_72212a280d77["test_llms.py"]
  b6bee9f8_8ef9_574a_fd5d_5657255be69a -->|defined in| 92c74082_b175_00d9_ee08_72212a280d77
  style b6bee9f8_8ef9_574a_fd5d_5657255be69a fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

libs/partners/ollama/tests/unit_tests/test_llms.py lines 16–33

def test_model_params() -> None:
    """Test standard tracing params"""
    llm = OllamaLLM(model=MODEL_NAME)
    ls_params = llm._get_ls_params()
    assert ls_params == {
        "ls_provider": "ollama",
        "ls_model_type": "llm",
        "ls_model_name": MODEL_NAME,
    }

    llm = OllamaLLM(model=MODEL_NAME, num_predict=3)
    ls_params = llm._get_ls_params()
    assert ls_params == {
        "ls_provider": "ollama",
        "ls_model_type": "llm",
        "ls_model_name": MODEL_NAME,
        "ls_max_tokens": 3,
    }

Domain

Subdomains

Frequently Asked Questions

What does test_model_params() do?
test_model_params() is a function in the langchain codebase, defined in libs/partners/ollama/tests/unit_tests/test_llms.py.
Where is test_model_params() defined?
test_model_params() is defined in libs/partners/ollama/tests/unit_tests/test_llms.py at line 16.

Analyze Your Own Codebase

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

Try Supermodel Free