Help us understand the problem. What is going on with this article?

機械学習API群A3RTをPythonから使う

More than 1 year has passed since last update.

A3RT
テキストの分類や自動生成、画像のスコアリング、対話などができるようです。

現在使うことのできるAPIは以下のようです。
* Text Suggest API
* Text Classification API
* Listing API
* Image Influence API
* Proofreading API
* Talk API

Pythonで使用する

使用するライブラリ: pya3rt
https://github.com/nocotan/pya3rt

インストール

$ pip install pya3rt

サンプル

Text Suggest

# -*- coding: utf-8 -*-
import pya3rt

apikey = "{YOUR_API_KEY}"
client = pya3rt.TextSuggestClient(apikey)

print(client.text_suggest("馬"))
print(client.text_suggest("あき", style=1))
print(client.text_suggest("func", style=2))

Text Classification

# -*- coding: utf-8 -*-
import pya3rt

apikey = "{YOUR_API_KEY}"
client = pya3rt.TextClassificationClient(apikey)

print(client.classify("システムの企画から開発・運用まで幅広く関われます。"))

Proofreading API

# -*- coding: utf-8 -*-
import pya3rt

apikey = "{YOUR_API_KEY}"
client = pya3rt.ProofreadingClient(apikey)

print(client.proofreading("システムの企画から開発・運用まで幅広く関われます。"))
print(client.proofreading("システムの規格から開発・運用まで幅広く関われます。"))

Image Influence API

# -*- coding: utf-8 -*-
import pya3rt

apikey = "{YOUR_API_KEY}"
client = pya3rt.ImageInfluenceClient(apikey)

print(client.get_upload_url())
print(client.meat_score("meat1.jpeg", 1))

Talk API

# -*- coding: utf-8 -*-
import pya3rt

apikey = "{YOUR_API_KEY}"
client = pya3rt.TalkClient(apikey)

print(client.talk("おはよう"))
Why not register and get more from Qiita?
  1. We will deliver articles that match you
    By following users and tags, you can catch up information on technical fields that you are interested in as a whole
  2. you can read useful information later efficiently
    By "stocking" the articles you like, you can search right away
Comments
No comments
Sign up for free and join this conversation.
If you already have a Qiita account
Why do not you register as a user and use Qiita more conveniently?
You need to log in to use this function. Qiita can be used more conveniently after logging in.
You seem to be reading articles frequently this month. Qiita can be used more conveniently after logging in.
  1. We will deliver articles that match you
    By following users and tags, you can catch up information on technical fields that you are interested in as a whole
  2. you can read useful information later efficiently
    By "stocking" the articles you like, you can search right away
ユーザーは見つかりませんでした