Просмотр исходного кода

chore: improve conversation list and rename docs (#11187)

非法操作 4 месяцев назад
Родитель
Сommit
e576d32fb6

+ 17 - 12
web/app/components/develop/template/template_advanced_chat.en.mdx

@@ -648,16 +648,13 @@ Chat applications support session persistence, allowing previous chat history to
           Should be uniquely defined by the developer within the application.
       </Property>
       <Property name='last_id' type='string' key='last_id'>
-          The ID of the last record on the current page, default is null.
+          (Optional) The ID of the last record on the current page, default is null.
       </Property>
       <Property name='limit' type='int' key='limit'>
-          How many records to return in one request, default is the most recent 20 entries.
-      </Property>
-      <Property name='pinned' type='bool' key='pinned'>
-        Return only pinned conversations as `true`, only non-pinned as `false`
+          (Optional) How many records to return in one request, default is the most recent 20 entries. Maximum 100, minimum 1.
       </Property>
       <Property name='sort_by' type='string' key='sort_by'>
-        Sorting Field (Optional), Default: -updated_at (sorted in descending order by update time)
+        (Optional) Sorting Field, Default: -updated_at (sorted in descending order by update time)
         - Available Values: created_at, -created_at, updated_at, -updated_at
         - The symbol before the field represents the order or reverse, "-" represents reverse order.
       </Property>
@@ -668,8 +665,10 @@ Chat applications support session persistence, allowing previous chat history to
       - `id` (string) Conversation ID
       - `name` (string) Conversation name, by default, is generated by LLM.
       - `inputs` (array[object]) User input parameters.
+      - `status` (string) Conversation status
       - `introduction` (string) Introduction
       - `created_at` (timestamp) Creation timestamp, e.g., 1705395332
+      - `updated_at` (timestamp) Update timestamp, e.g., 1705395332
     - `has_more` (bool)
     - `limit` (int) Number of entries returned, if input exceeds system limit, system limit number is returned
 
@@ -699,7 +698,8 @@ Chat applications support session persistence, allowing previous chat history to
               "myName": "Lucy"
           },
           "status": "normal",
