mirror of
https://github.com/MindWorkAI/AI-Studio.git
synced 2026-10-12 23:13:48 +00:00
Classify broken document and presentation packages
This commit is contained in:
7 files changed
+103
-9
No files matched your search
@@ -32,6 +32,13 @@ public enum FileExtractionErrorCode
|
||||
FORMAT_DETECTION_FAILED,
|
||||
NOT_A_VALID_PDF,
|
||||
NOT_A_VALID_SPREADSHEET,
|
||||
|
||||
/// <summary>
|
||||
/// The package of a Word, OpenDocument, or presentation file is broken, e.g. a damaged
|
||||
/// archive or a missing part inside it.
|
||||
/// </summary>
|
||||
NOT_A_VALID_DOCUMENT,
|
||||
|
||||
PDFIUM_UNAVAILABLE,
|
||||
PDF_ENCRYPTED,
|
||||
PAGE_EXTRACTION_FAILED,
|
||||
|
||||
@@ -32,6 +32,7 @@ internal static class FileExtractionErrorCodeExtensions
|
||||
FileExtractionErrorCode.NOT_TEXT_CONTENT => true,
|
||||
FileExtractionErrorCode.NOT_A_VALID_PDF => true,
|
||||
FileExtractionErrorCode.NOT_A_VALID_SPREADSHEET => true,
|
||||
FileExtractionErrorCode.NOT_A_VALID_DOCUMENT => true,
|
||||
FileExtractionErrorCode.PDF_ENCRYPTED => true,
|
||||
FileExtractionErrorCode.FORMAT_DETECTION_FAILED => true,
|
||||
FileExtractionErrorCode.EXECUTABLE_REJECTED => true,
|
||||
@@ -65,6 +66,7 @@ internal static class FileExtractionErrorCodeExtensions
|
||||
FileExtractionErrorCode.NOT_TEXT_CONTENT => TB("Not a text file"),
|
||||
FileExtractionErrorCode.NOT_A_VALID_PDF => TB("Not a readable PDF"),
|
||||
FileExtractionErrorCode.NOT_A_VALID_SPREADSHEET => TB("Not a readable spreadsheet"),
|
||||
FileExtractionErrorCode.NOT_A_VALID_DOCUMENT => TB("Not a readable document"),
|
||||
FileExtractionErrorCode.PDF_ENCRYPTED => TB("Protected PDF"),
|
||||
FileExtractionErrorCode.FORMAT_DETECTION_FAILED => TB("Unknown file type"),
|
||||
FileExtractionErrorCode.EXECUTABLE_REJECTED => TB("Executable program"),
|
||||
@@ -115,6 +117,7 @@ internal static class FileExtractionErrorCodeExtensions
|
||||
FileExtractionErrorCode.NOT_TEXT_CONTENT => TB("The file '{0}' is not a text file, so it was not indexed. Its content could not be read as text, which means it might have a wrong file extension. AI Studio reads it again as soon as the file changes."),
|
||||
FileExtractionErrorCode.NOT_A_VALID_PDF => TB("The file '{0}' is not a readable PDF, so it was not indexed. It might be damaged or transferred incompletely. AI Studio reads it again as soon as the file changes."),
|
||||
FileExtractionErrorCode.NOT_A_VALID_SPREADSHEET => TB("The file '{0}' is not a readable spreadsheet, so it was not indexed. It might be damaged or transferred incompletely. AI Studio reads it again as soon as the file changes."),
|
||||
FileExtractionErrorCode.NOT_A_VALID_DOCUMENT => TB("The file '{0}' is not a readable document, so it was not indexed. It might be damaged or transferred incompletely. AI Studio reads it again as soon as the file changes."),
|
||||
FileExtractionErrorCode.PDF_ENCRYPTED => TB("The file '{0}' is protected and could not be opened, so it was not indexed. AI Studio reads it again as soon as the file changes."),
|
||||
FileExtractionErrorCode.FORMAT_DETECTION_FAILED => TB("The file type of '{0}' could not be determined, so the file was not indexed. AI Studio reads it again as soon as the file changes."),
|
||||
FileExtractionErrorCode.EXECUTABLE_REJECTED => TB("The file '{0}' is an executable program and was not indexed, regardless of its file extension."),
|
||||
|
||||
@@ -78,6 +78,7 @@ internal static class FileExtractionResultExtensions
|
||||
FileExtractionErrorCode.TIMEOUT => TB("Reading the file '{0}' took too long and was stopped, so the file was not sent. When the file is stored on a network drive, the connection might be slow or interrupted."),
|
||||
FileExtractionErrorCode.NOT_A_VALID_PDF => TB("The file '{0}' is not a readable PDF and was not sent. It might be damaged or transferred incompletely."),
|
||||
FileExtractionErrorCode.NOT_A_VALID_SPREADSHEET => TB("The file '{0}' is not a readable spreadsheet and was not sent. It might be damaged or transferred incompletely."),
|
||||
FileExtractionErrorCode.NOT_A_VALID_DOCUMENT => TB("The file '{0}' is not a readable document and was not sent. It might be damaged or transferred incompletely."),
|
||||
FileExtractionErrorCode.PDF_ENCRYPTED => TB("The file '{0}' is protected and could not be opened, so it was not sent."),
|
||||
FileExtractionErrorCode.PDFIUM_UNAVAILABLE => TB("AI Studio was not able to start its PDF engine, so the file '{0}' was not sent."),
|
||||
FileExtractionErrorCode.PANDOC_UNAVAILABLE => TB("Reading the file '{0}' needs Pandoc, which is not available, so the file was not sent."),
|
||||
|
||||
Reference in new issue
Block a user