There's little doubt as to which companies led the charge into the artificial intelligence era (AI). Nvidia's processors are found at the heart of most of the planet's high-performance AI platforms, while its role in combating the COVID-19 pandemic thrust Palantir Technologies' software into the spotlight. And both stocks have performed incredibly well over the course of the past few years.

As we enter the next chapter of the AI era, though, things are changing. Unexpected needs are surfacing, and companies are catching up to their competitors. The industry's stocks are starting to ebb and flow a bit more as well, as investors are finally in a position to weigh one against the other. New winners are emerging.

With that as the backdrop, here's a rundown of three artificial intelligence stocks to buy right now while you're still able to step into them at a relative bargain price.

An AI humanoid robot pressing a virtual button.

Image source: Getty Images.

1. C3.ai

What's C3.ai (AI 0.95%)? It's not unlike the aforementioned Palantir in that it provides the software that makes using AI possible. It's just a much smaller outfit, sporting a market cap of only $4 billion.

Don't let its smaller size deter you, though. C3.ai packs a powerful performance punch.

The distinguishing factors here are the company's target markets and how its solutions are packaged. Whereas Palantir Technologies only offers a small number of platforms meant largely for institutional and government use, C3.ai's suite of solutions includes a large number of modest, purpose-specific apps mostly meant for businesses. Utility company ConEdison tapped C3.ai's tech to help it manage its use of so-called smart meters installed at customers' residences, for instance, while oil and gas giant Shell is using C3.ai's know-how to optimize its production machinery for greater net efficiency. The company's also refining its AI agent solutions, which are, of course, a cost-effective alternative to human customer service representatives.

And there's been plenty of historical growth here. C3.ai's revenue has grown at an average (albeit inconsistent) annual pace of about 20% for the past few years and is expected to continue growing at that pace for at least a few more. Although the company's not yet profitable and not likely to be anytime soon, the market is at least apt to offer some reward for any progress that pushes C3.ai toward fiscal viability. That's even more so the case with the stock still being down more than 30% from its December peak despite its partial rebound from its April low.

Just keep this lack of actual profitability in mind. It will make C3.ai a bit riskier trade to own and certainly more volatile than the average stock.

2. Applied Digital

Most investors have been so hyper-focused on the hardware and software being used by AI data centers that they've not stopped to think about who's building them. It's Applied Digital (APLD -2.10%) for one.

This is no mere matter of stacking up some bricks and setting up servers. As it turns out, AI data centers require a massive amount of electricity and pump out a massive amount of heat. This ultimately means a lot of sky-high costs.

Applied Digital helps keep these costs contained. By figuring out how and where to build data center infrastructure with power sources and cooling in mind, the company provides much-needed, next-generation solutions to the AI data center market. This includes tapping into nearby renewable energy sources and building-wide liquid cooling systems, and planning for expansion of server racks.

Much like C3.ai, this business can be a bit unpredictable. This year's top line is projected to grow to the tune of 33% but then slow to less than 8% growth next year. Blame the steep cost of erecting AI infrastructure in the first place. These are major capital expenditures that require significant funding that can be cancelled at the first sign of economic headwinds. In this vein, Microsoft recently cancelled plans for a handful of new data centers in Ohio, while Amazon is reconsidering several as well. For perspective, Astrid Atkinson, co-founder and CEO of grid-optimization software provider Camus Energy, believes only a fraction of the nation's currently planned data centers will actually get built. That's a big reason Applied Digital shares haven't made much net progress since late last year, suffering a couple of serious sell-offs between then and now.

Just take a step back and look at the bigger picture. The long-term need for AI is still as great as it's ever been. The industry's going to need this company's services sooner or later.

This might help: Nearly the entire analyst community following this stock considers Applied Digital a strong buy, with a consensus price target of $14.61, which is more than 30% above APLD stock's current price.

3. DigitalOcean

Finally, add DigitalOcean (DOCN -0.49%) to your list of AI stocks to buy while shares are still trading down more than 30% from their February high and still more than 70% below their 2021 peak. Analysts say it's worth at least 30% more right now, although it's arguably got far more upside further down the road.

Great, but what is it? It's a bit tricky to explain to the average non-techie, but it wouldn't be wrong to say it lies somewhere between Applied Digital and C3.ai. DigitalOcean neither builds data centers nor provides access to user-friendly AI software. Rather, this company's specialty is providing the cloud infrastructure and platforms needed by institutions that simply want to establish a new AI data center of their own. Its GradiantAI platform, for example, is a "developer-first platform that makes it easy to build, scale, and ship AI-powered applications."

The company also offers a range of more basic web-hosting options, blockchain solutions, and video-streaming tech . AI is a top growth driver though, contributing to last year's top-line improvement of 13% that's expected to accelerate just a bit over the course of the coming three years.

Growth is apt to remain robust for far longer than this forecasted time frame, however, especially given that the majority of its revenue is now recurring. That just means its customers continually pay for ongoing access to its services. As of this year's first quarter, its annualized revenue run rate stands at $843 million versus a reported top line of $211 million for the quarter in question. (Clearly, the company is very, very good at keeping business once it's won.)

Oh yeah ... it's profitable too. Of last year's revenue of $781 million, $328 million was turned into adjusted earnings before interest, taxes, depreciation, and amortization (EBITDA), while the company reported $135 million in free cash flow. There are bigger and higher-margin companies out there to be sure, but none in this same space that are nearly as promising.