Shift the economy away from agriculture and towards intellectual property such as patents and copyrights.
Is there something specific the government can do to steer this ship?
Spend more on R&D
R&D isn't just a government thing, how do we encourage private companies to invest in research? Do we have a problem with something in our patent system or company laws or something else that stems this? Or will R&D naturally increase as we steer away from agriculture?
Build trust in the share market so people will invest in business instead of real estate.
I honestly think a capital gains tax is absolutely crucial to this. Currently, the sharemarket is taxed, mainly in taxes on dividends and income taxes on overseas shares (FIF). You can buy a house, have it triple in value, and sell it without paying any tax. Negatively gearing rentals in order to not pay tax and instead make an untaxed profit when you sell is a common theme. We can try to disincentivise housing as an investment, but the bare minimum should be to stop subsidising it.
In terms of turning the ship, I think there's one big question that anyone will want to know. We can invest in alternative industries, increase R&D spending, invest in education and healthcare, try to stop the brain drain by somehow boosting salaries and the standard of living, and invest in infrastructure. But I'm assuming to kick start any of this it's up to the government, and the OP is literally about how the country is going broke. How do we find the money to do all of these things, in a world where the established large players are going to fight tooth and nail to avoid change? We also have a country of landlords, and even worse, a government who like to favour landlords by talking about the "mum and dad" landlords to pull heart strings, despite the majority of rentals being owned by people/companies that own many properties. As long as the media and government use the right words, it will be very difficult to get voters to support additional taxes even if only on rentals.