genie-toolkit icon indicating copy to clipboard operation
genie-toolkit copied to clipboard

step 7 of tutorial 1

Open vinith-reddy25 opened this issue 2 years ago • 5 comments

By running

"$ genie server --nlu-model file://OUTPUTDIR --thingpedia thingpedia.tt -l en-US"

output is coming as:

" I 220118 16:31:25 transformer_lstm:79] Initializing encoder and decoder embeddings [I 220118 16:31:26 transformer_lstm:108] Vocabulary has 28997 tokens [I 220118 16:31:27 util:555] TransformerLSTM has 125,656,333 parameters

" After that when "localhost:8400" is tried to open in browser then "{"error":"Invalid endpoint"}" is coming. Can someone tell what to do??

Will it take too much time to deploy?? or some issue is there in my side??

vinith-reddy25 avatar Jan 18 '22 12:01 vinith-reddy25

It won't take long to deploy. The only endpoint opened for the nlu server is /en/query. For example, if you want to get the result for utterance "get restaurants", you would go to localhost:8400/en/query?q=get restaurants

sileix avatar Feb 02 '22 19:02 sileix

/en/query endpoint not working. Can you send any link where there is a discussion about api call

vinith-reddy25 avatar Feb 07 '22 04:02 vinith-reddy25

Here is some documentation about the API provided in our production server: https://wiki.genie.stanford.edu/en/api-references/nlp - it is the same as the self-served one here. And the endpoint is implemented here: https://github.com/stanford-oval/genie-toolkit/blob/235171b1d1610a2b02a5a979d43a27e7ec6b9528/tool/server.ts#L222.

Both en and en-US should work as the locale. An example on our production server: https://nlp.genie.stanford.edu/en/query?q=get%20restaurants

sileix avatar Feb 07 '22 07:02 sileix

I was asking for http://localhost:8400 as it is giving error and not using https://nlp.genie.stanford.edu/

vinith-reddy25 avatar Feb 08 '22 10:02 vinith-reddy25

Both localhost and our production server share the same implementation of the API call. We don't have separate documentation for API for genie-server at the moment, but simply replace the URL from nlp.genie.stanford.edu to localhost:8400, everything else should be the same.

sileix avatar Feb 08 '22 17:02 sileix