CallCabinSecureLanding+Takeoff added

This commit is contained in:
hubobel 2025-12-29 16:30:09 +01:00
parent 36fb6e2888
commit a8a3bdc028
14 changed files with 58 additions and 35 deletions

View file

@ -341,6 +341,19 @@ def METAR():
prompt2 = prompt_org + 'Die METAR lautet ' + metar_dest
antwort_AI = ai(prompt2)
return antwort_AI
def CallCabinSecureTakeoff():
prompt_org = ("Hey " + passw['Prompt']['CptName'] + "hier ist " + passw['Prompt']['PurserName'] +
" von der EEins Links. Die Kabine ist sicher und bereit für den Flug nach " + dest_name)
prompt_org = "Formuliere diesen Satz um: " + prompt_org + "Du bist dabei eher " + Stimmung
antwort_AI = ai(prompt_org)
return antwort_AI
def CallCabinSecureLanding():
prompt_org = ("Hey " + passw['Prompt']['CptName'] + "hier ist " + passw['Prompt']['PurserName'] +
" von der EEins Links. Die Kabine ist sicher und bereit für die Landung in " + dest_name)
prompt_org = "Formuliere diesen Satz um: " + prompt_org + "Du bist dabei eher " + Stimmung
antwort_AI = ai(prompt_org)
return antwort_AI
def replaceFiles():
files = []
for datei in Path(Pfad_wd).glob("*.txt"):
@ -587,9 +600,23 @@ if debug == False:
Safety = "\n".join(filter(None, map(str.strip, Safety.splitlines())))
logging.info("SafetyBriefing erzeugt")
Pfad = Pfad_wd + 'BoardingWelcomePilot.txt'
txtSave(Pfad, Inhalt)
pfad_txt = Path(Pfad_wd) / "BoardingWelcomePilot.txt"
SecureTakeoff = CallCabinSecureTakeoff().choices[0].message.content
SecureTakeoff = "\n".join(filter(None, map(str.strip, SecureTakeoff.splitlines())))
logging.info("CallCabinSecureTakeoff erzeugt")
Pfad = Pfad_wd + 'CallCabinSecureTakeoff.txt'
txtSave(Pfad, SecureTakeoff)
pfad_txt = Path(Pfad_wd) / "CallCabinSecureTakeoff.txt"
pfad_ogg = pfad_txt.with_suffix(".ogg")
delete(pfad_ogg)
SecureLanding = CallCabinSecureLanding().choices[0].message.content
SecureLanding = "\n".join(filter(None, map(str.strip, SecureLanding.splitlines())))
logging.info("CallSecureLanding erzeugt")
Pfad = Pfad_wd + 'CallCabinSecureLanding.txt'
txtSave(Pfad, SecureLanding)
pfad_txt = Path(Pfad_wd) / "CallCabinSecureLanding.txt"
pfad_ogg = pfad_txt.with_suffix(".ogg")
delete(pfad_ogg)
@ -623,6 +650,10 @@ if debug == False:
pfad_ogg = pfad_txt.with_suffix(".ogg")
delete(pfad_ogg)
logging.info("--------------------------------------------------")
logging.info(" F E R T S C H ")
logging.info("--------------------------------------------------")