Skip to main content
Glama
xhh-im

TrendRadar

by xhh-im

analyze_topic_trend

Analyze topic trends by selecting analysis type: trend, lifecycle, viral, or predict. Specify date range and thresholds to gain insights on topic popularity changes.

Instructions

统一话题趋势分析工具 - 整合多种趋势分析模式

重要:日期范围处理 当用户使用"本周"、"最近7天"等自然语言时,请先调用 resolve_date_range 工具获取精确日期:

  1. 调用 resolve_date_range("本周") → 获取 {"start": "YYYY-MM-DD", "end": "YYYY-MM-DD"}

  2. 将返回的 date_range 传入本工具

Args: topic: 话题关键词(必需) analysis_type: 分析类型,可选值: - "trend": 热度趋势分析(追踪话题的热度变化) - "lifecycle": 生命周期分析(从出现到消失的完整周期) - "viral": 异常热度检测(识别突然爆火的话题) - "predict": 话题预测(预测未来可能的热点) date_range: 日期范围(trend和lifecycle模式),可选 - 格式: {"start": "YYYY-MM-DD", "end": "YYYY-MM-DD"} - 获取方式: 调用 resolve_date_range 工具解析自然语言日期 - 默认: 不指定时默认分析最近7天 granularity: 时间粒度(trend模式),默认"day"(仅支持 day,因为底层数据按天聚合) threshold: 热度突增倍数阈值(viral模式),默认3.0 time_window: 检测时间窗口小时数(viral模式),默认24 lookahead_hours: 预测未来小时数(predict模式),默认6 confidence_threshold: 置信度阈值(predict模式),默认0.7

Returns: JSON格式的趋势分析结果

Examples: 用户:"分析AI本周的趋势" 推荐调用流程: 1. resolve_date_range("本周") → {"date_range": {"start": "2025-11-18", "end": "2025-11-26"}} 2. analyze_topic_trend(topic="AI", date_range={"start": "2025-11-18", "end": "2025-11-26"})

用户:"看看特斯拉最近30天的热度"
推荐调用流程:
1. resolve_date_range("最近30天") → {"date_range": {"start": "2025-10-28", "end": "2025-11-26"}}
2. analyze_topic_trend(topic="特斯拉", analysis_type="lifecycle", date_range=...)

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
topicYes
thresholdNo
date_rangeNo
granularityNoday
time_windowNo
analysis_typeNotrend
lookahead_hoursNo
confidence_thresholdNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations present, so description carries full burden. It discloses behavioral traits: topic required, default date range (7 days), granularity limited to 'day', default values for viral and predict modes. Could mention more about output structure or error cases, but output schema exists to supplement.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Well-structured with sections, bold emphasis, bullet lists, and examples. Somewhat lengthy but every part serves a purpose. Could tighten the examples slightly.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Covers all parameters and provides usage context. With 8 parameters and no schema descriptions, it fills the gap well. Output schema exists, so return value explanation is less critical. Lacks error handling or edge case information.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Despite 0% schema coverage, the description thoroughly explains each parameter, including enum meanings, date_range format and default, granularity limitation, and mode-specific parameters. Adds significant value beyond the bare schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states it is a unified topic trend analysis tool that integrates multiple analysis modes (trend, lifecycle, viral, predict). It distinguishes itself from sibling tools like analyze_sentiment and search_news by focusing specifically on trend analysis of topics.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Provides explicit instructions for when to use this tool, including a prerequisite step to call resolve_date_range for natural language dates. Includes examples with recommended call flows, and implicitly guides when to use alternative analysis types via parameter descriptions.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/xhh-im/TrendRadar'

If you have feedback or need assistance with the MCP directory API, please join our Discord server