syntax = "proto3"; package ai_daemon; service AiDaemon { rpc Prompt(PromptRequest) returns (PromptResponse); rpc Chat(ChatRequest) returns (ChatResponse); rpc ChatHistory(ChatHistoryRequest) returns (ChatHistoryResponse); } message ChatMessage { int64 id = 1; string text = 10; bool is_user = 20; } message ChatResponse { int64 chat_id = 2; repeated ChatMessage messages = 10; } message ChatRequest { optional int64 chat_id = 1; optional string text = 10; } message ChatHistoryRequest { // If not set last chat is returned optional int64 chat_id = 1; } message ChatHistoryResponse { int64 chat_id = 1; repeated ChatMessage history = 10; } message PromptRequest { string prompt = 1; } message PromptResponse { string response = 1; }