diff --git a/web/app/components/base/features/types.ts b/web/app/components/base/features/types.ts
index 83f876383d..56bd7829ad 100644
--- a/web/app/components/base/features/types.ts
+++ b/web/app/components/base/features/types.ts
@@ -35,6 +35,22 @@ export type FileUpload = {
number_limits?: number
transfer_methods?: TransferMethod[]
}
+ document?: EnabledOrDisabled & {
+ number_limits?: number
+ transfer_methods?: TransferMethod[]
+ }
+ audio?: EnabledOrDisabled & {
+ number_limits?: number
+ transfer_methods?: TransferMethod[]
+ }
+ video?: EnabledOrDisabled & {
+ number_limits?: number
+ transfer_methods?: TransferMethod[]
+ }
+ custom?: EnabledOrDisabled & {
+ number_limits?: number
+ transfer_methods?: TransferMethod[]
+ }
allowed_file_types?: string[]
allowed_file_extensions?: string[]
allowed_file_upload_methods?: TransferMethod[]
diff --git a/web/app/components/develop/template/template.en.mdx b/web/app/components/develop/template/template.en.mdx
index f178645a8e..3fdb782628 100755
--- a/web/app/components/develop/template/template.en.mdx
+++ b/web/app/components/develop/template/template.en.mdx
@@ -580,11 +580,30 @@ The text generation application offers non-session support and is ideal for tran
- `default` (string) Default value
- `options` (array[string]) Option values
- `file_upload` (object) File upload configuration
- - `image` (object) Image settings
- Currently only supports image types: `png`, `jpg`, `jpeg`, `webp`, `gif`
- - `enabled` (bool) Whether it is enabled
- - `number_limits` (int) Image number limit, default is 3
- - `transfer_methods` (array[string]) List of transfer methods, remote_url, local_file, must choose one
+ - `document` (object) Document settings
+ Currently only supports document types: `txt`, `md`, `markdown`, `pdf`, `html`, `xlsx`, `xls`, `docx`, `csv`, `eml`, `msg`, `pptx`, `ppt`, `xml`, `epub`.
+ - `enabled` (bool) Whether it is enabled
+ - `number_limits` (int) Document number limit, default is 3
+ - `transfer_methods` (array[string]) List of transfer methods: `remote_url`, `local_file`. Must choose one.
+ - `image` (object) Image settings
+ Currently only supports image types: `png`, `jpg`, `jpeg`, `webp`, `gif`.
+ - `enabled` (bool) Whether it is enabled
+ - `number_limits` (int) Image number limit, default is 3
+ - `transfer_methods` (array[string]) List of transfer methods: `remote_url`, `local_file`. Must choose one.
+ - `audio` (object) Audio settings
+ Currently only supports audio types: `mp3`, `m4a`, `wav`, `webm`, `amr`.
+ - `enabled` (bool) Whether it is enabled
+ - `number_limits` (int) Audio number limit, default is 3
+ - `transfer_methods` (array[string]) List of transfer methods: `remote_url`, `local_file`. Must choose one.
+ - `video` (object) Video settings
+ Currently only supports video types: `mp4`, `mov`, `mpeg`, `mpga`.
+ - `enabled` (bool) Whether it is enabled
+ - `number_limits` (int) Video number limit, default is 3
+ - `transfer_methods` (array[string]) List of transfer methods: `remote_url`, `local_file`. Must choose one.
+ - `custom` (object) Custom settings
+ - `enabled` (bool) Whether it is enabled
+ - `number_limits` (int) Custom number limit, default is 3
+ - `transfer_methods` (array[string]) List of transfer methods: `remote_url`, `local_file`. Must choose one.
- `system_parameters` (object) System parameters
- `file_size_limit` (int) Document upload size limit (MB)
- `image_file_size_limit` (int) Image file upload size limit (MB)
diff --git a/web/app/components/develop/template/template.ja.mdx b/web/app/components/develop/template/template.ja.mdx
index 4dbefca8f8..238a921fb5 100755
--- a/web/app/components/develop/template/template.ja.mdx
+++ b/web/app/components/develop/template/template.ja.mdx
@@ -578,11 +578,30 @@ import { Row, Col, Properties, Property, Heading, SubProperty, Paragraph } from
- `default` (string) デフォルト値
- `options` (array[string]) オプション値
- `file_upload` (object) ファイルアップロード設定
- - `image` (object) 画像設定
- 現在は画像タイプのみ対応:`png`、`jpg`、`jpeg`、`webp`、`gif`
- - `enabled` (bool) 有効かどうか
- - `number_limits` (int) 画像数制限、デフォルトは3
- - `transfer_methods` (array[string]) 転送方法リスト、remote_url、local_file、いずれかを選択
+ - `document` (object) ドキュメント設定
+ 現在サポートされているドキュメントタイプ:`txt`, `md`, `markdown`, `pdf`, `html`, `xlsx`, `xls`, `docx`, `csv`, `eml`, `msg`, `pptx`, `ppt`, `xml`, `epub`。
+ - `enabled` (bool) 有効かどうか
+ - `number_limits` (int) ドキュメント数の上限。デフォルトは 3
+ - `transfer_methods` (array[string]) 転送方法リスト:`remote_url`, `local_file`。いずれかを選択する必要があります。
+ - `image` (object) 画像設定
+ 現在サポートされている画像タイプ:`png`, `jpg`, `jpeg`, `webp`, `gif`。
+ - `enabled` (bool) 有効かどうか
+ - `number_limits` (int) 画像数の上限。デフォルトは 3
+ - `transfer_methods` (array[string]) 転送方法リスト:`remote_url`, `local_file`。いずれかを選択する必要があります。
+ - `audio` (object) オーディオ設定
+ 現在サポートされているオーディオタイプ:`mp3`, `m4a`, `wav`, `webm`, `amr`。
+ - `enabled` (bool) 有効かどうか
+ - `number_limits` (int) オーディオ数の上限。デフォルトは 3
+ - `transfer_methods` (array[string]) 転送方法リスト:`remote_url`, `local_file`。いずれかを選択する必要があります。
+ - `video` (object) ビデオ設定
+ 現在サポートされているビデオタイプ:`mp4`, `mov`, `mpeg`, `mpga`。
+ - `enabled` (bool) 有効かどうか
+ - `number_limits` (int) ビデオ数の上限。デフォルトは 3
+ - `transfer_methods` (array[string]) 転送方法リスト:`remote_url`, `local_file`。いずれかを選択する必要があります。
+ - `custom` (object) カスタム設定
+ - `enabled` (bool) 有効かどうか
+ - `number_limits` (int) カスタム数の上限。デフォルトは 3
+ - `transfer_methods` (array[string]) 転送方法リスト:`remote_url`, `local_file`。いずれかを選択する必要があります。
- `system_parameters` (object) システムパラメータ
- `file_size_limit` (int) ドキュメントアップロードサイズ制限(MB)
- `image_file_size_limit` (int) 画像ファイルアップロードサイズ制限(MB)
diff --git a/web/app/components/develop/template/template.zh.mdx b/web/app/components/develop/template/template.zh.mdx
index 4af5a28050..a5eea3d193 100755
--- a/web/app/components/develop/template/template.zh.mdx
+++ b/web/app/components/develop/template/template.zh.mdx
@@ -552,11 +552,30 @@ import { Row, Col, Properties, Property, Heading, SubProperty } from '../md.tsx'
- `default` (string) 默认值
- `options` (array[string]) 选项值
- `file_upload` (object) 文件上传配置
- - `image` (object) 图片设置
- 当前仅支持图片类型:`png`, `jpg`, `jpeg`, `webp`, `gif`
- - `enabled` (bool) 是否开启
- - `number_limits` (int) 图片数量限制,默认 3
- - `transfer_methods` (array[string]) 传递方式列表,remote_url , local_file,必选一个
+ - `document` (object) 文档设置
+ 当前仅支持文档类型:`txt`, `md`, `markdown`, `pdf`, `html`, `xlsx`, `xls`, `docx`, `csv`, `eml`, `msg`, `pptx`, `ppt`, `xml`, `epub`。
+ - `enabled` (bool) 是否启用
+ - `number_limits` (int) 文档数量限制,默认为 3
+ - `transfer_methods` (array[string]) 传输方式列表:`remote_url`, `local_file`,必须选择一个。
+ - `image` (object) 图片设置
+ 当前仅支持图片类型:`png`, `jpg`, `jpeg`, `webp`, `gif`。
+ - `enabled` (bool) 是否启用
+ - `number_limits` (int) 图片数量限制,默认为 3
+ - `transfer_methods` (array[string]) 传输方式列表:`remote_url`, `local_file`,必须选择一个。
+ - `audio` (object) 音频设置
+ 当前仅支持音频类型:`mp3`, `m4a`, `wav`, `webm`, `amr`。
+ - `enabled` (bool) 是否启用
+ - `number_limits` (int) 音频数量限制,默认为 3
+ - `transfer_methods` (array[string]) 传输方式列表:`remote_url`, `local_file`,必须选择一个。
+ - `video` (object) 视频设置
+ 当前仅支持视频类型:`mp4`, `mov`, `mpeg`, `mpga`。
+ - `enabled` (bool) 是否启用
+ - `number_limits` (int) 视频数量限制,默认为 3
+ - `transfer_methods` (array[string]) 传输方式列表:`remote_url`, `local_file`,必须选择一个。
+ - `custom` (object) 自定义设置
+ - `enabled` (bool) 是否启用
+ - `number_limits` (int) 自定义数量限制,默认为 3
+ - `transfer_methods` (array[string]) 传输方式列表:`remote_url`, `local_file`,必须选择一个。
- `system_parameters` (object) 系统参数
- `file_size_limit` (int) 文档上传大小限制 (MB)
- `image_file_size_limit` (int) 图片文件上传大小限制(MB)
diff --git a/web/app/components/develop/template/template_advanced_chat.en.mdx b/web/app/components/develop/template/template_advanced_chat.en.mdx
index faecd3d1cd..adba404a64 100644
--- a/web/app/components/develop/template/template_advanced_chat.en.mdx
+++ b/web/app/components/develop/template/template_advanced_chat.en.mdx
@@ -1197,11 +1197,30 @@ Chat applications support session persistence, allowing previous chat history to
- `default` (string) Default value
- `options` (array[string]) Option values
- `file_upload` (object) File upload configuration
- - `image` (object) Image settings
- Currently only supports image types: `png`, `jpg`, `jpeg`, `webp`, `gif`
- - `enabled` (bool) Whether it is enabled
- - `number_limits` (int) Image number limit, default is 3
- - `transfer_methods` (array[string]) List of transfer methods, remote_url, local_file, must choose one
+ - `document` (object) Document settings
+ Currently only supports document types: `txt`, `md`, `markdown`, `pdf`, `html`, `xlsx`, `xls`, `docx`, `csv`, `eml`, `msg`, `pptx`, `ppt`, `xml`, `epub`.
+ - `enabled` (bool) Whether it is enabled
+ - `number_limits` (int) Document number limit, default is 3
+ - `transfer_methods` (array[string]) List of transfer methods: `remote_url`, `local_file`. Must choose one.
+ - `image` (object) Image settings
+ Currently only supports image types: `png`, `jpg`, `jpeg`, `webp`, `gif`.
+ - `enabled` (bool) Whether it is enabled
+ - `number_limits` (int) Image number limit, default is 3
+ - `transfer_methods` (array[string]) List of transfer methods: `remote_url`, `local_file`. Must choose one.
+ - `audio` (object) Audio settings
+ Currently only supports audio types: `mp3`, `m4a`, `wav`, `webm`, `amr`.
+ - `enabled` (bool) Whether it is enabled
+ - `number_limits` (int) Audio number limit, default is 3
+ - `transfer_methods` (array[string]) List of transfer methods: `remote_url`, `local_file`. Must choose one.
+ - `video` (object) Video settings
+ Currently only supports video types: `mp4`, `mov`, `mpeg`, `mpga`.
+ - `enabled` (bool) Whether it is enabled
+ - `number_limits` (int) Video number limit, default is 3
+ - `transfer_methods` (array[string]) List of transfer methods: `remote_url`, `local_file`. Must choose one.
+ - `custom` (object) Custom settings
+ - `enabled` (bool) Whether it is enabled
+ - `number_limits` (int) Custom number limit, default is 3
+ - `transfer_methods` (array[string]) List of transfer methods: `remote_url`, `local_file`. Must choose one.
- `system_parameters` (object) System parameters
- `file_size_limit` (int) Document upload size limit (MB)
- `image_file_size_limit` (int) Image file upload size limit (MB)
diff --git a/web/app/components/develop/template/template_advanced_chat.ja.mdx b/web/app/components/develop/template/template_advanced_chat.ja.mdx
index 5ce54a61d2..2e57d5e20c 100644
--- a/web/app/components/develop/template/template_advanced_chat.ja.mdx
+++ b/web/app/components/develop/template/template_advanced_chat.ja.mdx
@@ -1197,11 +1197,30 @@ import { Row, Col, Properties, Property, Heading, SubProperty, Paragraph } from
- `default` (string) デフォルト値
- `options` (array[string]) オプション値
- `file_upload` (object) ファイルアップロード設定
- - `image` (object) 画像設定
- 現在サポートされている画像タイプ:`png`, `jpg`, `jpeg`, `webp`, `gif`
- - `enabled` (bool) 有効かどうか
- - `number_limits` (int) 画像数の制限、デフォルトは3
- - `transfer_methods` (array[string]) 転送方法のリスト、remote_url, local_file、いずれかを選択する必要があります
+ - `document` (object) ドキュメント設定
+ 現在サポートされているドキュメントタイプ:`txt`, `md`, `markdown`, `pdf`, `html`, `xlsx`, `xls`, `docx`, `csv`, `eml`, `msg`, `pptx`, `ppt`, `xml`, `epub`。
+ - `enabled` (bool) 有効かどうか
+ - `number_limits` (int) ドキュメント数の上限。デフォルトは 3
+ - `transfer_methods` (array[string]) 転送方法リスト:`remote_url`, `local_file`。いずれかを選択する必要があります。
+ - `image` (object) 画像設定
+ 現在サポートされている画像タイプ:`png`, `jpg`, `jpeg`, `webp`, `gif`。
+ - `enabled` (bool) 有効かどうか
+ - `number_limits` (int) 画像数の上限。デフォルトは 3
+ - `transfer_methods` (array[string]) 転送方法リスト:`remote_url`, `local_file`。いずれかを選択する必要があります。
+ - `audio` (object) オーディオ設定
+ 現在サポートされているオーディオタイプ:`mp3`, `m4a`, `wav`, `webm`, `amr`。
+ - `enabled` (bool) 有効かどうか
+ - `number_limits` (int) オーディオ数の上限。デフォルトは 3
+ - `transfer_methods` (array[string]) 転送方法リスト:`remote_url`, `local_file`。いずれかを選択する必要があります。
+ - `video` (object) ビデオ設定
+ 現在サポートされているビデオタイプ:`mp4`, `mov`, `mpeg`, `mpga`。
+ - `enabled` (bool) 有効かどうか
+ - `number_limits` (int) ビデオ数の上限。デフォルトは 3
+ - `transfer_methods` (array[string]) 転送方法リスト:`remote_url`, `local_file`。いずれかを選択する必要があります。
+ - `custom` (object) カスタム設定
+ - `enabled` (bool) 有効かどうか
+ - `number_limits` (int) カスタム数の上限。デフォルトは 3
+ - `transfer_methods` (array[string]) 転送方法リスト:`remote_url`, `local_file`。いずれかを選択する必要があります。
- `system_parameters` (object) システムパラメータ
- `file_size_limit` (int) ドキュメントアップロードサイズ制限(MB)
- `image_file_size_limit` (int) 画像ファイルアップロードサイズ制限(MB)
diff --git a/web/app/components/develop/template/template_advanced_chat.zh.mdx b/web/app/components/develop/template/template_advanced_chat.zh.mdx
index 7a69ee60aa..8955396ad9 100755
--- a/web/app/components/develop/template/template_advanced_chat.zh.mdx
+++ b/web/app/components/develop/template/template_advanced_chat.zh.mdx
@@ -1229,11 +1229,30 @@ import { Row, Col, Properties, Property, Heading, SubProperty } from '../md.tsx'
- `default` (string) 默认值
- `options` (array[string]) 选项值
- `file_upload` (object) 文件上传配置
- - `image` (object) 图片设置
- 当前仅支持图片类型:`png`, `jpg`, `jpeg`, `webp`, `gif`
- - `enabled` (bool) 是否开启
- - `number_limits` (int) 图片数量限制,默认 3
- - `transfer_methods` (array[string]) 传递方式列表,remote_url , local_file,必选一个
+ - `document` (object) 文档设置
+ 当前仅支持文档类型:`txt`, `md`, `markdown`, `pdf`, `html`, `xlsx`, `xls`, `docx`, `csv`, `eml`, `msg`, `pptx`, `ppt`, `xml`, `epub`。
+ - `enabled` (bool) 是否启用
+ - `number_limits` (int) 文档数量限制,默认为 3
+ - `transfer_methods` (array[string]) 传输方式列表:`remote_url`, `local_file`,必须选择一个。
+ - `image` (object) 图片设置
+ 当前仅支持图片类型:`png`, `jpg`, `jpeg`, `webp`, `gif`。
+ - `enabled` (bool) 是否启用
+ - `number_limits` (int) 图片数量限制,默认为 3
+ - `transfer_methods` (array[string]) 传输方式列表:`remote_url`, `local_file`,必须选择一个。
+ - `audio` (object) 音频设置
+ 当前仅支持音频类型:`mp3`, `m4a`, `wav`, `webm`, `amr`。
+ - `enabled` (bool) 是否启用
+ - `number_limits` (int) 音频数量限制,默认为 3
+ - `transfer_methods` (array[string]) 传输方式列表:`remote_url`, `local_file`,必须选择一个。
+ - `video` (object) 视频设置
+ 当前仅支持视频类型:`mp4`, `mov`, `mpeg`, `mpga`。
+ - `enabled` (bool) 是否启用
+ - `number_limits` (int) 视频数量限制,默认为 3
+ - `transfer_methods` (array[string]) 传输方式列表:`remote_url`, `local_file`,必须选择一个。
+ - `custom` (object) 自定义设置
+ - `enabled` (bool) 是否启用
+ - `number_limits` (int) 自定义数量限制,默认为 3
+ - `transfer_methods` (array[string]) 传输方式列表:`remote_url`, `local_file`,必须选择一个。
- `system_parameters` (object) 系统参数
- `file_size_limit` (int) Document upload size limit (MB)
- `image_file_size_limit` (int) Image file upload size limit (MB)
diff --git a/web/app/components/develop/template/template_chat.en.mdx b/web/app/components/develop/template/template_chat.en.mdx
index c95471160e..73d1fa1b41 100644
--- a/web/app/components/develop/template/template_chat.en.mdx
+++ b/web/app/components/develop/template/template_chat.en.mdx
@@ -1234,11 +1234,30 @@ Chat applications support session persistence, allowing previous chat history to
- `default` (string) Default value
- `options` (array[string]) Option values
- `file_upload` (object) File upload configuration
- - `image` (object) Image settings
- Currently only supports image types: `png`, `jpg`, `jpeg`, `webp`, `gif`
- - `enabled` (bool) Whether it is enabled
- - `number_limits` (int) Image number limit, default is 3
- - `transfer_methods` (array[string]) List of transfer methods, remote_url, local_file, must choose one
+ - `document` (object) Document settings
+ Currently only supports document types: `txt`, `md`, `markdown`, `pdf`, `html`, `xlsx`, `xls`, `docx`, `csv`, `eml`, `msg`, `pptx`, `ppt`, `xml`, `epub`.
+ - `enabled` (bool) Whether it is enabled
+ - `number_limits` (int) Document number limit, default is 3
+ - `transfer_methods` (array[string]) List of transfer methods: `remote_url`, `local_file`. Must choose one.
+ - `image` (object) Image settings
+ Currently only supports image types: `png`, `jpg`, `jpeg`, `webp`, `gif`.
+ - `enabled` (bool) Whether it is enabled
+ - `number_limits` (int) Image number limit, default is 3
+ - `transfer_methods` (array[string]) List of transfer methods: `remote_url`, `local_file`. Must choose one.
+ - `audio` (object) Audio settings
+ Currently only supports audio types: `mp3`, `m4a`, `wav`, `webm`, `amr`.
+ - `enabled` (bool) Whether it is enabled
+ - `number_limits` (int) Audio number limit, default is 3
+ - `transfer_methods` (array[string]) List of transfer methods: `remote_url`, `local_file`. Must choose one.
+ - `video` (object) Video settings
+ Currently only supports video types: `mp4`, `mov`, `mpeg`, `mpga`.
+ - `enabled` (bool) Whether it is enabled
+ - `number_limits` (int) Video number limit, default is 3
+ - `transfer_methods` (array[string]) List of transfer methods: `remote_url`, `local_file`. Must choose one.
+ - `custom` (object) Custom settings
+ - `enabled` (bool) Whether it is enabled
+ - `number_limits` (int) Custom number limit, default is 3
+ - `transfer_methods` (array[string]) List of transfer methods: `remote_url`, `local_file`. Must choose one.
- `system_parameters` (object) System parameters
- `file_size_limit` (int) Document upload size limit (MB)
- `image_file_size_limit` (int) Image file upload size limit (MB)
diff --git a/web/app/components/develop/template/template_chat.ja.mdx b/web/app/components/develop/template/template_chat.ja.mdx
index 8368326e40..45c970a9f2 100644
--- a/web/app/components/develop/template/template_chat.ja.mdx
+++ b/web/app/components/develop/template/template_chat.ja.mdx
@@ -1224,12 +1224,31 @@ import { Row, Col, Properties, Property, Heading, SubProperty, Paragraph } from
- `required` (bool) 必須かどうか
- `default` (string) デフォルト値
- `options` (array[string]) オプション値
- - `file_upload` (object) ファイルアップロード構成
- - `image` (object) 画像設定
- 現在サポートされている画像タイプ:`png`, `jpg`, `jpeg`, `webp`, `gif`
- - `enabled` (bool) 有効かどうか
- - `number_limits` (int) 画像数の制限、デフォルトは3
- - `transfer_methods` (array[string]) 転送方法のリスト、remote_url, local_file、いずれかを選択する必要があります
+ - `file_upload` (object) ファイルアップロード設定
+ - `document` (object) ドキュメント設定
+ 現在サポートされているドキュメントタイプ:`txt`, `md`, `markdown`, `pdf`, `html`, `xlsx`, `xls`, `docx`, `csv`, `eml`, `msg`, `pptx`, `ppt`, `xml`, `epub`。
+ - `enabled` (bool) 有効かどうか
+ - `number_limits` (int) ドキュメント数の上限。デフォルトは 3
+ - `transfer_methods` (array[string]) 転送方法リスト:`remote_url`, `local_file`。いずれかを選択する必要があります。
+ - `image` (object) 画像設定
+ 現在サポートされている画像タイプ:`png`, `jpg`, `jpeg`, `webp`, `gif`。
+ - `enabled` (bool) 有効かどうか
+ - `number_limits` (int) 画像数の上限。デフォルトは 3
+ - `transfer_methods` (array[string]) 転送方法リスト:`remote_url`, `local_file`。いずれかを選択する必要があります。
+ - `audio` (object) オーディオ設定
+ 現在サポートされているオーディオタイプ:`mp3`, `m4a`, `wav`, `webm`, `amr`。
+ - `enabled` (bool) 有効かどうか
+ - `number_limits` (int) オーディオ数の上限。デフォルトは 3
+ - `transfer_methods` (array[string]) 転送方法リスト:`remote_url`, `local_file`。いずれかを選択する必要があります。
+ - `video` (object) ビデオ設定
+ 現在サポートされているビデオタイプ:`mp4`, `mov`, `mpeg`, `mpga`。
+ - `enabled` (bool) 有効かどうか
+ - `number_limits` (int) ビデオ数の上限。デフォルトは 3
+ - `transfer_methods` (array[string]) 転送方法リスト:`remote_url`, `local_file`。いずれかを選択する必要があります。
+ - `custom` (object) カスタム設定
+ - `enabled` (bool) 有効かどうか
+ - `number_limits` (int) カスタム数の上限。デフォルトは 3
+ - `transfer_methods` (array[string]) 転送方法リスト:`remote_url`, `local_file`。いずれかを選択する必要があります。
- `system_parameters` (object) システムパラメータ
- `file_size_limit` (int) ドキュメントアップロードサイズ制限(MB)
- `image_file_size_limit` (int) 画像ファイルアップロードサイズ制限(MB)
diff --git a/web/app/components/develop/template/template_chat.zh.mdx b/web/app/components/develop/template/template_chat.zh.mdx
index 325470ac62..8573408c36 100644
--- a/web/app/components/develop/template/template_chat.zh.mdx
+++ b/web/app/components/develop/template/template_chat.zh.mdx
@@ -1237,11 +1237,30 @@ import { Row, Col, Properties, Property, Heading, SubProperty } from '../md.tsx'
- `default` (string) 默认值
- `options` (array[string]) 选项值
- `file_upload` (object) 文件上传配置
- - `image` (object) 图片设置
- 当前仅支持图片类型:`png`, `jpg`, `jpeg`, `webp`, `gif`
- - `enabled` (bool) 是否开启
- - `number_limits` (int) 图片数量限制,默认 3
- - `transfer_methods` (array[string]) 传递方式列表,remote_url , local_file,必选一个
+ - `document` (object) 文档设置
+ 当前仅支持文档类型:`txt`, `md`, `markdown`, `pdf`, `html`, `xlsx`, `xls`, `docx`, `csv`, `eml`, `msg`, `pptx`, `ppt`, `xml`, `epub`。
+ - `enabled` (bool) 是否启用
+ - `number_limits` (int) 文档数量限制,默认为 3
+ - `transfer_methods` (array[string]) 传输方式列表:`remote_url`, `local_file`,必须选择一个。
+ - `image` (object) 图片设置
+ 当前仅支持图片类型:`png`, `jpg`, `jpeg`, `webp`, `gif`。
+ - `enabled` (bool) 是否启用
+ - `number_limits` (int) 图片数量限制,默认为 3
+ - `transfer_methods` (array[string]) 传输方式列表:`remote_url`, `local_file`,必须选择一个。
+ - `audio` (object) 音频设置
+ 当前仅支持音频类型:`mp3`, `m4a`, `wav`, `webm`, `amr`。
+ - `enabled` (bool) 是否启用
+ - `number_limits` (int) 音频数量限制,默认为 3
+ - `transfer_methods` (array[string]) 传输方式列表:`remote_url`, `local_file`,必须选择一个。
+ - `video` (object) 视频设置
+ 当前仅支持视频类型:`mp4`, `mov`, `mpeg`, `mpga`。
+ - `enabled` (bool) 是否启用
+ - `number_limits` (int) 视频数量限制,默认为 3
+ - `transfer_methods` (array[string]) 传输方式列表:`remote_url`, `local_file`,必须选择一个。
+ - `custom` (object) 自定义设置
+ - `enabled` (bool) 是否启用
+ - `number_limits` (int) 自定义数量限制,默认为 3
+ - `transfer_methods` (array[string]) 传输方式列表:`remote_url`, `local_file`,必须选择一个。
- `system_parameters` (object) 系统参数
- `file_size_limit` (int) 文档上传大小限制 (MB)
- `image_file_size_limit` (int) 图片文件上传大小限制(MB)
diff --git a/web/app/components/develop/template/template_workflow.en.mdx b/web/app/components/develop/template/template_workflow.en.mdx
index 77409c1284..23ff2bbb55 100644
--- a/web/app/components/develop/template/template_workflow.en.mdx
+++ b/web/app/components/develop/template/template_workflow.en.mdx
@@ -690,11 +690,30 @@ Workflow applications offers non-session support and is ideal for translation, a
- `default` (string) Default value
- `options` (array[string]) Option values
- `file_upload` (object) File upload configuration
- - `image` (object) Image settings
- Currently only supports image types: `png`, `jpg`, `jpeg`, `webp`, `gif`
- - `enabled` (bool) Whether it is enabled
- - `number_limits` (int) Image number limit, default is 3
- - `transfer_methods` (array[string]) List of transfer methods, remote_url, local_file, must choose one
+ - `document` (object) Document settings
+ Currently only supports document types: `txt`, `md`, `markdown`, `pdf`, `html`, `xlsx`, `xls`, `docx`, `csv`, `eml`, `msg`, `pptx`, `ppt`, `xml`, `epub`.
+ - `enabled` (bool) Whether it is enabled
+ - `number_limits` (int) Document number limit, default is 3
+ - `transfer_methods` (array[string]) List of transfer methods: `remote_url`, `local_file`. Must choose one.
+ - `image` (object) Image settings
+ Currently only supports image types: `png`, `jpg`, `jpeg`, `webp`, `gif`.
+ - `enabled` (bool) Whether it is enabled
+ - `number_limits` (int) Image number limit, default is 3
+ - `transfer_methods` (array[string]) List of transfer methods: `remote_url`, `local_file`. Must choose one.
+ - `audio` (object) Audio settings
+ Currently only supports audio types: `mp3`, `m4a`, `wav`, `webm`, `amr`.
+ - `enabled` (bool) Whether it is enabled
+ - `number_limits` (int) Audio number limit, default is 3
+ - `transfer_methods` (array[string]) List of transfer methods: `remote_url`, `local_file`. Must choose one.
+ - `video` (object) Video settings
+ Currently only supports video types: `mp4`, `mov`, `mpeg`, `mpga`.
+ - `enabled` (bool) Whether it is enabled
+ - `number_limits` (int) Video number limit, default is 3
+ - `transfer_methods` (array[string]) List of transfer methods: `remote_url`, `local_file`. Must choose one.
+ - `custom` (object) Custom settings
+ - `enabled` (bool) Whether it is enabled
+ - `number_limits` (int) Custom number limit, default is 3
+ - `transfer_methods` (array[string]) List of transfer methods: `remote_url`, `local_file`. Must choose one.
- `system_parameters` (object) System parameters
- `file_size_limit` (int) Document upload size limit (MB)
- `image_file_size_limit` (int) Image file upload size limit (MB)
diff --git a/web/app/components/develop/template/template_workflow.ja.mdx b/web/app/components/develop/template/template_workflow.ja.mdx
index a83e21aef7..287eb87f45 100644
--- a/web/app/components/develop/template/template_workflow.ja.mdx
+++ b/web/app/components/develop/template/template_workflow.ja.mdx
@@ -691,11 +691,30 @@ import { Row, Col, Properties, Property, Heading, SubProperty, Paragraph } from
- `default` (string) デフォルト値
- `options` (array[string]) オプション値
- `file_upload` (object) ファイルアップロード設定
- - `image` (object) 画像設定
- 現在サポートされている画像タイプのみ:`png`, `jpg`, `jpeg`, `webp`, `gif`
- - `enabled` (bool) 有効かどうか
- - `number_limits` (int) 画像数の制限、デフォルトは3
- - `transfer_methods` (array[string]) 転送方法のリスト、remote_url, local_file、いずれかを選択する必要があります
+ - `document` (object) ドキュメント設定
+ 現在サポートされているドキュメントタイプ:`txt`, `md`, `markdown`, `pdf`, `html`, `xlsx`, `xls`, `docx`, `csv`, `eml`, `msg`, `pptx`, `ppt`, `xml`, `epub`。
+ - `enabled` (bool) 有効かどうか
+ - `number_limits` (int) ドキュメント数の上限。デフォルトは 3
+ - `transfer_methods` (array[string]) 転送方法リスト:`remote_url`, `local_file`。いずれかを選択する必要があります。
+ - `image` (object) 画像設定
+ 現在サポートされている画像タイプ:`png`, `jpg`, `jpeg`, `webp`, `gif`。
+ - `enabled` (bool) 有効かどうか
+ - `number_limits` (int) 画像数の上限。デフォルトは 3
+ - `transfer_methods` (array[string]) 転送方法リスト:`remote_url`, `local_file`。いずれかを選択する必要があります。
+ - `audio` (object) オーディオ設定
+ 現在サポートされているオーディオタイプ:`mp3`, `m4a`, `wav`, `webm`, `amr`。
+ - `enabled` (bool) 有効かどうか
+ - `number_limits` (int) オーディオ数の上限。デフォルトは 3
+ - `transfer_methods` (array[string]) 転送方法リスト:`remote_url`, `local_file`。いずれかを選択する必要があります。
+ - `video` (object) ビデオ設定
+ 現在サポートされているビデオタイプ:`mp4`, `mov`, `mpeg`, `mpga`。
+ - `enabled` (bool) 有効かどうか
+ - `number_limits` (int) ビデオ数の上限。デフォルトは 3
+ - `transfer_methods` (array[string]) 転送方法リスト:`remote_url`, `local_file`。いずれかを選択する必要があります。
+ - `custom` (object) カスタム設定
+ - `enabled` (bool) 有効かどうか
+ - `number_limits` (int) カスタム数の上限。デフォルトは 3
+ - `transfer_methods` (array[string]) 転送方法リスト:`remote_url`, `local_file`。いずれかを選択する必要があります。
- `system_parameters` (object) システムパラメータ
- `file_size_limit` (int) ドキュメントアップロードサイズ制限(MB)
- `image_file_size_limit` (int) 画像ファイルアップロードサイズ制限(MB)
diff --git a/web/app/components/develop/template/template_workflow.zh.mdx b/web/app/components/develop/template/template_workflow.zh.mdx
index 42922610da..105eca0700 100644
--- a/web/app/components/develop/template/template_workflow.zh.mdx
+++ b/web/app/components/develop/template/template_workflow.zh.mdx
@@ -678,11 +678,30 @@ Workflow 应用无会话支持,适合用于翻译/文章写作/总结 AI 等
- `default` (string) 默认值
- `options` (array[string]) 选项值
- `file_upload` (object) 文件上传配置
- - `image` (object) 图片设置
- 当前仅支持图片类型:`png`, `jpg`, `jpeg`, `webp`, `gif`
- - `enabled` (bool) 是否开启
- - `number_limits` (int) 图片数量限制,默认 3
- - `transfer_methods` (array[string]) 传递方式列表,remote_url , local_file,必选一个
+ - `document` (object) 文档设置
+ 当前仅支持文档类型:`txt`, `md`, `markdown`, `pdf`, `html`, `xlsx`, `xls`, `docx`, `csv`, `eml`, `msg`, `pptx`, `ppt`, `xml`, `epub`。
+ - `enabled` (bool) 是否启用
+ - `number_limits` (int) 文档数量限制,默认为 3
+ - `transfer_methods` (array[string]) 传输方式列表:`remote_url`, `local_file`,必须选择一个。
+ - `image` (object) 图片设置
+ 当前仅支持图片类型:`png`, `jpg`, `jpeg`, `webp`, `gif`。
+ - `enabled` (bool) 是否启用
+ - `number_limits` (int) 图片数量限制,默认为 3
+ - `transfer_methods` (array[string]) 传输方式列表:`remote_url`, `local_file`,必须选择一个。
+ - `audio` (object) 音频设置
+ 当前仅支持音频类型:`mp3`, `m4a`, `wav`, `webm`, `amr`。
+ - `enabled` (bool) 是否启用
+ - `number_limits` (int) 音频数量限制,默认为 3
+ - `transfer_methods` (array[string]) 传输方式列表:`remote_url`, `local_file`,必须选择一个。
+ - `video` (object) 视频设置
+ 当前仅支持视频类型:`mp4`, `mov`, `mpeg`, `mpga`。
+ - `enabled` (bool) 是否启用
+ - `number_limits` (int) 视频数量限制,默认为 3
+ - `transfer_methods` (array[string]) 传输方式列表:`remote_url`, `local_file`,必须选择一个。
+ - `custom` (object) 自定义设置
+ - `enabled` (bool) 是否启用
+ - `number_limits` (int) 自定义数量限制,默认为 3
+ - `transfer_methods` (array[string]) 传输方式列表:`remote_url`, `local_file`,必须选择一个。
- `system_parameters` (object) 系统参数
- `file_size_limit` (int) 文档上传大小限制 (MB)
- `image_file_size_limit` (int) 图片文件上传大小限制(MB)
diff --git a/web/app/components/plugins/base/deprecation-notice.tsx b/web/app/components/plugins/base/deprecation-notice.tsx
new file mode 100644
index 0000000000..2366d31bac
--- /dev/null
+++ b/web/app/components/plugins/base/deprecation-notice.tsx
@@ -0,0 +1,105 @@
+import React, { useMemo } from 'react'
+import type { FC } from 'react'
+import Link from 'next/link'
+import cn from '@/utils/classnames'
+import { RiAlertFill } from '@remixicon/react'
+import { Trans } from 'react-i18next'
+import { snakeCase2CamelCase } from '@/utils/format'
+import { useMixedTranslation } from '../marketplace/hooks'
+
+type DeprecationNoticeProps = {
+ status: 'deleted' | 'active'
+ deprecatedReason: string
+ alternativePluginId: string
+ alternativePluginURL: string
+ locale?: string
+ className?: string
+ innerWrapperClassName?: string
+ iconWrapperClassName?: string
+ textClassName?: string
+}
+
+const i18nPrefix = 'plugin.detailPanel.deprecation'
+
+const DeprecationNotice: FC
= ({
+ status,
+ deprecatedReason,
+ alternativePluginId,
+ alternativePluginURL,
+ locale,
+ className,
+ innerWrapperClassName,
+ iconWrapperClassName,
+ textClassName,
+}) => {
+ const { t } = useMixedTranslation(locale)
+
+ const deprecatedReasonKey = useMemo(() => {
+ if (!deprecatedReason) return ''
+ return snakeCase2CamelCase(deprecatedReason)
+ }, [deprecatedReason])
+
+ // Check if the deprecatedReasonKey exists in i18n
+ const hasValidDeprecatedReason = useMemo(() => {
+ if (!deprecatedReason || !deprecatedReasonKey) return false
+
+ // Define valid reason keys that exist in i18n
+ const validReasonKeys = ['businessAdjustments', 'ownershipTransferred', 'noMaintainer']
+ return validReasonKeys.includes(deprecatedReasonKey)
+ }, [deprecatedReason, deprecatedReasonKey])
+
+ if (status !== 'deleted')
+ return null
+
+ return (
+
+
+
+
+
+
+
+ {
+ hasValidDeprecatedReason && alternativePluginId && (
+
+ ),
+ }}
+ values={{
+ deprecatedReason: t(`${i18nPrefix}.reason.${deprecatedReasonKey}`),
+ alternativePluginId,
+ }}
+ />
+ )
+ }
+ {
+ hasValidDeprecatedReason && !alternativePluginId && (
+
+ {t(`${i18nPrefix}.onlyReason`, { deprecatedReason: t(`${i18nPrefix}.reason.${deprecatedReasonKey}`) })}
+
+ )
+ }
+ {
+ !hasValidDeprecatedReason && (
+ {t(`${i18nPrefix}.noReason`)}
+ )
+ }
+
+
+
+ )
+}
+
+export default React.memo(DeprecationNotice)
diff --git a/web/app/components/plugins/marketplace/index.tsx b/web/app/components/plugins/marketplace/index.tsx
index 7a29556bda..d6189a92a1 100644
--- a/web/app/components/plugins/marketplace/index.tsx
+++ b/web/app/components/plugins/marketplace/index.tsx
@@ -6,7 +6,7 @@ import PluginTypeSwitch from './plugin-type-switch'
import ListWrapper from './list/list-wrapper'
import type { SearchParams } from './types'
import { getMarketplaceCollectionsAndPlugins } from './utils'
-import { TanstackQueryIniter } from '@/context/query-client'
+import { TanstackQueryInitializer } from '@/context/query-client'
type MarketplaceProps = {
locale: string
@@ -39,7 +39,7 @@ const Marketplace = async ({
}
return (
-
+
-
+
)
}
diff --git a/web/app/components/plugins/plugin-detail-panel/detail-header.tsx b/web/app/components/plugins/plugin-detail-panel/detail-header.tsx
index 124e133c2b..9c31a0b8e1 100644
--- a/web/app/components/plugins/plugin-detail-panel/detail-header.tsx
+++ b/web/app/components/plugins/plugin-detail-panel/detail-header.tsx
@@ -29,7 +29,7 @@ import Toast from '@/app/components/base/toast'
import { BoxSparkleFill } from '@/app/components/base/icons/src/vender/plugin'
import { Github } from '@/app/components/base/icons/src/public/common'
import { uninstallPlugin } from '@/service/plugins'
-import { useGetLanguage } from '@/context/i18n'
+import { useGetLanguage, useI18N } from '@/context/i18n'
import { useModalContext } from '@/context/modal-context'
import { useProviderContext } from '@/context/provider-context'
import { useInvalidateAllToolProviders } from '@/service/use-tools'
@@ -39,6 +39,7 @@ import { getMarketplaceUrl } from '@/utils/var'
import { PluginAuth } from '@/app/components/plugins/plugin-auth'
import { AuthCategory } from '@/app/components/plugins/plugin-auth'
import { useAllToolProviders } from '@/service/use-tools'
+import DeprecationNotice from '../base/deprecation-notice'
const i18nPrefix = 'plugin.action'
@@ -56,6 +57,7 @@ const DetailHeader = ({
const { t } = useTranslation()
const { theme } = useTheme()
const locale = useGetLanguage()
+ const { locale: currentLocale } = useI18N()
const { checkForUpdates, fetchReleases } = useGitHubReleases()
const { setShowUpdatePluginModal } = useModalContext()
const { refreshModelProviders } = useProviderContext()
@@ -70,6 +72,9 @@ const DetailHeader = ({
latest_version,
meta,
plugin_id,
+ status,
+ deprecated_reason,
+ alternative_plugin_id,
} = detail
const { author, category, name, label, description, icon, verified, tool } = detail.declaration
const isTool = category === PluginType.tool
@@ -98,7 +103,7 @@ const DetailHeader = ({
if (isFromGitHub)
return `https://github.com/${meta!.repo}`
if (isFromMarketplace)
- return getMarketplaceUrl(`/plugins/${author}/${name}`, { theme })
+ return getMarketplaceUrl(`/plugins/${author}/${name}`, { language: currentLocale, theme })
return ''
}, [author, isFromGitHub, isFromMarketplace, meta, name, theme])
@@ -272,6 +277,15 @@ const DetailHeader = ({