mirror of
https://github.com/AeThex-Corporation/AeThex-OS.git
synced 2026-04-18 14:27:20 +00:00
Add chat memory and leadership profile retrieval to AI assistant
Introduces ChatMessage type, leadership profile retrieval, and chat history management functions to the storage layer. Replit-Commit-Author: Agent Replit-Commit-Session-Id: 279f1558-c0e3-40e4-8217-be7e9f4c6eca Replit-Commit-Checkpoint-Type: full_checkpoint Replit-Commit-Event-Id: b1b3a853-f2e8-4864-ab40-f66d6dfffce9 Replit-Commit-Screenshot-Url: https://storage.googleapis.com/screenshot-production-us-central1/b984cb14-1d19-4944-922b-bc79e821ed35/279f1558-c0e3-40e4-8217-be7e9f4c6eca/MQQU9It Replit-Helium-Checkpoint-Created: true
This commit is contained in:
parent
13c99f97f0
commit
fb249c2343
1 changed files with 7 additions and 1 deletions
|
|
@ -1,4 +1,4 @@
|
|||
import { type Profile, type Project } from "@shared/schema";
|
||||
import { type Profile, type Project, type ChatMessage } from "@shared/schema";
|
||||
import { supabase } from "./supabase";
|
||||
|
||||
export interface IStorage {
|
||||
|
|
@ -7,6 +7,7 @@ export interface IStorage {
|
|||
getProfile(id: string): Promise<Profile | undefined>;
|
||||
getProfileByUsername(username: string): Promise<Profile | undefined>;
|
||||
updateProfile(id: string, data: Partial<Profile>): Promise<Profile | undefined>;
|
||||
getLeadershipProfiles(): Promise<Profile[]>;
|
||||
|
||||
// Projects
|
||||
getProjects(): Promise<Project[]>;
|
||||
|
|
@ -29,6 +30,11 @@ export interface IStorage {
|
|||
getAlerts(): Promise<any[]>;
|
||||
updateAlert(id: string, updates: any): Promise<any>;
|
||||
|
||||
// Chat Messages (AI memory)
|
||||
getChatHistory(userId: string, limit?: number): Promise<ChatMessage[]>;
|
||||
saveChatMessage(id: string, userId: string, role: string, content: string): Promise<void>;
|
||||
clearChatHistory(userId: string): Promise<void>;
|
||||
|
||||
// Metrics
|
||||
getMetrics(): Promise<{
|
||||
totalProfiles: number;
|
||||
|
|
|
|||
Loading…
Reference in a new issue