我在Weaviate中创建了一个具有多个属性的模式。使用以下方法:
for row in tqdm(data, total=len(data)):
client.data_object.create(data_object=row, class_name=INDEX_NAME)
以下是数据示例(1行):
{'Table_Name': 'Cust', 'Column_Name': 'Amount', 'Data_Type': 'Number', 'Table_Description': 'customer table', 'Column_Description': 'total transaction amount'}
langchain如何通过Weaviate()类访问多个键对象(参见上面的示例)?
vectorstore = Weaviate(weaviate_client, INDEX_NAME, <??>)
当没有传递第三个参数来获取所有对象时,我会得到以下错误:
Traceback (most recent call last):
File "/Users/main.py", line 43, in <module>
vectorstore = populate_data(weaviate_client)
File "/Users/main.py", line 39, in populate_data
return Weaviate(weaviate_client, INDEX_NAME)
TypeError: __init__() missing 1 required positional argument: 'text_key'