added Graph#put method
initial refactoring in order to support AMD loading