Package Methods (0.2.3)

Summary of entries of Methods for llama-index-alloydb-pg.

llama_index_alloydb_pg.engine._get_iam_principal_email

  _get_iam_principal_email 
 ( 
 credentials 
 : 
 google 
 . 
 auth 
 . 
 credentials 
 . 
 Credentials 
 ) 
 - 
> str 
 

Get email address associated with current authenticated IAM principal.

See more: llama_index_alloydb_pg.engine._get_iam_principal_email

llama_index_alloydb_pg.chat_store.AlloyDBChatStore

  AlloyDBChatStore 
 ( 
 key 
 : 
 object 
 , 
 engine 
 : 
 AlloyDBEngine 
 , 
 chat_store 
 : 
 AsyncAlloyDBChatStore 
 ) 
 

AlloyDBChatStore constructor.

See more: llama_index_alloydb_pg.chat_store.AlloyDBChatStore

llama_index_alloydb_pg.chat_store.AlloyDBChatStore.add_message

  add_message 
 ( 
 key 
 : 
 str 
 , 
 message 
 : 
 llama_index 
 . 
 core 
 . 
 base 
 . 
 llms 
 . 
 types 
 . 
 ChatMessage 
 ) 
 - 
> None 
 

Synchronously adds a new chat message to the specified key.

See more: llama_index_alloydb_pg.chat_store.AlloyDBChatStore.add_message

llama_index_alloydb_pg.chat_store.AlloyDBChatStore.adelete_last_message

  adelete_last_message 
 ( 
 key 
 : 
 str 
 , 
 ) 
 - 
> typing 
 . 
 Optional 
 [ 
 llama_index 
 . 
 core 
 . 
 base 
 . 
 llms 
 . 
 types 
 . 
 ChatMessage 
 ] 
 

Asynchronously deletes the last chat message associated with a given key.

See more: llama_index_alloydb_pg.chat_store.AlloyDBChatStore.adelete_last_message

llama_index_alloydb_pg.chat_store.AlloyDBChatStore.adelete_message

  adelete_message 
 ( 
 key 
 : 
 str 
 , 
 idx 
 : 
 int 
 ) 
 - 
> typing 
 . 
 Optional 
 [ 
 llama_index 
 . 
 core 
 . 
 base 
 . 
 llms 
 . 
 types 
 . 
 ChatMessage 
 ] 
 

Asynchronously deletes a specific chat message by index from the messages associated with a given key.

See more: llama_index_alloydb_pg.chat_store.AlloyDBChatStore.adelete_message

llama_index_alloydb_pg.chat_store.AlloyDBChatStore.adelete_messages

  adelete_messages 
 ( 
 key 
 : 
 str 
 , 
 ) 
 - 
> typing 
 . 
 Optional 
 [ 
 typing 
 . 
 List 
 [ 
 llama_index 
 . 
 core 
 . 
 base 
 . 
 llms 
 . 
 types 
 . 
 ChatMessage 
 ]] 
 

Asynchronously deletes the chat messages associated with a specific key.

See more: llama_index_alloydb_pg.chat_store.AlloyDBChatStore.adelete_messages

llama_index_alloydb_pg.chat_store.AlloyDBChatStore.aget_keys

  aget_keys 
 () 
 - 
> typing 
 . 
 List 
 [ 
 str 
 ] 
 

Asynchronously retrieves a list of all keys.

See more: llama_index_alloydb_pg.chat_store.AlloyDBChatStore.aget_keys

llama_index_alloydb_pg.chat_store.AlloyDBChatStore.aget_messages

  aget_messages 
 ( 
 key 
 : 
 str 
 , 
 ) 
 - 
> typing 
 . 
 List 
 [ 
 llama_index 
 . 
 core 
 . 
 base 
 . 
 llms 
 . 
 types 
 . 
 ChatMessage 
 ] 
 

Asynchronously retrieves the chat messages associated with a specific key.

See more: llama_index_alloydb_pg.chat_store.AlloyDBChatStore.aget_messages

llama_index_alloydb_pg.chat_store.AlloyDBChatStore.aset_messages

  aset_messages 
 ( 
 key 
 : 
 str 
 , 
 messages 
 : 
 typing 
 . 
 List 
 [ 
 llama_index 
 . 
 core 
 . 
 base 
 . 
 llms 
 . 
 types 
 . 
 ChatMessage 
 ] 
 ) 
 - 
> None 
 

Asynchronously sets the chat messages for a specific key.

See more: llama_index_alloydb_pg.chat_store.AlloyDBChatStore.aset_messages

llama_index_alloydb_pg.chat_store.AlloyDBChatStore.async_add_message

  async_add_message 
 ( 
 key 
 : 
 str 
 , 
 message 
 : 
 llama_index 
 . 
 core 
 . 
 base 
 . 
 llms 
 . 
 types 
 . 
 ChatMessage 
 ) 
 - 
> None 
 

Asynchronously adds a new chat message to the specified key.

See more: llama_index_alloydb_pg.chat_store.AlloyDBChatStore.async_add_message

llama_index_alloydb_pg.chat_store.AlloyDBChatStore.class_name

  class_name 
 () 
 - 
> str 
 

llama_index_alloydb_pg.chat_store.AlloyDBChatStore.create

  create 
 ( 
 engine 
 : 
 llama_index_alloydb_pg 
 . 
 engine 
 . 
 AlloyDBEngine 
 , 
 table_name 
 : 
 str 
 , 
 schema_name 
 : 
 str 
 = 
 "public" 
 , 
 ) 
 - 
> llama_index_alloydb_pg 
 . 
 chat_store 
 . 
 AlloyDBChatStore 
 

Create a new AlloyDBChatStore instance.

See more: llama_index_alloydb_pg.chat_store.AlloyDBChatStore.create

llama_index_alloydb_pg.chat_store.AlloyDBChatStore.create_sync

  create_sync 
 ( 
 engine 
 : 
 llama_index_alloydb_pg 
 . 
 engine 
 . 
 AlloyDBEngine 
 , 
 table_name 
 : 
 str 
 , 
 schema_name 
 : 
 str 
 = 
 "public" 
 , 
 ) 
 - 
> llama_index_alloydb_pg 
 . 
 chat_store 
 . 
 AlloyDBChatStore 
 

Create a new AlloyDBChatStore sync instance.

See more: llama_index_alloydb_pg.chat_store.AlloyDBChatStore.create_sync

llama_index_alloydb_pg.chat_store.AlloyDBChatStore.delete_last_message

  delete_last_message 
 ( 
 key 
 : 
 str 
 , 
 ) 
 - 
> typing 
 . 
 Optional 
 [ 
 llama_index 
 . 
 core 
 . 
 base 
 . 
 llms 
 . 
 types 
 . 
 ChatMessage 
 ] 
 

Synchronously deletes the last chat message associated with a given key.

See more: llama_index_alloydb_pg.chat_store.AlloyDBChatStore.delete_last_message

llama_index_alloydb_pg.chat_store.AlloyDBChatStore.delete_message

  delete_message 
 ( 
 key 
 : 
 str 
 , 
 idx 
 : 
 int 
 ) 
 - 
> typing 
 . 
 Optional 
 [ 
 llama_index 
 . 
 core 
 . 
 base 
 . 
 llms 
 . 
 types 
 . 
 ChatMessage 
 ] 
 

Synchronously deletes a specific chat message by index from the messages associated with a given key.

See more: llama_index_alloydb_pg.chat_store.AlloyDBChatStore.delete_message

llama_index_alloydb_pg.chat_store.AlloyDBChatStore.delete_messages

  delete_messages 
 ( 
 key 
 : 
 str 
 , 
 ) 
 - 
> typing 
 . 
 Optional 
 [ 
 typing 
 . 
 List 
 [ 
 llama_index 
 . 
 core 
 . 
 base 
 . 
 llms 
 . 
 types 
 . 
 ChatMessage 
 ]] 
 

Synchronously deletes the chat messages associated with a specific key.

See more: llama_index_alloydb_pg.chat_store.AlloyDBChatStore.delete_messages

llama_index_alloydb_pg.chat_store.AlloyDBChatStore.get_keys

  get_keys 
 () 
 - 
> typing 
 . 
 List 
 [ 
 str 
 ] 
 

Synchronously retrieves a list of all keys.

See more: llama_index_alloydb_pg.chat_store.AlloyDBChatStore.get_keys

llama_index_alloydb_pg.chat_store.AlloyDBChatStore.get_messages

  get_messages 
 ( 
 key 
 : 
 str 
 ) 
 - 
> typing 
 . 
 List 
 [ 
 llama_index 
 . 
 core 
 . 
 base 
 . 
 llms 
 . 
 types 
 . 
 ChatMessage 
 ] 
 

