add present? to relations
split core into multiple files
replaced puts with debug