Snap has acquired AI Factory, a startup developing image and video recognition, analysis and processing technology, the company confirmed.

Snap is using AI Factory’s tech to power Snapchat’s recently launched Cameos feature, in which users can insert a selfie of themselves, deepfakes-style, into a scene and send the short, looping videos to friends via chat. With Cameos, which launched in mid-December, Snapchatters can make themselves into (among other things) a flying hotdog, a singing bird with a chef’s hat, a talking cat, or a dancing roast chicken.

Snap paid $166 million for AI Factory, according to Ukranian tech publication AIN.ua, which first reported on the deal. A Snap spokesman declined to comment on the terms of the pact. AI Factory listed its headquarters in San Francisco with offices in the Ukraine.

AI Factory was founded by CEO Victor Shaburov, who previously founded facial-recognition startup Looksery — which Snapchat acquired in 2015. Snap used the Looksery technology to power its animated-selfie Lenses launched that year; Shaburov served as Snap’s director of engineering for three years following that deal, before departing in 2018 to form AI Factory.

The Cameos feature is located in Snapchat’s Chat menu, right beside Stickers, and began rolling out on iOS and Android apps last month. The initial feature includes some 150 Cameos and can let two Snapchat users co-star in a Cameo scene together.

Other Snap acquisitions have included its 2016 deal for Bitstrips for $100 million, bringing it the Bitmoji cartoon-avatar app; and Zenly, a French social mapping startup, in 2017, which formed the basis of Snap Map.