Official agent skill

Foundry Hosted Agent Copilotkit

by github in github/awesome-copilot

Ongoing development guidance for agentic web apps that pair a CopilotKit frontend with Microsoft Agent Framework agents on Azure AI Foundry hosted agents over the AG-UI protocol - add and gate agent…

OfficialMITAuto-check passedAI & LLM Engineering

Install Foundry Hosted Agent Copilotkit

skills CLI
$ npx skills add github/awesome-copilot --skill foundry-hosted-agent-copilotkit -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install github/awesome-copilot foundry-hosted-agent-copilotkit --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/github/awesome-copilot.git skills-src && mkdir -p .claude/skills && cp -r skills-src/skills/foundry-hosted-agent-copilotkit .claude/skills/foundry-hosted-agent-copilotkit && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
foundry-hosted-agent-copilotkit
GitHub stars
40k
Token cost
~2.3k tokens
SKILL.md length
1,055 words
Files
7 (incl. references)
Skills in repo
417
Repo updated
First seen
Licence
MIT

At a glance

Ongoing development guidance for agentic web apps that pair a CopilotKit frontend with Microsoft Agent Framework agents on Azure AI Foundry hosted agents over the AG-UI protocol - add and gate agent…

  • Works in 4 steps: Identify the wiring first. Inspect the… → Ground in live documentation. Every… → Execute the task using the matching… → …
  • Tasks that involve Human-in-the-loop approvals
  • SKILL.md covers Mental model, Workflow, References and Task playbooks, plus 1 more section
  • Calls curl

What it does

Foundry Hosted Agent Copilotkit is an agent skill from github/awesome-copilot, published by the product's own GitHub organization. Ongoing development guidance for agentic web apps that pair a CopilotKit frontend with Microsoft Agent Framework agents on Azure AI Foundry hosted agents over the AG-UI protocol - add and gate agent tools, wire human-in-the-loop approvals, build generative UI and shared state, debug the event stream, upgrade pre-1.0 packages safely, and deploy hosted agent updates.

Its SKILL.md is about 2.3k tokens, which your agent loads only when the skill is triggered. The skill folder holds 7 other files, including reference files (for example `references/architecture.md`, `references/deploy-loop.md` and `references/hitl.md`).

It sits in AI & LLM Engineering, covering Human-in-the-loop approvals and Building AI agents. It works with Azure AI Foundry. The repository describes itself as: Community-contributed instructions, agents, skills, and configurations to help you make the most of GitHub Copilot. The licence is MIT.

When your agent uses it

  • Tasks that involve Human-in-the-loop approvals
  • Tasks that involve Building AI agents

Example prompts

  • “/foundry-hosted-agent-copilotkit”

Requirements

  • Python 3

Workflow steps

4 steps, taken from the first numbered list in SKILL.md.

  1. Identify the wiring first. Inspect the codebase before changing anything
  2. Ground in live documentation. Every layer here is pre-1.0 or preview and moves between minor versions. Never trust memorized APIs
  3. Execute the task using the matching reference below.
  4. Verify adversarially. A compiling build, a started dev server, or one successful chat reply is NOT proof. Apply the completion criteria at…

What it can do on your machine

Read from SKILL.md and the folder at commit 727ff2e. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Shell commands in SKILL.md call:

    • curl

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md. Its commands use curl, which can reach the network depending on how they are called.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Foundry Hosted Agent Copilotkit loads about 2.3k tokens when it runs, and up to ~12k if it reads all its reference files. Until then it costs about 100 tokens; SKILL.md has 1,055 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~100
When it runs · the whole SKILL.md, loaded when a task matches
~2.3k
With references · SKILL.md plus every file in references/, read only if the agent opens them
~12k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from github/awesome-copilot at commit 727ff2e, republished under its MIT licence (© github). 1,055 words, ~2,272 tokens.

