import { Context } from 'koishi'; import type { PresetSpeakerInput, PresetSpeakerRecord, UserProfileInput, UserProfileRecord } from '../../contracts/memory'; import type { UserProfileRepository } from '../../contracts/workflows'; import type { LivingMemoryTransact } from './types'; export declare class LivingMemoryUserProfileRepository implements UserProfileRepository { private readonly ctx; private readonly transact; constructor(ctx: Context, transact: LivingMemoryTransact); listPresetSpeakers(presetId: string): Promise; upsertPresetSpeaker(input: PresetSpeakerInput): Promise; /** * 铸键不变量的基座:为缺失的键补注册行,缺失才写,不触碰既有行的标签 * 与身份字段(标签更新归 reconcile)。行不带身份字段,画像候选过滤 * 天然排除;该用户下次直接对话时 reconcile 按 stableId 命中同一行, * 覆盖升级为完整身份。 */ registerMissingPresetSpeakers(presetId: string, speakers: Array<{ speakerKey: string; speakerLabel: string; }>): Promise; listUserProfilesByPreset(presetId: string): Promise; listUserProfilesBySpeakerKeys(presetId: string, speakerKeys: string[]): Promise; replaceUserProfile(presetId: string, profile: UserProfileInput): Promise; updateUserProfileContent(profileId: string, content: string): Promise; /** 记下画像已按这组记忆审阅且无需改写:只刷新输入与时刻,正文不动。 */ markUserProfileReviewed(profileId: string, sourceMemoryIds: string[]): Promise; deleteUserProfile(profileId: string): Promise; }