donglixp / coarse2fine

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Understanding cond_span_l, cond_span_r and lay fields

Sandy26 opened this issue · comments

Hi Li,Stephen

Could you please shed some light on cond_span_l, cond_span_r and lay fields as to what they are used for and how are they modelled(classifier or rnn etc) ? I would like to use the way the in which condition value is predicted for predicting LIMIT value.

Any insights would be greatly helpful!

Thank you,
Shruti

Hi Shruti,

Each condition value is a text span extracted from the input question. cond_span_l/r is the index of the first/last token of the text span.

They are predicted as shown in the following two lines:

cond_span_l = argmax(self.model.cond_span_l_match(

cond_span_r = argmax(self.model.cond_span_r_match(

The details are described in Page 7 of http://aclweb.org/anthology/P18-1068.pdf .

Best,
Li

Thank you very much Li. That was indeed helpful!