快速入门:使用文本分析客户端库Quickstart: Use the Text Analytics client library

从文本分析客户端库开始操作。Get started with the Text Analytics client library. 请按照以下步骤安装程序包并试用基本任务的示例代码。Follow these steps to install the package and try out the example code for basic tasks.

使用文本分析客户端库执行:Use the Text Analytics client library to perform:

  • 情绪分析Sentiment analysis
  • 语言检测Language detection
  • 实体识别Entity recognition
  • 关键短语提取Key phrase extraction

重要

  • 文本分析 API 的最新预览版本为 3.0-preview,这包括改进的情绪分析命名实体识别 (NER) 的公共预览版。The latest preview version of the Text Analytics API is 3.0-preview, which includes a public preview for improved Sentiment Analysis and Named Entity Recognition (NER). 最新稳定版本为 2.1The latest stable version is 2.1.
    • 确保只按所用版本的说明操作。Be sure to only follow the instructions for the version you are using.
  • 为了简单起见,本文中的代码使用了同步方法和不受保护的凭据存储。The code in this article uses synchronous methods and un-secured credentials storage for simplicity reasons. 对于生产方案,我们建议使用批处理的异步方法来提高性能和可伸缩性。For production scenarios, we recommend using the batched asynchronous methods for performance and scalability. 请参阅下面的参考文档。See the reference documentation below.

重要

  • 文本分析 API 的最新预览版本为 3.0-preview,这包括改进的情绪分析命名实体识别 (NER) 的公共预览版。The latest preview version of the Text Analytics API is 3.0-preview, which includes a public preview for improved Sentiment Analysis and Named Entity Recognition (NER). 最新稳定版本为 2.1The latest stable version is 2.1.
    • 确保只按所用版本的说明操作。Be sure to only follow the instructions for the version you are using.
  • 为了简单起见,本文中的代码使用了同步方法和不受保护的凭据存储。The code in this article uses synchronous methods and un-secured credentials storage for simplicity reasons. 对于生产方案,我们建议使用批处理的异步方法来提高性能和可伸缩性。For production scenarios, we recommend using the batched asynchronous methods for performance and scalability. 请参阅下面的参考文档。See the reference documentation below.

重要

  • 本快速入门适用于文本分析客户端库的 3.0-preview 版本,这包括改进的情绪分析命名实体识别 (NER) 的公共预览版。This quickstart is only for version 3.0-preview of the Text Analytics client library, which includes a public preview for improved Sentiment Analysis and Named Entity Recognition (NER).
    • 确保只按所用版本的说明操作。Be sure to only follow the instructions for the version you are using.
  • 为了简单起见,本文中的代码使用了同步方法和不受保护的凭据存储。The code in this article uses synchronous methods and un-secured credentials storage for simplicity reasons. 对于生产方案,我们建议使用批处理的异步方法来提高性能和可伸缩性。For production scenarios, we recommend using the batched asynchronous methods for performance and scalability. 请参阅下面的参考文档。See the reference documentation below.

重要

  • 文本分析 API 的最新预览版本为 3.0-preview,这包括改进的情绪分析命名实体识别 (NER) 的公共预览版。The latest preview version of the Text Analytics API is 3.0-preview, which includes a public preview for improved Sentiment Analysis and Named Entity Recognition (NER). 最新稳定版本为 2.1The latest stable version is 2.1.
    • 确保只按所用版本的说明操作。Be sure to only follow the instructions for the version you are using.
  • 为了简单起见,本文中的代码使用了同步方法和不受保护的凭据存储。The code in this article uses synchronous methods and un-secured credentials storage for simplicity reasons. 对于生产方案,我们建议使用批处理的异步方法来提高性能和可伸缩性。For production scenarios, we recommend using the batched asynchronous methods for performance and scalability. 请参阅下面的参考文档。See the reference documentation below.

其他语言支持Additional language support

如果已单击此选项卡,则可能看不到采用你偏好的编程语言的快速入门。If you've clicked this tab, you probably didn't see a quickstart in your favorite programming language. 别担心,我们提供了其他快速入门。Don't worry, we have additional quickstarts available. 使用表格查找适用于编程语言的示例。Use the table to find the right sample for your programming language.

语言Language 可用版本Available version
RubyRuby 版本 2.1Version 2.1
GoGo 版本 2.1Version 2.1

清理资源Clean up resources

如果想要清理并删除认知服务订阅,可以删除资源或资源组。If you want to clean up and remove a Cognitive Services subscription, you can delete the resource or resource group. 删除资源组同时也会删除与之相关联的任何其他资源。Deleting the resource group also deletes any other resources associated with it.

后续步骤Next steps