Skip to main content
Using Deno in production at your company? Earn free Deno merch.
Give us feedback
Module

x/vectorizer/src/feature/conversion/text/base.ts>BaseVectorizer

Feature Extraction and Feature Selection in TypeScript
Go to Latest
class BaseVectorizer
import { BaseVectorizer } from "https://deno.land/x/vectorizer@v0.3.7/src/feature/conversion/text/base.ts";

Constructors

new
BaseVectorizer(options: Partial<BaseVectorizerOptions & { indices: boolean; }>)

Properties

readonly
lastToken: number
skipWords: "english" | false | string[]

Words to ignore from vocabulary

standardize: StandardizeConfig | ((s: string) => string)

Configuration / Function for preprocessing

vocabulary: Map<string, number>

Map words to indices

Methods

fit(text: string | string[]): this

Construct a vocabulary from a given set of text.

preprocess(text: string): string
split(text: string): string[]