How to resolve lexical ambiguity in natural language processing?
In general, how algorithm should distinguish the word meaning and recognise the word within the context?


I don't think anybody knows how to answer this for the general case. If they did, they'd have basically solved AGI.  But we can certainly talk about techniques that get part-of-the-way there, and approaches that could work.

One thing I would consider trying (and I don't know off-hand if anybody has tried this exact approach) is to model the disambiguation of each word as a discrete problem for a Bayesian Belief Network where your priors (for any given word) are based on both stored "knowledge" as well as the previously encountered words in the (sentence|paragraph|document|whatever).  So if you "know", for example, that "Reading is a city in the UK" and that "place names are usually capitalized", your network should be strongly biased towards interpreting "Reading" as the city, since nothing in the word position in the sentence strongly contradicts that.  

Of course I'm hand-waving around some tricky problems in saying that, as knowledge representation isn't exactly a solved problem either.  But there are at least approaches out there that you could use.  For example, you could use the RDF / triple based approach from the Semantic Web world.  Finding a good way to merge that stuff with a Bayesian framework could yield some interesting results.    

There has been a bit of research on "probabilistic RDF" that you could possibly use as a starting point.  For example:

http://om.umiacs.umd.edu/material/papers/prdf.pdf

http://ceur-ws.org/Vol-173/pos_paper5.pdf

https://www.w3.org/2005/03/07-yoshio-UMBC/

http://ebiquity.umbc.edu/paper/html/id/271/BayesOWL-Uncertainty-Modeling-in-Semantic-Web-Ontologies

http://www.pr-owl.org/