When Chinese President Xi Jinping welcomes African leaders to Beijing this week, he’ll be holding a smaller checkbook and will have a clearer sense of what China wants in exchange: bigger returns and fewer headaches.

From Angola to Djibouti, for over a decade, China poured more than $120 billion of government-backed loans through its Belt and Road Initiative to build hydropower plants, roads and rail lines across the continent — as well as unparalleled influence. Those relationships helped Beijing lock down access to energy and minerals, while providing an outlet for its pent up industrial capacity.

But the infrastructure and diplomacy also came with accusations of debt traps, exploitation and corruption, charges that were bolstered when a wave of debt distress swept Africa in recent years and three countries defaulted, sparking lengthy restructurings. Some projects, like an unfinished $3.8 billion railway in Kenya that ends in an empty field, seemed to epitomize the failed promise of the BRI.