Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

antonyms from wordnet #20

Merged
merged 2 commits into from Nov 27, 2018
Merged

Conversation

@coolbutuseless
Copy link
Collaborator

@coolbutuseless coolbutuseless commented Nov 27, 2018

  1. Use python to extract words and their antonyms from wordnet
    • see data-raw/generate-wordnet-antonyms.py
  2. Process the wordnet list into an R data structure
    • see data-raw/create-r-antonyms-data.R
  3. Included words_ant in the internal data for this package
  4. Added ant() and ants()

Unfortunately, there aren't really a lot of words in this antonym dataset i.e.

  • syn('good') has 667 results
  • ant('good') has 2 results

However, if we first find the list of synonyms of 'good', and then find all the antonyms of everything in there, there are 268 antonyms i.e.

sort(unique(flatten_chr(ants(syn('good')))))

This isn't perfect - somehow 'good' is in this list of antonyms for 'good'!

So for now, I've just included the wordnet antonyms as-is.

I've included the wordnet list as it is output by python (data-raw/wordnet-antonyms-cleaned.txt), as it's probably unreasonable to expect anyone to regenerate this.

@njtierney njtierney merged commit f36680c into ropenscilabs:master Nov 27, 2018
4 checks passed
4 checks passed
codecov/patch 100% of diff hit (target 100%)
Details
codecov/project 100% (+0%) compared to 95cb5b6
Details
continuous-integration/appveyor/pr AppVeyor build succeeded
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details
@njtierney
Copy link
Collaborator

@njtierney njtierney commented Nov 27, 2018

This is AWESOME!

Thanks, Mike! (@coolbutuseless) - this is cool AND useful! :)

I'm really happy with this, we can improve upon this in the future.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

2 participants
You can’t perform that action at this time.