jproman's picture
ready to start developing agent specifics
16f1cd8
raw
history blame
604 Bytes
from flow import createFlow
from logger import Logger
import config
class Agent:
def __init__(self, logger):
self.logger = logger
def invoke(self, question):
flow = createFlow(self.logger)
shared = { "question": question }
flow.run(shared)
return shared["answer"]
if __name__ == "__main__":
from assignment_utils import getQuestionByPos
logger = Logger(config.logLevel,config.logFile)
agent = Agent(logger)
question = getQuestionByPos(0)
print(question)
#response = agent.invoke(question['question'])
#print(response)