-          "created_at": 1679667915
+          "created_at": 1679667915,
+          "updated_at": 1679667915
         },
         {
           "id": "hSIhXBhNe8X1d8Et"
@@ -781,10 +781,10 @@ Chat applications support session persistence, allowing previous chat history to
 
     <Properties>
       <Property name='name' type='string' key='name'>
-          The name of the conversation. This parameter can be omitted if `auto_generate` is set to `true`.
+        (Optional) The name of the conversation. This parameter can be omitted if `auto_generate` is set to `true`.
       </Property>
       <Property name='auto_generate' type='bool' key='auto_generate'>
-        Automatically generate the title, default is `false`
+        (Optional) Automatically generate the title, default is `false`
       </Property>
       <Property name='user' type='string' key='user'>
         The user identifier, defined by the developer, must ensure uniqueness within the application.
@@ -794,13 +794,15 @@ Chat applications support session persistence, allowing previous chat history to
     ### Response
     - `id` (string) Conversation ID
     - `name` (string) Conversation name
-    - `inputs` array[object] User input parameters.
+    - `inputs` array[object] User input parameters
+    - `status` (string) Conversation status
     - `introduction` (string) Introduction
     - `created_at` (timestamp) Creation timestamp, e.g., 1705395332
+    - `updated_at` (timestamp) Update timestamp, e.g., 1705395332
   </Col>
   <Col sticky>
 
-    <CodeGroup title="Request" tag="POST" label="/conversations/:conversation_id/name" targetCode={`curl -X POST '${props.appDetail.api_base_url}/conversations/:conversation_id/name' \\\n--header 'Authorization: Bearer {api_key}' \\\n--header 'Content-Type: application/json' \\\n--data-raw '{ \n "name": "", \n "user": "abc-123"\n}'`}>
+    <CodeGroup title="Request" tag="POST" label="/conversations/:conversation_id/name" targetCode={`curl -X POST '${props.appDetail.api_base_url}/conversations/:conversation_id/name' \\\n--header 'Authorization: Bearer {api_key}' \\\n--header 'Content-Type: application/json' \\\n--data-raw '{ \n "name": "", \n "auto_generate": true, \n "user": "abc-123"\n}'`}>
 
     ```bash {{ title: 'cURL' }}
     curl -X POST '${props.appDetail.api_base_url}/conversations/{conversation_id}/name' \
@@ -808,6 +810,7 @@ Chat applications support session persistence, allowing previous chat history to
     --header 'Authorization: Bearer {api_key}' \
     --data-raw '{
         "name": "",
+        "auto_generate": true,
         "user": "abc-123"
     }'
     ```
@@ -820,8 +823,10 @@ Chat applications support session persistence, allowing previous chat history to
         "id": "cd78daf6-f9e4-4463-9ff2-54257230a0ce",
         "name": "Chat vs AI",
         "inputs": {},
+        "status": "normal",
         "introduction": "",
-        "created_at": 1705569238
+        "created_at": 1705569238,
+        "updated_at": 1705569238
     }
     ```
     </CodeGroup>

+ 16 - 12
web/app/components/develop/template/template_advanced_chat.ja.mdx

@@ -648,16 +648,13 @@ import { Row, Col, Properties, Property, Heading, SubProperty, Paragraph } from
           アプリケーション内で開発者によって一意に定義されるべきです。
       </Property>
       <Property name='last_id' type='string' key='last_id'>
-          現在のページの最後の記録のID、デフォルトはnullです。
+          (Optional)現在のページの最後の記録のID、デフォルトはnullです。
       </Property>
       <Property name='limit' type='int' key='limit'>
-          1回のリクエストで返す記録の数、デフォルトは最新の20件です。
-      </Property>
-      <Property name='pinned' type='bool' key='pinned'>
-        ピン留めされた会話のみを`true`として返し、非ピン留めを`false`として返します
+          (Optional)1回のリクエストで返す記録の数、デフォルトは最新の20件です。最大100、最小1。
       </Property>
       <Property name='sort_by' type='string' key='sort_by'>
-        ソートフィールド(オプション)、デフォルト:-updated_at(更新時間で降順にソート)
+        (Optional)ソートフィールド、デフォルト:-updated_at(更新時間で降順にソート)
         - 利用可能な値:created_at, -created_at, updated_at, -updated_at
         - フィールドの前の記号は順序または逆順を表し、"-"は逆順を表します。
       </Property>
@@ -670,6 +667,7 @@ import { Row, Col, Properties, Property, Heading, SubProperty, Paragraph } from
       - `inputs` (array[object]) ユーザー入力パラメータ。
       - `introduction` (string) 紹介
       - `created_at` (timestamp) 作成タイムスタンプ、例:1705395332
+      - `updated_at` (timestamp) 更新タイムスタンプ、例:1705395332
     - `has_more` (bool)
     - `limit` (int) 返されたエントリ数、入力がシステム制限を超える場合、システム制限数が返されます
 
@@ -699,7 +697,8 @@ import { Row, Col, Properties, Property, Heading, SubProperty, Paragraph } from
               "myName": "Lucy"
           },
           "status": "normal",
-          "created_at": 1679667915
+          "created_at": 1679667915,
+          "updated_at": 1679667915
         },
         {
           "id": "hSIhXBhNe8X1d8Et"
@@ -781,10 +780,10 @@ import { Row, Col, Properties, Property, Heading, SubProperty, Paragraph } from
 
     <Properties>
       <Property name='name' type='string' key='name'>
-          会話の名前。`auto_generate`が`true`に設定されている場合、このパラメータは省略できます。
+        (Optional)会話の名前。`auto_generate`が`true`に設定されている場合、このパラメータは省略できます。
       </Property>
       <Property name='auto_generate' type='bool' key='auto_generate'>
-        タイトルを自動生成、デフォルトは`false`
+        (Optional)タイトルを自動生成、デフォルトは`false`
       </Property>
       <Property name='user' type='string' key='user'>
         ユーザー識別子、開発者によって定義され、アプリケーション内で一意であることを保証しなければなりません。
@@ -794,13 +793,15 @@ import { Row, Col, Properties, Property, Heading, SubProperty, Paragraph } from
     ### 応答
     - `id` (string) 会話ID
     - `name` (string) 会話名
-    - `inputs` array[object] ユーザー入力パラメータ。
+    - `inputs` array[object] ユーザー入力パラメータ
+    - `status` (string) 会話状態
     - `introduction` (string) 紹介
     - `created_at` (timestamp) 作成タイムスタンプ、例:1705395332
+    - `updated_at` (timestamp) 更新タイムスタンプ、例:1705395332
   </Col>
   <Col sticky>
 
-    <CodeGroup title="リクエスト" tag="POST" label="/conversations/:conversation_id/name" targetCode={`curl -X POST '${props.appDetail.api_base_url}/conversations/:conversation_id/name' \\\n--header 'Authorization: Bearer {api_key}' \\\n--header 'Content-Type: application/json' \\\n--data-raw '{ \n "name": "", \n "user": "abc-123"\n}'`}>
+    <CodeGroup title="リクエスト" tag="POST" label="/conversations/:conversation_id/name" targetCode={`curl -X POST '${props.appDetail.api_base_url}/conversations/:conversation_id/name' \\\n--header 'Authorization: Bearer {api_key}' \\\n--header 'Content-Type: application/json' \\\n--data-raw '{ \n "name": "", \n "auto_generate": true, \n "user": "abc-123"\n}'`}>
 
     ```bash {{ title: 'cURL' }}
     curl -X POST '${props.appDetail.api_base_url}/conversations/{conversation_id}/name' \
