predictionio-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dennis Honders <dennishond...@gmail.com>
Subject Only one result Universal Recommender
Date Tue, 23 May 2017 14:23:12 GMT
I trained and deployed the universal recommender.
I only get the populair products as a result.

*Trainingdata*

[
{"event": "cart-transaction", "entityId": "1", "entityType": "user",
"targetEntityId": "12", "targetEntityType": "item"},
{"event": "cart-transaction", "entityId": "1", "entityType": "user",
"targetEntityId": "13", "targetEntityType": "item"},
{"event": "cart-transaction", "entityId": "1", "entityType": "user",
"targetEntityId": "14", "targetEntityType": "item"}
]‚Äč

{"event": "$set", "entityType": "item", "entityId": "12", "properties":
{"category": ["1", "2", "3", "4", "5", "6", "7"], "manufacturer": 1,
"label": "test", "price": "$1-$2"}}

*Query*
curl -H "Content-Type: application/json" -d { "item": ["1"]}
http://localhost:8000/queries.json

curl -H "Content-Type: application/json" -d { "items": ["1"]}
http://localhost:8000/queries.json

curl -H "Content-Type: application/json" -d { "cart-transaction": ["1"]}
http://localhost:8000/queries.json

*Result*
The populair (most bought) items, also for products that are sold a lot.

Log:

[INFO] [URAlgorithm] No user id for recs, returning item-based recs if an
item is specified in the query.
[INFO] [URAlgorithm] Query:
{"size":10,"query":{"bool":{"should":[{"terms":{"cart-transaction":[]}},{"constant_score":{"filter":{"match_all":{}},"boost":0}}],"must":[],"must_not":[{"ids":{"values":[],"boost":0}}],"minimum_should_match":1}},"sort":[{"_score":{"order":"desc"}},{"popRank":{"unmapped_type":"double","order":"desc"}}]}
[INFO] [URAlgorithm] Results: 10 retrieved of a possible 70658

Is the query correct?

What else could be the problem here?

Note: I also like to return 'similar items' (based on properties) when no
relation could be found with 'buy'.

Mime
View raw message