Synchronously retrieves the chat messages associated with a specific key.

See more: llama_index_alloydb_pg.chat_store.AlloyDBChatStore.get_messages

llama_index_alloydb_pg.chat_store.AlloyDBChatStore.model_post_init

  model_post_init 
 ( 
 context 
 : 
 Any 
 , 
 / 
 ) 
 - 
> None 
 

This function is meant to behave like a BaseModel method to initialise private attributes.

See more: llama_index_alloydb_pg.chat_store.AlloyDBChatStore.model_post_init

llama_index_alloydb_pg.chat_store.AlloyDBChatStore.set_messages

  set_messages 
 ( 
 key 
 : 
 str 
 , 
 messages 
 : 
 typing 
 . 
 List 
 [ 
 llama_index 
 . 
 core 
 . 
 base 
 . 
 llms 
 . 
 types 
 . 
 ChatMessage 
 ] 
 ) 
 - 
> None 
 

Synchronously sets the chat messages for a specific key.

See more: llama_index_alloydb_pg.chat_store.AlloyDBChatStore.set_messages

llama_index_alloydb_pg.document_store.AlloyDBDocumentStore

  AlloyDBDocumentStore 
 ( 
 key 
 : 
 object 
 , 
 engine 
 : 
 llama_index_alloydb_pg 
 . 
 engine 
 . 
 AlloyDBEngine 
 , 
 document_store 
 : 
 llama_index_alloydb_pg 
 . 
 async_document_store 
 . 
 AsyncAlloyDBDocumentStore 
 , 
 ) 
 

"AlloyDBDocumentStore constructor.

See more: llama_index_alloydb_pg.document_store.AlloyDBDocumentStore

llama_index_alloydb_pg.document_store.AlloyDBDocumentStore.add_documents

  add_documents 
 ( 
 docs 
 : 
 typing 
 . 
 Sequence 
 [ 
 llama_index 
 . 
 core 
 . 
 schema 
 . 
 BaseNode 
 ], 
 allow_update 
 : 
 bool 
 = 
 True 
 , 
 batch_size 
 : 
 int 
 = 
 1 
 , 
 store_text 
 : 
 bool 
 = 
 True 
 , 
 ) 
 - 
> None 
 

llama_index_alloydb_pg.document_store.AlloyDBDocumentStore.adelete_document

  adelete_document 
 ( 
 doc_id 
 : 
 str 
 , 
 raise_error 
 : 
 bool 
 = 
 True 
 ) 
 - 
> None 
 

llama_index_alloydb_pg.document_store.AlloyDBDocumentStore.adelete_ref_doc

  adelete_ref_doc 
 ( 
 ref_doc_id 
 : 
 str 
 , 
 raise_error 
 : 
 bool 
 = 
 True 
 ) 
 - 
> None 
 

Delete a ref_doc and all it's associated nodes.

See more: llama_index_alloydb_pg.document_store.AlloyDBDocumentStore.adelete_ref_doc

llama_index_alloydb_pg.document_store.AlloyDBDocumentStore.adocument_exists

  adocument_exists 
 ( 
 doc_id 
 : 
 str 
 ) 
 - 
> bool 
 

llama_index_alloydb_pg.document_store.AlloyDBDocumentStore.aget_all_document_hashes

  aget_all_document_hashes 
 () 
 - 
> dict 
 [ 
 str 
 , 
 str 
 ] 
 

llama_index_alloydb_pg.document_store.AlloyDBDocumentStore.aget_all_ref_doc_info

  aget_all_ref_doc_info 
 () 
 - 
> ( 
 typing 
 . 
 Optional 
 [ 
 dict 
 [ 
 str 
 , 
 llama_index 
 . 
 core 
 . 
 storage 
 . 
 docstore 
 . 
 types 
 . 
 RefDocInfo 
 ]] 
 ) 
 

Get a mapping of ref_doc_id -> RefDocInfo for all ingested documents.

See more: llama_index_alloydb_pg.document_store.AlloyDBDocumentStore.aget_all_ref_doc_info

llama_index_alloydb_pg.document_store.AlloyDBDocumentStore.aget_document

  aget_document 
 ( 
 doc_id 
 : 
 str 
 , 
 raise_error 
 : 
 bool 
 = 
 True 
 ) 
 - 
> typing 
 . 
 Optional 
 [ 
 llama_index 
 . 
 core 
 . 
 schema 
 . 
 BaseNode 
 ] 
 

Retrieves a document from the table by its doc_id.

See more: llama_index_alloydb_pg.document_store.AlloyDBDocumentStore.aget_document

llama_index_alloydb_pg.document_store.AlloyDBDocumentStore.aget_document_hash

  aget_document_hash 
 ( 
 doc_id 
 : 
 str 
 ) 
 - 
> typing 
 . 
 Optional 
 [ 
 str 
 ] 
 

Get the stored hash for a document, if it exists.

See more: llama_index_alloydb_pg.document_store.AlloyDBDocumentStore.aget_document_hash

llama_index_alloydb_pg.document_store.AlloyDBDocumentStore.aget_ref_doc_info

  aget_ref_doc_info 
 ( 
 ref_doc_id 
 : 
 str 
 , 
 ) 
 - 
> typing 
 . 
 Optional 
 [ 
 llama_index 
 . 
 core 
 . 
 storage 
 . 
 docstore 
 . 
 types 
 . 
 RefDocInfo 
 ] 
 

Get the RefDocInfo for a given ref_doc_id.

See more: llama_index_alloydb_pg.document_store.AlloyDBDocumentStore.aget_ref_doc_info

llama_index_alloydb_pg.document_store.AlloyDBDocumentStore.aref_doc_exists

  aref_doc_exists 
 ( 
 ref_doc_id 
 : 
 str 
 ) 
 - 
> bool 
 

Check if a ref_doc_id has been ingested.

See more: llama_index_alloydb_pg.document_store.AlloyDBDocumentStore.aref_doc_exists

llama_index_alloydb_pg.document_store.AlloyDBDocumentStore.aset_document_hash

  aset_document_hash 
 ( 
 doc_id 
 : 
 str 
 , 
 doc_hash 
 : 
 str 
 ) 
 - 
> None 
 

llama_index_alloydb_pg.document_store.AlloyDBDocumentStore.aset_document_hashes

  aset_document_hashes 
 ( 
 doc_hashes 
 : 
 dict 
 [ 
 str 
 , 
 str 
 ]) 
 - 
> None 
 

llama_index_alloydb_pg.document_store.AlloyDBDocumentStore.async_add_documents

  async_add_documents 
 ( 
 docs 
 : 
 typing 
 . 
 Sequence 
 [ 
 llama_index 
 . 
 core 
 . 
 schema 
 . 
 BaseNode 
 ], 
 allow_update 
 : 
 bool 
 = 
 True 
 , 
 batch_size 
 : 
 int 
 = 
 1 
 , 
 store_text 
 : 
 bool 
 = 
 True 
 , 
 ) 
 - 
> None 
 

llama_index_alloydb_pg.document_store.AlloyDBDocumentStore.create

  create 
 ( 
 engine 
 : 
 llama_index_alloydb_pg 
 . 
 engine 
 . 
 AlloyDBEngine 
 , 
 table_name 
 : 
 str 
 , 
 schema_name 
 : 
 str 
 = 
 "public" 
 , 
 batch_size 
 : 
 int 
 = 
 1 
 , 
 ) 
 - 
> llama_index_alloydb_pg 
 . 
 document_store 
 . 
 AlloyDBDocumentStore 
 

Create a new AlloyDBDocumentStore instance.

See more: llama_index_alloydb_pg.document_store.AlloyDBDocumentStore.create

llama_index_alloydb_pg.document_store.AlloyDBDocumentStore.create_sync

  create_sync 
 ( 
 engine 
 : 
 llama_index_alloydb_pg 
 . 
 engine 
 . 
 AlloyDBEngine 
 , 
 table_name 
 : 
 str 
 , 
 schema_name 
 : 
 str 
 = 
 "public" 
 , 
 batch_size 
 : 
 int 
 = 
 1 
 , 
 ) 
 - 
> llama_index_alloydb_pg 
 . 
 document_store 
 . 
 AlloyDBDocumentStore 
 

Create a new AlloyDBDocumentStore sync instance.

See more: llama_index_alloydb_pg.document_store.AlloyDBDocumentStore.create_sync

llama_index_alloydb_pg.document_store.AlloyDBDocumentStore.delete_document

  delete_document 
 ( 
 doc_id 
 : 
 str 
 , 
 raise_error 
 : 
 bool 
 = 
 True 
 ) 
 - 
> None 
 

