docs: finalize thread
This commit is contained in:
parent
31f16503c7
commit
2877f3234b
@ -263,7 +263,10 @@ paths:
|
||||
tags:
|
||||
- Threads
|
||||
summary: Create thread
|
||||
description: Create a thread
|
||||
description: |
|
||||
<a href = "https://platform.openai.com/docs/api-reference/threads/createThread"> <button style = "color: #388434"> OpenAI compatible </button></a>
|
||||
|
||||
Create a thread
|
||||
requestBody:
|
||||
required: false
|
||||
content:
|
||||
@ -303,7 +306,10 @@ paths:
|
||||
tags:
|
||||
- Threads
|
||||
summary: List threads
|
||||
description: Retrieves a list of all threads available in the system.
|
||||
description: |
|
||||
<span style = "color: #fec928"> Jan </span>
|
||||
|
||||
Retrieves a list of all threads available in the system.
|
||||
responses:
|
||||
"200":
|
||||
description: List of threads retrieved successfully
|
||||
@ -336,8 +342,11 @@ paths:
|
||||
operationId: getThread
|
||||
tags:
|
||||
- Threads
|
||||
summary: Get thread
|
||||
description: Retrieves detailed information about a specific thread using its thread_id.
|
||||
summary: Retrieve thread
|
||||
description: |
|
||||
<a href = "https://platform.openai.com/docs/api-reference/threads/getThread"> <button style = "color: #388434"> OpenAI compatible </button></a>
|
||||
|
||||
Retrieves detailed information about a specific thread using its thread_id.
|
||||
parameters:
|
||||
- in: path
|
||||
name: thread_id
|
||||
@ -345,7 +354,10 @@ paths:
|
||||
schema:
|
||||
type: string
|
||||
example: thread_abc123
|
||||
description: The ID of the thread to retrieve.
|
||||
description: |
|
||||
The ID of the thread to retrieve.
|
||||
|
||||
<span style="color:#388434">OpenAI compatible</span>
|
||||
responses:
|
||||
"200":
|
||||
description: Thread details retrieved successfully
|
||||
@ -362,7 +374,10 @@ paths:
|
||||
tags:
|
||||
- Threads
|
||||
summary: Modify thread
|
||||
description: Modifies a thread
|
||||
description: |
|
||||
<a href = "https://platform.openai.com/docs/api-reference/threads/modifyThread"> <button style = "color: #388434"> OpenAI compatible </button></a>
|
||||
|
||||
Modifies a thread
|
||||
parameters:
|
||||
- in: path
|
||||
name: thread_id
|
||||
@ -370,7 +385,10 @@ paths:
|
||||
schema:
|
||||
type: string
|
||||
example: thread_abc123
|
||||
description: The ID of the thread to be modified.
|
||||
description: |
|
||||
The ID of the thread to be modified.
|
||||
|
||||
<span style="color:#388434">OpenAI compatible</span>
|
||||
requestBody:
|
||||
required: false
|
||||
content:
|
||||
@ -411,7 +429,10 @@ paths:
|
||||
tags:
|
||||
- Threads
|
||||
summary: Delete thread
|
||||
description: Delete a thread
|
||||
description: |
|
||||
<a href = "https://platform.openai.com/docs/api-reference/threads/deleteThread"> <button style = "color: #388434"> OpenAI compatible </button></a>
|
||||
|
||||
Delete a thread
|
||||
parameters:
|
||||
- in: path
|
||||
name: thread_id
|
||||
@ -419,7 +440,10 @@ paths:
|
||||
schema:
|
||||
type: string
|
||||
example: thread_abc123
|
||||
description: The ID of the thread to be deleted.
|
||||
description: |
|
||||
The ID of the thread to be deleted.
|
||||
|
||||
<span style="color:#388434">OpenAI compatible</span>
|
||||
responses:
|
||||
"200":
|
||||
description: Thread deleted successfully
|
||||
@ -439,8 +463,10 @@ paths:
|
||||
tags:
|
||||
- Threads
|
||||
summary: Get Thread.Assistants
|
||||
description:
|
||||
- Can achieve this goal by calling Get thread API
|
||||
description: |
|
||||
<span style = "color: #fec928"> Jan </span>
|
||||
|
||||
Can achieve this goal by calling Get thread API
|
||||
parameters:
|
||||
- in: path
|
||||
name: thread_id
|
||||
@ -467,8 +493,10 @@ paths:
|
||||
tags:
|
||||
- Threads
|
||||
summary: Modify Thread.Assistants
|
||||
description:
|
||||
- Can achieve this goal by calling Modify Assistant API with thread.assistant[]
|
||||
description: |
|
||||
<span style = "color: #fec928"> Jan </span>
|
||||
|
||||
Can achieve this goal by calling Modify Assistant API with thread.assistant[]
|
||||
|
||||
/threads/{thread_id}/:
|
||||
get:
|
||||
@ -476,8 +504,10 @@ paths:
|
||||
tags:
|
||||
- Threads
|
||||
summary: List Thread.Messages
|
||||
description:
|
||||
- Can achieve this goal by calling Get Thread API
|
||||
description: |
|
||||
<span style = "color: #fec928"> Jan </span>
|
||||
|
||||
Can achieve this goal by calling Get Thread API
|
||||
parameters:
|
||||
- in: path
|
||||
name: thread_id
|
||||
@ -775,9 +805,13 @@ x-webhooks:
|
||||
post:
|
||||
summary: The thread object
|
||||
description: |
|
||||
- Each `thread` folder contains a `thread.json` file, which is a representation of a thread.
|
||||
- `thread.json` contains metadata and model parameter overrides.
|
||||
- There are no required fields.
|
||||
<a href = "https://platform.openai.com/docs/api-reference/threads/object"> <button style = "color: #388434"> OpenAI compatible </button></a> and <span style = "color: #fec928"> Jan </span>
|
||||
|
||||
Each `thread` folder contains a `thread.json` file, which is a representation of a thread.
|
||||
|
||||
`thread.json` contains metadata and model parameter overrides.
|
||||
|
||||
There are no required fields.
|
||||
|
||||
operationId: ThreadObject
|
||||
tags:
|
||||
|
||||
@ -5,47 +5,73 @@ components:
|
||||
properties:
|
||||
id:
|
||||
type: string
|
||||
description: "The identifier of the thread, defaults to foldername."
|
||||
description: |
|
||||
"The identifier of the thread, defaults to foldername."
|
||||
|
||||
<span style="color:#388434">OpenAI compatible</span>
|
||||
example: thread_....
|
||||
object:
|
||||
type: string
|
||||
description: "Type of the object, defaults to thread."
|
||||
description: |
|
||||
"Type of the object, defaults to thread."
|
||||
|
||||
<span style="color:#388434">OpenAI compatible</span>
|
||||
example: thread
|
||||
summary:
|
||||
title:
|
||||
type: string
|
||||
description: "A brief summary or description of the thread, defaults to an empty string."
|
||||
description: |
|
||||
"A brief summary or description of the thread, defaults to an empty string."
|
||||
|
||||
<span style = "color: #fec928"> Jan </span>
|
||||
example: "funny physics joke"
|
||||
assistants:
|
||||
type: array
|
||||
description: |
|
||||
<span style = "color: #fec928"> Jan </span>
|
||||
items:
|
||||
properties:
|
||||
assistant_id:
|
||||
type: string
|
||||
description: "List of assistants involved in the thread, defaults to [\"jan\"]."
|
||||
example: ["jan"]
|
||||
description: |
|
||||
The identifier of assistant, defaults to "jan"
|
||||
|
||||
<span style = "color: #fec928"> Jan </span>
|
||||
example: jan
|
||||
model:
|
||||
type: object
|
||||
properties:
|
||||
id:
|
||||
type: string
|
||||
description: |
|
||||
<span style = "color: #fec928"> Jan </span>
|
||||
example: ...
|
||||
settings:
|
||||
type: object
|
||||
description: |
|
||||
Defaults to and overrides assistant.json's "settings" (and if none, then model.json "settings")
|
||||
|
||||
<span style = "color: #fec928"> Jan </span>
|
||||
parameters:
|
||||
type: object
|
||||
description: |
|
||||
Defaults to and overrides assistant.json's "parameters" (and if none, then model.json "parameters")
|
||||
|
||||
<span style = "color: #fec928"> Jan </span>
|
||||
created:
|
||||
type: integer
|
||||
format: int64
|
||||
description: "Unix timestamp representing the creation time of the thread, defaults to file creation time."
|
||||
description: |
|
||||
"Unix timestamp representing the creation time of the thread, defaults to file creation time."
|
||||
|
||||
<span style="color:#388434">OpenAI compatible</span>
|
||||
example: 1231231
|
||||
metadata:
|
||||
type: object
|
||||
description: "Metadata associated with the thread, defaults to an empty object."
|
||||
description: |
|
||||
"Metadata associated with the thread, defaults to an empty object."
|
||||
|
||||
<span style="color:#388434">OpenAI compatible</span>
|
||||
example: {}
|
||||
messages:
|
||||
type: array
|
||||
description: "List of messages within the thread."
|
||||
items:
|
||||
type: string
|
||||
example: []
|
||||
model_id:
|
||||
type: string
|
||||
description: "Model identifier associated with the thread, defaults to assistant.model."
|
||||
example: "..."
|
||||
settings:
|
||||
type: object
|
||||
description: "Settings for the thread, defaults to and overrides assistant.settings."
|
||||
parameters:
|
||||
type: object
|
||||
description: "Parameters for the thread, defaults to and overrides assistant.settings."
|
||||
|
||||
GetThreadResponse:
|
||||
type: object
|
||||
@ -106,23 +132,33 @@ components:
|
||||
properties:
|
||||
role:
|
||||
type: string
|
||||
description: "Role of the sender, either 'user' or 'assistant'."
|
||||
description: |
|
||||
"Role of the sender, either 'user' or 'assistant'."
|
||||
|
||||
<span style="color:#388434">OpenAI compatible</span>
|
||||
enum: ["user", "assistant"]
|
||||
content:
|
||||
type: string
|
||||
description: "Text content of the message."
|
||||
description: |
|
||||
"Text content of the message."
|
||||
|
||||
<span style="color:#388434">OpenAI compatible</span>
|
||||
file_ids:
|
||||
type: array
|
||||
items:
|
||||
type: string
|
||||
description: "Array of file IDs associated with the message, if any."
|
||||
description: |
|
||||
"Array of file IDs associated with the message, if any."
|
||||
|
||||
<span style="color:#388434">OpenAI compatible</span>
|
||||
|
||||
ModifyThreadResponse:
|
||||
type: object
|
||||
properties:
|
||||
id:
|
||||
type: string
|
||||
description: "The identifier of the modified thread."
|
||||
description: |
|
||||
"The identifier of the modified thread."
|
||||
example: thread_abc123
|
||||
object:
|
||||
type: string
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user