Private AI meeting notes that stay on your computer. No meeting bot. Free and open source for Mac, Windows and Linux. An alternative to Granola, Otter and Fireflies.
TypeScript ai-meeting-assistantai-notetakerelectrongranola-alternativelinuxllama-cpplocal-ailocal-firstmacosmcpmeeting-minutesmeeting-notesoffline-firstopen-sourceprivacyspeech-to-texttranscriptionwhisperwhisper-cppwindows
People: a properly cased full name now wins over the name guessed from the email address (#122)
Arda Zeybekeef7e250b1d2
diff --git a/app/src/shared/people.ts b/app/src/shared/people.tsindex d25da2ea..ebf2bd95 100644--- a/app/src/shared/people.ts+++ b/app/src/shared/people.ts@@ -13,10 +13,12 @@ export function emailName(email: string): string {const local = email.split('@')[0], name = local.replace(/[._-]+/g, ' ').trim() || localreturn name.charAt(0).toUpperCase() + name.slice(1)}+// A seen name only echoes the address when it matches the fallback and has no real capitalization of its own.+const echoesEmail = (n: string, fallback: string) => n.toLowerCase() === fallback.toLowerCase() && (n === fallback || n === n.toLowerCase() || n === n.toUpperCase())export function resolvedPersonName(email: string, display: string | null, seen: string[]): string {if (display) return displayconst fallback = emailName(email)- const names = seen.filter(n => n.trim() && !n.includes('@') && n.toLowerCase() !== fallback.toLowerCase())+ const names = seen.filter(n => n.trim() && !n.includes('@') && !echoesEmail(n, fallback))// Prefer full names, then a longer name; ties keep the first observation.names.sort((a, b) => b.trim().split(/\s+/).length - a.trim().split(/\s+/).length || b.length - a.length)return names[0] || fallbackdiff --git a/app/test/peopleRecords.test.ts b/app/test/peopleRecords.test.tsindex 7dc37620..a7ef89b5 100644--- a/app/test/peopleRecords.test.ts+++ b/app/test/peopleRecords.test.ts@@ -12,6 +12,9 @@ it('resolves an override, best observed name, then a capitalized local part', ()expect(resolvedPersonName('[email protected]', null, ['jamie', 'Jamie Quill', 'Jamie'])).toBe('Jamie Quill')expect(resolvedPersonName('[email protected]', null, ['jamie'])).toBe('Jamie')expect(resolvedPersonName('[email protected]', null, [])).toBe('Maya chen')+ expect(resolvedPersonName('[email protected]', null, ['John', 'John Doe'])).toBe('John Doe')+ expect(resolvedPersonName('[email protected]', null, ['John Doe'])).toBe('John Doe')+ expect(resolvedPersonName('[email protected]', null, ['john doe', 'John doe'])).toBe('John doe')})it('backfills idempotently and propagates a rename across meetings and exports without changing membership', () => {const s = fresh(), a = create(s), b = create(s, '[email protected]')