llama_index_alloydb_pg.document_store.AlloyDBDocumentStore.delete_ref_doc

  delete_ref_doc 
 ( 
 ref_doc_id 
 : 
 str 
 , 
 raise_error 
 : 
 bool 
 = 
 True 
 ) 
 - 
> None 
 

Delete a ref_doc and all it's associated nodes.

See more: llama_index_alloydb_pg.document_store.AlloyDBDocumentStore.delete_ref_doc

llama_index_alloydb_pg.document_store.AlloyDBDocumentStore.document_exists

  document_exists 
 ( 
 doc_id 
 : 
 str 
 ) 
 - 
> bool 
 

llama_index_alloydb_pg.document_store.AlloyDBDocumentStore.get_all_document_hashes

  get_all_document_hashes 
 () 
 - 
> dict 
 [ 
 str 
 , 
 str 
 ] 
 

llama_index_alloydb_pg.document_store.AlloyDBDocumentStore.get_all_ref_doc_info

  get_all_ref_doc_info 
 () 
 - 
> ( 
 typing 
 . 
 Optional 
 [ 
 dict 
 [ 
 str 
 , 
 llama_index 
 . 
 core 
 . 
 storage 
 . 
 docstore 
 . 
 types 
 . 
 RefDocInfo 
 ]] 
 ) 
 

Get a mapping of ref_doc_id -> RefDocInfo for all ingested documents.

See more: llama_index_alloydb_pg.document_store.AlloyDBDocumentStore.get_all_ref_doc_info

llama_index_alloydb_pg.document_store.AlloyDBDocumentStore.get_document

  get_document 
 ( 
 doc_id 
 : 
 str 
 , 
 raise_error 
 : 
 bool 
 = 
 True 
 ) 
 - 
> typing 
 . 
 Optional 
 [ 
 llama_index 
 . 
 core 
 . 
 schema 
 . 
 BaseNode 
 ] 
 

Retrieves a document from the table by its doc_id.

See more: llama_index_alloydb_pg.document_store.AlloyDBDocumentStore.get_document

llama_index_alloydb_pg.document_store.AlloyDBDocumentStore.get_document_hash

  get_document_hash 
 ( 
 doc_id 
 : 
 str 
 ) 
 - 
> typing 
 . 
 Optional 
 [ 
 str 
 ] 
 

Get the stored hash for a document, if it exists.

See more: llama_index_alloydb_pg.document_store.AlloyDBDocumentStore.get_document_hash

llama_index_alloydb_pg.document_store.AlloyDBDocumentStore.get_ref_doc_info

  get_ref_doc_info 
 ( 
 ref_doc_id 
 : 
 str 
 , 
 ) 
 - 
> typing 
 . 
 Optional 
 [ 
 llama_index 
 . 
 core 
 . 
 storage 
 . 
 docstore 
 . 
 types 
 . 
 RefDocInfo 
 ] 
 

Get the RefDocInfo for a given ref_doc_id.

See more: llama_index_alloydb_pg.document_store.AlloyDBDocumentStore.get_ref_doc_info

llama_index_alloydb_pg.document_store.AlloyDBDocumentStore.ref_doc_exists

  ref_doc_exists 
 ( 
 ref_doc_id 
 : 
 str 
 ) 
 - 
> bool 
 

Check if a ref_doc_id has been ingested.

See more: llama_index_alloydb_pg.document_store.AlloyDBDocumentStore.ref_doc_exists

llama_index_alloydb_pg.document_store.AlloyDBDocumentStore.set_document_hash

  set_document_hash 
 ( 
 doc_id 
 : 
 str 
 , 
 doc_hash 
 : 
 str 
 ) 
 - 
> None 
 

llama_index_alloydb_pg.document_store.AlloyDBDocumentStore.set_document_hashes

  set_document_hashes 
 ( 
 doc_hashes 
 : 
 dict 
 [ 
 str 
 , 
 str 
 ]) 
 - 
> None 
 

llama_index_alloydb_pg.engine.AlloyDBEngine

  AlloyDBEngine 
 ( 
 key 
 : 
 object 
 , 
 pool 
 : 
 sqlalchemy 
 . 
 ext 
 . 
 asyncio 
 . 
 engine 
 . 
 AsyncEngine 
 , 
 loop 
 : 
 typing 
 . 
 Optional 
 [ 
 asyncio 
 . 
 events 
 . 
 AbstractEventLoop 
 ], 
 thread 
 : 
 typing 
 . 
 Optional 
 [ 
 threading 
 . 
 Thread 
 ], 
 ) 
 

AlloyDBEngine constructor.

See more: llama_index_alloydb_pg.engine.AlloyDBEngine

llama_index_alloydb_pg.engine.AlloyDBEngine._ainit_chat_store_table

  _ainit_chat_store_table 
 ( 
 table_name 
 : 
 str 
 , 
 schema_name 
 : 
 str 
 = 
 "public" 
 , 
 overwrite_existing 
 : 
 bool 
 = 
 False 
 ) 
 - 
> None 
 

Create an AlloyDB table to save chat store.

See more: llama_index_alloydb_pg.engine.AlloyDBEngine._ainit_chat_store_table

llama_index_alloydb_pg.engine.AlloyDBEngine._ainit_doc_store_table

  _ainit_doc_store_table 
 ( 
 table_name 
 : 
 str 
 , 
 schema_name 
 : 
 str 
 = 
 "public" 
 , 
 overwrite_existing 
 : 
 bool 
 = 
 False 
 ) 
 - 
> None 
 

Create an AlloyDB table for the DocumentStore.

See more: llama_index_alloydb_pg.engine.AlloyDBEngine._ainit_doc_store_table

llama_index_alloydb_pg.engine.AlloyDBEngine._ainit_index_store_table

  _ainit_index_store_table 
 ( 
 table_name 
 : 
 str 
 , 
 schema_name 
 : 
 str 
 = 
 "public" 
 , 
 overwrite_existing 
 : 
 bool 
 = 
 False 
 ) 
 - 
> None 
 

Create an AlloyDB table to save Index metadata.

See more: llama_index_alloydb_pg.engine.AlloyDBEngine._ainit_index_store_table

llama_index_alloydb_pg.engine.AlloyDBEngine._ainit_vector_store_table

  _ainit_vector_store_table 
 ( 
 table_name 
 : 
 str 
 , 
 vector_size 
 : 
 int 
 , 
 schema_name 
 : 
 str 
 = 
 "public" 
 , 
 id_column 
 : 
 typing 
 . 
 Union 
 [ 
 str 
 , 
 llama_index_alloydb_pg 
 . 
 engine 
 . 
 Column 
 ] 
 = 
 "node_id" 
 , 
 text_column 
 : 
 str 
 = 
 "text" 
 , 
 embedding_column 
 : 
 str 
 = 
 "embedding" 
 , 
 metadata_json_column 
 : 
 str 
 = 
 "li_metadata" 
 , 
 metadata_columns 
 : 
 list 
 [ 
 llama_index_alloydb_pg 
 . 
 engine 
 . 
 Column 
 ] 
 = 
 [], 
 ref_doc_id_column 
 : 
 str 
 = 
 "ref_doc_id" 
 , 
 node_column 
 : 
 str 
 = 
 "node_data" 
 , 
 stores_text 
 : 
 bool 
 = 
 True 
 , 
 overwrite_existing 
 : 
 bool 
 = 
 False 
 , 
 ) 
 - 
> None 
 

Create an AlloyDB table for the VectorStore.

See more: llama_index_alloydb_pg.engine.AlloyDBEngine._ainit_vector_store_table

llama_index_alloydb_pg.engine.AlloyDBEngine._aload_table_schema

  _aload_table_schema 
 ( 
 table_name 
 : 
 str 
 , 
 schema_name 
 : 
 str 
 = 
 "public" 
 ) 
 - 
> sqlalchemy 
 . 
 sql 
 . 
 schema 
 . 
 Table 
 

Load table schema from an existing table in a PgSQL database, potentially from a specific database schema.

See more: llama_index_alloydb_pg.engine.AlloyDBEngine._aload_table_schema

