Please compare the modernization and dependency theories on the causes of economic gap between rich and poor countries.
In attempting to explain the persistent underdevelopment of Global South, some theorists direct attention primarily toward what happens within these countries while other focus on the position of the developing countries in the world political economy
As you say in your explanation of the question, some theorists look at what happens within developing countries. These are the modernization theorists. They hold that internal factors determine the degree to which a country develops. They look at factors like educational levels, amounts of infrastructure, and cultural attitudes. They do not pay attention to the place of the country in the international system. They argue that countries should improve things like their educational systems so they can develop.
Again as you say, some theorists focus on the position of countries in the global economy. These are the dependency theorists. They argue that countries of the "North" colonized countries of the "South" in the past and that they continue to treat the Southern countries as economic colonies today. That is, they exploit the resources of the South for their own benefit, regardless of the impact on those countries. They argue that countries should limit their participation in the international economy (should close their own markets) so that they can develop instead of allowing themselves to be exploited.