@@ -808,6 +809,7 @@ import { Row, Col, Properties, Property, Heading, SubProperty, Paragraph } from
     --header 'Authorization: Bearer {api_key}' \
     --data-raw '{
         "name": "",
+        "auto_generate": true,
         "user": "abc-123"
     }'
     ```
@@ -820,8 +822,10 @@ import { Row, Col, Properties, Property, Heading, SubProperty, Paragraph } from
         "id": "cd78daf6-f9e4-4463-9ff2-54257230a0ce",
         "name": "チャット vs AI",
         "inputs": {},
+        "status": "normal",
         "introduction": "",
-        "created_at": 1705569238
+        "created_at": 1705569238,
+        "updated_at": 1705569238
     }
     ```
     </CodeGroup>

+ 22 - 13
web/app/components/develop/template/template_advanced_chat.zh.mdx

@@ -683,16 +683,13 @@ import { Row, Col, Properties, Property, Heading, SubProperty } from '../md.tsx'
         用户标识,由开发者定义规则,需保证用户标识在应用内唯一。
       </Property>
       <Property name='last_id' type='string' key='last_id'>
-        当前页最后面一条记录的 ID,默认 null
+        (选填)当前页最后面一条记录的 ID,默认 null
       </Property>
       <Property name='limit' type='int' key='limit'>
-        一次请求返回多少条记录
-      </Property>
-      <Property name='pinned' type='bool' key='pinned'>
-        只返回置顶 true,只返回非置顶 false
+        (选填)一次请求返回多少条记录,默认 20 条,最大 100 条,最小 1 条。
       </Property>
       <Property name='sort_by' type='string' key='sort_by'>
-        排序字段(选题),默认 -updated_at(按更新时间倒序排列)
+        (选填)排序字段,默认 -updated_at(按更新时间倒序排列)
         - 可选值:created_at, -created_at, updated_at, -updated_at
         - 字段前面的符号代表顺序或倒序,-代表倒序
       </Property>