llama_index_alloydb_pg.engine.AlloyDBEngine._create

  _create 
 ( 
 project_id 
 : 
 str 
 , 
 region 
 : 
 str 
 , 
 cluster 
 : 
 str 
 , 
 instance 
 : 
 str 
 , 
 database 
 : 
 str 
 , 
 ip_type 
 : 
 typing 
 . 
 Union 
 [ 
 str 
 , 
 google 
 . 
 cloud 
 . 
 alloydbconnector 
 . 
 enums 
 . 
 IPTypes 
 ], 
 user 
 : 
 typing 
 . 
 Optional 
 [ 
 str 
 ] 
 = 
 None 
 , 
 password 
 : 
 typing 
 . 
 Optional 
 [ 
 str 
 ] 
 = 
 None 
 , 
 loop 
 : 
 typing 
 . 
 Optional 
 [ 
 asyncio 
 . 
 events 
 . 
 AbstractEventLoop 
 ] 
 = 
 None 
 , 
 thread 
 : 
 typing 
 . 
 Optional 
 [ 
 threading 
 . 
 Thread 
 ] 
 = 
 None 
 , 
 iam_account_email 
 : 
 typing 
 . 
 Optional 
 [ 
 str 
 ] 
 = 
 None 
 , 
 ) 
 - 
> llama_index_alloydb_pg 
 . 
 engine 
 . 
 AlloyDBEngine 
 

Create an AlloyDBEngine from an AlloyDB instance.

See more: llama_index_alloydb_pg.engine.AlloyDBEngine._create

llama_index_alloydb_pg.engine.AlloyDBEngine._run_as_async

  _run_as_async 
 ( 
 coro 
 : 
 typing 
 . 
 Awaitable 
 [ 
 llama_index_alloydb_pg 
 . 
 engine 
 . 
 T 
 ], 
 ) 
 - 
> llama_index_alloydb_pg 
 . 
 engine 
 . 
 T 
 

Run an async coroutine asynchronously.

See more: llama_index_alloydb_pg.engine.AlloyDBEngine._run_as_async

llama_index_alloydb_pg.engine.AlloyDBEngine._run_as_sync

  _run_as_sync 
 ( 
 coro 
 : 
 typing 
 . 
 Awaitable 
 [ 
 llama_index_alloydb_pg 
 . 
 engine 
 . 
 T 
 ], 
 ) 
 - 
> llama_index_alloydb_pg 
 . 
 engine 
 . 
 T 
 

Run an async coroutine synchronously.

See more: llama_index_alloydb_pg.engine.AlloyDBEngine._run_as_sync

llama_index_alloydb_pg.engine.AlloyDBEngine.afrom_instance

  afrom_instance 
 ( 
 project_id 
 : 
 str 
 , 
 region 
 : 
 str 
 , 
 cluster 
 : 
 str 
 , 
 instance 
 : 
 str 
 , 
 database 
 : 
 str 
 , 
 user 
 : 
 typing 
 . 
 Optional 
 [ 
 str 
 ] 
 = 
 None 
 , 
 password 
 : 
 typing 
 . 
 Optional 
 [ 
 str 
 ] 
 = 
 None 
 , 
 ip_type 
 : 
 typing 
 . 
 Union 
 [ 
 str 
 , 
 google 
 . 
 cloud 
 . 
 alloydbconnector 
 . 
 enums 
 . 
 IPTypes 
 ] 
 = 
 IPTypes 
 . 
 PUBLIC 
 , 
 iam_account_email 
 : 
 typing 
 . 
 Optional 
 [ 
 str 
 ] 
 = 
 None 
 , 
 ) 
 - 
> llama_index_alloydb_pg 
 . 
 engine 
 . 
 AlloyDBEngine 
 

Create an AlloyDBEngine from an AlloyDB instance.

See more: llama_index_alloydb_pg.engine.AlloyDBEngine.afrom_instance

llama_index_alloydb_pg.engine.AlloyDBEngine.ainit_chat_store_table

  ainit_chat_store_table 
 ( 
 table_name 
 : 
 str 
 , 
 schema_name 
 : 
 str 
 = 
 "public" 
 , 
 overwrite_existing 
 : 
 bool 
 = 
 False 
 ) 
 - 
> None 
 

Create an AlloyDB table to save chat store.

See more: llama_index_alloydb_pg.engine.AlloyDBEngine.ainit_chat_store_table

llama_index_alloydb_pg.engine.AlloyDBEngine.ainit_doc_store_table

  ainit_doc_store_table 
 ( 
 table_name 
 : 
 str 
 , 
 schema_name 
 : 
 str 
 = 
 "public" 
 , 
 overwrite_existing 
 : 
 bool 
 = 
 False 
 ) 
 - 
> None 
 

Create an AlloyDB table for the DocumentStore.

See more: llama_index_alloydb_pg.engine.AlloyDBEngine.ainit_doc_store_table

llama_index_alloydb_pg.engine.AlloyDBEngine.ainit_index_store_table

  ainit_index_store_table 
 ( 
 table_name 
 : 
 str 
 , 
 schema_name 
 : 
 str 
 = 
 "public" 
 , 
 overwrite_existing 
 : 
 bool 
 = 
 False 
 ) 
 - 
> None 
 

Create an AlloyDB table to save Index metadata.

See more: llama_index_alloydb_pg.engine.AlloyDBEngine.ainit_index_store_table

llama_index_alloydb_pg.engine.AlloyDBEngine.ainit_vector_store_table

  ainit_vector_store_table 
 ( 
 table_name 
 : 
 str 
 , 
 vector_size 
 : 
 int 
 , 
 schema_name 
 : 
 str 
 = 
 "public" 
 , 
 id_column 
 : 
 typing 
 . 
 Union 
 [ 
 str 
 , 
 llama_index_alloydb_pg 
 . 
 engine 
 . 
 Column 
 ] 
 = 
 "node_id" 
 , 
 text_column 
 : 
 str 
 = 
 "text" 
 , 
 embedding_column 
 : 
 str 
 = 
 "embedding" 
 , 
 metadata_json_column 
 : 
 str 
 = 
 "li_metadata" 
 , 
 metadata_columns 
 : 
 list 
 [ 
 llama_index_alloydb_pg 
 . 
 engine 
 . 
 Column 
 ] 
 = 
 [], 
 ref_doc_id_column 
 : 
 str 
 = 
 "ref_doc_id" 
 , 
 node_column 
 : 
 str 
 = 
 "node_data" 
 , 
 stores_text 
 : 
 bool 
 = 
 True 
 , 
 overwrite_existing 
 : 
 bool 
 = 
 False 
 , 
 ) 
 - 
> None 
 

Create an AlloyDB table for the VectorStore.

See more: llama_index_alloydb_pg.engine.AlloyDBEngine.ainit_vector_store_table

llama_index_alloydb_pg.engine.AlloyDBEngine.close

  close 
 () 
 - 
> None 
 

Dispose of connection pool.

See more: llama_index_alloydb_pg.engine.AlloyDBEngine.close

llama_index_alloydb_pg.engine.AlloyDBEngine.from_connection_string

  from_connection_string 
 ( 
 url 
 : 
 typing 
 . 
 Union 
 [ 
 str 
 , 
 sqlalchemy 
 . 
 engine 
 . 
 url 
 . 
 URL 
 ], 
 ** 
 kwargs 
 : 
 typing 
 . 
 Any 
 ) 
 - 
> llama_index_alloydb_pg 
 . 
 engine 
 . 
 AlloyDBEngine 
 

Create an AlloyDBEngine instance from arguments .

See more: llama_index_alloydb_pg.engine.AlloyDBEngine.from_connection_string

llama_index_alloydb_pg.engine.AlloyDBEngine.from_engine

  from_engine 
 ( 
 engine 
 : 
 sqlalchemy 
 . 
 ext 
 . 
 asyncio 
 . 
 engine 
 . 
 AsyncEngine 
 , 
 loop 
 : 
 typing 
 . 
 Optional 
 [ 
 asyncio 
 . 
 events 
 . 
 AbstractEventLoop 
 ] 
 = 
 None 
 , 
 ) 
 - 
> llama_index_alloydb_pg 
 . 
 engine 
 . 
 AlloyDBEngine 
 

Create an AlloyDBEngine instance from an AsyncEngine.

See more: llama_index_alloydb_pg.engine.AlloyDBEngine.from_engine

llama_index_alloydb_pg.engine.AlloyDBEngine.from_instance

  from_instance 
 ( 
 project_id 
 : 
 str 
 , 
 region 
 : 
 str 
 , 
 cluster 
 : 
 str 
 , 
 instance 
 : 
 str 
 , 
 database 
 : 
 str 
 , 
 user 
 : 
 typing 
 . 
 Optional 
 [ 
 str 
 ] 
 = 
 None 
 , 
 password 
 : 
 typing 
 . 
 Optional 
 [ 
 str 
 ] 
 = 
 None 
 , 
 ip_type 
 : 
 typing 
 . 
 Union 
 [ 
 str 
 , 
 google 
 . 
 cloud 
 . 
 alloydbconnector 
 . 
 enums 
 . 
 IPTypes 
 ] 
 = 
 IPTypes 
 . 
 PUBLIC 
 , 
 iam_account_email 
 : 
 typing 
 . 
 Optional 
 [ 
 str 
 ] 
 = 
 None 
 , 
 ) 
 - 
