「Unity/ChatGPT」の版間の差分
提供: 初心者エンジニアの簡易メモ
| 行1: | 行1: | ||
| − | |||
| − | |||
==apiを取得する== | ==apiを取得する== | ||
#https://beta.openai.com/ でアカウントを作成 | #https://beta.openai.com/ でアカウントを作成 | ||
#"create new secret key"を押してAPIキーを作成する | #"create new secret key"を押してAPIキーを作成する | ||
| + | |||
| + | ==unityサンプル== | ||
| + | github: https://github.com/hexthedev/OpenAi-Api-Unity | ||
| + | |||
| + | ==サンプルを動作させる== | ||
| + | vi ~/.openai/auth.json | ||
| + | <pre> | ||
| + | { | ||
| + | "private_api_key":"<API_KEY>" | ||
| + | } | ||
| + | </pre> | ||
| + | "<API_KEY>"を、管理画面で取得した、APIキーで置換する。 | ||
==参考== | ==参考== | ||
https://techblog.kayac.com/2022-group-calendar-unity-openapi | https://techblog.kayac.com/2022-group-calendar-unity-openapi | ||
2023年1月28日 (土) 04:50時点における版
apiを取得する
- https://beta.openai.com/ でアカウントを作成
- "create new secret key"を押してAPIキーを作成する
unityサンプル
github: https://github.com/hexthedev/OpenAi-Api-Unity
サンプルを動作させる
vi ~/.openai/auth.json
{
"private_api_key":"<API_KEY>"
}
"<API_KEY>"を、管理画面で取得した、APIキーで置換する。
参考
https://techblog.kayac.com/2022-group-calendar-unity-openapi