@@ -703,8 +700,10 @@ import { Row, Col, Properties, Property, Heading, SubProperty } from '../md.tsx'
       - `id`  (string) 会话 ID
       - `name`  (string) 会话名称,默认由大语言模型生成。
       - `inputs` (array[object]) 用户输入参数。
+      - `status` (string) 会话状态
       - `introduction` (string) 开场白
       - `created_at` (timestamp) 创建时间
+      - `updated_at` (timestamp) 更新时间
     - `has_more` (bool)
     - `limit` (int) 返回条数,若传入超过系统限制,返回系统限制数量
 
@@ -734,7 +733,8 @@ import { Row, Col, Properties, Property, Heading, SubProperty } from '../md.tsx'
               "myName": "Lucy"
           },
           "status": "normal",
-          "created_at": 1679667915
+          "created_at": 1679667915,
+          "updated_at": 1679667915
         },
         {
           "id": "hSIhXBhNe8X1d8Et"
@@ -817,10 +817,10 @@ import { Row, Col, Properties, Property, Heading, SubProperty } from '../md.tsx'
 
     <Properties>
       <Property name='name' type='string' key='name'>
-        名称,若 `auto_generate` 为 `true` 时,该参数可不传。
+        (选填)名称,若 `auto_generate` 为 `true` 时,该参数可不传。
       </Property>
-      <Property name='auto_generate' type='string' key='auto_generate'>
-        自动生成标题,默认 false。
+      <Property name='auto_generate' type='bool' key='auto_generate'>
+        (选填)自动生成标题,默认 false。
       </Property>
       <Property name='user' type='string' key='user'>
         用户标识,由开发者定义规则,需保证用户标识在应用内唯一。
@@ -830,13 +830,15 @@ import { Row, Col, Properties, Property, Heading, SubProperty } from '../md.tsx'
     ### Response
     - `id`  (string) 会话 ID
     - `name`  (string) 会话名称
-    - `inputs` array[object] 用户输入参数。
+    - `inputs` array[object] 用户输入参数
+    - `status` (string) 会话状态
     - `introduction` (string) 开场白
     - `created_at` (timestamp) 创建时间
+    - `updated_at` (timestamp) 更新时间
   </Col>
   <Col sticky>
 
-    <CodeGroup title="Request" tag="POST" label="/conversations/:conversation_id/name" targetCode={`curl -X POST '${props.appDetail.api_base_url}/conversations/:conversation_id/name' \\\n--header 'Authorization: Bearer {api_key}' \\\n--header 'Content-Type: application/json' \\\n--data-raw '{ \n "name": "", \n "user": "abc-123"\n}'`}>
+    <CodeGroup title="Request" tag="POST" label="/conversations/:conversation_id/name" targetCode={`curl -X POST '${props.appDetail.api_base_url}/conversations/:conversation_id/name' \\\n--header 'Authorization: Bearer {api_key}' \\\n--header 'Content-Type: application/json' \\\n--data-raw '{ \n "name": "", \n "auto_generate": true, \n "user": "abc-123"\n}'`}>
 
     ```bash {{ title: 'cURL' }}
     curl -X POST '${props.appDetail.api_base_url}/conversations/{conversation_id}/name' \
@@ -844,6 +846,7 @@ import { Row, Col, Properties, Property, Heading, SubProperty } from '../md.tsx'
     --header 'Content-Type: application/json' \
     --data-raw '{
         "name": "",
+        "auto_generate": true,
         "user": "abc-123"
     }'
     ```
@@ -853,7 +856,13 @@ import { Row, Col, Properties, Property, Heading, SubProperty } from '../md.tsx'
     <CodeGroup title="Response">
     ```json {{ title: 'Response' }}
     {
-      "result": "success"
+      "id": "34d511d5-56de-4f16-a997-57b379508443",
+      "name": "hello",
+      "inputs": {},
+      "status": "normal",
+      "introduction": "",
+      "created_at": 1732731141,
+      "updated_at": 1732734510
     }
     ```
     </CodeGroup>

+ 17 - 12
web/app/components/develop/template/template_chat.en.mdx

@@ -682,16 +682,13 @@ Chat applications support session persistence, allowing previous chat history to
           Should be uniquely defined by the developer within the application.
       </Property>
       <Property name='last_id' type='string' key='last_id'>
-          The ID of the last record on the current page, default is null.
+          (Optional) The ID of the last record on the current page, default is null.
       </Property>
       <Property name='limit' type='int' key='limit'>
-          How many records to return in one request, default is the most recent 20 entries.
-      </Property>
-      <Property name='pinned' type='bool' key='pinned'>
-        Return only pinned conversations as `true`, only non-pinned as `false`
+          (Optional) How many records to return in one request, default is the most recent 20 entries. Maximum 100, minimum 1.
       </Property>
       <Property name='sort_by' type='string' key='sort_by'>
-        Sorting Field (Optional), Default: -updated_at (sorted in descending order by update time)
+        (Optional) Sorting Field, Default: -updated_at (sorted in descending order by update time)
         - Available Values: created_at, -created_at, updated_at, -updated_at
         - The symbol before the field represents the order or reverse, "-" represents reverse order.
       </Property>
@@ -702,8 +699,10 @@ Chat applications support session persistence, allowing previous chat history to
       - `id` (string) Conversation ID
       - `name` (string) Conversation name, by default, is a snippet of the first question asked by the user in the conversation.
       - `inputs` (array[object]) User input parameters.
+      - `status` (string) Conversation status
       - `introduction` (string) Introduction
       - `created_at` (timestamp) Creation timestamp, e.g., 1705395332
+      - `updated_at` (timestamp) Update timestamp, e.g., 1705395332
     - `has_more` (bool)
     - `limit` (int) Number of entries returned, if input exceeds system limit, system limit number is returned
 
@@ -733,7 +732,8 @@ Chat applications support session persistence, allowing previous chat history to
               "myName": "Lucy"
           },
           "status": "normal",
