Identify and categorize tokens in text for Named Entity Recognition (NER), Part-of-Speech tagging, and other NLP tasks.

Quickstart

Classify Tokens in Text

Send a text input to classify individual tokens.

import Bytez from "bytez.js";

const client = new Bytez("YOUR_BYTEZ_KEY_HERE");
const model = client.model("dslim/bert-base-NER");

const { error, output: wordObjects } = await model.run(
  "John Doe is a software engineer at Google."
);

if (error) {
  console.error("Error:", error);
} else {
  for (const wordObject of wordObjects) {
    console.log(wordObject);
    const { word, entity, score, index, start, end } = wordObject;
    console.log({ word, entity, score, index, start, end });
  }
}

Demo