feat: pre-launch vs post-launch analysis modes

- Backend: mode field in request, adapts summary tone and email subject
- Pre-launch: "Implementieren Sie X vor Veroeffentlichung"
- Post-launch: "ACHTUNG: Maengel sind oeffentlich sichtbar, sofortige Nachbesserung"
- Frontend: Mode toggle (internes Dokument vs. Live-Website)

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
Benjamin Admin
2026-04-28 14:07:32 +02:00
parent cb5aa2949b
commit 1988274420
3 changed files with 80 additions and 11 deletions

View File

@@ -39,7 +39,7 @@ export function useAgentAnalysis() {
const [result, setResult] = useState<AnalysisResult | null>(null)
const [history, setHistory] = useState<AnalysisResult[]>([])
async function analyze(url: string) {
async function analyze(url: string, mode: string = 'post_launch') {
setLoading(true)
setError(null)
setResult(null)
@@ -48,7 +48,7 @@ export function useAgentAnalysis() {
const fetchRes = await fetch('/api/sdk/v1/agent/analyze', {
method: 'POST',
headers: { 'Content-Type': 'application/json' },
body: JSON.stringify({ url }),
body: JSON.stringify({ url, mode }),
})
if (!fetchRes.ok) {