-          "created_at": 1679667915
+          "created_at": 1679667915,
+          "updated_at": 1679667915
         },
         {
           "id": "hSIhXBhNe8X1d8Et"
@@ -815,10 +815,10 @@ Chat applications support session persistence, allowing previous chat history to
 
     <Properties>
       <Property name='name' type='string' key='name'>
-          The name of the conversation. This parameter can be omitted if `auto_generate` is set to `true`.
+        (Optional) The name of the conversation. This parameter can be omitted if `auto_generate` is set to `true`.
       </Property>
       <Property name='auto_generate' type='bool' key='auto_generate'>
-        Automatically generate the title, default is `false`
+        (Optional) Automatically generate the title, default is `false`
       </Property>
       <Property name='user' type='string' key='user'>
         The user identifier, defined by the developer, must ensure uniqueness within the application.
@@ -828,13 +828,15 @@ Chat applications support session persistence, allowing previous chat history to
     ### Response
     - `id` (string) Conversation ID
     - `name` (string) Conversation name
-    - `inputs` array[object] User input parameters.
+    - `inputs` array[object] User input parameters
+    - `status` (string) Conversation status
     - `introduction` (string) Introduction
     - `created_at` (timestamp) Creation timestamp, e.g., 1705395332
+    - `updated_at` (timestamp) Update timestamp, e.g., 1705395332
   </Col>
   <Col sticky>
 
-    <CodeGroup title="Request" tag="POST" label="/conversations/:conversation_id/name" targetCode={`curl -X POST '${props.appDetail.api_base_url}/conversations/:conversation_id/name' \\\n--header 'Authorization: Bearer {api_key}' \\\n--header 'Content-Type: application/json' \\\n--data-raw '{ \n "name": "", \n "user": "abc-123"\n}'`}>
+    <CodeGroup title="Request" tag="POST" label="/conversations/:conversation_id/name" targetCode={`curl -X POST '${props.appDetail.api_base_url}/conversations/:conversation_id/name' \\\n--header 'Authorization: Bearer {api_key}' \\\n--header 'Content-Type: application/json' \\\n--data-raw '{ \n "name": "", \n "auto_generate": true, \n "user": "abc-123"\n}'`}>
 
     ```bash {{ title: 'cURL' }}
     curl -X POST '${props.appDetail.api_base_url}/conversations/{conversation_id}/name' \
@@ -842,6 +844,7 @@ Chat applications support session persistence, allowing previous chat history to
     --header 'Authorization: Bearer {api_key}' \
     --data-raw '{
         "name": "",
+        "auto_generate": true,
         "user": "abc-123"
     }'
     ```
@@ -854,8 +857,10 @@ Chat applications support session persistence, allowing previous chat history to
         "id": "cd78daf6-f9e4-4463-9ff2-54257230a0ce",
         "name": "Chat vs AI",
         "inputs": {},
+        "status": "normal",
         "introduction": "",
-        "created_at": 1705569238
+        "created_at": 1705569238,
+        "updated_at": 1705569238
     }
     ```
     </CodeGroup>

+ 15 - 12
web/app/components/develop/template/template_chat.ja.mdx

@@ -682,16 +682,13 @@ import { Row, Col, Properties, Property, Heading, SubProperty, Paragraph } from
           アプリケーション内で開発者によって一意に定義される必要があります。
       </Property>
       <Property name='last_id' type='string' key='last_id'>
-          現在のページの最後のレコードのID、デフォルトはnullです。
+          (Optional)現在のページの最後のレコードのID、デフォルトはnullです。
       </Property>
       <Property name='limit' type='int' key='limit'>
-          1回のリクエストで返すレコードの数、デフォルトは最新の20件です。
-      </Property>
-      <Property name='pinned' type='bool' key='pinned'>
-        ピン留めされた会話のみを`true`として返し、ピン留めされていないもののみを`false`として返します
+          (Optional)1回のリクエストで返すレコードの数、デフォルトは最新の20件です。最大100、最小1。
       </Property>
       <Property name='sort_by' type='string' key='sort_by'>
-        ソートフィールド(オプション)、デフォルト:-updated_at(更新時間で降順にソート)
+        (Optional)ソートフィールド、デフォルト:-updated_at(更新時間で降順にソート)
         - 利用可能な値:created_at, -created_at, updated_at, -updated_at
         - フィールドの前の記号は順序または逆順を表し、"-"は逆順を表します。
       </Property>
@@ -704,6 +701,7 @@ import { Row, Col, Properties, Property, Heading, SubProperty, Paragraph } from
       - `inputs` (array[object]) ユーザー入力パラメータ。
       - `introduction` (string) 紹介
       - `created_at` (timestamp) 作成タイムスタンプ、例:1705395332
+      - `updated_at` (timestamp) 更新タイムスタンプ、例:1705395332
     - `has_more` (bool)
     - `limit` (int) 返されたエントリの数、入力がシステム制限を超える場合、システム制限の数を返します
 
@@ -733,7 +731,8 @@ import { Row, Col, Properties, Property, Heading, SubProperty, Paragraph } from
               "myName": "Lucy"
           },
           "status": "normal",
-          "created_at": 1679667915
+          "created_at": 1679667915,
+          "updated_at": 1679667915
         },
         {
           "id": "hSIhXBhNe8X1d8Et"
@@ -815,10 +814,10 @@ import { Row, Col, Properties, Property, Heading, SubProperty, Paragraph } from
 
     <Properties>
       <Property name='name' type='string' key='name'>
-          会話の名前。このパラメータは、`auto_generate`が`true`に設定されている場合、省略できます。
+        (Optional)会話の名前。このパラメータは、`auto_generate`が`true`に設定されている場合、省略できます。
       </Property>
       <Property name='auto_generate' type='bool' key='auto_generate'>
-        タイトルを自動生成します。デフォルトは`false`です。
+        (Optional)タイトルを自動生成します。デフォルトは`false`です。
       </Property>
       <Property name='user' type='string' key='user'>
         ユーザー識別子、開発者によって定義され、アプリケーション内で一意である必要があります。
@@ -828,13 +827,15 @@ import { Row, Col, Properties, Property, Heading, SubProperty, Paragraph } from
     ### 応答
     - `id` (string) 会話ID
     - `name` (string) 会話名
-    - `inputs` array[object] ユーザー入力パラメータ。
+    - `inputs` array[object] ユーザー入力パラメータ
+    - `status` (string) 会話状態
     - `introduction` (string) 紹介
     - `created_at` (timestamp) 作成タイムスタンプ、例:1705395332
+    - `updated_at` (timestamp) 更新タイムスタンプ、例:1705395332
   </Col>
   <Col sticky>
 
-    <CodeGroup title="リクエスト" tag="POST" label="/conversations/:conversation_id/name" targetCode={`curl -X POST '${props.appDetail.api_base_url}/conversations/:conversation_id/name' \\\n--header 'Authorization: Bearer {api_key}' \\\n--header 'Content-Type: application/json' \\\n--data-raw '{ \n "name": "", \n "user": "abc-123"\n}'`}>
+    <CodeGroup title="リクエスト" tag="POST" label="/conversations/:conversation_id/name" targetCode={`curl -X POST '${props.appDetail.api_base_url}/conversations/:conversation_id/name' \\\n--header 'Authorization: Bearer {api_key}' \\\n--header 'Content-Type: application/json' \\\n--data-raw '{ \n "name": "", \n "auto_generate": true, \n "user": "abc-123"\n}'`}>
 
     ```bash {{ title: 'cURL' }}
     curl -X POST '${props.appDetail.api_base_url}/conversations/{conversation_id}/name' \
