Modify unidirectional and bidirectional versions of MedSLT GUI to support N-best processing. Communication with the translation server will use the protocol documented in $MED_SLT2/Runtime/Prolog/translation_server.pl, and reproduced here:
Request: action(translate_nbest(List)).
where List is a Prolog list of elements of form hyp(String, Confidence, LF)
[Example: action(translate_nbest([hyp('was the pain frontal',51,[[utterance_type,ynq],[tense,past],[verb,be],[spec,the_sing],[symptom,pain],[adj,frontal]]), hyp('is the pain frontal',45,[[utterance_type,ynq],[tense,present],[verb,be],[spec,the_sing],[symptom,pain],[adj,frontal]])])).
Response: (translation = TargetAtom) + (selected = Selected) + (target_lf = TargetLF ) + ( interlingua = Interlingua ) [ok]
[Example: Client rcv msg: (translation='+tts "la douleur est-elle frontale"')+(selected='is the pain frontal')+(target_lf=[[body_part,frontal],[symptom,douleur],[tense,present],[utterance_type,sentence],[state,Otre]])+(interlingua=[[adj,frontal],[symptom,pain],[tense,present],[utterance_type,ynq],[verb,be]])]
error. [Something went wrong]
Logged In: YES
user_id=529904
Originator: YES
Nikos, I have modified the translation server to be able to do N-best processing according to the model described in the TALN paper. The input format is the same as the one we discussed last week, but the output format is very slightly different - I discovered that our spec wasn't consistent with the one for 1-best processing. I've updated the documentation in $MED_SLT2/Runtime/Prolog/translation_server. Here it is:
Request: action(translate_nbest(List)).
where List is a Prolog list of elements of form hyp(String, Confidence, LF)
Response: (selected = SelectedAtom) + (translation = TargetAtom) + (text_translation = TargetTextAtom) + (target_lf = TargetLF ) + ( interlingua = Interlingua ) [ok]
error. [Something went wrong]
Example: action(translate_nbest([hyp('is the pain accompanied during anxiety',51,
[[event,accompany],[prep,duration_time],[secondary_symptom,anxiety],
[secondary_symptom,pain],[tense,present],[utterance_type,ynq],
[voice,passive]]),
hyp('is the pain accompanied by anxiety',45,
[[event,accompany],[prep,subj],[secondary_symptom,anxiety],
[secondary_symptom,pain],[tense,present],[utterance_type,ynq],
[voice,passive]])])).
Response: (selected='is the pain accompanied by anxiety')+
(translation='+tts "êtes-vous anxieux quand vous avez mal"')+
(text_translation='êtes-vous anxieux quand vous avez mal')+
(target_lf=[[cause,anxieux],
[clause,[[path_proc,avoir],[pronoun,vous],[symptom,mal],
[tense,present],[voice,active]]],
[pronoun,vous],[sc,quand],[state,être],[tense,present],[utterance_type,sentence],
[voice,active]])+
(interlingua=[[clause,[[pronoun,you],[state,have_symptom],[symptom,pain],
[tense,present],[utterance_type,dcl],[voice,active]]],
[pronoun,you],[sc,when],[secondary_symptom,anxiety],[state,experience],
[tense,present],[utterance_type,ynq],[voice,active]])