Skip to content

Commit

Permalink
Added is_synced in docs
Browse files Browse the repository at this point in the history
  • Loading branch information
Vits-99 committed Oct 4, 2024
1 parent 01b0103 commit 23ecf40
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion docs/source/route_layer/sync.rst
Original file line number Diff line number Diff line change
Expand Up @@ -67,4 +67,10 @@ You can try this yourself by running the following:
rl = RouteLayer(encoder=encoder, routes=routes, index=pc_index)
When initializing the `PineconeIndex` object, we can specify the `sync` parameter.
When initializing the `PineconeIndex` object, we can specify the `sync` parameter.

Checking for Synchronization
----------------------------

To verify whether the local and remote instances are synchronized, you can use the `is_synced` method. This method checks if the routes, utterances, and associated metadata in the local instance match those stored in the remote index.
Consider that if the `sync` flag is not set (e.g. for indexes different from Pinecone), it raises an error. If the index supports sync feature and everything aligns, it returns `True`, indicating that the local and remote instances are synchronized, otherwise it returns `False`.

0 comments on commit 23ecf40

Please sign in to comment.