chore: import upstream snapshot with attribution
CodeQL / Analyze (csharp) (push) Waiting to run
CodeQL / Analyze (python) (push) Waiting to run
dotnet-build-and-test / dotnet-test-functions (push) Has been cancelled
dotnet-build-and-test / paths-filter (push) Has been cancelled
dotnet-build-and-test / dotnet-build (Debug, windows-latest, net9.0) (push) Has been cancelled
dotnet-build-and-test / dotnet-build (Release, ubuntu-latest, net10.0) (push) Has been cancelled
dotnet-build-and-test / dotnet-build (Release, ubuntu-latest, net8.0) (push) Has been cancelled
dotnet-build-and-test / dotnet-build (Release, windows-latest, net472) (push) Has been cancelled
dotnet-build-and-test / dotnet-test (Release, integration, true, ubuntu-latest, net10.0) (push) Has been cancelled
dotnet-build-and-test / dotnet-test (Release, integration, true, windows-latest, net472) (push) Has been cancelled
dotnet-build-and-test / dotnet-foundry-hosted-it (push) Has been cancelled
dotnet-build-and-test / dotnet-build-and-test-check (push) Has been cancelled
dotnet-build-and-test / Integration Test Report (push) Has been cancelled

This commit is contained in:
wehub-resource-sync
2026-07-13 13:39:25 +08:00
commit db620d33df
5151 changed files with 925932 additions and 0 deletions
@@ -0,0 +1,73 @@
# Declarative Workflows
Declarative workflows allow you to define multi-agent orchestration patterns in YAML, including:
- Variable manipulation and state management
- Control flow (loops, conditionals, branching)
- Agent invocations
- Human-in-the-loop patterns
See the [main workflows README](../README.md#declarative) for the list of available samples.
## Prerequisites
```bash
pip install agent-framework-declarative
```
## Running Samples
Each sample directory contains:
- `workflow.yaml` - The declarative workflow definition
- `main.py` - Python code to load and execute the workflow
- `README.md` - Sample-specific documentation
To run a sample:
```bash
cd <sample_directory>
python main.py
```
## Workflow Structure
A basic workflow YAML file looks like:
```yaml
name: my-workflow
description: A simple workflow example
actions:
- kind: SetValue
path: turn.greeting
value: Hello, World!
- kind: SendActivity
activity:
text: =turn.greeting
```
## Action Types
### Variable Actions
- `SetValue` - Set a variable in state
- `SetVariable` - Set a variable (.NET style naming)
- `ResetVariable` - Clear a variable
### Control Flow
- `If` - Conditional branching
- `ConditionGroup` - Multi-way branching
- `Foreach` - Iterate over collections
- `GotoAction` - Jump to labeled action
### Output
- `SendActivity` - Send text/attachments to user
### Agent Invocation
- `InvokeAzureAgent` - Call an Azure AI agent
### Tool Invocation
- `InvokeFunctionTool` - Call a registered Python function
### Human-in-Loop
- `Question` - Request user input
- `RequestExternalInput` - Request external data/approval