@@ -842,6 +843,7 @@ import { Row, Col, Properties, Property, Heading, SubProperty, Paragraph } from
     --header 'Authorization: Bearer {api_key}' \
     --data-raw '{
         "name": "",
+        "auto_generate": true,
         "user": "abc-123"
     }'
     ```
@@ -855,7 +857,8 @@ import { Row, Col, Properties, Property, Heading, SubProperty, Paragraph } from
         "name": "Chat vs AI",
         "inputs": {},
         "introduction": "",
-        "created_at": 1705569238
+        "created_at": 1705569238,
+        "updated_at": 1705569238
     }
     ```
     </CodeGroup>

+ 22 - 13
web/app/components/develop/template/template_chat.zh.mdx

@@ -697,16 +697,13 @@ import { Row, Col, Properties, Property, Heading, SubProperty } from '../md.tsx'
         用户标识,由开发者定义规则,需保证用户标识在应用内唯一。
       </Property>
       <Property name='last_id' type='string' key='last_id'>
-        当前页最后面一条记录的 ID,默认 null
+        (选填)当前页最后面一条记录的 ID,默认 null
       </Property>
       <Property name='limit' type='int' key='limit'>
-        一次请求返回多少条记录
-      </Property>
-      <Property name='pinned' type='bool' key='pinned'>
-        只返回置顶 true,只返回非置顶 false
+        (选填)一次请求返回多少条记录,默认 20 条,最大 100 条,最小 1 条。
       </Property>
       <Property name='sort_by' type='string' key='sort_by'>
