feat(generation): persist summary outcomes without articles

Record generation outcomes and summaries for history while keeping article content transient.

Refs #7

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
2026-11-20 21:20:35 +01:00
parent 9970b49746
commit 768c0fd7f5
26 changed files with 1657 additions and 438 deletions

View File

@ -4,19 +4,21 @@ import (
"github.com/tradarr/backend/internal/ai"
"github.com/tradarr/backend/internal/config"
"github.com/tradarr/backend/internal/crypto"
"github.com/tradarr/backend/internal/generation"
"github.com/tradarr/backend/internal/models"
"github.com/tradarr/backend/internal/scheduler"
"github.com/tradarr/backend/internal/scraper"
)
type Handler struct {
repo *models.Repository
cfg *config.Config
enc *crypto.Encryptor
registry *scraper.Registry
pipeline *ai.Pipeline
scheduler *scheduler.Scheduler
reportManager *ai.ReportManager
generationUseCase generation.UseCase
repo *models.Repository
cfg *config.Config
enc *crypto.Encryptor
registry *scraper.Registry
pipeline *ai.Pipeline
scheduler *scheduler.Scheduler
reportManager *ai.ReportManager
}
func New(
@ -37,3 +39,5 @@ func New(
reportManager: ai.NewReportManager(),
}
}
func (h *Handler) SetGenerationUseCase(uc generation.UseCase) { h.generationUseCase = uc }