New Delhi, Oct. 24 -- SpaceX's efforts to finalize a $40 billion off-balance-sheet debt structure for its artificial intelligence buildout have been roiled by recent market turmoil that's driven up sector-wide borrowing costs and complicated price talks.

The transaction under discussion is designed to fund the purchase of Nvidia Corp.'s chips through a special purpose vehicle, keeping the liabilities off SpaceX's own books and safeguarding its investment-grade ratings, according to people familiar with the matter.

Bankers led by Goldman Sachs Group Inc. are discussing the structure with investors led by Apollo Global Management Inc., with Apollo-backed Atlas SP slated to manage the entity, the people said, asking not to be identified di...