Belge Şablonları uploads now also get extracted_text (same OCR/office pipeline as documents), and a new POST /api/drafting/generate builds a real AI draft from the case's actual data (title, UYAP parties, latest Dosya Özeti) — if the lawyer picks one of their own templates, its extracted text is passed as a style/format reference only (the prompt explicitly forbids copying the template's old case facts). Dilekçe Hazırlama no longer fakes a draft with setTimeout. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
10 lines
257 B
TypeScript
10 lines
257 B
TypeScript
import { Router } from 'express';
|
|
import { requireAuth } from '../middleware/auth';
|
|
import { generateDraft } from '../controllers/drafting.controller';
|
|
|
|
const router = Router();
|
|
|
|
router.post('/generate', requireAuth, generateDraft);
|
|
|
|
export default router;
|