Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enhance the chat request configuration #4

Merged
merged 4 commits into from
Oct 30, 2024
Merged

Enhance the chat request configuration #4

merged 4 commits into from
Oct 30, 2024

Conversation

penguineer
Copy link
Owner

This pull request introduces several changes to improve error handling and enhance the flexibility of chat request configurations. The most important changes include the introduction of a new ChatException class, modifications to the ChatRequest class to support additional parameters, and updates to the AIChatService to use these new features.

Error Handling Improvements:

  • Introduced a new ChatException class to handle different error scenarios with specific error codes. (src/main/java/com/penguineering/hareairis/model/ChatException.java)
  • Updated the ChatError class to utilize the new ChatException for error handling. (src/main/java/com/penguineering/hareairis/model/ChatError.java)
  • Modified ChatRequestHandler to replace ChatError with ChatException for consistent error handling and logging. (src/main/java/com/penguineering/hareairis/rmq/ChatRequestHandler.java) [1] [2] [3]

Chat Request Enhancements:

  • Enhanced the ChatRequest class to include additional parameters such as maxTokens, temperature, topP, presencePenalty, and frequencyPenalty to provide more control over the chat generation. (src/main/java/com/penguineering/hareairis/model/ChatRequest.java)

Service Updates:

  • Updated AIChatService to utilize the new parameters from ChatRequest and handle exceptions using ChatException. (src/main/java/com/penguineering/hareairis/ai/AIChatService.java) [1] [2] [3]

@penguineer penguineer self-assigned this Oct 30, 2024
@penguineer penguineer merged commit 6b33c4e into main Oct 30, 2024
1 check passed
@penguineer penguineer deleted the parameters branch October 30, 2024 11:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant