Resolve merges

This commit is contained in:
karoel2 2022-06-15 10:51:36 +02:00
parent 5a30aeded7
commit a6afe30b7f
2 changed files with 24 additions and 1 deletions

View File

@ -79,6 +79,7 @@ def generator_jezyka_nautalnego(frame, tactic, state, text):
elif tactic[0] == True:
_, act, req_args, opt_args = tactic
print('DEBUG: ', act, 'req', req_args, opt_args,sep = '\n')
if act == 'help':
print(random.choice(help))
print("Dostępne komendy: \n - " + '\n - '.join(commands))
@ -109,7 +110,30 @@ def generator_jezyka_nautalnego(frame, tactic, state, text):
print(pr['state'])
print()
elif act == 'brefing':
print("Podsumowanie w repozytorium " + find(req_args, 'repo')[0] + ":")
brefings = getBrefing()
for brefing in brefings:
print(brefing['name'])
print(brefing['description'])
print()
elif act == 'tests':
print("Lista testów w repozytorium " + find(req_args, 'repo')[0] + ":")
tests = listRepositoryTests(find(req_args, 'repo')[0])
for test in tests:
print(test['name'])
print(test['description'])
print(test['status'])
print()
elif act == 'notifications':
print("Lista powidomień w repozytorium " + find(req_args, 'repo')[0] + ":")
notifications = listNotifications(find(req_args, 'repo')[0])
for notification in notifications:
print(notification['name'])
print(notification['description'])
print()
#
# elif tactic[0] == 'QUESTION' and act[0] == 'repo':
# print("Dodaj nazwę repozytorium na końcu komendy")

View File

@ -40,7 +40,6 @@ def monitor_stanu_dialogowego(frame):
def append_or_merge_frame(frame, dialogue_state):
act = frame['act']
act_from_state = list(filter(lambda x: x['act'] == act, dialogue_state['topics']))
if len(act_from_state) > 0:
append_or_merge_slots(frame['slots'], act_from_state[0]['slots'])