> llama_index_alloydb_pg 
 . 
 engine 
 . 
 AlloyDBEngine 
 

Create an AlloyDBEngine from an AlloyDB instance.

See more: llama_index_alloydb_pg.engine.AlloyDBEngine.from_instance

llama_index_alloydb_pg.engine.AlloyDBEngine.init_chat_store_table

  init_chat_store_table 
 ( 
 table_name 
 : 
 str 
 , 
 schema_name 
 : 
 str 
 = 
 "public" 
 , 
 overwrite_existing 
 : 
 bool 
 = 
 False 
 ) 
 - 
> None 
 

Create an AlloyDB table to save chat store.

See more: llama_index_alloydb_pg.engine.AlloyDBEngine.init_chat_store_table

llama_index_alloydb_pg.engine.AlloyDBEngine.init_doc_store_table

  init_doc_store_table 
 ( 
 table_name 
 : 
 str 
 , 
 schema_name 
 : 
 str 
 = 
 "public" 
 , 
 overwrite_existing 
 : 
 bool 
 = 
 False 
 ) 
 - 
> None 
 

Create an AlloyDB table for the DocumentStore.

See more: llama_index_alloydb_pg.engine.AlloyDBEngine.init_doc_store_table

llama_index_alloydb_pg.engine.AlloyDBEngine.init_index_store_table

  init_index_store_table 
 ( 
 table_name 
 : 
 str 
 , 
 schema_name 
 : 
 str 
 = 
 "public" 
 , 
 overwrite_existing 
 : 
 bool 
 = 
 False 
 ) 
 - 
> None 
 

Create an AlloyDB table to save Index metadata.

See more: llama_index_alloydb_pg.engine.AlloyDBEngine.init_index_store_table

llama_index_alloydb_pg.engine.AlloyDBEngine.init_vector_store_table

  init_vector_store_table 
 ( 
 table_name 
 : 
 str 
 , 
 vector_size 
 : 
 int 
 , 
 schema_name 
 : 
 str 
 = 
 "public" 
 , 
 id_column 
 : 
 typing 
 . 
 Union 
 [ 
 str 
 , 
 llama_index_alloydb_pg 
 . 
 engine 
 . 
 Column 
 ] 
 = 
 "node_id" 
 , 
 text_column 
 : 
 str 
 = 
 "text" 
 , 
 embedding_column 
 : 
 str 
 = 
 "embedding" 
 , 
 metadata_json_column 
 : 
 str 
 = 
 "li_metadata" 
 , 
 metadata_columns 
 : 
 list 
 [ 
 llama_index_alloydb_pg 
 . 
 engine 
 . 
 Column 
 ] 
 = 
 [], 
 ref_doc_id_column 
 : 
 str 
 = 
 "ref_doc_id" 
 , 
 node_column 
 : 
 str 
 = 
 "node_data" 
 , 
 stores_text 
 : 
 bool 
 = 
 True 
 , 
 overwrite_existing 
 : 
 bool 
 = 
 False 
 , 
 ) 
 - 
> None 
 

Create an AlloyDB table for the VectorStore.

See more: llama_index_alloydb_pg.engine.AlloyDBEngine.init_vector_store_table

llama_index_alloydb_pg.engine.Column.__post_init__

  __post_init__ 
 () 
 - 
> None 
 

Check if initialization parameters are valid.

See more: llama_index_alloydb_pg.engine.Column. post_init

llama_index_alloydb_pg.index_store.AlloyDBIndexStore

  AlloyDBIndexStore 
 ( 
 key 
 : 
 object 
 , 
 engine 
 : 
 llama_index_alloydb_pg 
 . 
 engine 
 . 
 AlloyDBEngine 
 , 
 index_store 
 : 
 llama_index_alloydb_pg 
 . 
 async_index_store 
 . 
 AsyncAlloyDBIndexStore 
 , 
 ) 
 

AlloyDBIndexStore constructor.

See more: llama_index_alloydb_pg.index_store.AlloyDBIndexStore

llama_index_alloydb_pg.index_store.AlloyDBIndexStore.aadd_index_struct

  aadd_index_struct 
 ( 
 index_struct 
 : 
 llama_index 
 . 
 core 
 . 
 data_structs 
 . 
 data_structs 
 . 
 IndexStruct 
 , 
 ) 
 - 
> None 
 

llama_index_alloydb_pg.index_store.AlloyDBIndexStore.add_index_struct

  add_index_struct 
 ( 
 index_struct 
 : 
 llama_index 
 . 
 core 
 . 
 data_structs 
 . 
 data_structs 
 . 
 IndexStruct 
 , 
 ) 
 - 
> None 
 

llama_index_alloydb_pg.index_store.AlloyDBIndexStore.adelete_index_struct

  adelete_index_struct 
 ( 
 key 
 : 
 str 
 ) 
 - 
> None 
 

llama_index_alloydb_pg.index_store.AlloyDBIndexStore.aget_index_struct

  aget_index_struct 
 ( 
 struct_id 
 : 
 typing 
 . 
 Optional 
 [ 
 str 
 ] 
 = 
 None 
 , 
 ) 
 - 
> typing 
 . 
 Optional 
 [ 
 llama_index 
 . 
 core 
 . 
 data_structs 
 . 
 data_structs 
 . 
 IndexStruct 
 ] 
 

llama_index_alloydb_pg.index_store.AlloyDBIndexStore.aindex_structs

  aindex_structs 
 () 
 - 
> list 
 [ 
 llama_index 
 . 
 core 
 . 
 data_structs 
 . 
 data_structs 
 . 
 IndexStruct 
 ] 
 

llama_index_alloydb_pg.index_store.AlloyDBIndexStore.async_add_index_struct

  async_add_index_struct 
 ( 
 index_struct 
 : 
 llama_index 
 . 
 core 
 . 
 data_structs 
 . 
 data_structs 
 . 
 IndexStruct 
 , 
 ) 
 - 
> None 
 

llama_index_alloydb_pg.index_store.AlloyDBIndexStore.async_index_structs

  async_index_structs 
 () 
 - 
> ( 
 list 
 [ 
 llama_index 
 . 
 core 
 . 
 data_structs 
 . 
 data_structs 
 . 
 IndexStruct 
 ] 
 ) 
 

llama_index_alloydb_pg.index_store.AlloyDBIndexStore.create

  create 
 ( 
 engine 
 : 
 llama_index_alloydb_pg 
 . 
 engine 
 . 
 AlloyDBEngine 
 , 
 table_name 
 : 
 str 
 , 
 schema_name 
 : 
 str 
 = 
 "public" 
 , 
 ) 
 - 
> llama_index_alloydb_pg 
 . 
 index_store 
 . 
 AlloyDBIndexStore 
 

Create a new AlloyDBIndexStore instance.

See more: llama_index_alloydb_pg.index_store.AlloyDBIndexStore.create

llama_index_alloydb_pg.index_store.AlloyDBIndexStore.create_sync

  create_sync 
 ( 
 engine 
 : 
 llama_index_alloydb_pg 
 . 
 engine 
 . 
 AlloyDBEngine 
 , 
 table_name 
 : 
 str 
 , 
 schema_name 
 : 
 str 
 = 
 "public" 
 , 
 ) 
 - 
> llama_index_alloydb_pg 
 . 
 index_store 
 . 
 AlloyDBIndexStore 
 

Create a new AlloyDBIndexStore sync instance.

See more: llama_index_alloydb_pg.index_store.AlloyDBIndexStore.create_sync

llama_index_alloydb_pg.index_store.AlloyDBIndexStore.delete_index_struct

  delete_index_struct 
 ( 
 key 
 : 
 str 
 ) 
 - 
> None 
 

llama_index_alloydb_pg.index_store.AlloyDBIndexStore.get_index_struct

  get_index_struct 
 ( 
 struct_id 
 : 
 typing 
 . 
 Optional 
 [ 
 str 
 ] 
 = 
 None 
 , 
 ) 
 - 
> typing 
 . 
 Optional 
 [ 
 llama_index 
 . 
 core 
 . 
 data_structs 
 . 
 data_structs 
 . 
 IndexStruct 
 ] 
 

llama_index_alloydb_pg.index_store.AlloyDBIndexStore.index_structs

  index_structs 
 () 
 - 
> list 
 [ 
 llama_index 
 . 
 core 
 . 
 data_structs 
 . 
 data_structs 
 . 
 IndexStruct 
 ] 
 

llama_index_alloydb_pg.indexes.BaseIndex.index_options

  index_options 
 () 
 - 
> str 
 

Set index query options for vector store initialization.

