Skip to content

Commit

Permalink
add info button for query expansion to describe behaviour
Browse files Browse the repository at this point in the history
  • Loading branch information
victordibia committed Sep 16, 2020
1 parent 2e3b339 commit ba58161
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 11 deletions.
20 changes: 9 additions & 11 deletions neuralqa/server/ui/src/components/expandview/ExpandView.jsx
Expand Up @@ -225,7 +225,7 @@ class ExpandView extends Component {
// secondaryButtonText={"Cancel"}
>
<div>
<div className="underline pb5 mb10">
<div className="underline boldmediumtext pb5 mb10">
{" "}
What is Contextual Query Expansion?{" "}
</div>
Expand All @@ -243,13 +243,16 @@ class ExpandView extends Component {
{" "}
NeuralQA paper.
</a>{" "}
<div className="underline mt10 pb5 mb10">
<div className="underline boldmediumtext mt10 pb5 mb10">
{" "}
How is this Implemented{" "}
How is this Implemented?{" "}
</div>
Part of speech detection is implemented using Spacy NLP. A BERT
based masked language model is used for predicting expansion terms (
can be selected under advanced options).
<br /> <br />
*Note contextual query expansion works best when the model is
trained on the target (open-domain) dataset.
</div>
</Modal>
<div className=" mb10">
Expand All @@ -263,11 +266,11 @@ class ExpandView extends Component {
</span>
.
</div>
<div className="expandview p10 expandview">
<div className=" expandview">
{/* <span className="boldtext"> suggested terms: </span>
<span className="mediumdesc"> {suggestedTermList} </span> */}
<div className="positionrelative pb5 mediumdesc">
<div className=" pt10 pb10 underline">
<div className=" positionrelative pb5 mediumdesc">
<div className="pt10 pb10 underline">
Click any of the expansion candidate terms below to append it to
your query
</div>
Expand All @@ -284,11 +287,6 @@ class ExpandView extends Component {
{" "}
The visualization above indicates how the expansion terms were
generated.<br></br>
*Note that contextual query expansion works best when the model is
trained on the target (open-domain) dataset. To minimize the
potential for altering the meaning of the sentence, only NOUNS,
ADJECTIVES, and ADVERBS are expanded. Named entities are not
expanded.
</div>
</div>
</div>
Expand Down
4 changes: 4 additions & 0 deletions neuralqa/server/ui/src/components/expandview/expandview.css
Expand Up @@ -25,6 +25,10 @@
}
.expandview {
border: 1px solid #c4c3c3;
/* background-color: #f0efef; */
padding-left: 10px;
/* padding-right: 10px; */
padding-bottom: 10px;
}

.tooltip {
Expand Down
4 changes: 4 additions & 0 deletions neuralqa/server/ui/src/components/template.css
Expand Up @@ -99,6 +99,10 @@
.boldtext {
font-weight: bold;
}

.boldmediumtext {
font-weight: 600;
}
.whitetext {
color: white;
}
Expand Down

0 comments on commit ba58161

Please sign in to comment.