mirror of
https://github.com/toeverything/AFFiNE.git
synced 2026-02-14 21:27:20 +00:00
feat(core): add get session graphql api (#12237)
Close [AI-116](https://linear.app/affine-design/issue/AI-116) <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit - **New Features** - Added the ability to retrieve detailed information for a specific Copilot session by its ID, including model metadata and optional models, via the user interface and API. - Session data now includes additional fields such as the model used and a list of optional models. - Enhanced GraphQL queries and UI components to support fetching and displaying these new session details. - **Improvements** - Session lists now provide richer information, including model details, for each session. <!-- end of auto-generated comment: release notes by coderabbit.ai -->
This commit is contained in:
@@ -133,6 +133,9 @@ type Copilot {
|
||||
"""Get the quota of the user in the workspace"""
|
||||
quota: CopilotQuota!
|
||||
|
||||
"""Get the session by id"""
|
||||
session(sessionId: String!): CopilotSessionType!
|
||||
|
||||
"""Get the session id list in the workspace"""
|
||||
sessionIds(docId: String, options: QueryChatSessionsInput): [String!]! @deprecated(reason: "Use `sessions` instead")
|
||||
|
||||
@@ -318,6 +321,8 @@ type CopilotQuota {
|
||||
|
||||
type CopilotSessionType {
|
||||
id: ID!
|
||||
model: String!
|
||||
optionalModels: [String!]!
|
||||
parentSessionId: ID
|
||||
promptName: String!
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user