python wordnettest.py
Enter some text please.
What is the highest hill in Cornwall?
word: What
Hypernyms
[]
Hyponyms of all hypernyms
[]
word: highest
(Synset('high.a.01'), u'greater than normal in degree or intensity or amount')
(Synset('high.a.02'), u"(literal meaning) being at or having a relatively great or specific elevation or upward extension (sometimes used in combinations like `knee-high')")
(Synset('eminent.s.01'), u'standing above others in quality or position')
(Synset('high.a.04'), u'used of sounds and voices; high in pitch or frequency')
(Synset('high.s.05'), u'happy and excited and energetic')
(Synset('gamey.s.02'), u'(used of the smell of meat) smelling spoiled or tainted')
(Synset('high.s.07'), u'slightly and pleasantly intoxicated from alcohol or a drug (especially marijuana)')
Hypernyms
[]
Hyponyms of all hypernyms
[]
word: hill
(Synset('hill.n.01'), u'a local and well-defined elevation of the land')
(Synset('mound.n.04'), u'structure consisting of an artificial heap or bank usually of earth or stones')
(Synset('hill.n.03'), u'United States railroad tycoon (1838-1916)')
(Synset('hill.n.04'), u'risque English comedian (1925-1992)')
(Synset('mound.n.01'), u'(baseball) the slight elevation on which the pitcher stands')
(Synset('hill.v.01'), u'form into a hill')
Hypernyms
[Synset('natural_elevation.n.01'), Synset('structure.n.01'), Synset('baseball_equipment.n.01'), Synset('shape.v.02')]
(Synset('natural_elevation.n.01'), u'a raised or elevated geological formation')
(Synset('structure.n.01'), u'a thing constructed; a complex entity constructed of many parts')
(Synset('baseball_equipment.n.01'), u'equipment used in playing baseball')
(Synset('shape.v.02'), u'make something, usually for a specific function')
Hyponyms of all hypernyms
[u'highland', u'upland', u'hill', u'mountain', u'mount', u'promontory', u'headland', u'head', u'foreland', u'ridge', u'swell', u'airdock', u'hangar', u'repair_shed', u'altar', u'arcade', u'colonnade', u'arch', u'area', u'balance', u'equilibrium', u'equipoise', u'counterbalance', u'balcony', u'balcony', u'bascule', u'boarding', u'body', u'bridge', u'span', u'building', u'edifice', u'building_complex', u'complex', u'catchment', u'coil', u'spiral', u'volute', u'whorl', u'helix', u'colonnade', u'column', u'pillar', u'corner', u'quoin', u'cross', u'deathtrap', u'defensive_structure', u'defense', u'defence', u'door', u'entablature', u'erection', u'establishment', u'false_bottom', u'floor', u'level', u'storey', u'story', u'fountain', u'guide', u'honeycomb', u'house_of_cards', u'cardhouse', u'card-house', u'cardcastle', u'housing', u'lodging', u'living_accommodations', u'hull', u'jungle_gym', u'lamination', u'landing', u'landing_place', u'lookout', u'observation_tower', u'lookout_station', u'observatory', u'masonry', u'memorial', u'monument', u'mound', u'hill', u'obstruction', u'obstructor', u'obstructer', u'impediment', u'impedimenta', u'partition', u'divider', u'platform', u'weapons_platform', u'porch', u'post_and_lintel', u'prefab', u'projection', u'public_works', u'sail', u'set-back', u'setoff', u'offset', u'shelter', u'shoebox', u'signboard', u'sign', u'stadium', u'bowl', u'arena', u'sports_stadium', u'superstructure', u'supporting_structure', u'tower', u'transept', u'trestlework', u'vaulting', u'ways', u'shipway', u'slipway', u'wellhead', u'wind_tunnel', u'base', u'bag', u'baseball', u'baseball_bat', u'lumber', u'baseball_glove', u'glove', u'baseball_mitt', u'mitt', u'batting_cage', u'cage', u'batting_glove', u'batting_helmet', u"catcher's_mask", u'mound', u'hill', u"pitcher's_mound", u'pine-tar_rag', u'rosin_bag', u'beat', u'carve', u'cast', u'mold', u'mould', u'chip', u'cut_out', u'grind', u'handbuild', u'hand-build', u'coil', u'hill', u'layer', u'machine', u'model', u'mold', u'mould', u'mound', u'preform', u'preform', u'puddle', u'reshape', u'remold', u'roughcast', u'sculpt', u'sculpture', u'sinter', u'stamp', u'swage', u'upset', u'throw']
word: Cornwall
(Synset('cornwall.n.01'), u'a hilly county in southwestern England')
Hypernyms
[]
Hyponyms of all hypernyms
[]
word: ?
Hypernyms
[]
Hyponyms of all hypernyms
[]
What is the highest lookout in Cornwall?
What is the highest hill in Cornwall?
What is the highest story in Cornwall?
What is the highest hangar in Cornwall?
What is the highest shipway in Cornwall?
What is the highest landing in Cornwall?
What is the highest sculpt in Cornwall?
What is the highest tower in Cornwall?
What is the highest observation tower in Cornwall?
What is the highest wellhead in Cornwall?
What is the highest pine-tar rag in Cornwall?
What is the highest mould in Cornwall?
What is the highest pillar in Cornwall?
What is the highest deathtrap in Cornwall?
What is the highest offset in Cornwall?
What is the highest stamp in Cornwall?
What is the highest cardcastle in Cornwall?
What is the highest body in Cornwall?
What is the highest honeycomb in Cornwall?
What is the highest bag in Cornwall?
What is the highest weapons platform in Cornwall?
What is the highest post and lintel in Cornwall?
What is the highest prefab in Cornwall?
What is the highest erection in Cornwall?
What is the highest swage in Cornwall?
What is the highest obstructor in Cornwall?
What is the highest handbuild in Cornwall?
What is the highest baseball mitt in Cornwall?
What is the highest sports stadium in Cornwall?
What is the highest ridge in Cornwall?
What is the highest sail in Cornwall?
What is the highest divider in Cornwall?
What is the highest beat in Cornwall?
What is the highest cut out in Cornwall?
What is the highest carve in Cornwall?
What is the highest monument in Cornwall?
What is the highest corner in Cornwall?
What is the highest batting helmet in Cornwall?
What is the highest defence in Cornwall?
What is the highest airdock in Cornwall?
What is the highest sign in Cornwall?
What is the highest puddle in Cornwall?
What is the highest preform in Cornwall?
What is the highest mount in Cornwall?
What is the highest remold in Cornwall?
What is the highest area in Cornwall?
What is the highest supporting structure in Cornwall?
What is the highest level in Cornwall?
What is the highest building in Cornwall?
What is the highest head in Cornwall?
What is the highest cardhouse in Cornwall?
What is the highest promontory in Cornwall?
What is the highest porch in Cornwall?
What is the highest machine in Cornwall?
What is the highest whorl in Cornwall?
What is the highest foreland in Cornwall?
What is the highest upset in Cornwall?
What is the highest lumber in Cornwall?
What is the highest set-back in Cornwall?
What is the highest arch in Cornwall?
What is the highest balance in Cornwall?
What is the highest rosin bag in Cornwall?
What is the highest storey in Cornwall?
What is the highest wind tunnel in Cornwall?
What is the highest memorial in Cornwall?
What is the highest housing in Cornwall?
What is the highest spiral in Cornwall?
What is the highest transept in Cornwall?
What is the highest mold in Cornwall?
What is the highest complex in Cornwall?
What is the highest arena in Cornwall?
What is the highest upland in Cornwall?
What is the highest lodging in Cornwall?
What is the highest partition in Cornwall?
What is the highest altar in Cornwall?
What is the highest equilibrium in Cornwall?
What is the highest slipway in Cornwall?
What is the highest mountain in Cornwall?
What is the highest setoff in Cornwall?
What is the highest masonry in Cornwall?
What is the highest lookout station in Cornwall?
What is the highest edifice in Cornwall?
What is the highest defense in Cornwall?
What is the highest house of cards in Cornwall?
What is the highest obstructer in Cornwall?
What is the highest hull in Cornwall?
What is the highest building complex in Cornwall?
What is the highest batting cage in Cornwall?
What is the highest lamination in Cornwall?
What is the highest baseball bat in Cornwall?
What is the highest headland in Cornwall?
What is the highest shelter in Cornwall?
What is the highest highland in Cornwall?
What is the highest repair shed in Cornwall?
What is the highest guide in Cornwall?
What is the highest counterbalance in Cornwall?
What is the highest chip in Cornwall?
What is the highest model in Cornwall?
What is the highest column in Cornwall?
What is the highest impedimenta in Cornwall?
What is the highest catcher's mask in Cornwall?
What is the highest public works in Cornwall?
What is the highest pitcher's mound in Cornwall?
What is the highest boarding in Cornwall?
What is the highest reshape in Cornwall?
What is the highest baseball glove in Cornwall?
What is the highest sculpture in Cornwall?
What is the highest shoebox in Cornwall?
What is the highest catchment in Cornwall?
What is the highest establishment in Cornwall?
What is the highest bridge in Cornwall?
What is the highest colonnade in Cornwall?
What is the highest layer in Cornwall?
What is the highest cross in Cornwall?
What is the highest roughcast in Cornwall?
What is the highest glove in Cornwall?
What is the highest observatory in Cornwall?
What is the highest arcade in Cornwall?
What is the highest defensive structure in Cornwall?
What is the highest platform in Cornwall?
What is the highest bowl in Cornwall?
What is the highest card-house in Cornwall?
What is the highest cage in Cornwall?
What is the highest throw in Cornwall?
What is the highest mitt in Cornwall?
What is the highest batting glove in Cornwall?
What is the highest jungle gym in Cornwall?
What is the highest equipoise in Cornwall?
What is the highest swell in Cornwall?
What is the highest stadium in Cornwall?
What is the highest helix in Cornwall?
What is the highest door in Cornwall?
What is the highest projection in Cornwall?
What is the highest sinter in Cornwall?
What is the highest living accommodations in Cornwall?
What is the highest impediment in Cornwall?
What is the highest base in Cornwall?
What is the highest signboard in Cornwall?
What is the highest false bottom in Cornwall?
What is the highest bascule in Cornwall?
What is the highest entablature in Cornwall?
What is the highest floor in Cornwall?
What is the highest volute in Cornwall?
What is the highest hand-build in Cornwall?
What is the highest span in Cornwall?
What is the highest superstructure in Cornwall?
What is the highest baseball in Cornwall?
What is the highest coil in Cornwall?
What is the highest cast in Cornwall?
What is the highest fountain in Cornwall?
What is the highest ways in Cornwall?
What is the highest mound in Cornwall?
What is the highest trestlework in Cornwall?
What is the highest landing place in Cornwall?
What is the highest balcony in Cornwall?
What is the highest obstruction in Cornwall?
What is the highest vaulting in Cornwall?
What is the highest quoin in Cornwall?
What is the highest grind in Cornwall?
[(1403, [('in', 'cornwall'), ('highest', 'mountain'), ('the', 'highest'), ('mountain', 'in')]), (132, [('building', 'in')]), (1319, [('in', 'cornwall')]), (1510, [('the', 'highest')]), (1448, [('the', 'highest')]), (1189, [('tower', 'in')])]
Bronn Wennili yw an ughella menydh yn -- Brown Willy is the highest mountain
Kernow. -- in Cornwall.
(highest mountain in), (mountain in cornwall), (is the highest), (the highest mountain)
Bronn Wennili yw an ughella menydh yn -- Brown Willy is the highest mountain
Kernow. -- in Cornwall.
(in cornwall), (highest mountain), (the highest), (mountain in)
An drehevyans a-rag an chi yw karrji. -- The building in front of the house is
-- a garage.
(building in)
Ammeth yw tra vras yn Kernow. -- Agriculture is a big affair in
-- Cornwall.
(in cornwall)
An gwithyas-kres a yskynnas an skeul -- The policeman went up the ladder as
bys dhe fenester an ughella chambour. -- far as the window of the highest
-- bedroom.
(the highest)
Ny yll ev esedha war an ughella huni. -- He cannot sit on the highest one.
(the highest)
Ny welyn an baner kernewek a-ugh tour -- We do not see the Cornish flag above
an eglos y'n dre ma. -- the church tower in this town.
(tower in)
Showing posts with label WordNet. Show all posts
Showing posts with label WordNet. Show all posts
Sunday, 21 August 2016
What is the highest stadium in Cornwall?
Suppose we want to translate the sentence "What is the highest hill in Cornwall?" into Cornish, but that the corpus may use a synonym for one of the words.
Labels:
cornish language,
kernewek,
NLTK,
Python,
WordNet
Saturday, 20 August 2016
Nanotechnology is sunny in Cornwall today
Using Python NLTK, it is possible to find synonyms of input words using WordNet, and then feed this into the translation memory software.
It can produce odd results since some words will have different senses that was intended in the input sentence.
When using for the sentence "It is sunny in Cornwall today.", the only sentence returning the bigram ("today", ".") is
"Morwenna yw lowen. Hy fenn-bloedh yw hedhyw. -- Morwenna is happy. Her birthday is today. : [('today', '.')]". However using WordNet to find similar words (by finding words that are hyponyms of the hypernyms of the word) bigrams ("now", ".") and ("yesterday", ".") are also found in the sentence corpus.
It can produce odd results since some words will have different senses that was intended in the input sentence.
When using for the sentence "It is sunny in Cornwall today.", the only sentence returning the bigram ("today", ".") is
"Morwenna yw lowen. Hy fenn-bloedh yw hedhyw. -- Morwenna is happy. Her birthday is today. : [('today', '.')]". However using WordNet to find similar words (by finding words that are hyponyms of the hypernyms of the word) bigrams ("now", ".") and ("yesterday", ".") are also found in the sentence corpus.
python wordnettest.py
Enter some text please.
It is sunny in Cornwall today.
word: It
(Synset('information_technology.n.01'), u'the branch of engineering that deals with the use of computers and telecommunications to retrieve and store and transmit information')
Hypernyms
[Synset('engineering.n.02')]
(Synset('engineering.n.02'), u'the discipline dealing with the art or science of applying scientific knowledge to practical problems')
Hyponyms of all hypernyms
[u'aeronautical_engineering', u'architectural_engineering', u'bionics', u'biotechnology', u'bioengineering', u'ergonomics', u'chemical_engineering', u'civil_engineering', u'computer_science', u'computing', u'electrical_engineering', u'EE', u'industrial_engineering', u'industrial_management', u'information_technology', u'IT', u'mechanical_engineering', u'nanotechnology', u'naval_engineering', u'nuclear_engineering', u'rocketry']
word: sunny
(Synset('cheery.s.01'), u'bright and pleasant; promoting a feeling of cheer')
Hypernyms
[]
Hyponyms of all hypernyms
[]
word: Cornwall
(Synset('cornwall.n.01'), u'a hilly county in southwestern England')
Hypernyms
[]
Hyponyms of all hypernyms
[]
word: today
(Synset('today.n.01'), u'the present time or age')
(Synset('today.n.02'), u'the day that includes the present moment (as opposed to yesterday or tomorrow)')
(Synset('nowadays.r.01'), u'in these times')
(Synset('today.r.02'), u'on this day as distinct from yesterday or tomorrow')
Hypernyms
[Synset('present.n.01'), Synset('day.n.01')]
(Synset('present.n.01'), u'the period of time that is happening now; any continuous stretch of time including the moment of speech')
(Synset('day.n.01'), u'time for Earth to make a complete rotation on its axis')
Hyponyms of all hypernyms
[u'date', u'here_and_now', u'present_moment', u'moment', u'now', u'time_being', u'nonce', u'today', u'tonight', u'date', u'day_of_the_month', u'date', u'eve', u'morrow', u'today', u'tomorrow', u'yesterday']
word: .
Hypernyms
[]
Hyponyms of all hypernyms
[]
mechanical engineering is sunny in Cornwall today.
electrical engineering is sunny in Cornwall today.
industrial management is sunny in Cornwall today.
aeronautical engineering is sunny in Cornwall today.
nuclear engineering is sunny in Cornwall today.
nanotechnology is sunny in Cornwall today.
ergonomics is sunny in Cornwall today.
chemical engineering is sunny in Cornwall today.
It is sunny in Cornwall tonight.
It is sunny in Cornwall now.
It is sunny in Cornwall eve.
It is sunny in Cornwall present moment.
It is sunny in Cornwall morrow.
EE is sunny in Cornwall today.
It is sunny in Cornwall moment.
It is sunny in Cornwall today.
rocketry is sunny in Cornwall today.
biotechnology is sunny in Cornwall today.
information technology is sunny in Cornwall today.
It is sunny in Cornwall yesterday.
architectural engineering is sunny in Cornwall today.
civil engineering is sunny in Cornwall today.
naval engineering is sunny in Cornwall today.
computing is sunny in Cornwall today.
industrial engineering is sunny in Cornwall today.
It is sunny in Cornwall day of the month.
IT is sunny in Cornwall today.
bionics is sunny in Cornwall today.
It is sunny in Cornwall here and now.
It is sunny in Cornwall tomorrow.
bioengineering is sunny in Cornwall today.
It is sunny in Cornwall nonce.
It is sunny in Cornwall date.
computer science is sunny in Cornwall today.
It is sunny in Cornwall time being.
Nyns yw leuryow an chi salow lemmyn. -- The floors of the house are not safe now. : [('now', '.')]
Yma nebonan y'n gegin lemmyn. -- There is someone in the kitchen now. : [('now', '.')]
Nyns usi an flogh ow koska lemmyn. -- The child is not sleeping now. : [('now', '.')]
A-dro dhe gans lyver yw gwerthys lemmyn. -- About a hundred books are sold now. : [('now', '.')]
Nyns yw hemma dhe les lemmyn. -- This is no use now. : [('now', '.')]
Aga chi yw gwerthys y'n eur ma. -- Their house is sold now. : [('now', '.')]
Pandra! An gewer yw braffa lemmyn. -- What! The weather is finer now. : [('now', '.')]
Ergh a wra hi yn Alban lemmyn. -- It's snowing in Scotland now. : [('now', '.')]
An arghans yw tanow lemmyn. -- Money is scarce now. : [('now', '.')]
Ammeth yw tra vras yn Kernow. -- Agriculture is a big affair in Cornwall. : [('in', 'cornwall')]
Eus. Hi a wra glaw lemmyn. -- There is. It's raining now. : [('now', '.')]
An notenn yw parys lemmyn -- The note is ready now. : [('now', '.')]
Nyns eus le gesys yn kres an dre lemmyn. -- There isn't a place left in the town centre now. : [('now', '.')]
Ugens lyver yw gwerthys lemmyn. -- Twenty books are sold now. : [('now', '.')]
Bys dhe'n eur ma nyns yw an gewer mar lyb dell o hi de. -- Until now the weather is not as wet as it was yesterday. : [('yesterday', '.')]
Nyns yw hi pur lowen lemmyn. -- She is not very happy now. : [('now', '.')]
An glaw yw tynna es dell o de. Nyns o an dhargan gwir, my a dyb. -- The rain is more intense than it was yesterday. The forecast was not true, I think. : [('yesterday', '.')]
Oll an gerens yw marow lemmyn. -- All the near relations are dead now. : [('now', '.')]
Morwenna yw lowen. Hy fenn-bloedh yw hedhyw. -- Morwenna is happy. Her birthday is today. : [('today', '.')]
An byskadoryon yw parys lemmyn. -- The fishermen are ready now. : [('now', '.')]
Yma an dioges yn le'ti lemmyn. -- The farmwife is in the dairy now. : [('now', '.')]
Ni yw lowen lemmyn. -- We are happy now. : [('now', '.')]
Yma neppyth nowydh y'n dre lemmyn. Henn yw bryntin! -- There's something new in the town now. That's splendid! : [('now', '.')]
Yma Jerri ow koska lemmyn. -- Jerry is sleeping now. : [('now', '.')]
Nyns eus anwoes war Pam namoy. -- Pam hasn't got a cold now. : [('now', '.')]
Dha gyttrin yw gyllys lemmyn. -- Your bus is gone now. : [('now', '.')]
Ottena! Yma y wreg ganso lemmyn. -- Look! There's his wife with him now. : [('now', '.')]
Ni yw warbarth lemmyn. -- We are together now. : [('now', '.')]
Yma spas lowr y'n le na lemmyn. -- There is enough room in that place now. : [('now', '.')]
Bronn Wennili yw an ughella menydh yn Kernow. -- Brown Willy is the highest mountain in Cornwall. : [('in', 'cornwall')]
Kewer deg yw brav mes nyns yw an gewer teg lemmyn. -- Fine weather is great but the weather isn't fine now. : [('now', '.')]
An gewer hedhyw yw dihaval diworth an gewer de. -- The weather today is different from the weather yesterday. : [('yesterday', '.')]
Nyns eus denvydh omma kynth yw hi seyth eur lemmyn. -- There's no one here although it's seven o'clock now. : [('now', '.')]
An vamm re worras an kinyow war an voes lemmyn. Kynsa yma kowl onyon. -- Mother has put the dinner on the table now. First there is onion soup. : [('now', '.')]
An chi yw gwerthys lemmyn. -- The house is sold now. : [('now', '.')]
Nyns eus meur a gommolennow lemmyn. -- There are not many clouds now. : [('now', '.')]
Dydh da, Maureen. Brav yw lemmyn. -- Hello, Maureen. It's grand now. : [('now', '.')]
Labels:
cornish language,
kernewek,
NLTK,
Python,
WordNet
Subscribe to:
Posts (Atom)