See more: llama_index_alloydb_pg.indexes.BaseIndex.index_options

llama_index_alloydb_pg.indexes.DistanceStrategy._generate_next_value_

  _generate_next_value_ 
 ( 
 start 
 , 
 count 
 , 
 last_values 
 ) 
 

Generate the next value when not given.

See more: llama_index_alloydb_pg.indexes.DistanceStrategy. generate_next_value

llama_index_alloydb_pg.indexes.HNSWIndex.index_options

  index_options 
 () 
 - 
> str 
 

Set index query options for vector store initialization.

See more: llama_index_alloydb_pg.indexes.HNSWIndex.index_options

llama_index_alloydb_pg.indexes.HNSWQueryOptions.to_parameter

  to_parameter 
 () 
 - 
> list 
 [ 
 str 
 ] 
 

Convert index attributes to list of configurations.

See more: llama_index_alloydb_pg.indexes.HNSWQueryOptions.to_parameter

llama_index_alloydb_pg.indexes.HNSWQueryOptions.to_string

  to_string 
 () 
 - 
> str 
 

Convert index attributes to string.

See more: llama_index_alloydb_pg.indexes.HNSWQueryOptions.to_string

llama_index_alloydb_pg.indexes.IVFFlatIndex.index_options

  index_options 
 () 
 - 
> str 
 

Set index query options for vector store initialization.

See more: llama_index_alloydb_pg.indexes.IVFFlatIndex.index_options

llama_index_alloydb_pg.indexes.IVFFlatQueryOptions.to_parameter

  to_parameter 
 () 
 - 
> list 
 [ 
 str 
 ] 
 

Convert index attributes to list of configurations.

See more: llama_index_alloydb_pg.indexes.IVFFlatQueryOptions.to_parameter

llama_index_alloydb_pg.indexes.IVFFlatQueryOptions.to_string

  to_string 
 () 
 - 
> str 
 

Convert index attributes to string.

See more: llama_index_alloydb_pg.indexes.IVFFlatQueryOptions.to_string

llama_index_alloydb_pg.indexes.IVFIndex.index_options

  index_options 
 () 
 - 
> str 
 

Set index query options for vector store initialization.

See more: llama_index_alloydb_pg.indexes.IVFIndex.index_options

llama_index_alloydb_pg.indexes.IVFQueryOptions.to_parameter

  to_parameter 
 () 
 - 
> list 
 [ 
 str 
 ] 
 

Convert index attributes to list of configurations.

See more: llama_index_alloydb_pg.indexes.IVFQueryOptions.to_parameter

llama_index_alloydb_pg.indexes.IVFQueryOptions.to_string

  to_string 
 () 
 - 
> str 
 

Convert index attributes to string.

See more: llama_index_alloydb_pg.indexes.IVFQueryOptions.to_string

llama_index_alloydb_pg.indexes.QueryOptions.to_parameter

  to_parameter 
 () 
 - 
> list 
 [ 
 str 
 ] 
 

Convert index attributes to list of configurations.

See more: llama_index_alloydb_pg.indexes.QueryOptions.to_parameter

llama_index_alloydb_pg.indexes.QueryOptions.to_string

  to_string 
 () 
 - 
> str 
 

Convert index attributes to string.

See more: llama_index_alloydb_pg.indexes.QueryOptions.to_string

llama_index_alloydb_pg.indexes.ScaNNIndex.index_options

  index_options 
 () 
 - 
> str 
 

Set index query options for vector store initialization.

See more: llama_index_alloydb_pg.indexes.ScaNNIndex.index_options

llama_index_alloydb_pg.indexes.ScaNNQueryOptions.to_parameter

  to_parameter 
 () 
 - 
> list 
 [ 
 str 
 ] 
 

Convert index attributes to list of configurations.

See more: llama_index_alloydb_pg.indexes.ScaNNQueryOptions.to_parameter

llama_index_alloydb_pg.indexes.ScaNNQueryOptions.to_string

  to_string 
 () 
 - 
> str 
 

Convert index attributes to string.

See more: llama_index_alloydb_pg.indexes.ScaNNQueryOptions.to_string

llama_index_alloydb_pg.reader.AlloyDBReader

  AlloyDBReader 
 ( 
 key 
 : 
 object 
 , 
 engine 
 : 
 AlloyDBEngine 
 , 
 reader 
 : 
 AsyncAlloyDBReader 
 , 
 is_remote 
 : 
 bool 
 = 
 True 
 , 
 ) 
 

AlloyDBReader constructor.

See more: llama_index_alloydb_pg.reader.AlloyDBReader

llama_index_alloydb_pg.reader.AlloyDBReader.alazy_load_data

  alazy_load_data 
 () 
 - 
> typing 
 . 
 AsyncIterable 
 [ 
 llama_index 
 . 
 core 
 . 
 schema 
 . 
 Document 
 ] 
 

Asynchronously load AlloyDB data into Document objects lazily.

See more: llama_index_alloydb_pg.reader.AlloyDBReader.alazy_load_data

llama_index_alloydb_pg.reader.AlloyDBReader.aload_data

  aload_data 
 () 
 - 
> list 
 [ 
 llama_index 
 . 
 core 
 . 
 schema 
 . 
 Document 
 ] 
 

Asynchronously load AlloyDB data into Document objects.

See more: llama_index_alloydb_pg.reader.AlloyDBReader.aload_data

llama_index_alloydb_pg.reader.AlloyDBReader.class_name

  class_name 
 () 
 - 
> str 
 

llama_index_alloydb_pg.reader.AlloyDBReader.create

  create 
 ( 
 engine 
 : 
 llama_index_alloydb_pg 
 . 
 engine 
 . 
 AlloyDBEngine 
 , 
 query 
 : 
 typing 
 . 
 Optional 
 [ 
 str 
 ] 
 = 
 None 
 , 
 table_name 
 : 
 typing 
 . 
 Optional 
 [ 
 str 
 ] 
 = 
 None 
 , 
 schema_name 
 : 
 str 
 = 
 "public" 
 , 
 content_columns 
 : 
 typing 
 . 
 Optional 
 [ 
 list 
 [ 
 str 
 ]] 
 = 
 None 
 , 
 metadata_columns 
 : 
 typing 
 . 
 Optional 
 [ 
 list 
 [ 
 str 
 ]] 
 = 
 None 
 , 
 metadata_json_column 
 : 
 typing 
 . 
 Optional 
 [ 
 str 
 ] 
 = 
 None 
 , 
 format 
 : 
 typing 
 . 
 Optional 
 [ 
 str 
 ] 
 = 
 None 
 , 
 formatter 
 : 
 typing 
 . 
 Optional 
 [ 
 typing 
 . 
 Callable 
 ] 
 = 
 None 
 , 
 is_remote 
 : 
 bool 
 = 
 True 
 , 
 ) 
 - 
> llama_index_alloydb_pg 
 . 
 reader 
 . 
 AlloyDBReader 
 

Asynchronously create an AlloyDBReader instance.

See more: llama_index_alloydb_pg.reader.AlloyDBReader.create

llama_index_alloydb_pg.reader.AlloyDBReader.create_sync

  create_sync 
 ( 
 engine 
 : 
 llama_index_alloydb_pg 
 . 
 engine 
 . 
 AlloyDBEngine 
 , 
 query 
 : 
 typing 
 . 
 Optional 
 [ 
 str 
 ] 
 = 
 None 
 , 
 table_name 
 : 
 typing 
 . 
 Optional 
 [ 
 str 
 ] 
 = 
 None 
 , 
 schema_name 
 : 
 str 
 = 
 "public" 
 , 
 content_columns 
 : 
 typing 
 . 
 Optional 
 [ 
 list 
 [ 
 str 
 ]] 
 = 
 None 
 , 
 metadata_columns 
 : 
 typing 
 . 
 Optional 
 [ 
 list 
 [ 
 str 
 ]] 
 = 
 None 
 , 
 metadata_json_column 
 : 
 typing 
 . 
 Optional 
 [ 
 str 
 ] 
 = 
 None 
 , 
 format 
 : 
 typing 
 . 
 Optional 
 [ 
 str 
 ] 
 = 
 None 
 , 
 formatter 
 : 
 typing 
 . 
 Optional 
 [ 
 typing 
 . 
 Callable 
 ] 
 = 
 None 
 , 
 is_remote 
 : 
 bool 
 = 
 True 
 , 
 ) 
 - 
> llama_index_alloydb_pg 
 . 
 reader 
 . 
 AlloyDBReader 
 

Synchronously create an AlloyDBReader instance.

See more: llama_index_alloydb_pg.reader.AlloyDBReader.create_sync

