UnstructuredのAPIキー取得
以下のURLからアカウント登録を行なってAPIキーを取得してください。
https://unstructured.io/api-key-hosted
あとドキュメントはここ
https://docs.unstructured.io/api-reference/api-services/free-api
Difyの設定
環境変数に以下を追加してください。APIキーに関しては先ほど取得したものを使ってください。
docker-compose.yamlを使っている方はapiとworkerの下に配置するのです。
ETL_TYPE: Unstructured
UNSTRUCTURED_API_URL: https://api.unstructured.io/general/v0/general
UNSTRUCTURED_API_KEY: your-api-key
DifyETLとUnstructured ETLのサポート形式の違い
-
Unstructured ETL
ファイル解析のサポート形式:txt、markdown、md、pdf、html、htm、xlsx、xls、docx、csv、eml、msg、pptx、ppt、xml、epub
-
DIFY ETL
ファイル解析のサポート形式:txt、markdown、md、pdf、html、htm、xlsx、xls、docx、csv
ファイル解析のサポート形式の違いが出ていますね!Unstructuredの方がファイルの種類は多いですね。パワポとかもこれで行けるようになりますね!
ちなみにDifyのクラウド版はデフォルトでUnstructuredを使っているようです。
ちなみに私はUnstructuredで好きな機能はPDFからの画像切り抜き用のOCRです。
PDFを与えた時に表や図を一緒に切り抜いてくれれば最高なんですがね。。。
最後に
Xやってるので気になる方はフォローお願いします。
https://x.com/hudebakonosoto