主题
Live LLM 提及次数最高页面
POST /v3/ai_optimization/llm_mentions/top_mentioned_pages/live
本接口通过大语言模型(LLM)提及数据,按指定 target 统计被提及次数最高的页面,并返回页面级及多维度聚合指标。数据结果受平台、地区和语言参数影响。
- 请求方法:
POST - 接口路径:
/v3/ai_optimization/llm_mentions/top_mentioned_pages/live - 完整 URL:
https://api.seermartech.cn/v3/ai_optimization/llm_mentions/top_mentioned_pages/live
本接口支持 google(Google AI 概览)和 chat_gpt(ChatGPT)平台。每次请求只能 1 个任务,单个任务最多设置 10 个目标实体。接口当前最长执行时间约为 120 秒。
所有 POST 请求使用 UTF-8 编码的 JSON 格式,并将任务参数放顶层 JSON 数组中。平台限流以认证说明中的 30/60/120 次/分钟规则为准。
计费说明
本接口按任务计费。示例响应中的 cost 为容字段,人民币扣费以响应头 X-SeerMarTech-Charge-CNY 为准。
请求参数
目标参数
| 参数 | 类型 | 填 | 说明 |
|---|---|---|---|
target | array | 是 | 目标实体数组,最多 10 个对象。每个对象只能一个 domain 或一个 keyword。至少需要一个 search_filter 为 include 的域名实体或实体。 |
domain_entity | object | 否 | 目标域名实体。 |
domain | string | 条件填 | 目标域名。未指定 keyword 时填。最多 63 个字符;不得 https:// 和 www.。 |
search_filter | string | 否 | 目标筛选方式,可选值:include、exclude。默认值:include。 |
search_scope | array | 否 | 域名搜索范围,可选值:any、sources、search_results。默认值:any。设置为 search_results 时 chat_gpt 平台提供数据。 |
include_subdomains | boolean | 否 | 是否目标域名的子域名。默认值:false。 |
keyword_entity | object | 否 | 目标实体。 |
keyword | string | 条件填 | 目标。未指定 domain 时填,最多 250 个字符。 |
match_type | string | 否 | 匹类型,可选值:word_match、partial_match。默认值:word_match。 |
match_type 说明:
word_match:匹与种子对应的词组,可前后或的词。partial_match:匹中出现的或片段。
地区、语言和平台参数
| 参数 | 类型 | 填 | 说明 |
|---|---|---|---|
location_name | string | 否 | 搜索地区称。指定后无需指定 location_code。默认地区代码为 2840。 |
location_code | integer | 否 | 搜索地区代码。指定后无需指定 location_name。默认值:2840。 |
language_name | string | 否 | 搜索语言称。指定后无需指定 language_code。默认语言代码为 en。 |
language_code | string | 否 | 搜索语言代码。指定后无需指定 language_name。默认值:en。 |
platform | string | 否 | 目标平台,可选值:chat_gpt、google。未指定时返回两个平台的数据。 |
平台限制:
chat_gpt支持美国(United States、2840)。chat_gpt支持英语(English、en)。search_results搜索范围适用于chat_gpt。
聚合和筛选参数
| 参数 | 类型 | 填 | 说明 |
|---|---|---|---|
links_scope | string | 否 | 链接来源范围,用于提取域名并进行聚合。可选值:sources、search_results。默认值:sources。设置为 search_results 时 chat_gpt 平台提供数据。 |
filters | array | 否 | 聚合后的结果筛选条件,最多 8 个。多个条件之间使用逻辑运算符 and 或 or。 |
initial_dataset_filters | array | 否 | 聚合前应用于原始提及数据的筛选条件,最多 8 个,可减少参与聚合的数据行。 |
limit | integer | 否 | items 数组最多返回的结果数。取值范围:1–1000,默认值:100。 |
internal_list_limit | integer | 否 | 部数组最多返回的数,适用于 sources_domain、search_results_domain、brand_entities_title 和 brand_entities_category。取值范围:1–10,默认值:5。 |
order_by | array | 否 | 结果排序规则,最多设置 3 条。排序字段可使用与 filters 相同的字段,并以逗号指定排序方式:asc 或 desc。 |
offset | integer | 否 | 结果偏移量。默认值:0,最大值:1000000。例如设置为 10 时,前 10 条结果将被跳过。 |
include_pages | array | 否 | 返回指定页面。 |
exclude_pages | array | 否 | 排除指定页面,不在 items 中返回。 |
tag | string | 否 | 自定义任务标识,最多 255 个字符。该值会原样返回在响应任务的 data 对象中。 |
支持的筛选和排序运算符:
=、<>、in、not_in、like、not_like、ilike、not_ilike、match、not_match
like 和 not_like 支持使用 % 匹任意长度的字符串。
筛选条件示例:
json
[
["ai_search_volume", ">", 10],
"and",
["mentions", ">=", 5]
]请求示例
curl
bash
curl --location --request POST \
"https://api.seermartech.cn/v3/ai_optimization/llm_mentions/top_mentioned_pages/live" \
--header "Authorization: Bearer smt_live_YOUR_KEY" \
--header "Content-Type: application/json" \
--data-raw '[
{
"language_code": "en",
"location_code": 2840,
"platform": "chat_gpt",
"target": [
{
"keyword": "bmw",
"search_scope": ["answer"]
},
{
"keyword": "auto",
"search_scope": ["question"],
"match_type": "partial_match"
}
],
"links_scope": "sources",
"initial_dataset_filters": [
["ai_search_volume", ">", 10]
],
"limit": 5,
"internal_list_limit": 2,
"tag": "auto-llm-pages"
}
]'Python
python
import requests
url = "https://api.seermartech.cn/v3/ai_optimization/llm_mentions/top_mentioned_pages/live"
headers = {
"Authorization": "Bearer smt_live_YOUR_KEY",
"Content-Type": "application/json",
}
post_data = [
{
"language_code": "en",
"location_code": 2840,
"platform": "chat_gpt",
"target": [
{
"keyword": "bmw",
"search_scope": ["answer"],
},
{
"keyword": "auto",
"search_scope": ["question"],
"match_type": "partial_match",
},
],
"links_scope": "sources",
"initial_dataset_filters": [
["ai_search_volume", ">", 10],
],
"limit": 5,
"internal_list_limit": 2,
}
]
response = requests.post(url, headers=headers, json=post_data, timeout=150)
response.raise_for_status()
result = response.json()
if result.get("status_code") == 20000:
print(result)
else:
print(
f"请求失败:{result.get('status_code')} "
f"{result.get('status_message')}"
)TypeScript
typescript
import axios from "axios";
const response = await axios.post(
"https://api.seermartech.cn/v3/ai_optimization/llm_mentions/top_mentioned_pages/live",
[
{
language_code: "en",
location_code: 2840,
platform: "chat_gpt",
target: [
{
keyword: "bmw",
search_scope: ["answer"],
},
{
keyword: "auto",
search_scope: ["question"],
match_type: "partial_match",
},
],
links_scope: "sources",
initial_dataset_filters: [
["ai_search_volume", ">", 10],
],
limit: 5,
internal_list_limit: 2,
},
],
{
headers: {
Authorization: "Bearer smt_live_YOUR_KEY",
"Content-Type": "application/json",
},
timeout: 150000,
}
);
if (response.data.status_code === 20000) {
console.log(response.data);
} else {
console.error(
response.data.status_code,
response.data.status_message
);
}响应结构
接口返回 JSON 对象 tasks 数组。
顶层响应字段
| 字段 | 类型 | 说明 |
|---|---|---|
version | string | 当前 API 版本。 |
status_code | integer | 通用状态码。成功通常为 20000。 |
status_message | string | 通用状态说明。 |
time | string | 请求执行耗时,单位为秒。 |
cost | float | 平台原始 USD 成本兼容字段;人民币实扣以 X-SeerMarTech-Charge-CNY 为准。 |
tasks_count | integer | tasks 数组中的任务数量。 |
tasks_error | integer | 返回错误的任务数量。 |
tasks | array | 任务结果数组。 |
任务字段
| 字段 | 类型 | 说明 |
|---|---|---|
id | string | 任务唯一标识,UUID 格式。 |
status_code | integer | 任务状态码,通常在 10000–60000 范围。 |
status_message | string | 任务状态说明。 |
time | string | 任务执行耗时。 |
cost | float | 平台原始 USD 成本兼容字段;人民币实扣以 X-SeerMarTech-Charge-CNY 为准。 |
result_count | integer | result 数组中的数量。 |
path | array | 请求 API 路径。 |
data | object | 本次 POST 请求中提交的参数。 |
result | array | 结果数组。 |
结果字段
| 字段 | 类型 | 说明 |
|---|---|---|
total_count | integer | 与请求条件匹的结果总数。 |
offset | integer | items 中被跳过的结果数量。 |
items_count | integer | 本次 items 数组返回的结果数。 |
aggregated_metrics | object | 所有页面的聚合提及指标。 |
items | array | 被提及次数最高的页面明细。 |
aggregated_metrics 字段
aggregated_metrics 按不同维度汇总所有
实用场景
- 待补充具体业务场景