Why: I1 WP6 - eval needs per-turn command expectations to carry the SetSlot+Start acceptance case, and corpora must reproduce standalone in intentctl (the guard case has been red there since before I1 because the guard spec only existed as a test builtin). Evidence: go vet clean; go test ./... all ok; intentctl eval passes 11/11 on the v1 corpus (guard case fixed via self-declaration) and 1/1 on the new two-turn SetSlot+Start corpus. Impact: new intent/corpus.go (CorpusCase/CorpusTurn/CommandExpect, RunCorpusCase with chained expectations); intentctl eval consumes turns and corpus-declared builtin_specs and domains; report.generate spec and corpus_multiturn.json fixtures added. v1 corpus format and conformance unchanged. Refs: Documents proposal 2026-10-07-agent-stack-n1q1i1-plans.md I1 WP6
95 lines
2.1 KiB
JSON
95 lines
2.1 KiB
JSON
{
|
|
"cases": [
|
|
{
|
|
"name": "status_with_slot",
|
|
"input": "查询任务 42 的进度",
|
|
"expect_branch": "matched",
|
|
"expect_top": "demo.run.status_query",
|
|
"expect_slots": {
|
|
"run_id": "42"
|
|
}
|
|
},
|
|
{
|
|
"name": "status_term_only",
|
|
"input": "帮我看下进度",
|
|
"expect_branch": "matched",
|
|
"expect_top": "demo.run.status_query"
|
|
},
|
|
{
|
|
"name": "guard_config_query",
|
|
"input": "查询系统配置",
|
|
"expect_branch": "guard_hit",
|
|
"expect_top": "guard.config_change"
|
|
},
|
|
{
|
|
"name": "negated_write_readonly",
|
|
"input": "怎么配置查询进度",
|
|
"expect_branch": "fallback"
|
|
},
|
|
{
|
|
"name": "restart_task",
|
|
"input": "把任务重启一下",
|
|
"expect_branch": "matched",
|
|
"expect_top": "demo.run.restart"
|
|
},
|
|
{
|
|
"name": "greet_tiebreak_priority",
|
|
"input": "你好呀",
|
|
"expect_branch": "matched",
|
|
"expect_top": "demo.greet.hello"
|
|
},
|
|
{
|
|
"name": "cancel_missing_required_slot",
|
|
"input": "取消一下",
|
|
"expect_branch": "matched",
|
|
"expect_top": "demo.run.cancel",
|
|
"expect_missing_slots": [
|
|
"run_id"
|
|
]
|
|
},
|
|
{
|
|
"name": "case_fold_deploy",
|
|
"input": "please DEPLOY it",
|
|
"expect_branch": "matched",
|
|
"expect_top": "demo.misc.deploy"
|
|
},
|
|
{
|
|
"name": "casual_fallback",
|
|
"input": "今天天气不错",
|
|
"expect_branch": "fallback"
|
|
},
|
|
{
|
|
"name": "blank_fallback",
|
|
"input": " ",
|
|
"expect_branch": "fallback"
|
|
},
|
|
{
|
|
"name": "tie_ambiguous",
|
|
"input": "打结",
|
|
"expect_branch": "ambiguous"
|
|
}
|
|
],
|
|
"guard_domains": [
|
|
"guard"
|
|
],
|
|
"protected_domains": [
|
|
"guard"
|
|
],
|
|
"builtin_specs": [
|
|
{
|
|
"id": "guard.config_change",
|
|
"domain": "guard",
|
|
"version": 1,
|
|
"priority": 1000,
|
|
"matcher": {
|
|
"includes_any": [
|
|
"系统配置",
|
|
"网关",
|
|
"改密码"
|
|
]
|
|
},
|
|
"risk": "high",
|
|
"handler": "refuse.and_guide"
|
|
}
|
|
]
|
|
} |