- Add Journal.AI project with LLamaSharp-based AI service (Phi-3 model) - Implement coach sessions (daily check-in, evening review, weekly review) - Add conversation CRUD with SQLCipher persistence - AI chat with full conversation history for context-aware replies - Frontend: CoachPanel, AI stores, conversation stores, side panel UI - Conversation list with create, rename, and delete support - Fix Phi-3 output quality (system prompt leaking, token cleanup, JSON filtering) - Fix CREATEDRAFT kind override in coach sessions Co-Authored-By: Oz <oz-agent@warp.dev>
14 lines
766 B
C#
14 lines
766 B
C#
using Journal.Core.Dtos;
|
|
|
|
namespace Journal.Core.Services.Ai;
|
|
|
|
public interface IAiService
|
|
{
|
|
Task<AiHealthDto> HealthAsync(CancellationToken cancellationToken = default);
|
|
Task<string> SummarizeEntryAsync(string content, string? fileStem = null, CancellationToken cancellationToken = default);
|
|
Task<string> SummarizeAllAsync(IReadOnlyList<string> entries, CancellationToken cancellationToken = default);
|
|
Task<string> ChatAsync(string prompt, CancellationToken cancellationToken = default);
|
|
Task<string> ChatWithHistoryAsync(IReadOnlyList<(string Role, string Text)> history, string prompt, CancellationToken cancellationToken = default);
|
|
Task<IReadOnlyList<double>> EmbedAsync(string content, CancellationToken cancellationToken = default);
|
|
}
|