Home / File/ test_find_similar_tool.py — langchain Source File

test_find_similar_tool.py — langchain Source File

Architecture documentation for test_find_similar_tool.py, a python file in the langchain codebase. 1 imports, 0 dependents.

Entity Profile

Dependency Diagram

graph LR
  e4381db7_18a3_24fb_15bc_56305dbae8df["test_find_similar_tool.py"]
  a6947a84_a966_127d_d3a6_ed52b7ab3656["langchain_exa"]
  e4381db7_18a3_24fb_15bc_56305dbae8df --> a6947a84_a966_127d_d3a6_ed52b7ab3656
  style e4381db7_18a3_24fb_15bc_56305dbae8df fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

"""Integration tests for Exa find similar tool."""

from langchain_exa import (
    ExaFindSimilarResults,  # type: ignore[import-not-found, import-not-found]
)


def test_similarity_tool() -> None:
    """Test that the Exa find similar tool works."""
    tool = ExaFindSimilarResults()
    res = tool.invoke(
        {
            "url": "https://boutiquejapan.com/when-is-the-best-time-of-year-to-visit-japan/",
            "num_results": 5,
        }
    )
    print(res)  # noqa: T201
    assert not isinstance(res, str)  # str means error for this tool

Subdomains

Dependencies

  • langchain_exa

Frequently Asked Questions

What does test_find_similar_tool.py do?
test_find_similar_tool.py is a source file in the langchain codebase, written in python. It belongs to the CoreAbstractions domain, RunnableInterface subdomain.
What functions are defined in test_find_similar_tool.py?
test_find_similar_tool.py defines 1 function(s): test_similarity_tool.
What does test_find_similar_tool.py depend on?
test_find_similar_tool.py imports 1 module(s): langchain_exa.
Where is test_find_similar_tool.py in the architecture?
test_find_similar_tool.py is located at libs/partners/exa/tests/integration_tests/test_find_similar_tool.py (domain: CoreAbstractions, subdomain: RunnableInterface, directory: libs/partners/exa/tests/integration_tests).

Analyze Your Own Codebase

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

Try Supermodel Free