Add Korrespond tool: drafts replies & new correspondence to NO authorities
Two-pass wizard for drafting to NAV, Barnevernet, schools, Bufdir, kommune, Statsforvalter, Trygderetten. Pass 1 (gpt-4o-mini) classifies the situation and emits clarify questions if facts are missing; user answers inline and resubmits without losing context. Pass 2 retrieves law passages via hard-RAG (ClientRagPipeline with body-specific slice presets), drafts in Norwegian bokmål with gpt-4o using [CITE:N] tokens, self-checks that every citation maps to a real corpus passage, then translates to the working language. Result is side-by-side Norwegian + EN/PL/UK with copy/download per side and an expandable Cited Law panel. Credit deducts only when Pass 2 actually runs, not on a clarify cycle. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
@@ -6996,3 +6996,143 @@ body.lt-landing {
|
||||
.dr-brief { line-height:1.75; }
|
||||
summary { display:none; }
|
||||
}
|
||||
|
||||
/* ── Korrespond ──────────────────────────────────────────────────────────── */
|
||||
.korr-goal-chips {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
gap: 6px;
|
||||
margin: 6px 0 14px;
|
||||
}
|
||||
.korr-chip {
|
||||
background: rgba(15, 118, 110, 0.08);
|
||||
border: 1px solid rgba(15, 118, 110, 0.25);
|
||||
color: var(--ink, #1b2330);
|
||||
border-radius: 999px;
|
||||
padding: 4px 12px;
|
||||
font-size: 0.82rem;
|
||||
cursor: pointer;
|
||||
transition: background 0.12s ease, border-color 0.12s ease;
|
||||
}
|
||||
.korr-chip:hover { background: rgba(15, 118, 110, 0.16); }
|
||||
.korr-chip.is-active {
|
||||
background: var(--dbn-blue, #00205b);
|
||||
color: #fff;
|
||||
border-color: var(--dbn-blue, #00205b);
|
||||
}
|
||||
|
||||
.korr-clarify-panel {
|
||||
background: rgba(183, 121, 31, 0.08);
|
||||
border: 1px solid rgba(183, 121, 31, 0.35);
|
||||
border-radius: 10px;
|
||||
padding: 18px 20px;
|
||||
margin: 18px 0;
|
||||
}
|
||||
.korr-clarify-panel h3 {
|
||||
margin: 0 0 6px;
|
||||
font-size: 1.05rem;
|
||||
color: var(--ink, #1b2330);
|
||||
}
|
||||
.korr-clarify-list {
|
||||
display: grid;
|
||||
gap: 10px;
|
||||
margin: 14px 0;
|
||||
}
|
||||
.korr-clarify-item { display: grid; gap: 4px; }
|
||||
.korr-clarify-item label { font-size: 0.9rem; }
|
||||
.korr-clarify-item input {
|
||||
padding: 8px 10px;
|
||||
border: 1px solid rgba(0, 0, 0, 0.18);
|
||||
border-radius: 6px;
|
||||
font: inherit;
|
||||
background: #fff;
|
||||
}
|
||||
.korr-clarify-actions { display: flex; gap: 10px; }
|
||||
|
||||
.korr-result-head {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
flex-wrap: wrap;
|
||||
gap: 10px;
|
||||
margin-bottom: 14px;
|
||||
}
|
||||
.korr-flags { display: flex; flex-wrap: wrap; gap: 6px; }
|
||||
.korr-flag {
|
||||
font-size: 0.78rem;
|
||||
padding: 3px 9px;
|
||||
border-radius: 999px;
|
||||
border: 1px solid currentColor;
|
||||
font-weight: 500;
|
||||
}
|
||||
.korr-flag.is-ok { color: #0f766e; background: rgba(15, 118, 110, 0.08); }
|
||||
.korr-flag.is-warn { color: #b7791f; background: rgba(183, 121, 31, 0.10); }
|
||||
.korr-flag.is-error { color: #ba0c2f; background: rgba(186, 12, 47, 0.08); }
|
||||
|
||||
.korr-drafts {
|
||||
display: grid;
|
||||
grid-template-columns: 1fr 1fr;
|
||||
gap: 16px;
|
||||
}
|
||||
.korr-drafts.is-single { grid-template-columns: 1fr; }
|
||||
@media (max-width: 1100px) {
|
||||
.korr-drafts { grid-template-columns: 1fr; }
|
||||
}
|
||||
.korr-draft-col {
|
||||
background: #fff;
|
||||
border: 1px solid rgba(0, 0, 0, 0.10);
|
||||
border-radius: 10px;
|
||||
padding: 14px 16px;
|
||||
}
|
||||
.korr-draft-head {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
gap: 10px;
|
||||
margin-bottom: 10px;
|
||||
border-bottom: 1px solid rgba(0, 0, 0, 0.08);
|
||||
padding-bottom: 8px;
|
||||
}
|
||||
.korr-draft-head h3 {
|
||||
margin: 0;
|
||||
font-size: 0.92rem;
|
||||
color: var(--dbn-blue, #00205b);
|
||||
}
|
||||
.korr-draft-actions { display: flex; gap: 6px; }
|
||||
.korr-draft-body {
|
||||
margin: 0;
|
||||
font-family: 'IBM Plex Mono', 'Menlo', 'Consolas', monospace;
|
||||
font-size: 0.82rem;
|
||||
line-height: 1.55;
|
||||
white-space: pre-wrap;
|
||||
word-break: break-word;
|
||||
color: var(--ink, #1b2330);
|
||||
max-height: 600px;
|
||||
overflow-y: auto;
|
||||
}
|
||||
|
||||
.korr-cited {
|
||||
margin-top: 18px;
|
||||
background: #fff;
|
||||
border: 1px solid rgba(0, 0, 0, 0.10);
|
||||
border-radius: 10px;
|
||||
padding: 12px 16px;
|
||||
}
|
||||
.korr-cited summary {
|
||||
cursor: pointer;
|
||||
font-size: 0.9rem;
|
||||
color: var(--dbn-blue, #00205b);
|
||||
}
|
||||
.korr-cited-list { display: grid; gap: 12px; margin-top: 10px; }
|
||||
.korr-cited-item {
|
||||
border-left: 3px solid var(--dbn-blue, #00205b);
|
||||
padding: 6px 12px;
|
||||
background: rgba(0, 32, 91, 0.03);
|
||||
}
|
||||
.korr-cited-head { font-size: 0.88rem; margin-bottom: 4px; }
|
||||
.korr-cited-excerpt { font-size: 0.83rem; line-height: 1.5; margin: 0 0 4px; color: rgba(0, 0, 0, 0.75); }
|
||||
.korr-cited-item a { font-size: 0.78rem; color: var(--dbn-blue, #00205b); }
|
||||
|
||||
/* Required hint */
|
||||
.required-hint { color: var(--dbn-red, #ba0c2f); font-size: 0.78rem; font-weight: 500; }
|
||||
|
||||
|
||||
Reference in New Issue
Block a user