Skip to content

NNLP-IL/yap-js-client

Repository files navigation

YAP Client

npm package Issues

YAP was implemented to test the hypothesis on Joint Morpho-Syntactic Processing of Morphologically Rich Languages (MRLs) in a Transition Based Framework.

How to use

  • Run YAP and it via API (can run also via Docker)
  • Install the YAP Client
  • Use The YAP Client Feature

Install

npm i @nnlp-il/yap-js-client

Running YAP

The best way to run YAP is by Docker

docker run --name yap --restart always -d -p 8000:8000 public.ecr.aws/u8w1h2d8/nlp_yap_api:latest

Usage

const { YapClient } = require("@nnlp-il/yap-js-client");
const test = async () => {
    const client = new YapClient('http://localhost:8001');
    const result = await client.jointAnalysis("גנן גידל גנן בגן");
    console.log(result);
}
test();

API

jointAnalysis(text)

text

Type: string

Hebrew text to analyze

Output

Object containing the following fields:

  • Morphological Analysis Morphological Analysis shows shows all the options of interpretations for each word in the sentence.
  • Morphological Disambiguation Morphological Disambiguation is the next step after a full Morphological Analysis. Since the Morphological Analysis gave us all the possible options of each word in the sentence Morphological Disambiguation narrows down on the most viable option for each woord in the sentence.
  • Dependency Parsing Dependency Parsing is the process to analyze the grammatical structure in a sentence and find out related words as well as the type of the relationship between them. YAP returns a dependency tree of the inputted sentence.

About

YAP client for JavaScript and Typescript

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published