export type ArtifactObject = { name: string; id: string; displayName: string; ownerName: string; creatorName: string; createTime: string; updateTime: string; size: number; contentType: string; isUploaded: boolean; objectExpireDays: number; lastModifiedTime?: string; deleteTime?: string; }; export type GetNamespaceObjectUploadURLRequest = { parent: string; displayName: string; urlExpireDays?: number; lastModifiedTime?: string; objectExpireDays?: number; }; export type GetObjectUploadURLResponse = { uploadUrl: string; urlExpireAt: string; object: ArtifactObject; }; export type UploadNamespaceObjectRequest = { uploadUrl: string; object: Blob; /** MIME type of the object */ contentType?: string; }; export type GetNamespaceObjectDownloadURLRequest = { name: string; urlExpireDays?: number; downloadFilename?: string; }; export type GetNamespaceObjectDownloadURLResponse = { downloadUrl: string; urlExpireAt: string; object: ArtifactObject; }; export type DownloadNamespaceObjectRequest = { downloadUrl: string; }; export type KnowledgeBase = { name: string; id: string; description: string; createTime: string; updateTime: string; ownerName: string; tags: string[]; convertingPipelines: string[]; splittingPipelines: string[]; embeddingPipelines: string[]; summarizingPipelines: string[]; downstreamApps: string[]; totalFiles: number; totalTokens: number; usedStorage: number; }; export type FilePosition = { unit: "UNIT_UNSPECIFIED" | "UNIT_CHARACTER" | "UNIT_PAGE" | "UNIT_TIME_MS" | "UNIT_PIXEL"; coordinates: number[]; }; export type ChunkReference = { start: FilePosition; end: FilePosition; }; export type ChunkType = "TYPE_UNSPECIFIED" | "TYPE_CONTENT" | "TYPE_SUMMARY" | "TYPE_AUGMENTED"; export type Chunk = { name: string; id: string; retrievable: boolean; tokens: number; createTime: string; originalFile: string; type: ChunkType; reference?: ChunkReference; markdownReference?: ChunkReference; }; export type GetChunkResponse = { chunk: Chunk; }; export type SimilarChunk = { chunk: string; similarityScore: number; textContent: string; file: string; chunkMetadata: Chunk; }; export type FileProcessStatus = "FILE_PROCESS_STATUS_UNSPECIFIED" | "FILE_PROCESS_STATUS_NOTSTARTED" | "FILE_PROCESS_STATUS_PROCESSING" | "FILE_PROCESS_STATUS_CHUNKING" | "FILE_PROCESS_STATUS_EMBEDDING" | "FILE_PROCESS_STATUS_COMPLETED" | "FILE_PROCESS_STATUS_FAILED"; export type FileType = "TYPE_UNSPECIFIED" | "TYPE_TEXT" | "TYPE_MARKDOWN" | "TYPE_HTML" | "TYPE_CSV" | "TYPE_PDF" | "TYPE_DOC" | "TYPE_DOCX" | "TYPE_PPT" | "TYPE_PPTX" | "TYPE_XLS" | "TYPE_XLSX" | "TYPE_PNG" | "TYPE_JPEG" | "TYPE_GIF" | "TYPE_WEBP" | "TYPE_TIFF" | "TYPE_BMP" | "TYPE_HEIC" | "TYPE_HEIF" | "TYPE_AVIF" | "TYPE_MP3" | "TYPE_WAV" | "TYPE_AAC" | "TYPE_OGG" | "TYPE_FLAC" | "TYPE_M4A" | "TYPE_WMA" | "TYPE_AIFF" | "TYPE_WEBM_AUDIO" | "TYPE_MP4" | "TYPE_AVI" | "TYPE_MOV" | "TYPE_MKV" | "TYPE_FLV" | "TYPE_WMV" | "TYPE_MPEG" | "TYPE_WEBM_VIDEO"; export type FileMediaType = "FILE_MEDIA_TYPE_UNSPECIFIED" | "FILE_MEDIA_TYPE_DOCUMENT" | "FILE_MEDIA_TYPE_IMAGE" | "FILE_MEDIA_TYPE_AUDIO" | "FILE_MEDIA_TYPE_VIDEO"; export type File = { name: string; id: string; displayName: string; slug?: string; aliases?: string[]; description?: string; createTime: string; updateTime: string; deleteTime?: string; type: FileType; processStatus: FileProcessStatus; processOutcome: string; size: number; totalChunks: number; totalTokens: number; tags?: string[]; externalMetadata?: Record; knowledgeBases?: string[]; ownerName?: string; creatorName?: string; content?: string; downloadUrl?: string; convertingPipeline?: string; length?: FilePosition; collections?: string[]; object?: string; }; export type ListKnowledgeBasesRequest = { namespaceId: string; pageSize?: number; pageToken?: string; }; export type ListKnowledgeBasesResponse = { knowledgeBases: KnowledgeBase[]; nextPageToken: string; totalSize: number; }; export type CreateKnowledgeBaseRequest = { namespaceId: string; id?: string; description?: string; tags?: string[]; convertingPipelines?: string[]; }; export type CreateKnowledgeBaseResponse = { knowledgeBase: KnowledgeBase; }; export type UpdateKnowledgeBaseRequest = { namespaceId: string; knowledgeBaseId: string; knowledgeBase: { description?: string; tags?: string[]; convertingPipelines?: string[]; }; updateMask?: string; }; export type UpdateKnowledgeBaseResponse = { knowledgeBase: KnowledgeBase; }; export type DeleteKnowledgeBaseRequest = { namespaceId: string; knowledgeBaseId: string; }; export type GetKnowledgeBaseRequest = { namespaceId: string; knowledgeBaseId: string; }; export type GetKnowledgeBaseResponse = { knowledgeBase: KnowledgeBase; }; export type CreateFileRequest = { namespaceId: string; knowledgeBaseId: string; file: { displayName: string; slug?: string; description?: string; type?: FileType; content?: string; object?: string; convertingPipeline?: string; tags?: string[]; externalMetadata?: Record; }; }; export type CreateFileResponse = { file: File; }; export type FileView = "VIEW_UNSPECIFIED" | "VIEW_BASIC" | "VIEW_FULL" | "VIEW_SUMMARY" | "VIEW_CONTENT" | "VIEW_STANDARD_FILE_TYPE" | "VIEW_ORIGINAL_FILE_TYPE" | "VIEW_CACHE"; export type FileStorageProvider = "STORAGE_PROVIDER_UNSPECIFIED" | "STORAGE_PROVIDER_MINIO" | "STORAGE_PROVIDER_GCS"; export type GetFileRequest = { namespaceId: string; knowledgeBaseId: string; fileId: string; view?: FileView; storageProvider?: FileStorageProvider; }; export type GetFileResponse = { file: File; derivedResourceUri?: string; }; export type ListFilesRequest = { namespaceId: string; knowledgeBaseId: string; pageSize?: number; pageToken?: string; filter?: string; }; export type ListFilesResponse = { files: File[]; nextPageToken?: string; totalSize: number; pageSize?: number; }; export type UpdateFileRequest = { namespaceId: string; knowledgeBaseId: string; fileId: string; file: { displayName?: string; slug?: string; description?: string; tags?: string[]; externalMetadata?: Record; convertingPipeline?: string; }; updateMask?: string[]; }; export type UpdateFileResponse = { file: File; }; export type ReprocessFileRequest = { namespaceId: string; knowledgeBaseId: string; fileId: string; }; export type ReprocessFileResponse = { file: File; }; export type DeleteFileRequest = { namespaceId: string; knowledgeBaseId: string; fileId: string; }; export type GetChunkRequest = { namespaceId: string; knowledgeBaseId: string; fileId: string; chunkId: string; chunkType?: ChunkType; }; export type ListChunksRequest = { namespaceId: string; knowledgeBaseId: string; fileId: string; pageSize?: number; pageToken?: string; filter?: string; }; export type ListChunksResponse = { chunks: Chunk[]; nextPageToken?: string; totalSize?: number; }; export type UpdateChunkRequest = { namespaceId: string; knowledgeBaseId: string; fileId: string; chunkId: string; retrievable?: boolean; }; export type UpdateChunkResponse = { chunk: Chunk; }; export type SearchChunksRequest = { namespaceId: string; knowledgeBaseId?: string; textPrompt: string; topK?: number; type?: ChunkType; fileMediaType?: FileMediaType; fileIds?: string[]; tags?: string[]; }; export type SearchChunksResponse = { similarChunks: SimilarChunk[]; }; export type GetObjectRequest = { namespaceId: string; objectId: string; }; export type GetObjectResponse = { object: ArtifactObject; }; export type UpdateObjectRequest = { namespaceId: string; objectId: string; object?: Partial; }; export type UpdateObjectResponse = { object: ArtifactObject; }; export type DeleteObjectRequest = { namespaceId: string; objectId: string; }; //# sourceMappingURL=types.d.ts.map