
import sys
import os
sys.path.append(os.path.dirname(__file__)+"/..")
import argparse

def main(args=None):
    parser = argparse.ArgumentParser()
    parser.add_argument("--product_dict_synchonize",dest="product_dict_synchonize",action="store_true",help="start product_dict_synchonize process")
    parser.add_argument("--delete_product_collections",dest="delete_product_collections",action="store_true",help="start product_dict_synchonize process")
    parser.add_argument("--search_similar",dest="search_similar",action="store_true",help="start product_dict_synchonize process")
    parser.add_argument("--start_process_product",dest="start_process_product",action="store_true",help="start product_dict_synchonize process")
    parser.add_argument("--test",dest="test",action="store_true",help="start product_dict_synchonize process")
    parser.add_argument("--start_extract_parameter",dest="start_extract_parameter",action="store_true",help="start extract_parameter")

    args = parser.parse_args(args)
    if args.product_dict_synchonize:
        from BaseDataMaintenance.maintenance.product.product_dict import start_embedding_product_dict
        start_embedding_product_dict()
    if args.delete_product_collections:
        from BaseDataMaintenance.maintenance.product.product_dict import drop_product_dict_collections
        drop_product_dict_collections()
    if args.search_similar:
        from BaseDataMaintenance.maintenance.product.product_dict import search_similar
        search_similar()
    if args.start_process_product:
        from BaseDataMaintenance.maintenance.product.products import start_process_product
        start_process_product()
    if args.test:
        from BaseDataMaintenance.maintenance.product.products import test
        test()
    if args.start_extract_parameter:
        from BaseDataMaintenance.maintenance.product.product_parameter import start_process_parameters
        start_process_parameters()


if __name__ == '__main__':
    main()