Skip to main content

LlamaIndex Tools Integration: Valyu

This tool connects to Valyu and its Exchange Platform to easily enable your agent to search and get content from programmatically licensed proprietary content and the web using Valyu's deep search API.

To begin, you need to obtain an API key on the Valyu developer dashboard. You can also use the SDK without an API key by setting the VALYU_API_KEY environment variable.

Usage

Here's an example usage of the ValyuToolSpec.

# %pip install llama-index llama-index-core llama-index-tools-valyu

from llama_index.tools.valyu import ValyuToolSpec
from llama_index.core.agent.workflow import FunctionAgent
from llama_index.llms.openai import OpenAI
import os

valyu_tool = ValyuToolSpec(
    api_key=os.environ["VALYU_API_KEY"],
    max_price=100,  # default is 100
)
agent = FunctionAgent(
    tools=valyu_tool.to_tool_list(),
    llm=OpenAI(model="gpt-4.1"),
)

print(
    await agent.run(
        "What are the implications of using different volatility calculation methods (EWMA vs. GARCH) in Value at Risk (VaR) modeling for fixed income portfolios?"
    )
)

# You can also search directly with the new parameters
results = valyu_tool.search(
    query="artificial intelligence trends 2024",
    included_sources=[
        "arxiv.org",
        "nature.com",
    ],  # Only search academic sources
    response_length="medium",  # 50k characters per result
    max_num_results=3,
    relevance_threshold=0.5,
)

search: Search and retrieve relevant content from proprietary and public sources using Valyu's deep search. Supports filtering by:

  • Search type ("all", "proprietary", or "web")
  • Relevance threshold
  • Date ranges (start_date, end_date)
  • Source filtering (included_sources, excluded_sources)
  • Response length (integer for character count or preset values: "short" 25k, "medium" 50k, "large" 100k, "max" full content)

This loader is designed to be used as a way to load data as a Tool in a Agent.

Metadata

Release files for llama-index-tools-valyu 0.8.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for llama-index-tools-valyu 0.8.0
File Size Uploaded Provenance Actions
llama_index_tools_valyu-0.8.0.tar.gz 7.1 kB Without provenance Details for llama_index_tools_valyu-0.8.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for llama-index-tools-valyu 0.8.0
File Interpreter ABI Platform Actions
llama_index_tools_valyu-0.8.0-py3-none-any.whl Python 3 none any Details for llama_index_tools_valyu-0.8.0-py3-none-any.whl

Total release size: 15.2 kB

Release files / llama_index_tools_valyu-0.8.0.tar.gz

Download URL llama_index_tools_valyu-0.8.0.tar.gz
Size 7.1 kB
Tags Source
SHA-256 checksum
How to use checksums
05fb6c8bd9e09186f54f91e48179a3a8522da677b63a7606281ec84142261af8
BLAKE2b-256 checksum
How to use checksums
73492f2e6848e60ec63ab7b49f48bbe675ea9ad3ffcc488cc386be48d58c6bca
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.13.8 {"installer":{"name":"uv","version":"0.13.8","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"26.04","id":"resolute","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Release files / llama_index_tools_valyu-0.8.0-py3-none-any.whl

Download URL llama_index_tools_valyu-0.8.0-py3-none-any.whl
Size 8.1 kB
Tags Python 3
SHA-256 checksum
How to use checksums
6c723b79b9c3c7ae2368fe8350fd8ba6c578e1ece24b3810e3a21c52760222b7
BLAKE2b-256 checksum
How to use checksums
01420384d7d80da0740904af29906e325a6fe133c6a137870926f2bbc35cf6d9
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.13.8 {"installer":{"name":"uv","version":"0.13.8","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"26.04","id":"resolute","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Security for llama-index-tools-valyu 0.8.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page