235 lines
13 KiB
JSON
235 lines
13 KiB
JSON
{
|
||
"schema_version": "domain_scenario_pack_v1",
|
||
"pack_id": "active_counterparty_value_flow_boundary_20260615",
|
||
"domain": "agent_counterparty_value_flow_boundary",
|
||
"runtime_domain": "business_overview_counterparty_value_flow",
|
||
"title": "Counterparty value-flow and bank-role boundary",
|
||
"description": "Active slice for the autonomous agent loop: verify that company overview, explicit counterparty value-flow, selected counterparty follow-ups, and bank-role caveats stay separated in user-facing answers.",
|
||
"status": "active",
|
||
"source_of_truth_policy": {
|
||
"purpose": "single mutable domain source for the current orchestration target",
|
||
"switching_rule": "when the project switches to another domain, replace this file instead of rewriting the stable agent canon",
|
||
"stable_layers": [
|
||
"AGENTS.md",
|
||
".codex/skills/domain-case-loop",
|
||
".codex/agents/domain_analyst.toml",
|
||
".codex/agents/orchestrator.toml"
|
||
],
|
||
"mutable_layer": [
|
||
"docs/orchestration/active_domain_contract.json"
|
||
]
|
||
},
|
||
"analysis_context": {
|
||
"as_of_date": "2026-06-15",
|
||
"source": "agent_loop_next_domain_slice_after_margin_p12"
|
||
},
|
||
"target_score": 88,
|
||
"bindings": {
|
||
"main_organization": "ООО Альтернатива Плюс",
|
||
"control_year": "2020",
|
||
"svk_counterparty": "Группа СВК"
|
||
},
|
||
"issue_codes_under_test": [
|
||
"counterparty_value_flow_misrouted_to_company_profit",
|
||
"bank_counterparty_misclassified_as_business_partner",
|
||
"technical_garbage_in_answer",
|
||
"business_next_step_missing"
|
||
],
|
||
"detectors_under_test": [
|
||
"counterparty_value_flow_required_surface",
|
||
"counterparty_value_flow_profit_accounts_forbidden",
|
||
"bank_counterparty_boundary_required",
|
||
"runtime_tokens_in_user_answer",
|
||
"capability_ids_in_user_answer",
|
||
"limited_answer_without_next_action"
|
||
],
|
||
"agent_audit_expectations": {
|
||
"semantic_answer_review_first": true,
|
||
"direct_answer_first": true,
|
||
"business_utility_required": true,
|
||
"counterparty_scope_required": true,
|
||
"company_profit_boundary_required": true,
|
||
"bank_role_boundary_required": true,
|
||
"technical_garbage_forbidden": true,
|
||
"do_not_accept_if": [
|
||
"counterparty received/paid/net-flow question is answered as company profit",
|
||
"90/91/99 accounts are used as the direct answer for counterparty money flow",
|
||
"bank or financial counterparty is presented as an ordinary customer/supplier without role caveat",
|
||
"selected counterparty follow-up switches back to the organization",
|
||
"documents follow-up loses the active counterparty",
|
||
"final answer leaks route ids, capability ids, runtime enums, or debug payload"
|
||
]
|
||
},
|
||
"scenarios": [
|
||
{
|
||
"scenario_id": "company_business_overview_scope",
|
||
"title": "Company overview, money flow, and scope boundary",
|
||
"description": "Establish company-level context and verify that later counterparty questions do not inherit company-profit semantics.",
|
||
"steps": [
|
||
{
|
||
"step_id": "s01_business_overview_2020",
|
||
"title": "Direct business overview for the company and year",
|
||
"node_role": "root",
|
||
"question": "Дай взрослый бизнес-обзор {{bindings.main_organization}} за {{bindings.control_year}} год по данным 1С: обороты, входящие и исходящие деньги, нетто, НДС, долги, склад, клиенты, поставщики и что пока нельзя утверждать.",
|
||
"expected_intents": ["business_overview"],
|
||
"semantic_tags": ["business_overview", "money", "vat", "debt", "inventory", "scope_guard"],
|
||
"required_answer_shape": "direct_answer_first",
|
||
"required_answer_patterns_all": ["Альтернатива", "2020"],
|
||
"forbidden_answer_patterns": [
|
||
"(?i)capability_id",
|
||
"(?i)selected_chain_id",
|
||
"(?i)runtime_",
|
||
"(?i)business_overview_route_template_v1",
|
||
"(?i)mcp_discovery"
|
||
]
|
||
},
|
||
{
|
||
"step_id": "s02_money_followup",
|
||
"title": "Company money follow-up with counterparty highlights",
|
||
"question": "Раскрой деньги подробнее: сколько получили, сколько заплатили, какой чистый денежный поток, кто главный клиент и главный поставщик в {{bindings.control_year}}.",
|
||
"depends_on": ["s01_business_overview_2020"],
|
||
"semantic_tags": ["money", "counterparty", "scope_guard"],
|
||
"required_answer_shape": "direct_answer_first",
|
||
"required_answer_patterns_all": ["2020"],
|
||
"forbidden_answer_patterns": ["(?i)capability_id", "(?i)runtime_"]
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"scenario_id": "svk_counterparty_documents_scope",
|
||
"title": "Explicit SVK counterparty money and document scope",
|
||
"description": "Validate that an explicit counterparty request is not confused with company overview context and that document evidence is separated from business conclusions.",
|
||
"steps": [
|
||
{
|
||
"step_id": "s01_svk_money_documents",
|
||
"title": "Explicit counterparty money flow and evidence",
|
||
"node_role": "root",
|
||
"question": "Отдельно по контрагенту {{bindings.svk_counterparty}}, без опоры на прошлый диалог: сколько денег прошло, что входящее, что исходящее и есть ли документы или движения, на которых это основано?",
|
||
"expected_intents": ["value_flow"],
|
||
"semantic_tags": ["counterparty", "money", "documents", "scope_guard"],
|
||
"required_answer_shape": "direct_answer_first",
|
||
"required_answer_patterns_all": ["СВК"],
|
||
"forbidden_answer_patterns": [
|
||
"(?i)capability_id",
|
||
"(?i)selected_chain_id",
|
||
"(?i)runtime_",
|
||
"(?i)mcp_discovery",
|
||
"(?i)Альтернатива Плюс.*контрагент",
|
||
"(?i)(90[\\./](01|02|09)|91[\\./]|99\\b)"
|
||
]
|
||
},
|
||
{
|
||
"step_id": "s02_svk_documents_followup",
|
||
"title": "Counterparty documents follow-up",
|
||
"question": "Покажи документы по этой цепочке и не смешивай {{bindings.svk_counterparty}} с организацией {{bindings.main_organization}}.",
|
||
"depends_on": ["s01_svk_money_documents"],
|
||
"semantic_tags": ["counterparty", "documents", "scope_guard"],
|
||
"required_answer_shape": "direct_answer_first",
|
||
"required_answer_patterns_all": ["СВК"],
|
||
"forbidden_answer_patterns": [
|
||
"(?i)capability_id",
|
||
"(?i)runtime_",
|
||
"(?i)Альтернатива Плюс.*как контрагент"
|
||
]
|
||
},
|
||
{
|
||
"step_id": "s03_company_vs_svk_summary",
|
||
"title": "Separate company and counterparty conclusions",
|
||
"question": "Собери короткий итог: что мы подтвердили по компании, что отдельно по {{bindings.svk_counterparty}}, какие выводы можно делать и какие нельзя.",
|
||
"depends_on": ["s01_svk_money_documents", "s02_svk_documents_followup"],
|
||
"semantic_tags": ["business_overview", "counterparty", "scope_guard"],
|
||
"required_answer_shape": "direct_answer_first",
|
||
"required_answer_patterns_all": ["СВК", "компан"],
|
||
"forbidden_answer_patterns": ["(?i)capability_id", "(?i)runtime_"]
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"scenario_id": "company_business_overview_colloquial_scope",
|
||
"title": "Colloquial company overview and bank-role money follow-up",
|
||
"description": "Validate colloquial wording and the bank-role caveat when the user explicitly warns not to call a bank an ordinary customer.",
|
||
"steps": [
|
||
{
|
||
"step_id": "s01_colloquial_company_overview_2020",
|
||
"title": "Colloquial business overview for the company",
|
||
"node_role": "root",
|
||
"question": "По-человечески посмотри {{bindings.main_organization}} за {{bindings.control_year}}: что по бизнесу видно в 1С по деньгам, НДС, долгам, складу, клиентам/поставщикам и где пока нельзя делать вывод?",
|
||
"expected_intents": ["business_overview"],
|
||
"semantic_tags": ["business_overview", "colloquial", "money", "vat", "debt", "inventory", "scope_guard"],
|
||
"required_answer_shape": "direct_answer_first",
|
||
"required_answer_patterns_all": ["2020", "НДС"],
|
||
"forbidden_answer_patterns": ["(?i)capability_id", "(?i)selected_chain_id", "(?i)runtime_", "(?i)mcp_discovery"]
|
||
},
|
||
{
|
||
"step_id": "s02_colloquial_money_leaders",
|
||
"title": "Colloquial money leaders with bank-role boundary",
|
||
"question": "А по деньгам в этом же году кто больше всего занес и кому больше всего ушло? Банк не называй обычным клиентом без оговорки.",
|
||
"depends_on": ["s01_colloquial_company_overview_2020"],
|
||
"semantic_tags": ["money", "counterparty", "bank_role_boundary", "colloquial", "scope_guard"],
|
||
"required_answer_shape": "direct_answer_first",
|
||
"required_answer_patterns_all": ["2020"],
|
||
"forbidden_answer_patterns": ["(?i)capability_id", "(?i)runtime_"]
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"scenario_id": "svk_selected_object_followup_scope",
|
||
"title": "Selected-object style SVK counterparty follow-up",
|
||
"description": "Validate selected-object and pronoun coverage for the SVK counterparty edge: root counterparty money fact, documents by selected object, and separated summary.",
|
||
"steps": [
|
||
{
|
||
"step_id": "s01_select_svk_counterparty_money",
|
||
"title": "Select SVK as the active counterparty",
|
||
"node_role": "root",
|
||
"question": "Возьми как выбранного контрагента {{bindings.svk_counterparty}}: сколько по нему входящих денег, исходящих денег и расчетное нетто, на чем это основано?",
|
||
"expected_intents": ["value_flow"],
|
||
"semantic_tags": ["counterparty", "money", "selected_object", "scope_guard"],
|
||
"required_answer_shape": "direct_answer_first",
|
||
"required_answer_patterns_all": ["СВК"],
|
||
"forbidden_answer_patterns": [
|
||
"(?i)capability_id",
|
||
"(?i)selected_chain_id",
|
||
"(?i)runtime_",
|
||
"(?i)mcp_discovery",
|
||
"(?i)(90[\\./](01|02|09)|91[\\./]|99\\b)"
|
||
]
|
||
},
|
||
{
|
||
"step_id": "s02_pronoun_documents_for_selected_svk",
|
||
"title": "Documents for the selected counterparty by pronoun",
|
||
"question": "Теперь по нему покажи документы и не переключайся на организацию.",
|
||
"depends_on": ["s01_select_svk_counterparty_money"],
|
||
"semantic_tags": ["counterparty", "documents", "selected_object", "pronoun_followup", "scope_guard"],
|
||
"required_answer_shape": "direct_answer_first",
|
||
"required_answer_patterns_all": ["СВК"],
|
||
"forbidden_answer_patterns": [
|
||
"(?i)capability_id",
|
||
"(?i)runtime_",
|
||
"(?i)Альтернатива Плюс.*как контрагент"
|
||
]
|
||
},
|
||
{
|
||
"step_id": "s03_selected_svk_company_boundary_summary",
|
||
"title": "Boundary summary after selected-object document follow-up",
|
||
"question": "И коротко сравни: что у нас подтверждено по компании, что отдельно по выбранному контрагенту, и какие выводы нельзя делать?",
|
||
"depends_on": ["s01_select_svk_counterparty_money", "s02_pronoun_documents_for_selected_svk"],
|
||
"semantic_tags": ["business_overview", "counterparty", "selected_object", "scope_guard"],
|
||
"required_answer_shape": "direct_answer_first",
|
||
"required_answer_patterns_all": ["СВК", "компан"],
|
||
"forbidden_answer_patterns": ["(?i)capability_id", "(?i)runtime_"]
|
||
},
|
||
{
|
||
"step_id": "s04_org_clarification_boundary_summary",
|
||
"title": "Organization clarification after selected counterparty branch",
|
||
"question": "{{bindings.main_organization}}",
|
||
"depends_on": ["s03_selected_svk_company_boundary_summary"],
|
||
"semantic_tags": ["clarification", "organization", "scope_guard"],
|
||
"required_answer_shape": "direct_answer_first",
|
||
"required_answer_patterns_all": ["Альтернатива"],
|
||
"forbidden_answer_patterns": ["(?i)capability_id", "(?i)runtime_"]
|
||
}
|
||
]
|
||
}
|
||
]
|
||
}
|