用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
直接命令不会经过审查 Prompt;运行前请先检查来源。
npx skills add https://github.com/fabioc-aloha/Alex_Plug_In --skill foundry-agent-platform命令会保持在同一行。复制前请横向滚动并检查完整内容。
想先保存到本地?可下载 SkillsMP 当前能够提供的文件。
正在显示 SKILL.md
基于 SOC 职业分类
| name | foundry-agent-platform |
| description | Microsoft Foundry agent deployment, orchestration, and cloud-native AI service patterns |
| tier | extended |
| applyTo | **/*foundry*,**/*agent*platform*,**/*orchestrat* |
| user-invokable | false |
Deploy, orchestrate, and manage AI agents on Microsoft Foundry — the unified Azure PaaS for enterprise AI.
Foundry is in active preview (February 2026). SDK versions change frequently.
Refresh triggers:
azure-ai-projects SDK version bump (currently 2.0.0b3)Last validated: February 2026
Microsoft Foundry (formerly Azure AI Foundry) unifies model hosting, agent orchestration, tool management, observability, and multi-channel publishing.
| Concept | Description |
|---|---|
| Portal |
| https://ai.azure.com |
| Endpoint | https://<resource>.services.ai.azure.com/api/projects/<project> |
| MCP Server | https://mcp.ai.azure.com (cloud-hosted, Entra ID) |
| VS Code Extension | TeamsDevApp.vscode-ai-foundry |
| Key Distinction | Infrastructure platform (backend), not a surface |
| Aspect | VS Code Extension | M365 Copilot | Foundry |
|---|---|---|---|
| Type | IDE plugin | Declarative agent | Cloud PaaS |
| Runtime | Desktop app | M365 cloud | Azure managed |
| Users | Single developer | Single user | Multi-user |
| Availability | When IDE open | When M365 open | Always-on (24/7) |
| Memory | File-based synapses | OneDrive | Platform-managed |
| Tools | MCP (manual config) | Web/SP/Graph | 1,400+ catalog |
| Agents | .agent.md files | Single agent | Multi-agent fleet |
| Observability | Manual | None | Full OpenTelemetry |
This is the most common source of confusion. Foundry has four distinct SDK types, each with different endpoints and use cases:
| SDK | Endpoint | When to Use |
|---|---|---|
| Foundry SDK | .services.ai.azure.com/api/projects/ | Agent management, evaluations, deployments |
| OpenAI SDK | .openai.azure.com/openai/v1 | Chat completions, embeddings (OpenAI-compatible) |
| Foundry Tools SDKs | Service-specific | Speech, Vision, Language, Search, etc. |
| Agent Framework | Framework-specific | Multi-agent orchestration (cloud-agnostic) |
| Language | Foundry SDK | OpenAI SDK |
|---|---|---|
| Python | azure-ai-projects>=2.0.0b3 (use --pre) | openai |
| C# | Azure.AI.Projects (preview) | Azure.AI.OpenAI |
| JS/TS | @azure/ai-projects (beta) | openai |
| Java | com.azure:azure-ai-projects (preview) | — |
Breaking Change: Python 2.x is incompatible with 1.x. The 2.x uses
.services.ai.azure.comendpoints.
from azure.ai.projects import AIProjectClient
from azure.identity import DefaultAzureCredential
client = AIProjectClient(
endpoint="https://<resource>.services.ai.azure.com/api/projects/<project>",
credential=DefaultAzureCredential()
)
agent = client.agents.create_agent(
model="gpt-4.1-mini",
name="my-agent",
instructions="System prompt here."
)
from azure.ai.projects.models import PromptAgentDefinition
definition = PromptAgentDefinition(
model="gpt-4.1-mini",
instructions="System prompt",
tools=[bing_tool, file_search_tool]
)
version = client.agents.create_agent_version(
agent_id=agent.id,
definition=definition
)
conversation = client.agents.create_conversation(agent_id=agent.id)
client.agents.create_message(
conversation_id=conversation.id,
role="user",
content="Hello"
)
run = client.agents.create_run(
conversation_id=conversation.id,
agent_id=agent.id
)
| Concept | Meaning |
|---|---|
| Agent | Stateless definition (model + instructions + tools) |
| Conversation | Stateful multi-turn context |
| Run | Single execution within a conversation |
| Version | Immutable snapshot of agent definition |
| Tool | Use Case | Setup |
|---|---|---|
| Bing Grounding | Real-time web search | Bing Search resource |
| File Search | RAG over documents (vector stores) | Upload files → vector store |
| Code Interpreter | Python sandbox execution | Automatic |
| SharePoint | Enterprise document grounding | SP site + permissions |
| OpenAPI | Any REST API via spec | Provide spec + auth |
| MCP Servers | Remote Model Context Protocol | Server URL + auth |
| A2A | Agent-to-Agent communication | Target URL + auth |
vector_store = client.agents.create_vector_store(name="knowledge")
client.agents.upload_file_and_poll(
vector_store_id=vector_store.id,
file_path="skills.pdf"
)
file_search_tool = FileSearchTool(vector_store_ids=[vector_store.id])
| Feature | Description |
|---|---|
| Memory | Cross-session context retention, per-user, automatic |
| Foundry IQ | Enterprise knowledge base with citations + web grounding |
| Priority Chain | Instructions → IQ → File Search → Tool results → Training data |
Memory is the cloud-native equivalent of Alex's synapse architecture — automatic, persistent, cross-surface.
Containerized agents on managed infrastructure:
pip install azure-ai-agentserver-agentframework
agentserver run --interactive # local test
agentserver run # container mode (port 8080)
azd deploy # deploy to Foundry
Supports any framework: LangGraph, MS Agent Framework, Semantic Kernel, custom.
Agent → OpenTelemetry → Application Insights → Agent Dashboard
from azure.ai.agentserver import setup_observability
setup_observability(vs_code_extension_port=4319) # local dev
Relevance, Groundedness, Coherence, Safety, F1, BLEU, ROUGE
One agent, many surfaces:
| Channel | Transport |
|---|---|
| M365 Copilot | Teams manifest + Entra app |
| Teams | Bot Framework |
| BizChat | Via M365 publish |
| Web Preview | Auto-generated URL |
| REST API | Standard HTTP |
| Container | Docker (Hosted Agent) |
| Transport | Latency | Use Case |
|---|---|---|
| WebRTC | ~100ms | Browser voice |
| WebSocket | ~200ms | Server-side |
| SIP | Varies | Telephony |
Models: gpt-realtime (GA), gpt-realtime-mini (GA). Supports MCP tools during voice sessions, semantic VAD, image input. 30-min session limit, PCM16 mono 24kHz.
from azure.identity import DefaultAzureCredential
credential = DefaultAzureCredential() # Keyless (recommended)
client = AIProjectClient(endpoint=endpoint, credential=credential)
| RBAC Role | Scope |
|---|---|
| Azure AI User | Least privilege — call agents, use models |
| Azure AI Owner | Create/manage agents, deploy models |
| Contributor | Create Foundry projects and resources |
| Anti-Pattern | Why It Fails | Instead |
|---|---|---|
| Using Python SDK 1.x with 2.x docs | Incompatible APIs, wrong endpoints | Always install --pre for 2.x |
| Treating Foundry as "just another heir" | It's a backend, not a surface | Design as shared infrastructure |
| Hardcoding API keys | Security risk, doesn't scale | Use DefaultAzureCredential |
| One giant agent | Context overload, poor routing | Multi-agent with orchestrator |
| Skipping evaluation | No quality baseline | Run evaluators before shipping |
| Ignoring cost | Pay-per-use can surprise | Use efficient models (4.1-mini) for most agents |
When designing a Foundry-based agent:
Create and maintain ASCII visual dashboards for project tracking with parallel lane progress bars
Store and manage voice samples for TTS cloning — portable, version-controlled audio references
Clear documentation through visual excellence