Josedcape commited on
Commit
29320a2
·
verified ·
1 Parent(s): c200462

Update agent_functions.py

Browse files
Files changed (1) hide show
  1. agent_functions.py +2 -2
agent_functions.py CHANGED
@@ -83,7 +83,7 @@ def generar_pdf_orden(order_details, filepath='orden_compra.pdf'):
83
  c.save()
84
  return filepath
85
 
86
- def obtener_respuesta(pregunta, texto_preprocesado, modelo="gpt-4", temperatura=0.5):
87
  try:
88
  response = openai.ChatCompletion.create(
89
  model=modelo,
@@ -98,7 +98,7 @@ def obtener_respuesta(pregunta, texto_preprocesado, modelo="gpt-4", temperatura=
98
  # Configura la solicitud de síntesis de voz
99
  input_text = texttospeech.SynthesisInput(text=respuesta)
100
  voice = texttospeech.VoiceSelectionParams(
101
- language_code="es-ES", ssml_gender=texttospeech.SsmlVoiceGender.MALE,
102
  )
103
  audio_config = texttospeech.AudioConfig(
104
  audio_encoding=texttospeech.AudioEncoding.MP3
 
83
  c.save()
84
  return filepath
85
 
86
+ def obtener_respuesta(pregunta, texto_preprocesado, modelo="gpt-4-turbo", temperatura=0.5):
87
  try:
88
  response = openai.ChatCompletion.create(
89
  model=modelo,
 
98
  # Configura la solicitud de síntesis de voz
99
  input_text = texttospeech.SynthesisInput(text=respuesta)
100
  voice = texttospeech.VoiceSelectionParams(
101
+ language_code="es-ES", ssml_gender=texttospeech.SsmlVoiceGender.FEMALE,
102
  )
103
  audio_config = texttospeech.AudioConfig(
104
  audio_encoding=texttospeech.AudioEncoding.MP3