From 64439fa962f011d0139443e7a2b38310a0b15a89 Mon Sep 17 00:00:00 2001 From: droplet-bot Date: Tue, 1 Oct 2024 15:04:24 +0000 Subject: [PATCH] chore: auto-gen by protobufs triggered by commit: https://github.com/instill-ai/protobufs/commit/491c6e80c3a7e383fb5b210deee881ae334dcf36 --- artifact/artifact/v1alpha/chunk_pb2.py | 4 ++-- artifact/artifact/v1alpha/chunk_pb2.pyi | 12 +++++++++--- 2 files changed, 11 insertions(+), 5 deletions(-) diff --git a/artifact/artifact/v1alpha/chunk_pb2.py b/artifact/artifact/v1alpha/chunk_pb2.py index 346f277..8a56b5a 100644 --- a/artifact/artifact/v1alpha/chunk_pb2.py +++ b/artifact/artifact/v1alpha/chunk_pb2.py @@ -14,7 +14,7 @@ from google.protobuf import timestamp_pb2 as google_dot_protobuf_dot_timestamp__pb2 -DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n%artifact/artifact/v1alpha/chunk.proto\x12\x19\x61rtifact.artifact.v1alpha\x1a\x1fgoogle/protobuf/timestamp.proto\"\xfd\x01\n\x05\x43hunk\x12\x1b\n\tchunk_uid\x18\x01 \x01(\tR\x08\x63hunkUid\x12 \n\x0bretrievable\x18\x02 \x01(\x08R\x0bretrievable\x12\x1b\n\tstart_pos\x18\x04 \x01(\rR\x08startPos\x12\x17\n\x07\x65nd_pos\x18\x05 \x01(\rR\x06\x65ndPos\x12\x16\n\x06tokens\x18\x06 \x01(\rR\x06tokens\x12;\n\x0b\x63reate_time\x18\x07 \x01(\x0b\x32\x1a.google.protobuf.TimestampR\ncreateTime\x12*\n\x11original_file_uid\x18\x08 \x01(\tR\x0foriginalFileUid\"\x8f\x01\n\x11ListChunksRequest\x12!\n\x0cnamespace_id\x18\x01 \x01(\tR\x0bnamespaceId\x12\x1d\n\ncatalog_id\x18\x02 \x01(\tR\tcatalogId\x12\x19\n\x08\x66ile_uid\x18\x03 \x01(\tR\x07\x66ileUid\x12\x1d\n\nchunk_uids\x18\x04 \x03(\tR\tchunkUids\"N\n\x12ListChunksResponse\x12\x38\n\x06\x63hunks\x18\x01 \x03(\x0b\x32 .artifact.artifact.v1alpha.ChunkR\x06\x63hunks\"\xcc\x01\n\nSourceFile\x12*\n\x11original_file_uid\x18\x01 \x01(\tR\x0foriginalFileUid\x12\x18\n\x07\x63ontent\x18\x03 \x01(\tR\x07\x63ontent\x12;\n\x0b\x63reate_time\x18\x05 \x01(\x0b\x32\x1a.google.protobuf.TimestampR\ncreateTime\x12;\n\x0bupdate_time\x18\x06 \x01(\x0b\x32\x1a.google.protobuf.TimestampR\nupdateTime\"s\n\x14GetSourceFileRequest\x12!\n\x0cnamespace_id\x18\x01 \x01(\tR\x0bnamespaceId\x12\x1d\n\ncatalog_id\x18\x02 \x01(\tR\tcatalogId\x12\x19\n\x08\x66ile_uid\x18\x03 \x01(\tR\x07\x66ileUid\"_\n\x15GetSourceFileResponse\x12\x46\n\x0bsource_file\x18\x01 \x01(\x0b\x32%.artifact.artifact.v1alpha.SourceFileR\nsourceFile\"S\n\x12UpdateChunkRequest\x12\x1b\n\tchunk_uid\x18\x01 \x01(\tR\x08\x63hunkUid\x12 \n\x0bretrievable\x18\x02 \x01(\x08R\x0bretrievable\"M\n\x13UpdateChunkResponse\x12\x36\n\x05\x63hunk\x18\x01 \x01(\x0b\x32 .artifact.artifact.v1alpha.ChunkR\x05\x63hunk\"\x97\x01\n\x1dSimilarityChunksSearchRequest\x12!\n\x0cnamespace_id\x18\x01 \x01(\tR\x0bnamespaceId\x12\x1d\n\ncatalog_id\x18\x02 \x01(\tR\tcatalogId\x12\x1f\n\x0btext_prompt\x18\x03 \x01(\tR\ntextPrompt\x12\x13\n\x05top_k\x18\x04 \x01(\rR\x04topK\"s\n\x1eSimilarityChunksSearchResponse\x12Q\n\x0esimilar_chunks\x18\x01 \x03(\x0b\x32*.artifact.artifact.v1alpha.SimilarityChunkR\rsimilarChunks\"\x9d\x01\n\x0fSimilarityChunk\x12\x1b\n\tchunk_uid\x18\x01 \x01(\tR\x08\x63hunkUid\x12)\n\x10similarity_score\x18\x02 \x01(\x02R\x0fsimilarityScore\x12!\n\x0ctext_content\x18\x03 \x01(\tR\x0btextContent\x12\x1f\n\x0bsource_file\x18\x04 \x01(\tR\nsourceFileB\xfe\x01\n\x1d\x63om.artifact.artifact.v1alphaB\nChunkProtoP\x01ZKgithub.com/instill-ai/protogen-go/artifact/artifact/v1alpha;artifactv1alpha\xa2\x02\x03\x41\x41X\xaa\x02\x19\x41rtifact.Artifact.V1alpha\xca\x02\x19\x41rtifact\\Artifact\\V1alpha\xe2\x02%Artifact\\Artifact\\V1alpha\\GPBMetadata\xea\x02\x1b\x41rtifact::Artifact::V1alphab\x06proto3') +DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n%artifact/artifact/v1alpha/chunk.proto\x12\x19\x61rtifact.artifact.v1alpha\x1a\x1fgoogle/protobuf/timestamp.proto\"\xfd\x01\n\x05\x43hunk\x12\x1b\n\tchunk_uid\x18\x01 \x01(\tR\x08\x63hunkUid\x12 \n\x0bretrievable\x18\x02 \x01(\x08R\x0bretrievable\x12\x1b\n\tstart_pos\x18\x04 \x01(\rR\x08startPos\x12\x17\n\x07\x65nd_pos\x18\x05 \x01(\rR\x06\x65ndPos\x12\x16\n\x06tokens\x18\x06 \x01(\rR\x06tokens\x12;\n\x0b\x63reate_time\x18\x07 \x01(\x0b\x32\x1a.google.protobuf.TimestampR\ncreateTime\x12*\n\x11original_file_uid\x18\x08 \x01(\tR\x0foriginalFileUid\"\x8f\x01\n\x11ListChunksRequest\x12!\n\x0cnamespace_id\x18\x01 \x01(\tR\x0bnamespaceId\x12\x1d\n\ncatalog_id\x18\x02 \x01(\tR\tcatalogId\x12\x19\n\x08\x66ile_uid\x18\x03 \x01(\tR\x07\x66ileUid\x12\x1d\n\nchunk_uids\x18\x04 \x03(\tR\tchunkUids\"N\n\x12ListChunksResponse\x12\x38\n\x06\x63hunks\x18\x01 \x03(\x0b\x32 .artifact.artifact.v1alpha.ChunkR\x06\x63hunks\"\xcc\x01\n\nSourceFile\x12*\n\x11original_file_uid\x18\x01 \x01(\tR\x0foriginalFileUid\x12\x18\n\x07\x63ontent\x18\x03 \x01(\tR\x07\x63ontent\x12;\n\x0b\x63reate_time\x18\x05 \x01(\x0b\x32\x1a.google.protobuf.TimestampR\ncreateTime\x12;\n\x0bupdate_time\x18\x06 \x01(\x0b\x32\x1a.google.protobuf.TimestampR\nupdateTime\"s\n\x14GetSourceFileRequest\x12!\n\x0cnamespace_id\x18\x01 \x01(\tR\x0bnamespaceId\x12\x1d\n\ncatalog_id\x18\x02 \x01(\tR\tcatalogId\x12\x19\n\x08\x66ile_uid\x18\x03 \x01(\tR\x07\x66ileUid\"_\n\x15GetSourceFileResponse\x12\x46\n\x0bsource_file\x18\x01 \x01(\x0b\x32%.artifact.artifact.v1alpha.SourceFileR\nsourceFile\"S\n\x12UpdateChunkRequest\x12\x1b\n\tchunk_uid\x18\x01 \x01(\tR\x08\x63hunkUid\x12 \n\x0bretrievable\x18\x02 \x01(\x08R\x0bretrievable\"M\n\x13UpdateChunkResponse\x12\x36\n\x05\x63hunk\x18\x01 \x01(\x0b\x32 .artifact.artifact.v1alpha.ChunkR\x05\x63hunk\"\x97\x01\n\x1dSimilarityChunksSearchRequest\x12!\n\x0cnamespace_id\x18\x01 \x01(\tR\x0bnamespaceId\x12\x1d\n\ncatalog_id\x18\x02 \x01(\tR\tcatalogId\x12\x1f\n\x0btext_prompt\x18\x03 \x01(\tR\ntextPrompt\x12\x13\n\x05top_k\x18\x04 \x01(\rR\x04topK\"s\n\x1eSimilarityChunksSearchResponse\x12Q\n\x0esimilar_chunks\x18\x01 \x03(\x0b\x32*.artifact.artifact.v1alpha.SimilarityChunkR\rsimilarChunks\"\xe6\x01\n\x0fSimilarityChunk\x12\x1b\n\tchunk_uid\x18\x01 \x01(\tR\x08\x63hunkUid\x12)\n\x10similarity_score\x18\x02 \x01(\x02R\x0fsimilarityScore\x12!\n\x0ctext_content\x18\x03 \x01(\tR\x0btextContent\x12\x1f\n\x0bsource_file\x18\x04 \x01(\tR\nsourceFile\x12G\n\x0e\x63hunk_metadata\x18\x05 \x01(\x0b\x32 .artifact.artifact.v1alpha.ChunkR\rchunkMetadataB\xfe\x01\n\x1d\x63om.artifact.artifact.v1alphaB\nChunkProtoP\x01ZKgithub.com/instill-ai/protogen-go/artifact/artifact/v1alpha;artifactv1alpha\xa2\x02\x03\x41\x41X\xaa\x02\x19\x41rtifact.Artifact.V1alpha\xca\x02\x19\x41rtifact\\Artifact\\V1alpha\xe2\x02%Artifact\\Artifact\\V1alpha\\GPBMetadata\xea\x02\x1b\x41rtifact::Artifact::V1alphab\x06proto3') _globals = globals() _builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, _globals) @@ -44,5 +44,5 @@ _globals['_SIMILARITYCHUNKSSEARCHRESPONSE']._serialized_start=1322 _globals['_SIMILARITYCHUNKSSEARCHRESPONSE']._serialized_end=1437 _globals['_SIMILARITYCHUNK']._serialized_start=1440 - _globals['_SIMILARITYCHUNK']._serialized_end=1597 + _globals['_SIMILARITYCHUNK']._serialized_end=1670 # @@protoc_insertion_point(module_scope) diff --git a/artifact/artifact/v1alpha/chunk_pb2.pyi b/artifact/artifact/v1alpha/chunk_pb2.pyi index eb240be..6b21548 100644 --- a/artifact/artifact/v1alpha/chunk_pb2.pyi +++ b/artifact/artifact/v1alpha/chunk_pb2.pyi @@ -82,7 +82,7 @@ class ListChunksRequest(google.protobuf.message.Message): """unique identifier of the file""" @property def chunk_uids(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.str]: - """repeated chunk uid""" + """repeated chunk uid(not implemented yet)""" def __init__( self, *, @@ -294,6 +294,7 @@ class SimilarityChunk(google.protobuf.message.Message): SIMILARITY_SCORE_FIELD_NUMBER: builtins.int TEXT_CONTENT_FIELD_NUMBER: builtins.int SOURCE_FILE_FIELD_NUMBER: builtins.int + CHUNK_METADATA_FIELD_NUMBER: builtins.int chunk_uid: builtins.str """chunk uid""" similarity_score: builtins.float @@ -301,7 +302,10 @@ class SimilarityChunk(google.protobuf.message.Message): text_content: builtins.str """content""" source_file: builtins.str - """source file""" + """source file's name""" + @property + def chunk_metadata(self) -> global___Chunk: + """chunk""" def __init__( self, *, @@ -309,7 +313,9 @@ class SimilarityChunk(google.protobuf.message.Message): similarity_score: builtins.float = ..., text_content: builtins.str = ..., source_file: builtins.str = ..., + chunk_metadata: global___Chunk | None = ..., ) -> None: ... - def ClearField(self, field_name: typing_extensions.Literal["chunk_uid", b"chunk_uid", "similarity_score", b"similarity_score", "source_file", b"source_file", "text_content", b"text_content"]) -> None: ... + def HasField(self, field_name: typing_extensions.Literal["chunk_metadata", b"chunk_metadata"]) -> builtins.bool: ... + def ClearField(self, field_name: typing_extensions.Literal["chunk_metadata", b"chunk_metadata", "chunk_uid", b"chunk_uid", "similarity_score", b"similarity_score", "source_file", b"source_file", "text_content", b"text_content"]) -> None: ... global___SimilarityChunk = SimilarityChunk