feature/recommendation-model#85
Merged
Merged
Conversation
… model recommender
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This pull request introduces a recommendation system for products using machine learning and integrates it into the existing application. It also includes updates to dependencies, enhancements to DTOs, and improvements to the
ProductsService. Below is a summary of the key changes:Recommendation System Integration:
RecommendationModulewith aRecommendationServicethat uses a nearest neighbors algorithm to recommend products based on user purchase history. The service fetches user-specific product data and calculates recommendations using TensorFlow (src/recommendation/recommendation.module.ts,src/recommendation/recommendation.service.ts,src/recommendation/model.ts,src/recommendation/data.ts) [1] [2] [3] [4].ProductsControllerwith a newGET /product/recommendationsendpoint, guarded by authentication (src/products/products.controller.ts).Dependency Updates:
@tensorflow/tfjs-nodefor machine learning functionality and updatedtypeormto version^0.3.22(package.json) [1] [2].Enhancements to DTOs:
@Exposedecorator to multiple DTOs to ensure proper serialization and usedclass-transformer's@Typedecorator for nested objects (src/category/dto/category.dto.ts,src/products/dto/manufacturer.dto.ts,src/products/dto/product.dto.ts) [1] [2] [3].Improvements to Products Service:
ProductsServiceby deprecating the oldgetProductsmethod and introducing a new, more flexible version that supports additional filters likecategoryIds,manufacturerIds, andpriceRange(src/products/products.service.ts) [1] [2].src/products/products.service.ts).Database Enhancements:
VirtualColumnto theProductPresentationentity to calculate stock quantity dynamically using a SQL query (src/products/entities/product-presentation.entity.ts).