jizt-it / jizt-backend-microservice

AI Text Summarization in the cloud (microservice, event-driven version). Not currently maintained.
https://www.jizt.it
GNU General Public License v3.0
3 stars 0 forks source link

Implement parameter checking in POST requests #6

Closed dmlls closed 3 years ago

dmlls commented 3 years ago

Right now, only a very basic checking is carried out in the summarization parameters when dispatching POST requests. This checks are basically limited to the data type, e.g., the API won't take a "true" as the "relative_max_length", since it expects a float value.

However, following the previous example, the API would not check whether the received "relative_max_length" is ranges between 0.1 and 1.0. Thus, it would take a 999.9 as a correct value.

Expected enhancement: implement robust value checks so that incorrect parameters are detected and ignored.