More work on dataset insertion api