Skip to content

Commit

Permalink
docs: Update README.md (#22)
Browse files Browse the repository at this point in the history
  • Loading branch information
averikitsch committed Feb 23, 2024
1 parent f94f7a2 commit e9eb86b
Showing 1 changed file with 20 additions and 0 deletions.
20 changes: 20 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 33,25 @@ source <your-env>/bin/activate
<your-env>/bin/pip install langchain-google-spanner
```

## Vector Store Usage

Use a vector store to store embedded data and perform vector search.

```python
from langchain_google_sapnner import SpannerVectorstore
from langchain.embeddings import VertexAIEmbeddings

embeddings_service = VertexAIEmbeddings()
vectorstore = SpannerVectorStore(
instance_id="my-instance",
database_id="my-database",
table_name="my-table",
embeddings=embedding_service
)
```

See the full [Vector Store][vectorstore] tutorial.

## Document Loader Usage

Use a document loader to load data as LangChain `Document`s.
Expand Down Expand Up @@ -94,4 113,5 @@ This is not an officially supported Google product.
[venv]: https://virtualenv.pypa.io/en/latest/
[loader]: ./docs/document_loader.ipynb
[history]: ./docs/chat_message_history.ipynb
[vectorstore]: ./docs/vector_store.ipynb
[langchain]: https://github.com/langchain-ai/langchain

0 comments on commit e9eb86b

Please sign in to comment.