AI-3018 Learning Portal
Objective 1.1 30 minhigh priorityazure-ai-foundryhubprojectagentthreads

1.1 — Create an Agent Project or New Agent

Understand the Hub → Project → Agent hierarchy in Azure AI Foundry and how to create your first agent.

Concept — What & Why

The Foundry Hierarchy

Azure AI Foundry is Microsoft's unified platform for building, deploying, and managing AI solutions — including AI agents, language models, and generative AI applications. The portal at ai.azure.com is your primary interface for agent development under the AI-3018 applied skills credential.

Understanding where agents live requires understanding three nested levels:

LevelWhat it isAnalogy
HubThe top-level Azure AI Foundry resource that governs networking, shared connections, and governance policies. A Hub is the billing and governance parent for all Projects within it.Top-level Azure resource; governs networking, shared connections, and governance policiesThe office building
ProjectA development workspace that lives inside a Hub. It holds agents, model deployments, evaluations, and datasets. A Project belongs to exactly one Hub.A workspace inside a Hub; holds agents, deployments, evaluations, and datasetsA team's workspace
AgentAn AI entity within a Project that wraps a model deployment with persistent system instructions, optional tools, and automatic thread management.An AI entity within a Project; has a model, instructions, and toolsThe actual employee

You cannot create an agent without first having a Project, and you cannot have a Project without a Hub. Both are Azure resources with their own resource IDs, but a Hub is the billing and governance parent.

Agent Anatomy

Every Azure AI Foundry agent is composed of four core components:

ComponentPurposeConfigurable?
ModelThe language model that reasons and generates responsesYes — choose deployment
InstructionsSystem prompt defining the agent's persona, scope, and rulesYes — plain text or markdown
ToolsCapabilities: file search, code interpreter, or custom functionsYes — enable per agent
ThreadA per-session conversation history created automatically at runtime when a user conversation begins. Threads are managed by the Agents API and persist across multi-turn exchanges.Conversation histories; each user session gets its own threadCreated at runtime
Deep Dive — How It Works

Foundry Agent vs. Standalone Model Deployment

A common point of confusion is the difference between an agent configured inside a Foundry Project versus a standalone model deployment:

AspectFoundry Agent (in a Project)Standalone Model Deployment
Has instructionsYes — system prompt baked inNo — caller must pass instructions each request
Has toolsYes — file search, code interpreterNo — raw model endpoint only
Has thread managementYes — automaticNo — caller manages conversation history
Endpoint typeAgents API (/assistants)Completions / Chat Completions API
Best forMulti-turn agentic workflowsOne-off completions, custom orchestration

A standalone model deployment is a prerequisite for creating an agent — the agent uses the deployment as its reasoning engine — but the two concepts serve different purposes.

Creating a Foundry Hub and Project

Step-by-step from the Azure portal:

  1. Navigate to ai.azure.com and sign in with your Azure account.
  2. Select All hubs + projects from the left navigation, then click + New hub.
  3. Provide a Hub name, select your Subscription, Resource group, and Region.
  4. Optionally connect an existing Azure OpenAI resource or let Foundry create one.
  5. Click Next — you can create a default Project at the same time.
  6. Review and click Create. Provisioning takes 1–3 minutes.

Creating a New Agent Inside a Project

Once you have a Project, agents are created in the Agents blade:

  1. Open your Project in AI Foundry.
  2. Select Agents in the left-hand navigation panel.
  3. Click + New agent.
  4. The Agent playground opens with a blank agent configuration.
  5. Assign the agent a name, select a model deployment, and paste your system instructions.
  6. Optionally attach tools (file search, code interpreter, functions).
  7. Click Save to persist the agent definition.

Threads are created automatically when a conversation starts and are not pre-configured in the portal. They persist the full conversation history so the agent can maintain context across multi-turn exchanges.

Hands-On Lab

Hands-On: Create a Hub, Project, and First Agent

Goal: Create a Hub, Project, and first agent in the Azure AI Foundry portal.

  1. Go to ai.azure.com. Sign in with your Azure credentials.
  2. In the left navigation, click All hubs + projects+ New hub. Fill in the Hub name (e.g., ai3018-hub), subscription, resource group, and region. Select East US or Sweden Central for broadest model availability. Click Next.
  3. On the Project step, name the project ai3018-lab and click Create. Wait for provisioning (green checkmarks on all resources).
  4. Once inside the project, click Agents in the left sidebar.
  5. Click + New agent. The Agent Playground opens.
  6. In the Name field enter Demo Assistant.
  7. In the Deployment dropdown, select your GPT-4o deployment (or create one — see Lesson 1.2).
  8. In the Instructions box, type: You are a helpful assistant that answers questions concisely.
  9. Click Save. Your agent now appears in the Agents list with a generated Agent ID (e.g., asst_abc123).
  10. In the playground chat box, type Hello, what can you help me with? and press Enter. The agent should respond using your instructions.
Exam Angle — What AI-3018 Tests

AI-3018 Assessment Focus

This lesson underpins every other domain — you must know the Foundry resource hierarchy cold.

Exam Trap

"A Hub and a Project are the same resource" — They are distinct Azure resources. A Hub is the governance parent (networking, shared connections, policy); a Project is the development workspace that lives inside a Hub. You cannot create a Project without a Hub.

Exam Trap

"You can create an agent before deploying a model" — You cannot. The model deployment must exist before you can create an agent that references it. Attempting to save an agent without selecting a valid model deployment fails.

Exam Trap

"Threads are configured when you create an agent" — Threads are created at runtime when a conversation begins. They are not a property you configure on the agent itself — they are the per-session conversation history managed by the Agents API.

Exam Trap

"An agent and a model deployment are interchangeable" — A model deployment is just the underlying LLM endpoint. An agent wraps the deployment with instructions, tools, and thread management. Using the raw deployment endpoint gives you no agent behavior.

Must Memorize

Hub → Project → Agent is a strict containment hierarchy. A Project belongs to exactly one Hub. A Hub can contain multiple Projects. Cross-project agent references are not supported.

Question — click to flip

Q: What is the direct parent resource of a Foundry Project?

Question — click to flip

Q: Which agent component is created at runtime rather than configured at agent creation time?

Question — click to flip

Q: What is the key difference between using a raw model deployment endpoint and a Foundry Agent?

Question — click to flip

Q: Can you create a Foundry Agent without first deploying a model?

Question — click to flip

Q: Does the Agents API endpoint differ from the Chat Completions API endpoint?

Question — click to flip

Q: What happens to Threads when a Foundry conversation ends?

Sources & Further Reading