load_or_retrieve_lookup: Load a lookup file, or retrieve from cache

View source: R/vocab.R

load_or_retrieve_lookupR Documentation

Load a lookup file, or retrieve from cache

Description

Usually you will want to use the included lookup that can be accessed via morphemepiece_lookup(). This function can be used to load (and cache) a different lookup from a file.

Usage

load_or_retrieve_lookup(lookup_file)

Arguments

lookup_file

path to lookup file. File is assumed to be a text file, with one word per line. The lookup value, if different from the word, follows the word on the same line, after a space.

Value

The lookup table as a named character vector.


morphemepiece documentation built on April 16, 2022, 5:05 p.m.