Skip to content

Commit d9c8cf3

Browse files
committed
fix(showcase): wire ms-agent-dotnet hitl suggestions + reconcile canonical e2e specs
Extracts the ms-agent-dotnet hitl demo's inline useConfigureSuggestions call into a dedicated suggestions.ts that mirrors langgraph-python's canonical hitl/suggestions.ts (identical pill titles and prompts), then wires the new useHitlSuggestions() hook into hitl/page.tsx in place of the inline block. This matches the gold-standard wiring shape the canonical D6 hitl assertions expect. Spec reconciliation: ms-agent-dotnet/tests/e2e/hitl.spec.ts and interrupt-headless.spec.ts are not present in langgraph-python's canonical suite, but both exercise MAF-specific behavior with no LGP equivalent (plain /demos/hitl reject branch using the Simple plan pill; MAF's frontend-tool adaptation of /demos/interrupt-headless). They are kept and expected to not count toward the 185 LGP-parity floor.
1 parent 47d3b59 commit d9c8cf3

2 files changed

Lines changed: 21 additions & 14 deletions

File tree

showcase/integrations/ms-agent-dotnet/src/app/demos/hitl/page.tsx

Lines changed: 2 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,9 @@ import {
55
CopilotKit,
66
CopilotChat,
77
useHumanInTheLoop,
8-
useConfigureSuggestions,
98
} from "@copilotkit/react-core/v2";
109
import { z } from "zod";
10+
import { useHitlSuggestions } from "./suggestions";
1111

1212
interface Step {
1313
description: string;
@@ -23,19 +23,7 @@ export default function HitlDemo() {
2323
}
2424

2525
function DemoContent() {
26-
useConfigureSuggestions({
27-
suggestions: [
28-
{
29-
title: "Simple plan",
30-
message: "Please plan a trip to mars in 5 steps.",
31-
},
32-
{
33-
title: "Complex plan",
34-
message: "Please plan a pasta dish in 10 steps.",
35-
},
36-
],
37-
available: "always",
38-
});
26+
useHitlSuggestions();
3927

4028
// NB: dropped the `useLangGraphInterrupt({...})` registration here because
4129
// MS Agent Framework has no `interrupt()` primitive — the agent only ever
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
"use client";
2+
3+
import { useConfigureSuggestions } from "@copilotkit/react-core/v2";
4+
5+
export function useHitlSuggestions() {
6+
useConfigureSuggestions({
7+
suggestions: [
8+
{
9+
title: "Simple plan",
10+
message: "Please plan a trip to mars in 5 steps.",
11+
},
12+
{
13+
title: "Complex plan",
14+
message: "Please plan a pasta dish in 10 steps.",
15+
},
16+
],
17+
available: "always",
18+
});
19+
}

0 commit comments

Comments
 (0)