It would be easy to write software to parse that particular phrasing of that particular relationship ("Company X in Talks to Buy Company Y"), but to catch any arbitrary relationship between two entities in a given domain? That's no longer an easy problem. Not to mention that you'll need to represent that world knowledge coherently in ontologies / knowledge bases and write complex logic around it to make the data actionable.