llama_index_alloydb_pg.reader.AlloyDBReader.lazy_load_data

  lazy_load_data 
 () 
 - 
> typing 
 . 
 Iterable 
 [ 
 llama_index 
 . 
 core 
 . 
 schema 
 . 
 Document 
 ] 
 

Synchronously aoad AlloyDB data into Document objects lazily.

See more: llama_index_alloydb_pg.reader.AlloyDBReader.lazy_load_data

llama_index_alloydb_pg.reader.AlloyDBReader.load_data

  load_data 
 () 
 - 
> list 
 [ 
 llama_index 
 . 
 core 
 . 
 schema 
 . 
 Document 
 ] 
 

Synchronously load AlloyDB data into Document objects.

See more: llama_index_alloydb_pg.reader.AlloyDBReader.load_data

llama_index_alloydb_pg.reader.AlloyDBReader.model_post_init

  model_post_init 
 ( 
 context 
 : 
 Any 
 , 
 / 
 ) 
 - 
> None 
 

This function is meant to behave like a BaseModel method to initialise private attributes.

See more: llama_index_alloydb_pg.reader.AlloyDBReader.model_post_init

llama_index_alloydb_pg.vector_store.AlloyDBVectorStore

  AlloyDBVectorStore 
 ( 
 key 
 : 
 object 
 , 
 engine 
 : 
 AlloyDBEngine 
 , 
 vs 
 : 
 AsyncAlloyDBVectorStore 
 , 
 stores_text 
 : 
 bool 
 = 
 True 
 , 
 is_embedding_query 
 : 
 bool 
 = 
 True 
 , 
 ) 
 

AlloyDBVectorStore constructor.

See more: llama_index_alloydb_pg.vector_store.AlloyDBVectorStore

llama_index_alloydb_pg.vector_store.AlloyDBVectorStore.aapply_vector_index

  aapply_vector_index 
 ( 
 index 
 : 
 llama_index_alloydb_pg 
 . 
 indexes 
 . 
 BaseIndex 
 , 
 name 
 : 
 typing 
 . 
 Optional 
 [ 
 str 
 ] 
 = 
 None 
 , 
 concurrently 
 : 
 bool 
 = 
 False 
 , 
 ) 
 - 
> None 
 

Create an index on the vector store table.

See more: llama_index_alloydb_pg.vector_store.AlloyDBVectorStore.aapply_vector_index

llama_index_alloydb_pg.vector_store.AlloyDBVectorStore.aclear

  aclear 
 () 
 - 
> None 
 

Asynchronously delete all nodes from the table.

See more: llama_index_alloydb_pg.vector_store.AlloyDBVectorStore.aclear

llama_index_alloydb_pg.vector_store.AlloyDBVectorStore.add

  add 
 ( 
 nodes 
 : 
 typing 
 . 
 Sequence 
 [ 
 llama_index 
 . 
 core 
 . 
 schema 
 . 
 BaseNode 
 ], 
 ** 
 add_kwargs 
 : 
 typing 
 . 
 Any 
 ) 
 - 
> list 
 [ 
 str 
 ] 
 

Synchronously add nodes to the table.

See more: llama_index_alloydb_pg.vector_store.AlloyDBVectorStore.add

llama_index_alloydb_pg.vector_store.AlloyDBVectorStore.adelete

  adelete 
 ( 
 ref_doc_id 
 : 
 str 
 , 
 ** 
 delete_kwargs 
 : 
 typing 
 . 
 Any 
 ) 
 - 
> None 
 

Asynchronously delete nodes belonging to provided parent document from the table.

See more: llama_index_alloydb_pg.vector_store.AlloyDBVectorStore.adelete

llama_index_alloydb_pg.vector_store.AlloyDBVectorStore.adelete_nodes

  adelete_nodes 
 ( 
 node_ids 
 : 
 typing 
 . 
 Optional 
 [ 
 list 
 [ 
 str 
 ]] 
 = 
 None 
 , 
 filters 
 : 
 typing 
 . 
 Optional 
 [ 
 llama_index 
 . 
 core 
 . 
 vector_stores 
 . 
 types 
 . 
 MetadataFilters 
 ] 
 = 
 None 
 , 
 ** 
 delete_kwargs 
 : 
 typing 
 . 
 Any 
 ) 
 - 
> None 
 

Asynchronously delete a set of nodes from the table matching the provided nodes and filters.

See more: llama_index_alloydb_pg.vector_store.AlloyDBVectorStore.adelete_nodes

llama_index_alloydb_pg.vector_store.AlloyDBVectorStore.adrop_vector_index

  adrop_vector_index 
 ( 
 index_name 
 : 
 typing 
 . 
 Optional 
 [ 
 str 
 ] 
 = 
 None 
 ) 
 - 
> None 
 

llama_index_alloydb_pg.vector_store.AlloyDBVectorStore.aget_nodes

  aget_nodes 
 ( 
 node_ids 
 : 
 typing 
 . 
 Optional 
 [ 
 list 
 [ 
 str 
 ]] 
 = 
 None 
 , 
 filters 
 : 
 typing 
 . 
 Optional 
 [ 
 llama_index 
 . 
 core 
 . 
 vector_stores 
 . 
 types 
 . 
 MetadataFilters 
 ] 
 = 
 None 
 , 
 ) 
 - 
> list 
 [ 
 llama_index 
 . 
 core 
 . 
 schema 
 . 
 BaseNode 
 ] 
 

Asynchronously get nodes from the table matching the provided nodes and filters.

See more: llama_index_alloydb_pg.vector_store.AlloyDBVectorStore.aget_nodes

llama_index_alloydb_pg.vector_store.AlloyDBVectorStore.ais_valid_index

  ais_valid_index 
 ( 
 index_name 
 : 
 typing 
 . 
 Optional 
 [ 
 str 
 ] 
 = 
 None 
 ) 
 - 
> bool 
 

Check if index exists in the table.

See more: llama_index_alloydb_pg.vector_store.AlloyDBVectorStore.ais_valid_index

llama_index_alloydb_pg.vector_store.AlloyDBVectorStore.apply_vector_index

  apply_vector_index 
 ( 
 index 
 : 
 llama_index_alloydb_pg 
 . 
 indexes 
 . 
 BaseIndex 
 , 
 name 
 : 
 typing 
 . 
 Optional 
 [ 
 str 
 ] 
 = 
 None 
 , 
 concurrently 
 : 
 bool 
 = 
 False 
 , 
 ) 
 - 
> None 
 

Create an index on the vector store table.

See more: llama_index_alloydb_pg.vector_store.AlloyDBVectorStore.apply_vector_index

llama_index_alloydb_pg.vector_store.AlloyDBVectorStore.aquery

  aquery 
 ( 
 query 
 : 
 llama_index 
 . 
 core 
 . 
 vector_stores 
 . 
 types 
 . 
 VectorStoreQuery 
 , 
 ** 
 kwargs 
 : 
 typing 
 . 
 Any 
 ) 
 - 
> llama_index 
 . 
 core 
 . 
 vector_stores 
 . 
 types 
 . 
 VectorStoreQueryResult 
 

Asynchronously query vector store.

See more: llama_index_alloydb_pg.vector_store.AlloyDBVectorStore.aquery

llama_index_alloydb_pg.vector_store.AlloyDBVectorStore.areindex

  areindex 
 ( 
 index_name 
 : 
 typing 
 . 
 Optional 
 [ 
 str 
 ] 
 = 
 None 
 ) 
 - 
> None 
 

Re-index the vector store table.

See more: llama_index_alloydb_pg.vector_store.AlloyDBVectorStore.areindex

llama_index_alloydb_pg.vector_store.AlloyDBVectorStore.aset_maintenance_work_mem

  aset_maintenance_work_mem 
 ( 
 num_leaves 
 : 
 int 
 , 
 vector_size 
 : 
 int 
 ) 
 - 
> None 
 

Set database maintenance work memory (for ScaNN index creation).

See more: llama_index_alloydb_pg.vector_store.AlloyDBVectorStore.aset_maintenance_work_mem

llama_index_alloydb_pg.vector_store.AlloyDBVectorStore.async_add

  async_add 
 ( 
 nodes 
 : 
 typing 
 . 
 Sequence 
 [ 
 llama_index 
 . 
 core 
 . 
 schema 
 . 
 BaseNode 
 ], 
 ** 
 kwargs 
 : 
 typing 
 . 
 Any 
 ) 
 - 
> list 
 [ 
 str 
 ] 
 

Asynchronously add nodes to the table.

See more: llama_index_alloydb_pg.vector_store.AlloyDBVectorStore.async_add

llama_index_alloydb_pg.vector_store.AlloyDBVectorStore.class_name

  class_name 
 () 
 - 
