triple generation for inverse and non-inverse relations