#! /bin/sh

# You can use this script to check some frequent words -- it
# sees if the matched text always matches the word.
# This can sometiems fail if you have, say, buggy troff files,
# or if the lq-text index is corrupt.

for i
do
    lqphrase "$1" |
    lqkwic -S '' -s '${FID}     ${DocName}@${MatchedText}@${NL}' |
    grep -i -v "@$1[s']*@$"
done
