In fiction, artificial intelligence is often associated with intelligent androids or dystopian futures. But in reality, the AI market mainly revolves around crunching large amounts of data to make quick decisions.

Demand for these services -- which power analytics tools, driverless cars, voice assistants, and more -- is climbing. The global AI market was already worth $39.9 billion in 2019, according to Grand View Research, but could still grow at a compound annual growth rate of 42.2% between 2020 and 2027.

That's why many companies are jumping aboard the AI bandwagon. Some of those companies, such as C3.ai (AI 1.31%), are too hot to handle. But several other tech stocks -- including Baidu (BIDU 1.24%), Palantir (PLTR -0.84%), and NVIDIA (NVDA 0.76%) -- are still great long-term plays on the growing AI market.

An android's brain shatters into pieces.

Image source: Getty Images.

1. Baidu

Baidu, which owns China's largest search engine, is one of the world's most advanced AI companies. Its AI services power its main apps, as well as its DuerOS voice assistant and Apollo platform for driverless cars.

DuerOS processed 2.7 billion monthly voice queries last quarter, up 65% from a year ago. The OS provides over 4,300 skills for its mobile apps, Xiaodu smart speakers, Xiaodu Smart Earphones, various third-party hardware devices, and its automotive platform Apollo.

Over 100 automotive and tech companies, including Intel and Ford, are developing self-driving platforms with Apollo. Baidu already launched driverless taxis powered by its services across China last year, and it recently formed a joint venture with the Chinese automaker Geely to produce autonomous electric vehicles.

Baidu's simultaneous expansion across the AI, voice assistant, and automotive markets could extend its reach beyond traditional searches and reduce its overall dependence on ad revenue.

Baidu's business might seem weak right now, since its core advertising revenue has withered year over year for six straight quarters. But as I recently noted, its advertising business is recovering, and the stock still looks reasonably valued at 24 times forward earnings.

2. Palantir

Palantir's data mining platforms, which are used by both government and enterprise customers, gather data on individuals and groups from disparate sources to help organizations make informed decisions.

Its Gotham platform, which is used by the U.S. government, helps the military and government agencies track individuals and plan missions. In its prospectus, Palantir boldly claims Gotham will become the "default operating system for data across the U.S. government."

But Gotham is also a tinderbox of controversy. In one recent example, the company's own employees protested its contract with Immigration and Customs Enforcement (ICE) after its tools were used to identify and deport undocumented immigrants. Its Foundry platform, which offers similar services to enterprise customers and other organizations, is less controversial.

Palantir might not appeal to everyone, but its growth is impressive. It expects its revenue to rise 44% in fiscal 2020, fueled by new contracts and big renewals, and analysts anticipate 32% growth in fiscal 2021.

Palantir still isn't profitable, and its stock isn't cheap at 45 times next year's sales. But its Gotham platform will likely power the U.S. government's AI-driven decisions for the foreseeable future, while Foundry -- which still accounts for less than half of Palantir's revenue -- still has room to grow.

3. NVIDIA

NVIDIA is best known for its gaming GPUs, but its higher-end GPUs also process machine learning and AI tasks in data centers. That's why revenue from its data center business, which acquired the networking technology company Mellanox last April, surged 162% year over year to $1.9 billion last quarter and accounted for 40% of its top line.

A woman reads while sitting in a driverless car.

Image source: Getty Images.

NVIDIA also powers driverless cars with its Drive platform, which bundles together its ARM-based Tegra CPUs, GPUs, and other technologies in onboard computers to help cars drive themselves. Over 370 automotive and tech companies, including Baidu, currently use NVIDIA's Drive technologies.

NVIDIA's automotive revenue declined last quarter, mainly due to the pandemic's impact on auto sales, but the strength of its data center business and its gaming revenue -- which surged 37% year over year to $2.3 billion -- easily offset that decline.

As a result, NVIDIA expects its revenue to rise 51% this fiscal year, and analysts expect its earnings to grow 68%. Next year, they expect its revenue and earnings to rise another 21% and 20%, respectively, even after it laps its takeover of Mellanox. Its pending takeover of ARM, which still faces tough antitrust challenges, could also generate fresh streams of high-margin royalties and licensing revenue once it finally closes.

NVIDIA's stock isn't cheap at nearly 50 times forward earnings, but it remains a great long-term play on the AI market as the data center and automotive industries ramp up their purchases of its powerful chips.