Model deployment

So I feel that this is the best feature of DLS, especially again for non-expert users like me.

After training and deploying a sentiment classifier I had a small question I want to ask. This might or might not fall within the remit of this forum so I apologize in advance.

Is it possible, through the automatic deployment interface, to allow for text as input to a deployed sentiment classifier? Right now, since the input text to the model is tokenized and passed as an numpy array, a user would need to input a series of integers separated by a ‘;’ to get a prediction. How could we go about allowing a user to simply type a sentence to the rest API? Probably that would require an additional step with a tokenizer transforming the text into appropriate integers, correct? Is that possible through DLS atm, even if we have to ‘hack’ the deployment code a bit? Or would it be simpler to add another layer smh that does this decoding before the user inputs that to DLS?

Thanks in advance!

Kind regards,

Hi Theodore,

We have plan to support direct text input in near future but there is no ETA at the moment.

In the meantime, if you want to enable text input for your users, the simplest way would be to develop an web application, which takes the text input and preprocesses it and then call the REST api.

A more involved way would be to modify the form template in the existing deployment code (only desktop versions). You can search for a file app.html inside the DLS installation folder (windows) / DLS docker container (Linux).

If you are able to get it to work, it would be beneficial for others if you can share the modified file here.