[TXTREC-45] Align methods of TextClassificationService to unify the flow Created: 05/Aug/19  Updated: 16/Mar/21  Resolved: 16/Mar/21

Status: Closed
Project: Text Classification
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: Improvement Priority: Neutral
Reporter: Nguyen Phung Chi Assignee: Unassigned
Resolution: Outdated Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Template:
Acceptance criteria:
Empty
Task DoD:
[ ]* Doc/release notes changes? Comment present?
[ ]* Downstream builds green?
[ ]* Solution information and context easily available?
[ ]* Tests
[ ]* FixVersion filled and not yet released
[ ]  Architecture Decision Record (ADR)
Epic Link: Txt Classification

 Description   

Situtation:

Currently, we have 2 different methods in TextClassificationService to run classification for 2 scenarios:

  1. A single String as parameter, this is using for ecommerce integration
  2. Collection<String> as parameter, mainly use for Text classification modules, running classification on Pages.
public interface TextClassificationService {

    CompletableFuture<Collection<TextLabel>> submitTextClassificationRequest(String text);

    CompletableFuture<Map<String, Collection<TextLabel>>> submitTextClassificationRequest(Collection<String> texts);

//...

AC:

  • Find a way to unify those 2 methods if possible
  • Refactor the service and flow to have the best code readability (for maintenance and further improvement)

 



 Comments   
Comment by Nguyen Phung Chi [ 16/Mar/21 ]

This is not really needed and outdated.

Generated at Mon Feb 12 11:04:55 CET 2024 using Jira 9.4.2#940002-sha1:46d1a51de284217efdcb32434eab47a99af2938b.