Space Mining · 15 / 26

Microsoft Foundry Example

The mining platform's mission copilot built on Microsoft Foundry: agent service, Azure AI (artificial intelligence) Search, Entra ID (identifier), tracing and evaluation, for documentation only.

The same platform on Microsoft Foundry

Microsoft Foundry (formerly Azure AI Foundry) is Microsoft's platform for building and running AI applications and agents. This build keeps the contracts from the overall design and maps each part onto a Foundry or Azure service. It covers only the language-model copilot: the advisors run on ground systems and flight control runs on the vehicle, and neither is in Foundry.

Design partIn Microsoft Foundry
Copilot agentA Foundry agent in a project, with instructions and draft-only tools. A thin service in front handles the workflow
ModelsModel deployments in the project, reached through the enterprise AI gateway for scanning and budgets
Procedure indexAzure AI Search index (now presented as Foundry IQ) with a knowledge tool on the agent, filtered by vehicle class and date
Tool gatewayThe ground API (Application Programming Interface) as an OpenAPI tool, or the gateway attached as an MCP (Model Context Protocol) tool, exposing reads and drafts only
IdentityMicrosoft Entra ID, managed identities and role-based access control; no keys in code
SafetyFoundry content filters and guardrails, in addition to Prisma AIRS at the gateway
Tracing and evaluationOpenTelemetry traces to Application Insights, and Foundry evaluators for agents

Build steps

  1. 1 · Create the project

    One Foundry project per environment, with a managed identity and role assignments for search, storage and the ground API.

  2. 2 · Deploy models

    Deploy the small and reasoning models and point the project at the enterprise gateway so every call is scanned and budgeted.

  3. 3 · Build the procedure index

    Load procedures and licence terms into Azure AI Search with vehicle class, version and effective-date fields, and attach it as the agent's knowledge tool.

  4. 4 · Register tools

    Describe the read and draft operations as an OpenAPI tool. No tool signs, approves, releases or files anything; those happen at mission control by a named person.

  5. 5 · Create the agent

    Write instructions, attach tools and run a thread per shift.

  6. 6 · Trace and evaluate

    Turn on tracing, run agent evaluators on the shared evaluation set and gate releases on the result.

Creating the agent

A sketch with the Azure AI Projects SDK (Software Development Kit). The SDK changes quickly, so confirm the current class and method names. The important points are the identity, the draft-only tool set and the thread per shift.

foundry/mission_copilot.py · a sketch, not a pinned SDK version
from azure.identity import DefaultAzureCredential
from azure.ai.projects import AIProjectClient

project = AIProjectClient(
    endpoint=os.environ["FOUNDRY_PROJECT_ENDPOINT"],
    credential=DefaultAzureCredential(),            # managed identity in Azure, your login locally
)

agent = project.agents.create_agent(
    model="sm-reasoner",                            # deployment name, routed through the gateway
    name="mission-copilot",
    instructions=open("prompts/mission_copilot.md").read(),
    tools=[SEARCH_PROCEDURES_TOOL, MINING_OPENAPI_TOOL],   # procedures from AI Search; draft-only tools via OpenAPI
)

def draft_for_shift(thread_id: str | None, structured_facts: str):
    thread = project.agents.threads.get(thread_id) if thread_id else project.agents.threads.create()
    project.agents.messages.create(thread_id=thread.id, role="user", content=structured_facts)
    run = project.agents.runs.create_and_process(thread_id=thread.id, agent_id=agent.id)
    return thread.id, run
A Foundry agent run that drafts the shift report The service adds the structured shift facts to a thread and runs the copilot. The agent calls the model through the gateway, searches the procedures for the report template, reads the ledger status through the OpenAPI tool and returns a draft. The engineer edits and signs at mission control, which issues a signature that allows the filing. Workflow service Foundry agent Model via gateway AI Search Mining API Engineer structured facts, run thread plan the draft call get_ledger_status OpenAPI: ledger status reconciled, gap 0.2% query report template, class filter template v4 draft from facts and template draft draft for the engineer review, edit, sign signature on content hash file report with signature filed
A Foundry agent run that drafts the shift report

The agent drafts. Only a person's signature allows filing, and no tool can supply it.

Keeping the mission safe

Evaluation in Foundry

What is measuredEvaluatorThreshold
Did the agent understand the requestIntent resolutionAt least 0.9 on the set
Did it call the right tool with the right argumentsTool call accuracyAt least 0.95
Did it follow its instructions and policiesTask adherenceAt least 0.95
Are statements supported by the facts and the procedureGroundednessAt least 0.95
Is anything unsafe, leaked or beyond a draftSafety evaluators and a custom checkZero failures

Thresholds are illustrative. Set them from your own baseline and review them as the set grows.

When to choose it

Choose Foundry whenChoose another build when
The company standardises on Azure, Entra ID and Application InsightsYou need to control the workflow graph and its checkpoints in code
Managed hosting of agent threads and tools is a benefitData residency or export rules rule out a hosted agent service
Security and operations teams already work in Azure toolsYour evaluation and tracing tools are built around another stack

Build this for your business

This example is speculative and describes no real mission, but the same pattern, deterministic safety for every hard duty, a governed gateway, runtime security, advisory-only AI and measured quality, fits any remote, high-consequence operation. We can scope a pilot on your own systems.

Book a discovery call