Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support NLP Services for Deprel Labels #4

Open
mr-martian opened this issue Jul 21, 2022 · 2 comments · May be fixed by #6
Open

Support NLP Services for Deprel Labels #4

mr-martian opened this issue Jul 21, 2022 · 2 comments · May be fixed by #6
Labels
enhancement New feature or request

Comments

@mr-martian
Copy link

Currently, when I try to run a service for deprel labels, I get

620754 ERROR midas-loop.server.nlp.setup - #error {
 :cause Invalid probas key:
 :data {:key :deprel/probas}
 :via
 [{:type clojure.lang.ExceptionInfo
   :message Invalid probas key:
   :data {:key :deprel/probas}
   :at [midas_loop.server.nlp.common$write_probas invokeStatic common.clj 116]}]
 :trace
 [[midas_loop.server.nlp.common$write_probas invokeStatic common.clj 116]
  [midas_loop.server.nlp.common$write_probas invoke common.clj 114]
  [midas_loop.server.nlp.http$get_probas invokeStatic http.clj 170]
  [midas_loop.server.nlp.http$get_probas invoke http.clj 112]
  [midas_loop.server.nlp.http.HttpProbDistProvider predict_prob_dists http.clj 46]
  [midas_loop.server.nlp.common$fn__8698$G__8694__8702 invoke common.clj 32]
  [midas_loop.server.nlp.common$fn__8698$G__8693__8707 invoke common.clj 32]
  [clojure.core$binding_conveyor_fn$fn__5823 invoke core.clj 2056]
  [clojure.lang.AFn applyToHelper AFn.java 160]
  [clojure.lang.RestFn applyTo RestFn.java 132]
  [clojure.lang.Agent$Action doRun Agent.java 114]
  [clojure.lang.Agent$Action run Agent.java 163]
  [java.util.concurrent.ThreadPoolExecutor runWorker ThreadPoolExecutor.java 1149]
  [java.util.concurrent.ThreadPoolExecutor$Worker run ThreadPoolExecutor.java 624]
  [java.lang.Thread run Thread.java 748]]}

I tried adding :deprel/probas to the list at

(defn write-probas [node key token-probas-pairs]
(when-not (#{:sentence/probas :xpos/probas :upos/probas :head/probas} key)
(throw (ex-info "Invalid probas key:" {:key key})))
(-write-probas node key token-probas-pairs))

But after recompiling, I found that the resulting .jar file would say it was running, but my browser wouldn't connect, but I expect that's an issue with my compilation environment rather than due to the change.

@mr-martian mr-martian linked a pull request Jul 21, 2022 that will close this issue
@mr-martian
Copy link
Author

I missed the step of copying generated files from midas-loop-ui, after doing that, this change does what I would expect (see #6).

@lgessler lgessler added the enhancement New feature or request label Aug 6, 2022
@lgessler
Copy link
Collaborator

lgessler commented Aug 6, 2022

Correct, as documented, service outputs for DEPREL are currently not supported. Thanks for the PR--will add comments there

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants