in dataset that start with 'doc':", len(results))    Job: doctor    Job: doctor    Jobs in dataset that start with 'doc': 2from langchain.vectorstores.redis import RedisNumis_over_18 = RedisNum("age") > 18is_under_99 = RedisNum("age") < 99age_range = is_over_18 & is_under_99results = rds.similarity_search("foo", filter=age_range)for result in results:    print("User:", result.metadata["user"], "is", result.metadata["age"])    User: derrick is 45    User: nancy is 94    User: joe is 35# make sure to use parenthesis around FilterExpressions# if initializing them while constructing themage_range = (RedisNum("age") > 18) & (RedisNum("age") < 99)results = rds.similarity_search("foo", filter=age_range)for result in results:    print("User:", result.metadata["user"], "is", result.metadata["age"])    User: derrick is 45    User: nancy is 94    User: joe is 35Redis as Retrieverâ€‹Here we go over different options for using the vector store as a retriever.There are three different search methods we can use to do retrieval. By default, it will use semantic similarity.query = "foo"results = rds.similarity_search_with_score(query, k=3, return_metadata=True)for result in results:    print("Content:", result[0].page_content, " --- Score: ", result[1])    Content: foo  --- Score:  0.0    Content: foo  --- Score:  0.0    Content: foo  --- Score:  0.0retriever = rds.as_retriever(search_type="similarity", search_kwargs={"k": 4})docs = retriever.get_relevant_documents(query)docs    [Document(page_content='foo', metadata={'id': 'doc:users_modified:988ecca7574048e396756efc0e79aeca', 'user': 'john', 'job': 'engineer', 'credit_score': 'high', 'age': '18'}),     Document(page_content='foo', metadata={'id': 'doc:users_modified:009b1afeb4084cc6bdef858c7a99b48e', 'user': 'derrick', 'job': 'doctor', 'credit_score': 'low', 'age': '45'}),     Document(page_content='foo', metadata={'id': 'doc:users_modified:7087cee9be5b4eca93c30fbdd09a2731', 'user': 'nancy', 'job': 'doctor', 'credit_score':
Redis vector database introduction and langchain integration guide.
Redis vector database introduction and langchain integration guide. ->: in dataset that start with 'doc':", len(results))    Job: doctor    Job: doctor    Jobs in dataset that start with 'doc': 2from langchain.vectorstores.redis import RedisNumis_over_18 = RedisNum("age") > 18is_under_99 = RedisNum("age") < 99age_range = is_over_18 & is_under_99results = rds.similarity_search("foo", filter=age_range)for result in results:    print("User:", result.metadata["user"], "is", result.metadata["age"])    User: derrick is 45    User: nancy is 94    User: joe is 35# make sure to use parenthesis around FilterExpressions# if initializing them while constructing themage_range = (RedisNum("age") > 18) & (RedisNum("age") < 99)results = rds.similarity_search("foo", filter=age_range)for result in results:    print("User:", result.metadata["user"], "is", result.metadata["age"])    User: derrick is 45    User: nancy is 94    User: joe is 35Redis as Retrieverâ€‹Here we go over different options for using the vector store as a retriever.There are three different search methods we can use to do retrieval. By default, it will use semantic similarity.query = "foo"results = rds.similarity_search_with_score(query, k=3, return_metadata=True)for result in results:    print("Content:", result[0].page_content, " --- Score: ", result[1])    Content: foo  --- Score:  0.0    Content: foo  --- Score:  0.0    Content: foo  --- Score:  0.0retriever = rds.as_retriever(search_type="similarity", search_kwargs={"k": 4})docs = retriever.get_relevant_documents(query)docs    [Document(page_content='foo', metadata={'id': 'doc:users_modified:988ecca7574048e396756efc0e79aeca', 'user': 'john', 'job': 'engineer', 'credit_score': 'high', 'age': '18'}),     Document(page_content='foo', metadata={'id': 'doc:users_modified:009b1afeb4084cc6bdef858c7a99b48e', 'user': 'derrick', 'job': 'doctor', 'credit_score': 'low', 'age': '45'}),     Document(page_content='foo', metadata={'id': 'doc:users_modified:7087cee9be5b4eca93c30fbdd09a2731', 'user': 'nancy', 'job': 'doctor', 'credit_score':