forked from Marsan-Ma-zz/tf_chatbot_seq2seq_antilm
-
Notifications
You must be signed in to change notification settings - Fork 2
/
main.py
28 lines (21 loc) · 588 Bytes
/
main.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
import os, sys, argparse
sys.path.append(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))
import tensorflow as tf
from lib.config import params_setup
from lib.train import train
from lib.predict import predict
from lib.chat import chat
# from lib.mert import mert
def main(_):
args = params_setup()
print("[args]: ", args)
if args.mode == 'train':
train(args)
elif args.mode == 'test':
predict(args)
elif args.mode == 'chat':
chat(args)
# elif args.mode == 'mert':
# mert(args)
if __name__ == "__main__":
tf.app.run()