fixed pattern loading and insertion