May 19th, 2025
0 reactions

Microsoft and Hugging Face expand collaboration to accelerate Open-Source AI Innovation on Azure AI Foundry

Vaidyaraman Sambasivam
Partner Head of Product, Azure AI Ecosystems

Today, Microsoft and Hugging Face are excited to announce an expanded collaboration that puts over ten thousand Hugging Face models at the fingertips of Azure developers.  

Azure AI Foundry Models now allows immediate deployment of the most popular open models on Hugging Face, spanning text, vision, speech, and multimodal models. This expanded collaboration advances our shared goal to democratize AI by making it easier for developers and enterprises to access, deploy, and scale the latest open models on Azure. This also makes Azure AI Foundry as the platform that offers one of the largest and most diverse open-source model collections on a hyper scale cloud platform. 

“This expanded collaboration is a reflection of our deep commitment to open-source AI. Hugging Face has emerged as the central hub hosting millions of open models and serving as the default launchpad for open-source AI innovation.”  said Asha Sharma, Corporate Vice President at Microsoft. “By combining Hugging Face’s vibrant developer ecosystem with Azure’s enterprise-grade infrastructure, we’re enabling customers to innovate faster and more securely with the best models the community has to offer.”

Hugging Face is home to millions of open models. Organizations, large and small, along with a large community of 8 million AI builders, use the Hugging Face platform to access and share models, datasets and applications. They release model weights and cards for their models on Hugging Face organizations, contribute to Hugging Face libraries such as transformers and diffusers to enable new model architectures, and demonstrate model performance using evaluation metrics on Hugging Face open model leaderboards. Leveraging all this innovation in an enterprise environment, where you need to scale throughput, optimize latency, screen for malicious code, and secure endpoints with private networks can be a challenge. The goal of this expanded collaboration is to bring opensource AI innovation to Azure through a secure, scalable and reliable integration between the Hugging Face hub and Azure AI Foundry.

Expanding Modalities

The refreshed integration enables Azure AI developers to incorporate more modalities in their applications and facilitate a variety of tasks including text generation, feature extraction, fillmask, translation, identifying sentence similarity, image classification, image segmentation, text to image generation, image to text conversion, automatic speech recognition and audio-classification. Whether you’re starting foundational research or deploying AI at scale, you now have access to one of the most robust open-source AI ecosystems, backed by the enterprise readiness of Microsoft Azure.

Microsoft is also working with Hugging Face to bring in additional models enabling tasks like text to speech, audio to audio, image to 3D and text to video. Support for trending models of Hugging Face hub on Foundry across these new modalities is coming soon, expanding what’s possible for developers to build multimodal AI solutions on Azure.

As Clem Delangue, co-founder and CEO of Hugging Face, puts it, “We’re enabling companies to take control of their AI destiny, deploying the best open models securely within their Azure account, to build AI applications they can trust and verify.”

 Top Providers, Trending Models—Available Day One

Through this expanded collaboration, we will also offer the latest models from top model providers in the Azure AI Foundry catalog on the same day they’re released on the Hugging Face hub, providing day one access to the latest models for one-click deployment on Foundry.

We will also bring in customized variants of trending open models, giving enterprises and developers access to fine-tuned, production-ready models meeting functional and performance needs.

Security First

All models made available in the Hugging Face collection in the Azure AI Foundry catalog for discovery and deployment have been scanned by Hugging Face to be safe from vulnerabilities. As part of this expanded collaboration, Microsoft will work with Hugging Face to also host certain model weights on Azure, that will enable customers to deploy these models as secure endpoints with no external network egress to Hugging Face hub.

Beyond Models: Tools, Agents, and More

In the future, we will also work to bring community driven apps from Hugging Face, expanding the catalog to containerized tools to power agents with the smolagents framework. This will enable developers to build modular agentic applications using open and composable components, all within a scalable, production-grade cloud environment.

Consume using Azure AI Inference SDK

Models offered with Text Generation Inference (TGI) and Text Embedding Inference (TEI) offer an OpenAI Chat Completion API compatible layer under the API routes /v1/chat/completions and /v1/embeddings, check the full specification in the OpenAI Chat Completion Create Documentation. These models can be consumed using Azure AI Inference SDK.

Python Code sample:

Pre-requisite: Install the Azure AI Inferencing package using pip install azure.ai.inference

Add your Azure AI Foundry endpoint and API Key to the following sample code sample and run inference:

import os
from azure.ai.inference import ChatCompletionsClient
from azure.core.credentials import AzureKeyCredential
from azure.ai.inference.models import SystemMessage, UserMessage

endpoint = "https://<endpoint-name>.<region>.inference.ml.azure.com/v1"
key = os.getenv("AZURE_AI_CHAT_KEY", "key here")

client = ChatCompletionsClient(
    endpoint=endpoint,
    credential=AzureKeyCredential(key),
)

response = client.complete(
    stream=True,
    messages=[
        SystemMessage("You are a helpful assistant."),
        UserMessage("I want to go to Iceland, which is the best time of the year to visit?"),
    ],
)

for update in response:
    if update.choices and update.choices[0].delta:
        print(update.choices[0].delta.content or "", end="", flush=True)
    if update.usage:
        print(f"\n\nToken usage: {update.usage}")

client.close()

Learn More and Get Started

As the open-source AI landscape continues to evolve, our expanded collaboration with Hugging Face will remain focused on bringing the latest in AI innovation to Azure AI developers.

👉 Start exploring the Azure AI + Hugging Face collection: https://aka.ms/FoundryHuggingFaceCollection

👉 Join us at Microsoft Build to see it in action

Author

Vaidyaraman Sambasivam
Partner Head of Product, Azure AI Ecosystems

Vaidya leads Azure AI Core Ecosystems, driving innovation across Foundry hosting for models, agents and tooling, the Atlas of AI catalog — which includes Foundry Labs, where our mission is to accelerate product innovation and incubate next-generation AI solutions.

0 comments