mirror of
https://github.com/langgenius/dify-docs.git
synced 2026-03-28 13:38:36 +07:00
101 lines
4.1 KiB
Plaintext
101 lines
4.1 KiB
Plaintext
---
|
||
title: モデルプラグイン
|
||
---
|
||
|
||
|
||
|
||
{/*
|
||
コントリビューター注:
|
||
----------------
|
||
これはレガシードキュメントであり、非推奨になります。
|
||
このバージョンに変更を加えないでください。
|
||
すべての更新は新しいバージョンに向けられるべきです:
|
||
/plugin-dev-ja/0411-model-plugin-introduction
|
||
*/}
|
||
|
||
<Card title="このドキュメントはまもなく非推奨になります" icon="circle-exclamation" href="/plugin-dev-ja/0411-model-plugin-introduction">
|
||
<p>ドキュメント再編の一環として、このページは段階的に廃止されます。</p>
|
||
|
||
<p><u><b>このカードをクリックして</b></u>、最新情報が含まれる更新版にリダイレクトしてください。</p>
|
||
|
||
<p>新しいドキュメントに不一致や改善が必要な箇所を見つけた場合は、ページ下部の「問題を報告」ボタンを使用してください。</p>
|
||
</Card>
|
||
|
||
モデルタイププラグインを導入することで、Difyプラットフォームは特定のモデルプロバイダーが提供するモデルを利用できるようになります。例えば、OpenAIモデルプラグインをインストールすると、DifyプラットフォームからOpenAIのGPT-4やGPT-4o-2024-05-13といったモデルをリクエストできるようになります。
|
||
|
||
### **モデルプラグインの構造**
|
||
|
||
プラグインモデルの開発に関する理解を深めるために、モデルタイププラグインの構造例を以下に示します。
|
||
|
||
* モデルプロバイダー:OpenAI、Anthropic、Googleなどの大規模モデル開発企業です。
|
||
* モデルカテゴリ:プロバイダーに応じて、大規模言語モデル(LLM)、テキスト埋め込みモデル、音声テキスト変換モデルなどがあります。
|
||
* 具体的なモデル:`claude-3-5-sonnet`、`gpt-4-turbo`など。
|
||
|
||
プラグインプロジェクトのコード構造:
|
||
|
||
```bash
|
||
- モデルプロバイダー
|
||
- モデルカテゴリ
|
||
- 具体的なモデル
|
||
```
|
||
|
||
Anthropicを例にとると、モデルプラグインの構造は次のようになります。
|
||
|
||
```bash
|
||
- Anthropic
|
||
- llm
|
||
claude-3-5-sonnet-20240620
|
||
claude-3-haiku-20240307
|
||
claude-3-opus-20240229
|
||
claude-3-sonnet-20240229
|
||
claude-instant-1.2
|
||
claude-instant-1
|
||
```
|
||
|
||
OpenAIを例にとると、複数のモデルタイプをサポートしています。
|
||
|
||
```bash
|
||
├── models
|
||
│ ├── llm
|
||
│ │ ├── chatgpt-4o-latest
|
||
│ │ ├── gpt-3.5-turbo
|
||
│ │ ├── gpt-4-0125-preview
|
||
│ │ ├── gpt-4-turbo
|
||
│ │ ├── gpt-4o
|
||
│ │ ├── llm
|
||
│ │ ├── o1-preview
|
||
│ │ └── text-davinci-003
|
||
│ ├── moderation
|
||
│ │ ├── moderation
|
||
│ │ └── text-moderation-stable
|
||
│ ├── speech2text
|
||
│ │ ├── speech2text
|
||
│ │ └── whisper-1
|
||
│ ├── text_embedding
|
||
│ │ ├── text-embedding-3-large
|
||
│ │ └── text_embedding
|
||
│ └── tts
|
||
│ ├── tts-1-hd
|
||
│ ├── tts-1
|
||
│ └── tts
|
||
```
|
||
|
||
### **モデルプラグイン作成の準備**
|
||
|
||
モデルプラグインを作成するには、以下の手順に従ってください。具体的な作成ガイドは、各ドキュメントのタイトルをクリックして参照してください。
|
||
|
||
1. [モデルプロバイダーの作成](/ja-jp/plugins/quick-start/develop-plugins/model-plugin/create-model-providers)
|
||
2. [事前定義済み](/ja-jp/guides/model-configuration/predefined-model)モデル、または[カスタム](/ja-jp/guides/model-configuration/customizable-model)モデルの統合
|
||
3. [モデルプラグインのデバッグ](/ja-jp/plugins/quick-start/debug-plugin)
|
||
|
||
{/*
|
||
Contributing Section
|
||
DO NOT edit this section!
|
||
It will be automatically generated by the script.
|
||
*/}
|
||
|
||
---
|
||
|
||
[このページを編集する](https://github.com/langgenius/dify-docs/edit/main/ja-jp/plugins/quick-start/develop-plugins/model-plugin/README.mdx) | [問題を報告する](https://github.com/langgenius/dify-docs/issues/new?template=docs.yml)
|
||
|