更新日志改进

回答分析降至 1 积分

API
回答分析从 2 积分降到 1 积分,旁边是一条 ChatGPT 回答的分析结果:Northwind 排名第一、Acme CRM 排名第二,两者都被推荐,引用网站分为 owned 和 reviews

开启 include.analysis 的回答任务,以原来一半的价格返回回答中每个品牌的排名、是否推荐和情感,以及每个引用网站的类型。

更新内容

  • 回答分析在引擎价格之上每个任务加 1 积分(原为 2 积分)。开启分析的 ChatGPT 回答共计 2 积分。
  • 引用网站的 kind 更细了。已知网站分为 editorial、review_media、pr_wire、reviews、commerce、social、blog、community、video 和 institution。其他网站会被分类一次,归为 brand、content 或上述类型之一,结果会重复使用。
  • 分析确认为品牌本名的拼写(例如 Kurly 的 컬리)会被保存,之后的回答按规则匹配。
  • CHATGPT、GEMINI、PERPLEXITY、GOOGLE、AIMODE、NAVER_AI_BRIEF 和 NAVER_AI_TAB 任务都支持分析。

工作原理

哪些名称是品牌、其中哪个是你的品牌,以及 recommended 和 sentiment,由模型判断。位置、排名、名称匹配和来源类型按规则计算,因此同样的判断得到同样的结果。

你的品牌和竞品按与监测相同的规则匹配名称和别名:拉丁字母按整词匹配,韩文、日文、中文和泰文在任意位置匹配。模型读取回答的前 40,000 个字符,分析会让任务晚几秒完成。

应用场景

  • 直接用 analysis.targets 计算所有问题的提及率、平均排名和声量份额。
  • 用 recommended 和 sentiment 比较各引擎如何谈论你的品牌和竞品。
  • 用 sources[].kind 查看引擎在你的领域引用哪些类型的网站,以及你的网站以 owned 出现在哪里。

发送请求

在 Authorization 请求头中带上 API 密钥发送请求。

curl -X POST https://api.querying.ai/v1/async/task \
  -H "Authorization: Bearer $QUERYING_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "taskType": "CHATGPT",
    "payload": {
      "prompt": "best CRM for a small team",
      "country": "US",
      "include": { "analysis": true },
      "brand": "Acme CRM",
      "brandAliases": ["Acme"],
      "brandDomains": ["acme-crm.example"],
      "competitors": [
        "Northwind",
        {
          "name": "Contoso CRM",
          "aliases": ["Contoso"],
          "domains": ["contoso-crm.example"]
        }
      ]
    }
  }'

请求字段

taskTypestring必填
要运行的引擎,例如 CHATGPT 或 GOOGLE。
payload.promptstring必填
按用户在聊天框中输入的方式写的问题,最多 100,000 个字符。
payload.countrystring
提问所在市场的两位国家代码,例如 US、KR、JP。默认 US。
payload.include.analysisboolean必填
设为 true 会附带 analysis:回答提到的每个品牌的排名、是否推荐、情感,以及每个引用网站的类型。在引擎价格之上加 1 积分。
payload.brandstring
你的品牌名称,最多 200 个字符,以角色 brand 出现在 analysis.targets 中。
payload.brandAliasesarray
回答可能用来称呼你品牌的其他名称,最多 20 个,需与 brand 一起使用。
payload.brandDomainsarray
你的网站,最多 20 个,例如 acme-crm.example。来自这些网站或其子域名的引用 kind 为 owned。需与 brand 一起使用。
payload.competitorsarray
竞品,最多 50 个。可只写名称,或写成 { name, aliases, domains },别名和域名各最多 20 个。以角色 competitor 出现在 analysis.targets 中。

响应

完成的任务如下所示,已截取部分内容。

JSON
{
  "success": true,
  "task": {
    "id": "…",
    "taskType": "CHATGPT",
    "status": "COMPLETED",
    "createdAt": "…"
  },
  "credits": { "creditsToCharge": 2, "creditsCharged": 2 },
  "response": {
    "text": "…",
    "analysis": {
      "version": 1,
      "status": "ok",
      "brands": [
        {
          "name": "Northwind",
          "rank": 1,
          "role": "competitor",
          "recommended": true,
          "sentiment": "positive",
          "sentimentScore": 0.9
        },
        {
          "name": "Acme CRM",
          "rank": 2,
          "role": "brand",
          "recommended": true,
          "sentiment": "positive",
          "sentimentScore": 0.5
        },
        {
          "name": "Fabrikam",
          "rank": 3,
          "role": null,
          "recommended": false,
          "sentiment": "neutral",
          "sentimentScore": 0
        }
      ],
      "targets": [
        {
          "name": "Acme CRM",
          "role": "brand",
          "mentioned": true,
          "rank": 2,
          "recommended": true,
          "sentiment": "positive",
          "sentimentScore": 0.5,
          "cited": true
        },
        {
          "name": "Northwind",
          "role": "competitor",
          "mentioned": true,
          "rank": 1,
          "recommended": true,
          "sentiment": "positive",
          "sentimentScore": 0.9,
          "cited": false
        },
        {
          "name": "Contoso CRM",
          "role": "competitor",
          "mentioned": false,
          "rank": null,
          "recommended": null,
          "sentiment": null,
          "sentimentScore": null,
          "cited": false
        }
      ],
      "sources": [
        {
          "position": 1,
          "url": "https://www.acme-crm.example/pricing",
          "domain": "acme-crm.example",
          "kind": "owned",
          "brand": "Acme CRM"
        },
        {
          "position": 2,
          "url": "https://www.g2.com/categories/crm",
          "domain": "g2.com",
          "kind": "reviews",
          "brand": null
        }
      ]
    }
  }
}
response.analysis.statusstring
分析已运行时为 ok;引擎没有返回回答文本时为 no_answer;分析无法运行时为 failed。仅 ok 时扣费。
response.analysis.brandsarray
回答提到的每个品牌,按首次提到的顺序排列。rank 从 1 开始,产品计入其制造商。每个品牌带有 recommended、sentiment 和 sentimentScore。
response.analysis.targetsarray
你发送的品牌,按你的顺序排列,每个带有 mentioned、在 brands 中的 rank,以及表示其域名是否被引用的 cited。
response.analysis.sources[].kindstring
每个引用网站的类型:owned 和 competitor 由你发送的域名决定,其余为 editorial、review_media、pr_wire、reviews、commerce、social、blog、community、video、institution、brand、content 或 other。

获取结果

请求会立即返回 status 为 QUEUED 的任务。用 GET /v1/async/task/{id} 轮询,直到 status 变为 COMPLETED 或 FAILED;或者加上 webhook.url,在服务器上接收同样的 task、credits 和 response。任务结束后,结果保留 24 小时供查询。

curl https://api.querying.ai/v1/async/task/$TASK_ID \
  -H "Authorization: Bearer $QUERYING_API_KEY"

价格

任务在提交时为分析预留 1 积分,仅当 analysis.status 为 ok 时扣除。结果为 no_answer 或 failed 时会释放积分,任务照常带着回答完成。套餐和积分价格见 https://querying.ai/pricing 。

更多更新

接收最新消息

通过邮件接收产品更新。

RSS 订阅