Hello.
My goal:
Build a product recommendation system in which the choice of product to be offered to the user will be based on the user’s similarity with other users and the products they have.
To do this, I would like (please correct me if there is a more rational way):
- Check the user’s similarity with other users based on his properties (Age, income, etc.)
- Based on relationships of similar users with products, receive products that may be of interest to the user for whom we are making calculations.
I built a simple graph to explore how such a process could be built.
It consists of:
- Users
- Several cards presented in the form of products
- Several insurances presented in the form of products
Data structure:
CREATE
(maxDoe:AccountHolder {
name: "Max",
ekbId: "1001",
phone: "",
address: "Lisabon",
gender: "male",
creditLimit: 100000,
age: 30,
monthIncome: 20000
}),
(yevheniiDoe:AccountHolder {
name: "Yevhenii",
ekbId: "1002",
phone: "",
address: "Lviv",
gender: "male",
creditLimit: 90000,
age: 31,
monthIncome: 5000
}),
(vasiliyDoe:AccountHolder {
name: "Vasiliy",
ekbId: "1003",
phone: "",
address: "Lviv",
gender: "male",
creditLimit: 50000,
age: 31,
monthIncome: 3000
}),
(ahmedDoe:AccountHolder {
name: "Ahmed",
ekbId: "1004",
phone: "",
address: "Dubai",
gender: "male",
creditLimit: 0,
age: 50,
monthIncome: 50000
}),
(fredDoe:AccountHolder {
name: "Fred",
ekbId: "1005",
phone: "",
address: "Pokhara",
gender: "female",
creditLimit: 0,
age: 45,
monthIncome: 500
}),
(insuranceProducts:InsuranceProduct {
name: "Insurance Products",
activeOcagoAmount: 10,
activeKaskoAmount: 30,
activeHealth: 0,
totalActive: 40
}),
(carInsurance:InsuranceCategory {
name: "Car Insurance",
categoryName: "carInsurance",
categoryId: 1,
data: "{}"
}),
(osagoInsurance:InsuranceSubcategory{
name: "OSAGO",
categoryName: "carInsurance",
categoryId: 1,
subcategoryName: "osago",
subcategoryId: 1,
data: "{}"
}),
(greenCardInsurance:InsuranceSubcategory{
name: "Green Card",
categoryName: "carInsurance",
categoryId: 1,
subcategoryName: "greenCard",
subcategoryId: 2,
data: "{}"
}),
(kaskoInsurance:InsuranceSubcategory{
name: "KASKO",
categoryName: "carInsurance",
categoryId: 1,
subcategoryName: "kasko",
subcategoryId: 3,
data: "{}"
}),
(liveInsurance:InsuranceCategory{
name: "Live Insurance",
categoryName: "liveInsurance",
categoryId: 1,
data: "{}"
}),
(cardProducts:CardProduct{
name: "Card Products",
creditCardAmount: 0,
debitCardAbount: 0
}),
(creditCard:Card{
name: "Credit card",
type: "credit",
data: "{}"
}),
(debitCard:Card{
name: "Debit card",
type: "debit",
data: "{}"
})
CREATE
(osagoInsurance)-[:SUBCATEGORY_OF]->(carInsurance),
(greenCardInsurance)-[:SUBCATEGORY_OF]->(carInsurance),
(kaskoInsurance)-[:SUBCATEGORY_OF]->(carInsurance),
(carInsurance)-[:TYPE_OF]->(insuranceProducts),
(liveInsurance)-[:TYPE_OF]->(insuranceProducts),
(creditCard)-[:TYPE_OF]->(cardProducts),
(debitCard)-[:TYPE_OF]->(cardProducts),
(maxDoe)-[:OWNS{amount: 1}]->(kaskoInsurance),
(maxDoe)-[:OWNS{amount: 1}]->(greenCardInsurance),
(yevheniiDoe)-[:OWNS{amount: 1}]->(kaskoInsurance),
(yevheniiDoe)-[:OWNS{amount: 1}]->(greenCardInsurance),
(vasiliyDoe)-[:OWNS{amount: 1}]->(kaskoInsurance),
(ahmedDoe)-[:OWNS{amount: 1}]->(osagoInsurance),
(ahmedDoe)-[:OWNS{amount: 1}]->(greenCardInsurance),
(fredDoe)-[:OWNS{amount: 1}]->(osagoInsurance),
(maxDoe)-[:OWNS{amount: 1}]->(creditCard),
(maxDoe)-[:OWNS{amount: 1}]->(debitCard),
(yevheniiDoe)-[:OWNS{amount: 1}]->(debitCard),
(vasiliyDoe)-[:OWNS{amount: 1}]->(creditCard),
(ahmedDoe)-[:OWNS{amount: 1}]->(creditCard),
(ahmedDoe)-[:OWNS{amount: 1}]->(debitCard),
(fredDoe)-[:OWNS{amount: 1}]->(debitCard)
I started studying the "Node Similarity", but so far I can't adapt the examples from it to my graph.
Perhaps you will have recommendations for good articles or examples of implementing a similar idea.
I would be grateful for any feedback.
Thank you.