Google Cloud NLP
收藏Google Cloud NLP 数据集概述
基本信息
- 数据集名称:Google Cloud NLP
- 类别:Text Analysis
- 提供者:frequency404
- 订阅者数量:1
订阅计划
- BASIC:$0.00 / 月
- PRO:$10.00 / 月
- ULTRA:$100.00 / 月
- MEGA:$1,000.00 / 月
API 概述
Google Cloud Natural Language API — 使用 Google 强大的 NLP 模型理解文本。分析情感、提取实体和分类内容。适用于评论、社交媒体、客户反馈和内容分析。
使用此 API 的原因
- 情感分析 — 对文本进行评分,范围从 -1.0(负面)到 1.0(正面)
- 实体提取 — 识别人物、组织、地点、日期等
- 多语言支持 — 支持 10 多种语言
- 逐句分析 — 提供每个句子的情感得分
- 由 Google Cloud 驱动 — 企业级 NLP
端点
| 端点 | 描述 |
|---|---|
POST /nlp/sentiment |
分析文本情感 |
POST /nlp/entities |
从文本中提取命名实体 |
快速开始
Python 示例
python import requests
url = "https://google-cloud-nlp.p.rapidapi.com/nlp/sentiment" headers = { "x-rapidapi-key": "YOUR_RAPIDAPI_KEY", "x-rapidapi-host": "google-cloud-nlp.p.rapidapi.com", "Content-Type": "application/json" } payload = { "text": "This product is amazing! Best purchase Ive ever made." } response = requests.post(url, json=payload, headers=headers) data = response.json() print(f"Sentiment: {data[score]} (magnitude: {data[magnitude]})")
输出: Sentiment: 0.9 (magnitude: 1.8)
cURL 示例
bash curl -X POST "https://google-cloud-nlp.p.rapidapi.com/nlp/sentiment" -H "x-rapidapi-key: YOUR_RAPIDAPI_KEY" -H "Content-Type: application/json" -d {"text": "I love this product!"}
技术支持
- 提供者:NexaAPI (https://nexa-api.com) — 为开发人员提供经济实惠的 AI API。



