Add patient personalization: profile saved once, reused every chat turn

This commit is contained in:
2026-08-25 11:55:13 +07:00
parent 501c226ecd
commit 1ddd878431
12 changed files with 548 additions and 6 deletions
+14
View File
@@ -23,3 +23,17 @@ export interface RegisterRequest {
username: string;
password: string;
}
/** Per-user clinical context, set once from the account profile page and
* reused across chat turns so a logged-in doctor isn't re-asked age/weight
* on every dosing question. All fields optional/nullable — an anonymous
* user or a logged-in user with no saved profile is entirely unaffected. */
export interface PatientProfile {
ageText: string | null;
weightKg: number | null;
renalFunction: string | null;
hepaticFunction: string | null;
knownAllergies: string | null;
}
export type PatientProfileUpdate = Partial<PatientProfile>;