Skip to content

Commit

Permalink
Generate the llm response
Browse files Browse the repository at this point in the history
  • Loading branch information
verovaleros committed Feb 13, 2024
1 parent f41c25a commit 88c1153
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions hermeneisGPT.py
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,14 @@ def main():
translate_messages = [{"role":"system", "content": config['system']},
{"role":"user", "content": config['user']+input_lang_ru}]

# Initialize the OpenAI LLM (Language Learning Model)
llm_response = client.chat.completions.create(
model = config['model'],
messages = translate_messages,
max_tokens = config['max_tokens'],
temperature = config['temperature'],
)
print(llm_response.choices[0].message.content)

except Exception as err:
logger.info("Exception in main()")
Expand Down

0 comments on commit 88c1153

Please sign in to comment.