mirror of
https://github.com/toeverything/AFFiNE.git
synced 2026-02-19 07:17:00 +08:00
feat(server): copilot session prompt query (#10479)
This commit is contained in:
@@ -5,7 +5,10 @@ query getCopilotSessions(
|
||||
) {
|
||||
currentUser {
|
||||
copilot(workspaceId: $workspaceId) {
|
||||
sessionIds(docId: $docId, options: $options)
|
||||
sessions(docId: $docId, options: $options) {
|
||||
id
|
||||
promptName
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -424,7 +424,10 @@ export const getCopilotSessionsQuery = {
|
||||
query getCopilotSessions($workspaceId: String!, $docId: String, $options: QueryChatSessionsInput) {
|
||||
currentUser {
|
||||
copilot(workspaceId: $workspaceId) {
|
||||
sessionIds(docId: $docId, options: $options)
|
||||
sessions(docId: $docId, options: $options) {
|
||||
id
|
||||
promptName
|
||||
}
|
||||
}
|
||||
}
|
||||
}`,
|
||||
|
||||
@@ -83,7 +83,7 @@ export interface Copilot {
|
||||
/** Get the quota of the user in the workspace */
|
||||
quota: CopilotQuota;
|
||||
/** Get the session list in the workspace */
|
||||
sessionIds: Array<Scalars['String']['output']>;
|
||||
sessions: Array<CopilotSessionType>;
|
||||
workspaceId: Maybe<Scalars['ID']['output']>;
|
||||
}
|
||||
|
||||
@@ -97,7 +97,7 @@ export interface CopilotHistoriesArgs {
|
||||
options?: InputMaybe<QueryChatHistoriesInput>;
|
||||
}
|
||||
|
||||
export interface CopilotSessionIdsArgs {
|
||||
export interface CopilotSessionsArgs {
|
||||
docId?: InputMaybe<Scalars['String']['input']>;
|
||||
options?: InputMaybe<QueryChatSessionsInput>;
|
||||
}
|
||||
@@ -259,6 +259,12 @@ export interface CopilotQuota {
|
||||
used: Scalars['SafeInt']['output'];
|
||||
}
|
||||
|
||||
export interface CopilotSessionType {
|
||||
__typename?: 'CopilotSessionType';
|
||||
id: Scalars['ID']['output'];
|
||||
promptName: Scalars['String']['output'];
|
||||
}
|
||||
|
||||
export interface CreateChatMessageInput {
|
||||
attachments?: InputMaybe<Array<Scalars['String']['input']>>;
|
||||
blobs?: InputMaybe<Array<Scalars['Upload']['input']>>;
|
||||
@@ -2236,7 +2242,14 @@ export type GetCopilotSessionsQuery = {
|
||||
__typename?: 'Query';
|
||||
currentUser: {
|
||||
__typename?: 'UserType';
|
||||
copilot: { __typename?: 'Copilot'; sessionIds: Array<string> };
|
||||
copilot: {
|
||||
__typename?: 'Copilot';
|
||||
sessions: Array<{
|
||||
__typename?: 'CopilotSessionType';
|
||||
id: string;
|
||||
promptName: string;
|
||||
}>;
|
||||
};
|
||||
} | null;
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user