#ESTABLISH THE SERVER | |
from flask import Flask,request | |
from flask_cors import CORS | |
from dotenv import load_dotenv | |
# Initializing flask app | |
app = Flask(__name__) | |
CORS(app) | |
load_dotenv() | |
def index(): | |
from agent._create import agent | |
return agent(request.values) | |
def train_faq(): | |
from train.faq import train | |
return train(); | |
def train_products(): | |
from train.products import train | |
return train(); | |
#from train.faq import train | |
#train(); | |
#from agent._create import agent | |
#agent({}) | |