id = "mecab" name = "MeCab" homepage = "https://github.com/taku910/mecab" description = "Yet another Japanese morphological analyzer" executables = ["mecab"] [dotfiles] # MeCab's official dictionary guide says that, when the system mecabrc cannot # be read, users can copy it to ~/.mecabrc. The other locations it documents # are system-wide installation files, not user dotfiles. # https://github.com/taku910/mecab/blob/master/dic.html paths = ["~/.mecabrc"] secret = [] [commands] format = 1 label = "Analyze text" description = "Morphologically analyze files (or stdin when none are given) with common dictionary, output and N-best options. Format strings and lattice options are left out." quality = "ai-draft" parser = { end_of_options = "--", interleave = "permute", long_equals = true, short_attached = false, short_bundles = false } [[commands.source]] id = "man" kind = "manual" url = "https://manpages.debian.org/unstable/mecab/mecab.1.en.html" revision = "0.996-16.1" evidence = """ mecab [options] files -r, --rcfile=FILE use FILE as resource file -d, --dicdir=DIR set DIR as a system dicdir -u, --userdic=FILE use FILE as a user dictionary -a, --all-morphs output all morphs(default false) -O, --output-format-type=TYPE set output format type (wakati,none,...) -p, --partial partial parsing mode -N, --nbest=INT output N best results (default 1) -o, --output=FILE set the output file name -D, --dictionary-info show dictionary information and exit """ [[commands.field]] id = "files" label = "Input files" type = "path" position = 0 multiple = true path = { kind = "file", role = "input" } sources = ["man"] [[commands.field]] id = "output_format" label = "Output format type" type = "string" option = ["--output-format-type", "-O"] suggestions = [{ value = "wakati", label = "Wakati (space-separated words)" }, { value = "none", label = "None" }] sources = ["man"] [[commands.field]] id = "nbest" label = "N-best results" type = "integer" option = ["--nbest", "-N"] sources = ["man"] [[commands.field]] id = "all_morphs" label = "Output all morphs" type = "boolean" option = ["--all-morphs", "-a"] sources = ["man"] [[commands.field]] id = "partial" label = "Partial parsing mode" type = "boolean" option = ["--partial", "-p"] sources = ["man"] [[commands.field]] id = "dicdir" label = "System dictionary directory" type = "path" option = ["--dicdir", "-d"] path = { kind = "directory", role = "input" } sources = ["man"] [[commands.field]] id = "userdic" label = "User dictionary" type = "path" option = ["--userdic", "-u"] path = { kind = "file", role = "input" } sources = ["man"] [[commands.field]] id = "rcfile" label = "Resource file" type = "path" option = ["--rcfile", "-r"] path = { kind = "file", role = "input" } sources = ["man"] [[commands.field]] id = "output" label = "Output file" type = "path" option = ["--output", "-o"] path = { kind = "file", role = "output" } effect = "overwrite" sources = ["man"] [[commands.field]] id = "dictionary_info" label = "Show dictionary info" type = "boolean" option = ["--dictionary-info", "-D"] sources = ["man"] [[commands.task]] id = "wakati" label = "Split into words" fields = ["files", "output_format", "output"] required = ["files"] set = { output_format = ["wakati"] } [[commands.task]] id = "nbest" label = "N-best analysis" fields = ["files", "nbest", "userdic"] required = ["files", "nbest"] [[commands.group]] id = "basic" label = "Basic" fields = ["files", "output_format", "nbest", "all_morphs", "partial", "output"] [[commands.group]] id = "advanced" label = "Advanced" fields = ["dicdir", "userdic", "rcfile", "dictionary_info"]