def update_parser(parser):
    """Parse the arguments from the CLI and update the parser."""    
    parser.add_argument(
        '--prepro_step',
        type=str,
        default='preprocessing', #'slicing', 'preprocessing'
        help='To execute a preprocessing method')    
    #this is for allfeatures_preprocessing:
    parser.add_argument(
        '--train_period',
        type=int,
        nargs='*',
        default=[121,323], #[156, 180], [121,143],  # 279],
        help='Training Period')
    parser.add_argument(
        '--valid_period',
        type=int,
        nargs='*',
        default=[324,329], #[181,185], [144,147],
        help='Validation Period')    
    parser.add_argument(
        '--test_period',
        type=int,
        nargs='*',
        default= [330, 342], # [186,191], [148, 155],
        help='Testing Period')    
    parser.add_argument(
        '--prepro_dir',
        type=str,
        default='chuncks_random_c1mill',
        help='Directory with raw data inside data/raw/ and it will be the output directory inside data/processed/')    
    parser.add_argument(
        '--prepro_chunksize',
        type=int,
        default=500000,
        help='Chunk size to put into the h5 file...')    
    parser.add_argument(
        '--prepro_with_index',
        type=bool,
        default=True,
        help='To keep indexes for each record')
    parser.add_argument(
        '--ref_norm',
        type=bool,
        default=True,
        help='To execute the normalization over the raw inputs')
    
    #to execute slice_table_sets:
    parser.add_argument(
        '--slice_input_dir',
        type=str,
        default='chuncks_random_c1mill',
        help='Input data directory')
    parser.add_argument(
        '--slice_output_dir',
        type=str,
        nargs='*',
        default=['chuncks_random_c1mill_train', 'chuncks_random_c1mill_valid', 'chuncks_random_c1mill_test'],
        help='Output data directory. Input and output could be the same per group, it is recommendable different directories...')
    parser.add_argument(
        '--slice_tag',
        type=str,
        nargs='*',
        default=['train', 'valid', 'test'],
        help='features group to be extracted')
    parser.add_argument(
        '--slice_target_name',
        type=str,
        nargs='*',
        default=['c1mill99-01_train', 'c1mill99-01_valid', 'c1mill99-01_test'],
        help='file name root inside output directory')
    parser.add_argument(
        '--slice_chunksize',
        type=int,
        default=1000,
        help='Chunk size to put into the h5 output files...')
    parser.add_argument(
        '--slice_target_size',
        type=int,
        default=36000000,
        help='Output file size')
    parser.add_argument(
        '--slice_with_index',
        type=bool,
        default=False,
        help='To keep indexes for each record')
    parser.add_argument(
        '--slice_index',
        type=int,
        default=0,
        help='index to label each output file')       
    
    return parser.parse_known_args()