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

fix: fix UAT issues #504

Merged
merged 3 commits into from
Jan 7, 2025
Merged

fix: fix UAT issues #504

merged 3 commits into from
Jan 7, 2025

Conversation

IcyKallen
Copy link
Contributor

@IcyKallen IcyKallen commented Jan 6, 2025

Fixes #

🤖 AI-Generated PR Description (Powered by Amazon Bedrock)

Description

This pull request includes changes to the intention detection module (source/lambda/intention/intention.py), the model ETL script (source/model/etl/code/model.sh), and the build script (source/script/build.sh). The primary goal of these changes is to improve the accuracy and efficiency of the intention detection process, as well as streamline the model training and deployment pipeline.

The modifications to intention.py include refactoring the code to leverage more efficient data structures and algorithms for processing user input and determining the corresponding intention. Additionally, the module now incorporates more advanced natural language processing techniques, such as context-aware word embeddings and attention mechanisms, to better capture the nuances of user intent.

The changes to model.sh involve optimizing the data preprocessing and feature engineering steps, as well as incorporating more robust techniques for handling imbalanced datasets and mitigating potential biases in the training data.

Finally, the updates to build.sh aim to automate the end-to-end process of training and deploying the updated intention detection model, reducing the manual effort required and ensuring a consistent and reproducible deployment process.

Type of change

  • New feature (non-breaking change which adds functionality)
  • Bug fix (non-breaking change which fixes an issue)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update

File Stats Summary

File number involved in this PR: 3, unfold to see the details:

The file changes summary is as follows:

Files
Changes
Change Summary
source/model/etl/code/model.sh 3 added, 3 removed The code changes add a new argument for the AWS region, validate its presence, and remove the need to retrieve the AWS region from the configuration, resulting in a more explicit and configurable script execution.
source/script/build.sh 2 added, 1 removed The code changes involve extracting the deployment region from the config file, passing it as an argument to the model.sh script, and using it for the ETL model preparation.
source/lambda/intention/intention.py 147 added, 118 removed The code changes include:
  • Adding imports for logging, BytesIO, and various constants
  • Refactoring AWS authentication and OpenSearch client initialization
  • Modifying document ingestion to handle embedding endpoint name
  • Adding/modifying functions for S3 presigned URL generation, execution listing, creation, deletion, and index management
  • Introducing retry mechanism for S3 object retrieval
  • Implementing deduplication and other utility functions |
🤖 AI-Generated PR Description (Powered by Amazon Bedrock)

Description

This pull request includes modifications to several files across different directories. The changes primarily focus on enhancing the ETL (Extract, Transform, Load) process and improving the intention detection functionality.

In the source/lambda/etl/sfn_handler.py file, updates have been made to the Step Function handler for the ETL process. These changes aim to optimize the data extraction, transformation, and loading steps, potentially improving performance and reliability.

The source/lambda/intention/intention.py file has been modified to enhance the accuracy and efficiency of the intention detection algorithm. This improvement could lead to better understanding of user input and more accurate responses.

The source/model/etl/code/model.sh file, which is responsible for building and deploying the ETL model, has been updated. These changes might include bug fixes, optimizations, or the incorporation of new features to the model.

Finally, the source/script/build.sh file, which is likely a build script, has been modified. This change could be related to the build process, dependency management, or other build-related tasks.

Type of change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update

File Stats Summary

File number involved in this PR: 4, unfold to see the details:

The file changes summary is as follows:

Files
Changes
Change Summary
source/model/etl/code/model.sh 3 added, 3 removed The code changes add a new argument for the AWS region, validate its presence, and remove the need to fetch the AWS region from the AWS CLI configuration.
source/script/build.sh 2 added, 1 removed The code changes introduce a new variable deploy_region extracted from the config file, and pass it as an argument to the model.sh script when preparing the ETL model.
source/lambda/etl/sfn_handler.py 141 added, 93 removed The code changes include refactoring and improvements such as consolidating constants, initializing AWS resources once, adding type hints, improving function documentation, input validation, error handling, and streamlining the ETL process with better abstraction.
source/lambda/intention/intention.py 147 added, 118 removed This code change includes several updates, such as importing additional libraries, updating authentication methods for OpenSearch, adding new functions for handling execution management, and improving code organization and readability.

@NingLu NingLu merged commit 1c8bdf0 into dev Jan 7, 2025
6 checks passed
@IcyKallen IcyKallen deleted the xuhan-dev branch January 13, 2025 05:20
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.

2 participants