The setup is based on the slideshow below.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
= Untying the Graph Database Import Knot = | |
This Graphgist accompanies http://blog.bruggen.com/2013/12/untying-graph-database-import-knot.html[my blogpost of December 6th, 2013] which tries to explain the different types of questions that people should be asking themselves when thinking about importing data into http://www.neo4j.org[neo4j], and the tools that can contribute to finding the most optimal import strategy for your specific use case. | |
//setup | |
//hide | |
[source,cypher] | |
---- | |
create (n1:Tool {id:'1',name:'Spreadsheets'}), | |
(n2:Tool {id:'2',name:'Cypher Statements'}), |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
= People, books and cities | |
=== “Those who find ugly meanings in beautiful things are corrupt without being charming. This is a fault. Those who find beautiful meanings in beautiful things are the cultivated. For these there is hope. They are the elect to whom beautiful things mean only Beauty. There is no such thing as a moral or an immoral book. Books are well written, or badly written. That is all.” | |
― Oscar Wilde, The Picture of Dorian Gray | |
image::http://i.imgur.com/425PvXE.jpg[] | |
== Modeling the Graph | |
Let's take a look at the domain model: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
# encoding: utf-8 | |
''' | |
linkedin-query.py | |
Created by Thomas Cabrol on 2012-12-03. | |
Customised by Rik Van Bruggen | |
Customised by Torbjorn Sjogren | |
Copyright (c) 2012 dataiku. All rights reserved. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
create ({id:'1',name:'DeepPAX',type:'ShopArticle'}); | |
create ({id:'112996',name:'Screw',type:'Component'}); | |
create ({id:'124593',name:'Nail',type:'Component'}); | |
create ({id:'113434',name:'ScrewLock',type:'Component'}); | |
create ({id:'101375',name:'WoodStick',type:'Component'}); | |
create ({id:'100402',name:'Screw',type:'Component'}); | |
create ({id:'100644',name:'Screw',type:'Component'}); | |
create ({id:'100347',name:'Screw',type:'Component'}); | |
create ({id:'103693',name:'LockPlate',type:'Component'}); | |
create ({id:'123773',name:'CornerCover',type:'Component'}); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
= IKEA GraphGist = | |
This gist is to complement the http://blog.bruggen.com/2013/09/ikea-wardrobes-and-graphs-perfect-fit.html[more elaborate blogpost] that I wrote about using http://neo4j.org[neo4j] to model the partlist and the assembly process of two IKEA wardrobes. | |
First, we will create a part of the graph using this model: | |
image::https://lh4.googleusercontent.com/7XxUuCjnFtDhO-JAI5Ia6tcYZkQoMfcv_1pNE0mTA2cx76vIySrBU0z0tnykAPvqsMrZZD-cca3Q7ca-ERI0f5sDsGAUCEJTIx7wt15mxKhFEXeYFrZD_vEGJQ[] | |
[source,cypher] | |
---- |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
= Organization Learning | |
Learning Management Systems (LMS) are typically deployed in large organizations to support learning processes that align with business goals. These systems tie together their employees, organizations, certifications, courses, jobs in order to supplement business strategy. | |
This graph gist models a slice of this ecosystem- certification paths and position dependencies on certifications. | |
== Domain | |
A certification has one or more learning paths. A learning path is an ordered sequence of items that must be completed in order to acquire the certification. A learning item can be completed by taking a course or proving work experience. A course has a delivery type- it can be web based or classroom. Work Experience specifies the number of hours one must put in to complete it. | |
To aquire a certification, an employee can take take any learning path and complete every item in it. | |
Employees hold certifications and complete courses and work experience. An employee may fill a position which require |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
= Business Rule / Recommendation gist = | |
In this simple example, we want to highlight the power of graphs to describe, discover, visualise and implement powerful business rule-based recommendations. | |
In the example, we will create a simple graph containing | |
- a +person+ ("Rik") | |
- a +city+ ("London") | |
- an +age+ ("39") | |
- a +child+ ("Toon") | |
and all the required relationships from the person to the city, to his age, and his child. |
Welcome to the wonderful world of Harry Potter!
v0 of this graph models some of Harrys friends, enemies and their parents. Also have some pets and a few killings. The obvious relation missing is the one between Harry Potter and Voldemort- it took us 7 books to figure that one out, so you’ll have to wait till I add more data :-)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Option Explicit | |
'for more about this | |
' http://ramblings.mcpher.com/Home/excelquirks/classeslink/data-manipulation-classes | |
'to contact me | |
' http://groups.google.com/group/excel-ramblings | |
'reuse of code | |
' http://ramblings.mcpher.com/Home/excelquirks/codeuse | |
' google rules and api documentation | |
' http://code.google.com/apis/patentsearch/v1/jsondevguide.html |