-
Notifications
You must be signed in to change notification settings - Fork 535
[website] Add a demo page for the Website #1180
base: v0.x
Are you sure you want to change the base?
Conversation
Codecov Report
@@ Coverage Diff @@
## master #1180 +/- ##
=======================================
Coverage 87.42% 87.42%
=======================================
Files 81 81
Lines 7346 7346
=======================================
Hits 6422 6422
Misses 924 924 |
Job PR-1180/4 is complete. |
|
Job PR-1180/5 is complete. |
docs/demo/sentiment.rst
Outdated
Introduction | ||
------------ | ||
|
||
Sentiment Analysis predicts whether an input is positive or negative. The model is based on BERT base, and are trained on the binary classification setting of the Stanford Sentiment Treebank. It achieves about 87% and 93.4% accuracy on the test set. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sorry, it should be "It achieves about 93.4% accuracy on the dev set. "
Job PR-1180/9 is complete. |
This may have been due to invalid input? Currently the server just times out when submitting |
I think it is due to invalid input. You may try out the default example I am now providing in the placeholder - it should work. Currently on the server side, I followed the same model as you provided in the #1140 . |
Still times out for me. How long do you wait for a response? |
Are you on Amazon Corporate VPN? VPN blocks 8888 port, so it will not work. I can get response within one second. |
Yes, this was due to VPN. |
Job PR-1180/10 is complete. |
Please help review whether the UI looks fine. |
Job PR-1180/12 is complete. |
Job PR-1180/13 is complete. |
[Help wanted] Currently I want to use an ajax to send the form information to the server and get the response so that I can display the information on the same page without refreshing the page. But I am stopped by the Cross Origin policy of ajax. It seems that modifying the server end is necessary for handling this problem? But the server running MMS is not a typical PHP/Java EE server, so I am not familiar about how to modify its response header. I am not sure I am seeking for the best strategy for solving this problem... |
docs/demo/sentiment.rst
Outdated
|
||
Please input the following into the text box: | ||
|
||
["Positive sentiment", "Negative sentiment"] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We should just show one sentence here. Without quotes. Without brackets.
So that the result can be displayed directly from the same page
Job PR-1180/14 is complete. |
Job PR-1180/15 is complete. |
|
Job PR-1180/21 is complete. |
Job PR-1180/22 is complete. |
This pull request is ready for review and merge. Thanks! |
Demo | ||
---- | ||
|
||
You can either input a sentence into the textbox or select one sample from the select control. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Currently we're giving an existence proof of "it's possible to have some web application to do sentiment analysis". But to be really useful to the end users, we need to teach them how to build it (not only show it's possible).
To make things simple, such instructions should be based on https://aws.amazon.com/serverless/ and https://aws.amazon.com/sagemaker/
In fact, can we just provide a Colab/SageMaker Notebook? |
We should definitely provide colab/sagemaker links for all tutorials. Demo is different in that it show cases the model for certain task without any involvement of code. Tutorial for setting up serving/inference is indeed appealing to end users. We should definitely pursue that after this PR by summarizing the steps. |
I think we can also provide demos with Colab + SageMaker, e.g., in https://magenta.tensorflow.org/demos/colab/. So we won't need to write any HTML codes (or just a few lines of HTML). |
@sxjscience @szha I'm not sure just having a demo without providing any instructions on how to reproduce it (and how to deploy it) is very helpful without the demo meeting a very high bar. For a simple demo such as currently, we can make it special by showcasing how easy it is to deploy it on AWS. |
I am planning to add more descriptions on configuration and then add a CoLab. Do you think it is OK? |
@leezu users who just want to try our pre-trained models will benefit from the set up. These are people who don't concern themselves with understanding the code yet, so mixing the concern would create noise for this need. |
@szha it doesn't need to be mixed. The proposal is to have an impressive demo, and provide information how to reproduce it showing the benefits of the technical stack. Not everyone has to read the latter part. |
Sounds good, @leezu. Do you have suggestions on how to improve the demo? Considering the investment, maybe the colab as @sxjscience suggested would indeed be the most efficient option. Please continue the discussion and conclude the path forward. |
Since colab needs someone's Google account, should I use my personal Google account to create colab? And should we create some repo/directory specifically for colab? Or just give a static file in someone's Google Drive? |
@StrayBird-ATSH I think we can do the same thing as d2l: automatically/manully uploading the notebooks to another repo called https://github.com/d2l-ai/d2l-en-colab. In order to access specific notebooks, we can add the |
That sounds great! Do you have any ideas about where to place this repo? Or just give a folder in the current repo? |
|
@szha Would you create a repo in DMLC? |
@sxjscience @StrayBird-ATSH I created https://github.com/dmlc/gluon-nlp-notebooks How do we automate the deployment to that repo? |
@szha I'm currently not sure about the details. Need to as the D2L people about the existing solution. |
Hi @astonzhang, how does the notebook deploy to colab work in d2l? |
@szha Thanks! |
@StrayBird-ATSH done |
Wonderful |
@leezu Since I am currently using your trained model in this website and we are planning to create a colab. Maybe you can provide the python scripts that are equivalent to your trained models so that users can run the scripts and get the result in the colab? |
Description
According to Issue (#688), a demo page is wanted in the GluonNLP website. So I am working on creating a demo web page for it. This is pull request will be continuously updated until the website is acceptable to be released.
Checklist
Essentials
Changes
Comments
cc @dmlc/gluon-nlp-team