tavily-search

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

tavily search

Tavily 搜索

Web search returning LLM-optimized results with content snippets and relevance scores.
网页搜索工具,返回经LLM优化的结果,包含内容片段和相关性评分。

Prerequisites

前提条件

Requires the Tavily CLI. See tavily-cli for install and auth setup.
Quick install:
curl -fsSL https://cli.tavily.com/install.sh | bash && tvly login
需要安装Tavily CLI。请查看tavily-cli了解安装和身份验证设置。
快速安装:
curl -fsSL https://cli.tavily.com/install.sh | bash && tvly login

When to use

使用场景

  • You need to find information on any topic
  • You don't have a specific URL yet
  • First step in the workflow: search → extract → map → crawl → research
  • 你需要查找任意主题的信息
  • 你还没有特定的URL
  • tavily-cli工作流的第一步:搜索 → 提取 → 映射 → 爬取 → 研究

Quick start

快速开始

bash
undefined
bash
undefined

Basic search

基础搜索

tvly search "your query" --json
tvly search "你的查询内容" --json

Advanced search with more results

高级搜索,获取更多结果

tvly search "quantum computing" --depth advanced --max-results 10 --json
tvly search "量子计算" --depth advanced --max-results 10 --json

Recent news

最新新闻

tvly search "AI news" --time-range week --topic news --json
tvly search "AI新闻" --time-range week --topic news --json

Domain-filtered

域名过滤搜索

tvly search "SEC filings" --include-domains sec.gov,reuters.com --json
tvly search "SEC文件" --include-domains sec.gov,reuters.com --json

Include full page content in results

在结果中包含完整页面内容

tvly search "react hooks tutorial" --include-raw-content --max-results 3 --json
undefined
tvly search "react hooks教程" --include-raw-content --max-results 3 --json
undefined

Options

选项

OptionDescription
--depth
ultra-fast
,
fast
,
basic
(default),
advanced
--max-results
Max results, 0-20 (default: 5)
--topic
general
(default),
news
,
finance
--time-range
day
,
week
,
month
,
year
--start-date
Results after date (YYYY-MM-DD)
--end-date
Results before date (YYYY-MM-DD)
--include-domains
Comma-separated domains to include
--exclude-domains
Comma-separated domains to exclude
--country
Boost results from country
--include-answer
Include AI answer (
basic
or
advanced
)
--include-raw-content
Include full page content (
markdown
or
text
)
--include-images
Include image results
--include-image-descriptions
Include AI image descriptions
--chunks-per-source
Chunks per source (advanced/fast depth only)
-o, --output
Save output to file
--json
Structured JSON output
选项描述
--depth
ultra-fast
fast
basic
(默认)、
advanced
--max-results
最大结果数,0-20(默认:5)
--topic
general
(默认)、
news
finance
--time-range
day
week
month
year
--start-date
结果的起始日期(YYYY-MM-DD)
--end-date
结果的结束日期(YYYY-MM-DD)
--include-domains
逗号分隔的需包含的域名
--exclude-domains
逗号分隔的需排除的域名
--country
优先展示指定国家的结果
--include-answer
包含AI生成的答案(
basic
advanced
--include-raw-content
包含完整页面内容(
markdown
text
--include-images
包含图片结果
--include-image-descriptions
包含AI生成的图片描述
--chunks-per-source
每个来源的内容块数(仅
advanced
/
fast
深度支持)
-o, --output
将输出保存到文件
--json
结构化JSON格式输出

Search depth

搜索深度

DepthSpeedRelevanceBest for
ultra-fast
FastestLowerReal-time chat, autocomplete
fast
FastGoodNeed chunks, latency matters
basic
MediumHighGeneral-purpose (default)
advanced
SlowerHighestPrecision, specific facts
深度速度相关性适用场景
ultra-fast
最快较低实时聊天、自动补全
fast
良好需要内容块、对延迟敏感的场景
basic
中等通用场景(默认)
advanced
较慢最高需要精准信息、特定事实的场景

Tips

小贴士

  • Keep queries under 400 characters — think search query, not prompt.
  • Break complex queries into sub-queries for better results.
  • Use
    --include-raw-content
    when you need full page text (saves a separate extract call).
  • Use
    --include-domains
    to focus on trusted sources.
  • Use
    --time-range
    for recent information.
  • Read from stdin:
    echo "query" | tvly search - --json
  • 保持查询内容在400字符以内——要像搜索关键词,而不是提示词。
  • 将复杂查询拆分为多个子查询以获得更好的结果。
  • **使用
    --include-raw-content
    **当你需要完整页面文本时(可省去单独的提取调用)。
  • **使用
    --include-domains
    **聚焦于可信来源。
  • **使用
    --time-range
    **获取最新信息。
  • 从标准输入读取查询:
    echo "查询内容" | tvly search - --json

See also

另请参阅

  • tavily-extract — extract content from specific URLs
  • tavily-research — comprehensive multi-source research
  • tavily-extract — 从特定URL提取内容
  • tavily-research — 多来源综合研究