- Introduced `battery_report.json` for local data analysis, excluding it from the database. - Enhanced `AGENTS.md` to reflect updated test baseline with 795 passed tests. - Added new metrics for trade flow in `dict_service.py`, improving transaction data analysis. - Updated regex patterns in `guardrail.py` to better handle numeric extraction and prevent misinterpretation of tokens. - Expanded course modules with new content on FR-8/9/10 capabilities and L3 role management. - Improved concurrency handling in transaction processing to ensure accurate alert generation. This update enhances data analysis capabilities and improves the overall structure and clarity of course materials.
140 lines
7.4 KiB
HTML
140 lines
7.4 KiB
HTML
<section class="module" id="module-6">
|
||
<div class="module-inner">
|
||
<p class="eyebrow animate-in">模块 6 · L3 与角色</p>
|
||
<h1 class="module-title animate-in">监测档怎么写<br>谁能看谁能处置</h1>
|
||
<p class="module-lead animate-in">
|
||
L3 监测画像写入服务(<code>profile_l3.py</code>)把 AML 命中、规则结果写入 <code>customer_profile_l3</code>(<strong>防降级合并</strong>)。
|
||
模块鉴权工厂(<code>deps.py</code>)按 JWT 角色决定台账 REST 与对话 Tool 能看到什么——接前端或新 Tool 前先对这张矩阵。
|
||
</p>
|
||
|
||
<div class="screen animate-in">
|
||
<h2>L3 监测档 · 谁写、谁读</h2>
|
||
<div class="step-cards">
|
||
<div class="step-card">
|
||
<span class="step-num">①</span>
|
||
<p><strong>写入</strong> · AML 扫描服务(<code>aml_service.py</code>)命中 → 写 L3 <code>monitor_tier=high</code> + 预警出单(R-03 通知不冻户)</p>
|
||
</div>
|
||
<div class="step-card">
|
||
<span class="step-num">②</span>
|
||
<p><strong>合并</strong> · 只升不降(normal < watch < high);禁止 Agent 把 high 改回 normal</p>
|
||
</div>
|
||
<div class="step-card">
|
||
<span class="step-num">③</span>
|
||
<p><strong>读取</strong> · <code>customer_context</code> Tool:Core L0 + L3 + 待审预警摘要(只读,供风控 Chat 解读)</p>
|
||
</div>
|
||
</div>
|
||
<div class="callout callout-accent">
|
||
<strong>铁律:</strong> L3 是 enrich 监测标签,<strong>不覆盖</strong> Core 正式 C1~C5 风评;审计表只 INSERT。
|
||
</div>
|
||
</div>
|
||
|
||
<div class="screen animate-in">
|
||
<h2>角色矩阵(REST + 对话数据面)</h2>
|
||
<div class="pattern-cards">
|
||
<div class="pattern-card">
|
||
<h3>risk_officer</h3>
|
||
<p>台账全量 · <code>POST .../handle</code> 处置 · AML scan · 模拟 risk_demo · 行为链明细可见</p>
|
||
</div>
|
||
<div class="pattern-card">
|
||
<h3>risk_manager</h3>
|
||
<p>台账全量 · 一般不 handle(按矩阵)· 行为链明细可见</p>
|
||
</div>
|
||
<div class="pattern-card">
|
||
<h3>compliance</h3>
|
||
<p>台账强制 aml 域 · 无 simulate · 对话 Tool 仍只读</p>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
|
||
<div class="screen animate-in">
|
||
<h2>群聊:AML 命中后 L3 与台账</h2>
|
||
<div class="chat-window" id="chat-risk-m6">
|
||
<div class="chat-messages">
|
||
<div class="chat-message" data-msg="0" data-sender="scan" style="display:none">
|
||
<div class="chat-avatar" style="background:#D94F30">扫</div>
|
||
<div class="chat-bubble">
|
||
<span class="chat-sender" style="color:#D94F30">aml_service.scan</span>
|
||
<p>CUST-1002 展示名命中名单 → 独立 aml 预警单</p>
|
||
</div>
|
||
</div>
|
||
<div class="chat-message" data-msg="1" data-sender="l3" style="display:none">
|
||
<div class="chat-avatar" style="background:#E87A62">L3</div>
|
||
<div class="chat-bubble">
|
||
<span class="chat-sender" style="color:#E87A62">profile_l3.upsert</span>
|
||
<p>monitor_tier → high(若原档更低则抬升,不降级)</p>
|
||
</div>
|
||
</div>
|
||
<div class="chat-message" data-msg="2" data-sender="tool" style="display:none">
|
||
<div class="chat-avatar" style="background:#B83E24">Tool</div>
|
||
<div class="chat-bubble">
|
||
<span class="chat-sender" style="color:#B83E24">customer_context</span>
|
||
<p>风控 Chat 问客户档案 → 返回 L0 + L3 high + 待审预警数</p>
|
||
</div>
|
||
</div>
|
||
<div class="chat-message" data-msg="3" data-sender="officer" style="display:none">
|
||
<div class="chat-avatar" style="background:#D4A843">员</div>
|
||
<div class="chat-bubble">
|
||
<span class="chat-sender" style="color:#D4A843">risk_officer</span>
|
||
<p>台账 handle 处置 · <strong>不</strong>自动冻户 · 不改 Core 正式风评</p>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
<div class="chat-typing" id="chat-risk-m6-typing" style="display:none">
|
||
<div class="chat-avatar" id="chat-risk-m6-typing-avatar">…</div>
|
||
<div class="chat-typing-dots"><span class="typing-dot"></span><span class="typing-dot"></span><span class="typing-dot"></span></div>
|
||
</div>
|
||
<div class="chat-controls">
|
||
<button class="btn chat-next-btn">下一条</button>
|
||
<button class="btn chat-all-btn">全部播放</button>
|
||
<button class="btn chat-reset-btn">重播</button>
|
||
<span class="chat-progress"></span>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
|
||
<div class="screen animate-in">
|
||
<div class="translation-block">
|
||
<div class="translation-code">
|
||
<span class="translation-label">L3 防降级 · profile_l3.py 口径</span>
|
||
<pre><code><span class="code-line"><span class="code-comment"># monitor_tier: normal < watch < high</span></span>
|
||
<span class="code-line"><span class="code-comment"># 合并时取 max(tier),禁止写低档覆盖高档</span></span>
|
||
<span class="code-line"><span class="code-comment"># risk_score 一期 NULL,归评分模型首写</span></span></code></pre>
|
||
</div>
|
||
<div class="translation-english">
|
||
<span class="translation-label">白话</span>
|
||
<div class="translation-lines">
|
||
<p class="tl">指挥 AI 加「自动降档」= 违规;L3 只能抬监测强度或保持。</p>
|
||
<p class="tl">客户 Agent 不可读 L3 全文念给客户;只有风控/顾问 Tool 在 RBAC 内读。</p>
|
||
<p class="tl">处置预警用 REST handle,不是让 LLM 在对话里改库。</p>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
|
||
<div class="quiz-container" id="quiz-risk-m6">
|
||
<div class="quiz-question-block"
|
||
data-correct="option-c"
|
||
data-explanation-right="对。AML 命中写 L3 high + 出 aml 预警;不自动冻户、不改 Core C 等级。"
|
||
data-explanation-wrong="R-03 是通知与监测,不是自动冻户或改正式风评。">
|
||
<h3 class="quiz-question">AML 扫描命中 CUST-1002 后,系统会做什么?</h3>
|
||
<div class="quiz-options">
|
||
<button class="quiz-option" data-value="option-a" onclick="selectOption(this)">
|
||
<div class="quiz-option-radio"></div><span>自动冻结账户</span>
|
||
</button>
|
||
<button class="quiz-option" data-value="option-b" onclick="selectOption(this)">
|
||
<div class="quiz-option-radio"></div><span>把 Core 风评改成 C5</span>
|
||
</button>
|
||
<button class="quiz-option" data-value="option-c" onclick="selectOption(this)">
|
||
<div class="quiz-option-radio"></div><span>写 L3 high + aml 预警,待人审</span>
|
||
</button>
|
||
</div>
|
||
<div class="quiz-feedback"></div>
|
||
</div>
|
||
<button class="quiz-check-btn" onclick="checkQuiz('quiz-risk-m6')">检查答案</button>
|
||
<button class="quiz-reset-btn" onclick="resetQuiz('quiz-risk-m6')">重做</button>
|
||
</div>
|
||
|
||
<p class="module-footer-note">相关文件:L3 写入(<code>app/service/risk/profile_l3.py</code>)· AML(<code>aml_service.py</code>)· 模块鉴权(<code>app/api/deps.py</code>)· PRD <code>docs/PRD/PRD-风控监测Agent.md</code></p>
|
||
</div>
|
||
</div>
|
||
</section>
|