Last November, OpenAI launched the intelligent language tool, ChatGPT, and it's since exploded in popularity and netted a $10 billion investment from Microsoft. The bot has impressed me with how well it can spit out articulate, comprehensive explanations for things as varying as dating app messages to news articles.Earlier this month, I asked ChatGPT to share its thoughts on the stock market, and it gave a surprisingly thorough breakdown of meme stocks, S&P 500 moves, and lingering market impacts from the pandemic.Here's what the AI tool had to say when I asked for a good investment strategy for a recession. ChatGPT's 5-part investing strategyThe bot's history only goes as far as 2021, so it doesn't have access to real-time markets data or news of current affairs. Yet, the portfolio advice it produced was similar to that of human strategists I've spoken to this year. "During a recession, it is important to have a well-diversified investment portfolio that can weather market volatility," ChatGPT wrote.Then it listed out the following: Defensive sectors: "Sectors such as healthcare, utilities, and consumer staples tend to perform well during a recession because they provide essential goods and services that are in demand regardless of economic conditions."Bonds: "Bonds are considered a "safe haven" asset class because they provide a steady stream of income and can protect against stock market volatility. During a recession, it may be wise to invest in bonds issued by the U.S.
government or high-quality corporations."Value stocks: "These companies typically have strong fundamentals, such as high cash reserves and low debt levels, which can help them weather economic downturns."Real estate: "Real estate can be a good investment during a recession because it is a tangible asset that can provide cash flow through rental income. While the real estate market may be affected by the recession, the impact is not as severe as the stock market, and the long-term prospects of real estate remain positive." ChatGPT emphasized that a recession is a short-term economic slowdown, and markets eventually recover. That means investors would be wise to adopt a long-term perspective on each of these investments, it said.As any cautious advisor would warn, the bot concluded with the reminder that "past performance of an investment is not indicative of future performance and that investing always carries risk."Thanks, ChatGPT.