feat(server): stop embedding in doc embedding disabled workspace (#11761)

fix AI-33
This commit is contained in:
darkskygit
2025-04-17 09:57:33 +00:00
parent e577bb7aa9
commit 570dc79e3d
8 changed files with 50 additions and 1 deletions

View File

@@ -759,6 +759,12 @@ export class CopilotFailedToMatchContext extends UserFriendlyError {
}
}
export class CopilotEmbeddingDisabled extends UserFriendlyError {
constructor(message?: string) {
super('action_forbidden', 'copilot_embedding_disabled', message);
}
}
export class CopilotEmbeddingUnavailable extends UserFriendlyError {
constructor(message?: string) {
super('action_forbidden', 'copilot_embedding_unavailable', message);
@@ -1037,6 +1043,7 @@ export enum ErrorNames {
COPILOT_CONTEXT_FILE_NOT_SUPPORTED,
COPILOT_FAILED_TO_MODIFY_CONTEXT,
COPILOT_FAILED_TO_MATCH_CONTEXT,
COPILOT_EMBEDDING_DISABLED,
COPILOT_EMBEDDING_UNAVAILABLE,
COPILOT_TRANSCRIPTION_JOB_EXISTS,
COPILOT_TRANSCRIPTION_JOB_NOT_FOUND,