-        排序字段(选题),默认 -updated_at(按更新时间倒序排列)
+        (选填)排序字段,默认 -updated_at(按更新时间倒序排列)
         - 可选值:created_at, -created_at, updated_at, -updated_at
         - 字段前面的符号代表顺序或倒序,-代表倒序
       </Property>
@@ -717,8 +714,10 @@ import { Row, Col, Properties, Property, Heading, SubProperty } from '../md.tsx'
       - `id`  (string) 会话 ID
       - `name`  (string) 会话名称,默认为会话中用户最开始问题的截取。
       - `inputs` (array[object]) 用户输入参数。
+      - `status` (string) 会话状态
       - `introduction` (string) 开场白
       - `created_at` (timestamp) 创建时间
+      - `updated_at` (timestamp) 更新时间
     - `has_more` (bool)
     - `limit` (int) 返回条数,若传入超过系统限制,返回系统限制数量
 
@@ -748,7 +747,8 @@ import { Row, Col, Properties, Property, Heading, SubProperty } from '../md.tsx'
               "myName": "Lucy"
           },
           "status": "normal",
-          "created_at": 1679667915
+          "created_at": 1679667915,
+          "updated_at": 1679667915
         },
         {
           "id": "hSIhXBhNe8X1d8Et"
@@ -831,10 +831,10 @@ import { Row, Col, Properties, Property, Heading, SubProperty } from '../md.tsx'
 
     <Properties>
       <Property name='name' type='string' key='name'>
-        名称,若 `auto_generate` 为 `true` 时,该参数可不传。
+        (选填)名称,若 `auto_generate` 为 `true` 时,该参数可不传。
       </Property>
-      <Property name='auto_generate' type='string' key='auto_generate'>
-        自动生成标题,默认 false。
+      <Property name='auto_generate' type='bool' key='auto_generate'>
+        (选填)自动生成标题,默认 false。
       </Property>
       <Property name='user' type='string' key='user'>
         用户标识,由开发者定义规则,需保证用户标识在应用内唯一。
@@ -844,13 +844,15 @@ import { Row, Col, Properties, Property, Heading, SubProperty } from '../md.tsx'
     ### Response
     - `id`  (string) 会话 ID
     - `name`  (string) 会话名称
-    - `inputs` array[object] 用户输入参数。
+    - `inputs` array[object] 用户输入参数
+    - `status` (string) 会话状态
     - `introduction` (string) 开场白
     - `created_at` (timestamp) 创建时间
+    - `updated_at` (timestamp) 更新时间
   </Col>
   <Col sticky>
 
-    <CodeGroup title="Request" tag="POST" label="/conversations/:conversation_id/name" targetCode={`curl -X POST '${props.appDetail.api_base_url}/conversations/:conversation_id/name' \\\n--header 'Authorization: Bearer {api_key}' \\\n--header 'Content-Type: application/json' \\\n--data-raw '{ \n "name": "", \n "user": "abc-123"\n}'`}>
+    <CodeGroup title="Request" tag="POST" label="/conversations/:conversation_id/name" targetCode={`curl -X POST '${props.appDetail.api_base_url}/conversations/:conversation_id/name' \\\n--header 'Authorization: Bearer {api_key}' \\\n--header 'Content-Type: application/json' \\\n--data-raw '{ \n "name": "", \n "auto_generate": true, \n "user": "abc-123"\n}'`}>
 
     ```bash {{ title: 'cURL' }}
     curl -X POST '${props.appDetail.api_base_url}/conversations/{conversation_id}/name' \
@@ -858,6 +860,7 @@ import { Row, Col, Properties, Property, Heading, SubProperty } from '../md.tsx'
     --header 'Content-Type: application/json' \
     --data-raw '{
         "name": "",
+        "auto_generate": true,
         "user": "abc-123"
     }'
     ```
@@ -867,7 +870,13 @@ import { Row, Col, Properties, Property, Heading, SubProperty } from '../md.tsx'
     <CodeGroup title="Response">
     ```json {{ title: 'Response' }}
     {
-      "result": "success"
+      "id": "34d511d5-56de-4f16-a997-57b379508443",
+      "name": "hello",
+      "inputs": {},
+      "status": "normal",
+      "introduction": "",
+      "created_at": 1732731141,
+      "updated_at": 1732734510
     }
     ```
     </CodeGroup>