Transwarp Hippo is an enterprise-level cloud-native distributed vector database that supports storage, retrieval, and management of massive vector-based datasets. It efficiently solves problems such as vector similarity search and high-density vector clustering. Hippo features high availability, high performance, and easy scalability. It has many functions, such as multiple vector search indexes, data partitioning and sharding, data persistence, incremental data ingestion, vector scalar field filtering, and mixed queries. It can effectively meet the high real-time search demands of enterprises for massive vector data
Getting Started
The only prerequisite here is an API key from the OpenAI website. Make sure you have already started a Hippo instance.Installing Dependencies
Initially, we require the installation of certain dependencies, such as OpenAI, LangChain, and Hippo-API. Please note, that you should install the appropriate versions tailored to your environment.Best Practices
Importing Dependency Packages
Loading Knowledge Documents
Segmenting the Knowledge Document
Here, we use LangChain’s CharacterTextSplitter for segmentation. The delimiter is a period. After segmentation, the text segment does not exceed 1000 characters, and the number of repeated characters is 0.Declaring the Embedding Model
Below, we create the OpenAI or Azure embedding model using theOpenAIEmbeddings method from LangChain.
Declaring Hippo Client
Storing the Document
Conducting Knowledge-based Question and Answer
Creating a Large Language Question-Answering Model
Below, we create the OpenAI or Azure large language question-answering model respectively using the AzureChatOpenAI and ChatOpenAI methods from LangChain.Acquiring Related Knowledge Based on the Question
Constructing a Prompt Template
Waiting for the Large Language Model to Generate an Answer
Connect these docs programmatically to Claude, VSCode, and more via MCP for real-time answers.