Find important words from a sentence.
Project description
Introduction
mask-predictor is a wrapper of BERT which can predict masked word of a sentence.
Example:
Given : I like to eat * as my dinner.
Result: [Chicken, Fish, Curry, Steak, ...]
How to run this
All you need to do is:
- Run
pip install mask-predictor
- Download
main.py
andinput.json
- Run
main.py
The main.py is a simple example showing how to use the mask-predictor package.
The main.py
will read the input.json
, and will produce a output file named result.json
.
Note that the 1st time of running will download the spacy model file. Please re-run the code after it has successfully downloaded. The model file sized 7xxMB and expected to take fews minutes. Please keep your computer awake while downloading, otherwise it might fails.
Other files
The mask_predictor
folder contains the source code of mask-predictor package, which you don't need if you install it via pip.
Others files is used for packaging the code to PyPI, which you don't need.
All you need is only main.py
and input.json
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Hashes for important_words-0.0.2-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 00607ecdec0fa93e0a391ef7d1ca33b880a5ead6074afd6ad9ce7c11084dbb84 |
|
MD5 | e4ce68e4dd360661a42befb35cd27023 |
|
BLAKE2b-256 | 11ae3503a56a1af6271a2af571b9d12d9ffe366c2dba68f1b85d1c3838bbfee4 |