Skip to content

Commit

Permalink
readme: Reflect suggestion API work in progress
Browse files Browse the repository at this point in the history
  • Loading branch information
the-mikedavis committed Sep 21, 2024
1 parent d487c6a commit 6d76bc0
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,9 @@ fn main() {
if dict.check(&word) {
println!("{word:?} is in the dictionary.");
} else {
eprintln!("{word:?} is NOT in the dictionary.");
let mut suggestions = Vec::new();
dict.suggest(&word, &mut suggestions);
eprintln!("{word:?} is NOT in the dictionary. Did you mean {suggestions:?}?");
std::process::exit(1);
}
}
Expand All @@ -28,7 +30,7 @@ Spellbook is `no_std` and only requires [`hashbrown`] as a dependency. (Note tha

Spellbook is a work in progress and might see breaking changes to any part of the API as well as updates to the MSRV and dependencies.

Currently the `check` API works well for `en_US` - a relatively simple dictionary - though it should work reasonably well for most other dictionaries. Some dictionaries which use complex compounding directives may work less well. The `suggest` API is not yet implemented but is planned.
Currently the `check` API works well for `en_US` - a relatively simple dictionary - though it should work reasonably well for most other dictionaries. Some dictionaries which use complex compounding directives may work less well. The `suggest` API is a work in progress.

Spellbook should be considered to be in _alpha_. Part of the Hunspell test corpus has been successfully ported and there are a healthy number of unit tests, but there are certainly bugs to be found.

Expand Down

0 comments on commit 6d76bc0

Please sign in to comment.