Download SKILL.mdSave it as .claude/skills/foundry-hosted-agent-copilotkit/SKILL.md (or your agent's skills folder). This skill also uses 6 other files; get the full folder from GitHub.
name
foundry-hosted-agent-copilotkit
description
Ongoing development guidance for agentic web apps that pair a CopilotKit frontend with Microsoft Agent Framework agents on Azure AI Foundry hosted agents over the AG-UI protocol - add and gate agent tools, wire human-in-the-loop approvals, build generative UI and shared state, debug the event stream, upgrade pre-1.0 packages safely, and deploy hosted agent updates.

Developing with CopilotKit + AG-UI + Azure AI Foundry Hosted Agents

Use this skill for development work inside an EXISTING application built on this stack: a React/Next.js frontend using CopilotKit, connected over the AG-UI protocol to a Microsoft Agent Framework (MAF) agent (Python or .NET) that runs as — or is being developed against — an Azure AI Foundry hosted agent (paid Azure service; usage may incur costs).

Do NOT use this skill to scaffold a new project. Dedicated scaffolders exist (the CopilotKit CLI, azd ai agent init); use those, then return here for everything that follows: adding tools, gating them behind approvals, generative UI, shared state, debugging, dependency upgrades, and deploying agent updates.

Mental model

text
CopilotKit hooks (React)            useFrontendTool / useHumanInTheLoop /
        │                           useRenderToolCall / useCoAgent
        ▼
CopilotKit Runtime (route handler)  agents: { <name>: new HttpAgent({ url }) }
        │  AG-UI events over SSE
        ▼
AG-UI endpoint                      ← WHERE this lives defines your architecture
        │
        ▼
MAF Agent (tools, approval modes)   → model deployment

The single most important fact: a deployed Foundry hosted agent endpoint does not speak AG-UI by default. It exposes an OpenAI Responses endpoint (.../protocols/openai/responses) and/or a raw .../protocols/invocations endpoint. AG-UI must be produced somewhere, and where it is produced determines how every feature (especially human-in-the-loop) behaves. The three wirings are described in references/architecture.md.

Workflow

Follow these steps for every task on this stack:

  1. Identify the wiring first. Inspect the codebase before changing anything:
    • add_agent_framework_fastapi_endpoint(...) (Python) or MapAGUI(...) (.NET) wrapping an in-process agent → Architecture A (in-process AG-UI endpoint).
    • A hosted agent whose own container serves AG-UI, declared with protocol: invocations in agent.yaml → Architecture B.
    • A separate service translating between the AG-UI endpoint and a hosted agent's /responses endpoint (look for previous_response_id, mcp_approval_response, or a Foundry conversation object in the code) → Architecture C (translation bridge).
    • Confirm the frontend agent name: the key in the runtime agents config, the agent prop on the <CopilotKit> provider, and the hosted agent name in agent.yaml must all agree.
  2. Ground in live documentation. Every layer here is pre-1.0 or preview and moves between minor versions. Never trust memorized APIs:
    • MAF and Foundry hosted agents: use the Microsoft Docs MCP tools when available, otherwise learn.microsoft.com (/agent-framework/integrations/ag-ui/, /azure/foundry/).
    • CopilotKit: docs.copilotkit.ai (Microsoft Agent Framework section). Verify hook and runtime API names against the TypeScript declarations bundled in the installed @copilotkit/* packages — names have churned (useCopilotAction is legacy; current names include useFrontendTool, useHumanInTheLoop, useRenderToolCall, useCoAgent).
    • AG-UI protocol: docs.ag-ui.com (event reference, dojo patterns).
  3. Execute the task using the matching reference below.
  4. Verify adversarially. A compiling build, a started dev server, or one successful chat reply is NOT proof. Apply the completion criteria at the end of this skill.

References

Load on demand; each is self-contained:

ReferenceLoad when
references/architecture.mdChoosing or understanding the wiring; local-vs-deployed modes; why a translation bridge exists and what it must handle
references/patterns.mdImplementing any of the 7 AG-UI interaction patterns (frontend tools, backend tool rendering, HITL, generative UI, shared state, predictive state)
references/hitl.mdAdding or debugging human-in-the-loop approvals, including the known duplicate-execution hazard
references/troubleshooting.mdAny failure: symptom → root cause → fix tables for every layer
references/upgrading.mdBumping any dependency; version compatibility rules; tracked upstream issues
references/deploy-loop.mdRunning the agent locally with azd ai agent run, deploying updates, deployment gotchas

Task playbooks

Add or modify an agent tool
  1. Define the tool on the agent (@tool in Python; AIFunctionFactory.Create in .NET) with typed, described parameters.
  2. Keep docstrings grounding-safe: do not put concrete example values in parameter descriptions for fields the model must derive from real data — models copy literal examples. Use placeholders and validate inside the tool.
  3. Return compact, model-consumable values; rich formatting belongs in the UI render, not the tool result.
  4. Decide the approval mode now: side-effecting tools get approval_mode="always_require" (see references/hitl.md); read-only tools stay unrestricted.
  5. If the tool call should render in the UI, add a useRenderToolCall/render entry for it (references/patterns.md).
  6. Verify live: trigger the tool through the chat UI, confirm the call and result stream as TOOL_CALL_* events, and confirm renamed or re-typed parameters did not break any frontend component that parses the arguments.
Show full SKILL.md (426 more words)Show less
Wire human-in-the-loop onto an existing tool

Follow references/hitl.md end to end. Summary: mark the tool (approval_mode="always_require" / ApprovalRequiredAIFunction), enable confirmation on the AG-UI wrapper, register the approval UI hook on the frontend, and make the response payload shape match what the server detection expects. Then test approve AND reject AND a follow-up turn after approval (see the duplicate-execution hazard).

Build generative UI or shared state

Follow the pattern table in references/patterns.md. Know the honesty caveat: state synchronization patterns are native when the AG-UI adapter wraps an in-process agent (Architecture A/B); through a Responses-protocol bridge (Architecture C) they require explicit synthesis work — check what the codebase actually implements before promising the feature.

Debug a broken flow
  1. Reproduce at the lowest layer first: curl -N the AG-UI endpoint with a minimal RunAgentInput JSON body and read the raw SSE events. If the bug reproduces there, the frontend is innocent.
  2. For hosted agents, go one layer lower: call the agent's /responses endpoint directly. This is how the known re-execution bug was isolated to the framework rather than the UI stack.
  3. Match the symptom against references/troubleshooting.md — exact error strings are listed.
  4. Restart a locally running hosted agent (azd ai agent run) between verification passes if the agent holds in-memory state; stale state makes tests pass or fail for the wrong reason.
Upgrade dependencies

Follow references/upgrading.md. Never bump a single package in isolation: the version relationship rules there (runtime ↔ AG-UI client, agent-framework line consistency, hosting protocol ↔ manifest version) must hold simultaneously, and any local workaround must be re-validated against its tracked upstream issue before removal.

Deploy an agent update

Follow references/deploy-loop.md: iterate locally against the real agent with azd ai agent run, then azd deploy (each deploy creates a new agent version), then verify the deployed agent — including the approval pause — before declaring success.

Completion criteria

A change on this stack is done only when ALL of these hold:

  1. The read/query path works through the real UI (not only via curl).
  2. Every approval-gated tool was tested both ways: approve → the tool executes server-side and state visibly changes; reject → the tool does not run and the agent acknowledges.
  3. At least one follow-up turn was sent in the same thread after an approval, and the gated tool did NOT silently execute again (references/hitl.md, duplicate-execution hazard).
  4. Tool calls render correctly at stream end, not just during streaming (message snapshots can differ from live events).
  5. For deployed changes: the checks above were run against the deployed endpoint, not only locally — deployment success is not proof of behavior.

© github, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

SKILL.md and 6 other files (references) in skills/foundry-hosted-agent-copilotkit of github/awesome-copilot.

  • SKILL.md
  • references/architecture.md
  • references/deploy-loop.md
  • references/hitl.md
  • references/patterns.md
  • references/troubleshooting.md
  • references/upgrading.md

Open the folder on GitHubat commit 727ff2e

Compare with similar skills

Foundry Hosted Agent Copilotkit next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Foundry Hosted Agent Copilotkit compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Foundry Hosted Agent Copilotkit this skillgithub/awesome-copilot40k—~2.3kAutomated safety check: PassMIT
Langgraphkid-sid/claude-spellbook189—~3.4kAutomated safety check: PassMIT
Azure AI Projects Python SDKmicrosoft/skills3.1k6 repos~2.8kAutomated safety check: PassMIT
Langgraph Human In The Looplangchain-ai/langchain-skills1.3k2 repos~4.1kAutomated safety check: PassMIT
Deep Agents Corelangchain-ai/langchain-skills1.3k1 repos~3.1kAutomated safety check: PassMIT
Langgraphlangchain-ai/docs424—~1.1kAutomated safety check: PassMIT

Similar skills

  • Langgraph

    kid-sid/claude-spellbook

    A skill your agent uses when building or debugging LangGraph workflows — designing state graphs, adding conditional routing, wiring checkpointers, streaming tokens, implementing human-in-the-loop…

    189 GitHub stars~3.4k tokensUpdated 2 mo ago
    AI & LLM EngineeringAuto-check passed
  • Official

    Reference for building on Microsoft Foundry with the azure-ai-projects Python SDK: project clients, versioned agents, evaluations, connections, datasets and indexes.

    3.1k GitHub starsUsed in 6 repos~2.8k tokens
    AI & LLM EngineeringAuto-check passed
  • Langgraph Human In The Loop

    langchain-ai/langchain-skills

    Official

    INVOKE THIS SKILL when implementing human-in-the-loop patterns, pausing for approval, or handling errors in LangGraph.

    1.3k GitHub starsUsed in 2 repos~4.1k tokens
    AI & LLM EngineeringAuto-check passed
  • Deep Agents Core

    langchain-ai/langchain-skills

    Official

    Explains how to build agents with the Deep Agents framework: create_deep_agent, the built-in middleware, the harness, SKILL.md format and configuration options.

    1.3k GitHub starsUsed in 1 repo~3.1k tokens
    AI & LLM EngineeringAuto-check passed
  • Langgraph

    langchain-ai/docs

    Official

    Build stateful, durable agent workflows with LangGraph. An agent skill from langchain-ai/docs.

    424 GitHub stars~1.1k tokensUpdated today
    AI & LLM EngineeringAuto-check passed
  • Trigger.dev Agent Patterns

    papermark/papermark

    Patterns for building LLM agents on Trigger.dev tasks: prompt chaining, routing, parallel workers, orchestrator-workers, evaluator loops and human approval gates.

    9.2k GitHub stars~2k tokensUpdated 1 mo ago
    AI & LLM EngineeringAuto-check passed

More from github/awesome-copilot

All 417 skills in this repo
  • Acquire Codebase Knowledge

    github/awesome-copilot

    Official

    Maps an unfamiliar codebase into seven evidence-backed documents in docs/codebase/, using a scan script and templates, for onboarding or architecture write-ups.

    40k GitHub starsUsed in 1 repo~2.3k tokens
    Auto-check passed
  • Azure Architecture Autopilot

    github/awesome-copilot

    Official

    Designs Azure infrastructure from a natural-language description, or diagrams an existing resource group, then refines the design through conversation and deploys it with Bicep.

    40k GitHub starsUsed in 1 repo~1.9k tokens
    Auto-check passed
  • Draw.io Diagram Generator

    github/awesome-copilot

    Official

    Generates, edits and validates draw.io files with correct mxGraph XML, covering flowcharts, architecture, sequence, ER and UML class diagrams.

    40k GitHub starsUsed in 1 repo~4.9k tokens
    Auto-check passed
  • Credit Risk Data Cleaning

    github/awesome-copilot

    Official

    Cleans raw credit data and screens variables before loan modeling, dropping unstable, noisy or redundant features and writing an Excel report of every step.

    40k GitHub starsUsed in 1 repo~1.5k tokens
    Auto-check passed
  • Daily Focus Board

    github/awesome-copilot

    Official

    Builds a warm, browser-based daily focus board the user updates by talking to their agent, with Eisenhower priorities, a brain-dump box and kind not-today carryover.

    40k GitHub stars~3k tokensUpdated today
    Auto-check passed
  • Python Pypi Package Builder

    github/awesome-copilot

    Official

    End-to-end skill for building, testing, linting, versioning, and publishing a production-grade Python library to PyPI.

    40k GitHub starsUsed in 1 repo~4.6k tokens
    Auto-check passed

Questions about Foundry Hosted Agent Copilotkit

What does Foundry Hosted Agent Copilotkit do?

Ongoing development guidance for agentic web apps that pair a CopilotKit frontend with Microsoft Agent Framework agents on Azure AI Foundry hosted agents over the AG-UI protocol - add and gate agent…. Foundry Hosted Agent Copilotkit is an agent skill from github/awesome-copilot, published by the product's own GitHub organization.0 packages safely, and deploy hosted agent updates.

When should I use Foundry Hosted Agent Copilotkit?

Foundry Hosted Agent Copilotkit fits situations like: tasks that involve Human-in-the-loop approvals; tasks that involve Building AI agents.

How do I install Foundry Hosted Agent Copilotkit in Claude Code?

Run `npx skills add github/awesome-copilot --skill foundry-hosted-agent-copilotkit -a claude-code`. Or copy the skill folder (skills/foundry-hosted-agent-copilotkit in github/awesome-copilot) into .claude/skills/foundry-hosted-agent-copilotkit in your project. Claude Code loads it when a task matches its description.

How do I install Foundry Hosted Agent Copilotkit in Codex?

Run `npx skills add github/awesome-copilot --skill foundry-hosted-agent-copilotkit -a codex`. Or copy the skill folder (skills/foundry-hosted-agent-copilotkit in github/awesome-copilot) into .agents/skills/foundry-hosted-agent-copilotkit in your project. Codex loads it when a task matches its description.

Can I use Foundry Hosted Agent Copilotkit in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add github/awesome-copilot --skill foundry-hosted-agent-copilotkit -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/foundry-hosted-agent-copilotkit, .gemini/skills/foundry-hosted-agent-copilotkit, .github/skills/foundry-hosted-agent-copilotkit and .opencode/skills/foundry-hosted-agent-copilotkit in your project.

What does Foundry Hosted Agent Copilotkit need to run?

Going by SKILL.md and its folder, Foundry Hosted Agent Copilotkit needs the command-line tools its instructions call (curl). Our summary lists: Python 3.

Does Foundry Hosted Agent Copilotkit access the network?

SKILL.md contains no URLs. Its commands use curl, which can reach the network depending on how they are called. This is read from the text; nothing was executed.

Is Foundry Hosted Agent Copilotkit safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Foundry Hosted Agent Copilotkit use?

Foundry Hosted Agent Copilotkit is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Foundry Hosted Agent Copilotkit use?

About 2.3k tokens (SKILL.md is roughly 9.1k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full. Its references folder adds about 9.7k tokens, read only when the agent opens those files.

What are the alternatives to Foundry Hosted Agent Copilotkit?

Skills that share tags, products or a category with Foundry Hosted Agent Copilotkit: Langgraph (kid-sid/claude-spellbook, 189 stars), Azure AI Projects Python SDK (microsoft/skills, 3.1k stars), Langgraph Human In The Loop (langchain-ai/langchain-skills, 1.3k stars) and Deep Agents Core (langchain-ai/langchain-skills, 1.3k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Foundry Hosted Agent Copilotkit?

github (a GitHub organization, an official publisher) maintains it in github/awesome-copilot, which has 39,748 GitHub stars. The repository holds 417 skills in this directory. The repository was last updated on October 7, 2026.

Source: github/awesome-copilot on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.