feat: sync quick add ingestion updates

- simplify quick add source selection and fallback saving
- improve description context and manual edit behavior
- add extractor dimension filtering and edge explanation migration
This commit is contained in:
“BeeRad”
2026-03-19 21:15:30 +11:00
parent 64aaf10feb
commit 1f8f41b4e0
14 changed files with 558 additions and 140 deletions
+3 -3
View File
@@ -14,18 +14,18 @@ export async function POST(request: NextRequest) {
}
const normalizedMode: QuickAddMode | undefined =
mode === 'link' || mode === 'note' || mode === 'chat' ? mode : undefined;
mode === 'link' || mode === 'text' ? mode : undefined;
const normalizedDescription: string | undefined =
typeof description === 'string' && description.trim() ? description.trim() : undefined;
const delegation = await enqueueQuickAdd({
const result = await enqueueQuickAdd({
rawInput: input.trim(),
mode: normalizedMode,
description: normalizedDescription,
});
return NextResponse.json({ success: true, delegation });
return NextResponse.json({ success: true, result });
} catch (error) {
console.error('[Quick Add API] Error:', error);
const message = error instanceof Error ? error.message : 'Unknown error';