Reputation: 1
Is it possible to change the datatype of an vector? When I for instance trying to save following object to /batch/objects
{
"fields": [
"ALL"
],
"objects": [
{
"id": "1112a0911b90de8277fc3fb45c97d3c3",
"vector": [
0.11111111111122222
],
"class": "Test"
}
]
}
Only 0.11111111 is being saved as the vector and I suppose it is because the datatype is float32
Upvotes: 0
Views: 527
Reputation: 7598
I think you've set the vector as a normal data type.
As you can see in the example below (from this demo dataset), you can see that what you call objects
actually has an objects properties
. It seems that you've set your vector as an array in properties
.
This Weaviate Core Knowledge section in the documentation might also be helpful.
{
"class": "Article",
"creationTimeUnix": 1664505085008,
"id": "000e4e5f-40a8-3981-ba08-2407c92efa6c",
"lastUpdateTimeUnix": 1664505086123740200,
"properties": {
"inPublication": [
{
"beacon": "weaviate://localhost/16476dca-59ce-395e-b896-050080120cd4",
"href": "/v1/objects/16476dca-59ce-395e-b896-050080120cd4"
}
],
"summary": "Mission accomplished for Florida International's James Morgan, Charlotte's Benny LeMay and Navy's Malcolm Perry in the East-West Shrine Bowl. The trio shined for the East in a 31-27 victory, with Morgan leading two first-quarter touchdown drives and LeMay rushing for a pair of TDs, including the game-winner. Perry took a direct snap from center and sprinted 52 yards for a TD on his only carry. Robinson, who rushed for 1,899 yards and 18 touchdowns for Illinois State this season, finished with 80 yards rushing on seven attempts. Stevens also had an 18-yard completion to Rhode Island's Aaron Parker to set up LeMay's second touchdown.",
"title": "LeMay's 2 TDs lead East over West 31-27 in Shrine Bowl",
"url": "http://www.foxnews.com/sports/lemays-2-tds-lead-east-over-west-31-27-in-shrine-bowl",
"wordCount": 411
},
"vector": [
-0.09015006,
0.11759494,
0.024284547,
// etc
]
}
Upvotes: 0