> str 
 

Get the class name, used as a unique ID in serialization.

See more: llama_index_alloydb_pg.vector_store.AlloyDBVectorStore.class_name

llama_index_alloydb_pg.vector_store.AlloyDBVectorStore.clear

  clear 
 () 
 - 
> None 
 

Synchronously delete all nodes from the table.

See more: llama_index_alloydb_pg.vector_store.AlloyDBVectorStore.clear

llama_index_alloydb_pg.vector_store.AlloyDBVectorStore.create

  create 
 ( 
 engine 
 : 
 llama_index_alloydb_pg 
 . 
 engine 
 . 
 AlloyDBEngine 
 , 
 table_name 
 : 
 str 
 , 
 schema_name 
 : 
 str 
 = 
 "public" 
 , 
 id_column 
 : 
 str 
 = 
 "node_id" 
 , 
 text_column 
 : 
 str 
 = 
 "text" 
 , 
 embedding_column 
 : 
 str 
 = 
 "embedding" 
 , 
 metadata_json_column 
 : 
 str 
 = 
 "li_metadata" 
 , 
 metadata_columns 
 : 
 list 
 [ 
 str 
 ] 
 = 
 [], 
 ref_doc_id_column 
 : 
 str 
 = 
 "ref_doc_id" 
 , 
 node_column 
 : 
 str 
 = 
 "node_data" 
 , 
 stores_text 
 : 
 bool 
 = 
 True 
 , 
 is_embedding_query 
 : 
 bool 
 = 
 True 
 , 
 distance_strategy 
 : 
 llama_index_alloydb_pg 
 . 
 indexes 
 . 
 DistanceStrategy 
 = 
 DistanceStrategy 
 . 
 COSINE_DISTANCE 
 , 
 index_query_options 
 : 
 typing 
 . 
 Optional 
 [ 
 llama_index_alloydb_pg 
 . 
 indexes 
 . 
 QueryOptions 
 ] 
 = 
 None 
 , 
 ) 
 - 
> llama_index_alloydb_pg 
 . 
 vector_store 
 . 
 AlloyDBVectorStore 
 

Create an AlloyDBVectorStore instance and validates the table schema.

See more: llama_index_alloydb_pg.vector_store.AlloyDBVectorStore.create

llama_index_alloydb_pg.vector_store.AlloyDBVectorStore.create_sync

  create_sync 
 ( 
 engine 
 : 
 llama_index_alloydb_pg 
 . 
 engine 
 . 
 AlloyDBEngine 
 , 
 table_name 
 : 
 str 
 , 
 schema_name 
 : 
 str 
 = 
 "public" 
 , 
 id_column 
 : 
 str 
 = 
 "node_id" 
 , 
 text_column 
 : 
 str 
 = 
 "text" 
 , 
 embedding_column 
 : 
 str 
 = 
 "embedding" 
 , 
 metadata_json_column 
 : 
 str 
 = 
 "li_metadata" 
 , 
 metadata_columns 
 : 
 list 
 [ 
 str 
 ] 
 = 
 [], 
 ref_doc_id_column 
 : 
 str 
 = 
 "ref_doc_id" 
 , 
 node_column 
 : 
 str 
 = 
 "node_data" 
 , 
 stores_text 
 : 
 bool 
 = 
 True 
 , 
 is_embedding_query 
 : 
 bool 
 = 
 True 
 , 
 distance_strategy 
 : 
 llama_index_alloydb_pg 
 . 
 indexes 
 . 
 DistanceStrategy 
 = 
 DistanceStrategy 
 . 
 COSINE_DISTANCE 
 , 
 index_query_options 
 : 
 typing 
 . 
 Optional 
 [ 
 llama_index_alloydb_pg 
 . 
 indexes 
 . 
 QueryOptions 
 ] 
 = 
 None 
 , 
 ) 
 - 
> llama_index_alloydb_pg 
 . 
 vector_store 
 . 
 AlloyDBVectorStore 
 

Create an AlloyDBVectorStore instance and validates the table schema.

See more: llama_index_alloydb_pg.vector_store.AlloyDBVectorStore.create_sync

llama_index_alloydb_pg.vector_store.AlloyDBVectorStore.delete

  delete 
 ( 
 ref_doc_id 
 : 
 str 
 , 
 ** 
 delete_kwargs 
 : 
 typing 
 . 
 Any 
 ) 
 - 
> None 
 

Synchronously delete nodes belonging to provided parent document from the table.

See more: llama_index_alloydb_pg.vector_store.AlloyDBVectorStore.delete

llama_index_alloydb_pg.vector_store.AlloyDBVectorStore.delete_nodes

  delete_nodes 
 ( 
 node_ids 
 : 
 typing 
 . 
 Optional 
 [ 
 list 
 [ 
 str 
 ]] 
 = 
 None 
 , 
 filters 
 : 
 typing 
 . 
 Optional 
 [ 
 llama_index 
 . 
 core 
 . 
 vector_stores 
 . 
 types 
 . 
 MetadataFilters 
 ] 
 = 
 None 
 , 
 ** 
 delete_kwargs 
 : 
 typing 
 . 
 Any 
 ) 
 - 
> None 
 

Synchronously delete a set of nodes from the table matching the provided nodes and filters.

See more: llama_index_alloydb_pg.vector_store.AlloyDBVectorStore.delete_nodes

llama_index_alloydb_pg.vector_store.AlloyDBVectorStore.drop_vector_index

  drop_vector_index 
 ( 
 index_name 
 : 
 typing 
 . 
 Optional 
 [ 
 str 
 ] 
 = 
 None 
 ) 
 - 
> None 
 

llama_index_alloydb_pg.vector_store.AlloyDBVectorStore.get_nodes

  get_nodes 
 ( 
 node_ids 
 : 
 typing 
 . 
 Optional 
 [ 
 list 
 [ 
 str 
 ]] 
 = 
 None 
 , 
 filters 
 : 
 typing 
 . 
 Optional 
 [ 
 llama_index 
 . 
 core 
 . 
 vector_stores 
 . 
 types 
 . 
 MetadataFilters 
 ] 
 = 
 None 
 , 
 ) 
 - 
> list 
 [ 
 llama_index 
 . 
 core 
 . 
 schema 
 . 
 BaseNode 
 ] 
 

Asynchronously get nodes from the table matching the provided nodes and filters.

See more: llama_index_alloydb_pg.vector_store.AlloyDBVectorStore.get_nodes

llama_index_alloydb_pg.vector_store.AlloyDBVectorStore.is_valid_index

  is_valid_index 
 ( 
 index_name 
 : 
 typing 
 . 
 Optional 
 [ 
 str 
 ] 
 = 
 None 
 ) 
 - 
> bool 
 

Check if index exists in the table.

See more: llama_index_alloydb_pg.vector_store.AlloyDBVectorStore.is_valid_index

llama_index_alloydb_pg.vector_store.AlloyDBVectorStore.model_post_init

  model_post_init 
 ( 
 context 
 : 
 Any 
 , 
 / 
 ) 
 - 
> None 
 

This function is meant to behave like a BaseModel method to initialise private attributes.

See more: llama_index_alloydb_pg.vector_store.AlloyDBVectorStore.model_post_init

llama_index_alloydb_pg.vector_store.AlloyDBVectorStore.query

  query 
 ( 
 query 
 : 
 llama_index 
 . 
 core 
 . 
 vector_stores 
 . 
 types 
 . 
 VectorStoreQuery 
 , 
 ** 
 kwargs 
 : 
 typing 
 . 
 Any 
 ) 
 - 
> llama_index 
 . 
 core 
 . 
 vector_stores 
 . 
 types 
 . 
 VectorStoreQueryResult 
 

Synchronously query vector store.

See more: llama_index_alloydb_pg.vector_store.AlloyDBVectorStore.query

llama_index_alloydb_pg.vector_store.AlloyDBVectorStore.reindex

  reindex 
 ( 
 index_name 
 : 
 typing 
 . 
 Optional 
 [ 
 str 
 ] 
 = 
 None 
 ) 
 - 
> None 
 

Re-index the vector store table.

See more: llama_index_alloydb_pg.vector_store.AlloyDBVectorStore.reindex

llama_index_alloydb_pg.vector_store.AlloyDBVectorStore.set_maintenance_work_mem

  set_maintenance_work_mem 
 ( 
 num_leaves 
 : 
 int 
 , 
 vector_size 
 : 
 int 
 ) 
 - 
> None 
 

Set database maintenance work memory (for ScaNN index creation).

See more: llama_index_alloydb_pg.vector_store.AlloyDBVectorStore.set_maintenance_work_mem

Design a Mobile Site
View Site in Mobile | Classic
Share by: