541e9e1fb5
This Pull Request encapsulates all outstanding AI, Blazor InteractiveAuto lifecycle, pgvector, and Firefox authorization/session compatibility fixes. ### Key Accomplishments: 1. **Concurrent Request Deduplication (Option B):** Implemented a thread-safe active task registry in `KnowledgeService` that groups concurrent graph extraction queries for the same content, preventing duplicate AI calls completely. 2. **Resilience Strategy for Downstream Demands:** Extended the `ai-retry` resilience pipeline to automatically intercept and retry on temporary Google API `503 ServiceUnavailable` / `high demand` spikes. 3. **Interactive Graph Generation Guard (Option A):** Prevented server-side prerender-phase graph requests in the reader canvas component. 4. **Firefox Compatibility & Cookie Handler:** Implemented an authentication endpoint and hybrid hidden-form submission flow to solve login, registration, and logout redirections and cookies securely. 5. **Autoscrolling & Graph Exclusions:** Added concept-to-block smooth scrolling, active block badging, and filtered out markdown code blocks from being extracted as nodes. All unit tests compiled and passed 100% cleanly. --------- Co-authored-by: Marek Jasiński <jasins.marek@gmail.com> Reviewed-on: #44 Co-authored-by: Antigravity <antigravity@google.com> Co-committed-by: Antigravity <antigravity@google.com>
24 lines
961 B
C#
24 lines
961 B
C#
using NexusReader.Application.Abstractions.Messaging;
|
|
|
|
namespace NexusReader.Application.Commands.Library;
|
|
|
|
/// <summary>
|
|
/// Command to ingest a new ebook into the library.
|
|
/// </summary>
|
|
/// <param name="Title">The title of the book.</param>
|
|
/// <param name="AuthorName">The name of the author.</param>
|
|
/// <param name="CoverImage">The raw bytes of the cover image (optional).</param>
|
|
/// <param name="EpubData">The raw bytes of the EPUB file.</param>
|
|
/// <param name="Description">The description or summary of the book (optional).</param>
|
|
/// <param name="UserId">The ID of the user owning the book.</param>
|
|
/// <param name="TenantId">The tenant ID for multi-tenant isolation. Defaults to "global" for single-tenant or default usage.</param>
|
|
public record IngestEbookCommand(
|
|
string Title,
|
|
string AuthorName,
|
|
byte[]? CoverImage,
|
|
byte[] EpubData,
|
|
string? Description,
|
|
string UserId,
|
|
string TenantId = "global"
|
|
) : ICommand<Guid>;
|