Skip to content

Add a todo-harness agent example - #1166

Open
PratikDhanave (PratikDhanave) wants to merge 3 commits into
microsoft:mainfrom
PratikDhanaveFork:feat/example-todo-harness
Open

PratikDhanave (PratikDhanave) wants to merge 3 commits into
microsoft:mainfrom
PratikDhanaveFork:feat/example-todo-harness

Conversation

@PratikDhanave

Copy link
Copy Markdown
Contributor

Continuing the harness sample coverage (after the loop-harness example): Go supports the todo harness (agent/harness/todo) but examples/ has no sample for it, unlike the .NET Harness samples.

Change

  • New examples/02-agents/harness/step02_todo that attaches the todo context provider to a Foundry agent. The provider exposes todo tools and injects the current todo list each turn, so the agent plans a multi-step task (a three-course dinner) as todo items and completes them one by one (session-backed, so it runs inside a session).
  • Registered in cmd/verifyexamples (env-gated on FOUNDRY_PROJECT_ENDPOINT), skipping cleanly without credentials.

Builds, go vet, gofumpt clean; the verifyexamples test passes and the entry is discovered and skips without credentials.

Go supports the todo harness (agent/harness/todo) but has no sample for it.
Add an example that attaches the todo context provider to a Foundry agent so
the agent plans a multi-step task with todo items and completes them, and
register it with cmd/verifyexamples (env-gated on FOUNDRY_PROJECT_ENDPOINT).
Copilot AI lite review requested due to automatic review settings September 23, 2026 04:39
@github-actions github-actions Bot added area:examples Changes files in the examples area area:tooling Changes files in the tooling area size:medium At most 100 changed lines across at most 5 files labels Sep 23, 2026

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot review overview

🟢 Approval recommended

No unresolved review comments remain, and all reviewed changes are covered.

Review effort: Lite
Findings: None

What changed in this PR

Adds a Go example demonstrating the session-backed todo harness with a Foundry agent.

Changes:

  • Adds a three-course dinner planning example using todo tools.
  • Registers the example with environment-gated verification.
File Description
examples/​02-agents/​harness/​step02_todo/​main.go Demonstrates todo context-provider usage.
cmd/​verifyexamples/​examples.go Registers the sample for verification.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

@github-actions github-actions Bot added the kind:examples Changes examples or example-support metadata label Sep 23, 2026
@github-actions

This comment has been minimized.

@github-actions github-actions Bot added the parity-approved Go API consistency review found no parity issues label Sep 23, 2026
@qmuntal
Quim Muntal (qmuntal) added this pull request to the merge queue Sep 29, 2026
@github-merge-queue
github-merge-queue Bot removed this pull request from the merge queue due to a conflict with the base branch Sep 29, 2026
…arness

# Conflicts:
#	cmd/verifyexamples/examples.go
@github-actions

This comment has been minimized.

…arness

# Conflicts:
#	cmd/verifyexamples/examples.go
@github-actions

github-actions Bot commented Nov 4, 2026

Copy link
Copy Markdown
Contributor

API consistency review

Result Scope
aligned examples

Changed Go contract

New example examples/02-agents/harness/step02_todo, which attaches todo.New(nil) as a context provider to a Foundry agent. It also adds a matching cmd/verifyexamples entry. No exported API changes.

Upstream evidence reviewed

Implementation Source Contract checked
.NET dotnet/samples/02-agents/Harness Harness sample tree (Step01 to Step05). There is no standalone todo sample, but the sample organization and scenario intent match.

Assessment

The example only uses the existing todo harness. It follows the upstream Harness sample folder layout and adds no new public behavior, defaults, or opt-in gates. No parity issues found. parity-approved is already present, and public-api-change is not applicable.

I checked only the upstream .NET Harness sample listing. I did not check Python samples or the .NET todo provider implementation.

Generated by Go API Consistency Review Agent · copilot · auto · 15.9 AIC · ⌖ 0.613 AIC · ⊞ 5.1K · ◷

@qmuntal
Quim Muntal (qmuntal) added this pull request to the merge queue Nov 4, 2026
@github-merge-queue
github-merge-queue Bot removed this pull request from the merge queue due to a conflict with the base branch Nov 4, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area:examples Changes files in the examples area area:tooling Changes files in the tooling area kind:examples Changes examples or example-support metadata parity-approved Go API consistency review found no parity issues size:medium At most 100 changed lines across at most 5 files

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants