Wordnet pipesΒΆ

from sim.patch_wn import *
w('car')|lst
[car]
w('car')|ids|lst
['ewn-car-n']
w('car')|syns|lst
[automobile:motorcar:machine:car:auto, railcar:railroad car:car:railway car, car:gondola, elevator car:car, cable car:car]
ws('car')|lst
[automobile:motorcar:machine:car:auto, railcar:railroad car:car:railway car, car:gondola, elevator car:car, cable car:car]
ws('car')|ids|lst
['ewn-02961779-n', 'ewn-02963378-n', 'ewn-02963937-n', 'ewn-02963788-n', 'ewn-02937835-n']
w(['lemon','orange'])|syns|lst
ws('wheel')|partof|lst
[wheeled vehicle, steering system:steering mechanism]
ws('wheel')|isa|lst
[simple machine:machine,
 handwheel,
 force,
 helm,
 game equipment,
 instrument of torture,
 wheeled vehicle,
 rotate:go around:revolve,
 transport,
 move:go:travel:locomote,
 ride]
ws('gem')|typeof|lst
[cabochon, opaque gem, transparent gem, semi-precious stone, bran muffin, corn muffin, popover, crown jewel, solitaire, diamond, ruby, pearl, emerald, sapphire]
ws('car')|haspart|take(10)|lst
[gas:gun:accelerator pedal:gas pedal:accelerator:throttle,
 air bag,
 auto accessory,
 automobile engine,
 car horn:automobile horn:hooter:motor horn:horn,
 buffer:fender,
 bumper,
 car door,
 car mirror,
 car seat]
(ws('wheel'),ws('steer'))|prod|wup|sort|reverse|take(5)|lst
[(0.444, (wheel:roulette wheel, bullock:steer)),
 (0.444, (wheel:bicycle:cycle:bike, bullock:steer)),
 (0.400, (wheel, bullock:steer)),
 (0.400, (wheel, bullock:steer)),
 (0.400, (wheel:steering wheel, bullock:steer))]
(ws('gem'),ws('stone'))|prod|path|sort|reverse|take(5)|lst
[(1.000, (stone:gem:gemstone, stone:gem:gemstone)),
 (0.200, (gem:jewel, Lucy Stone:Stone)),
 (0.200, (gem:jewel, Stone:Edward Durell Stone)),
 (0.167, (gem:jewel, Harlan Stone:Harlan F. Stone:Stone:Harlan Fisk Stone)),
 (0.167, (gem:jewel, Stone:Oliver Stone))]
[list((ws('car'),ws('bike'))|prod|wup|sort|reverse|take(5))[0][1][1]]|sns|ids|lst
['ewn-motorcycle-n-03796045-01', 'ewn-bike-n-03796045-02']