Current section

Files

Jump to
xberg lib xberg summary_strategy.ex
Raw

lib/xberg/summary_strategy.ex

# This file is auto-generated by alef — DO NOT EDIT.
# alef:hash:b2c29ab80fb9cdb8c5190a7808ad862ad890f416ad887092447b282a5b1b69e0
# To regenerate: alef generate
# To verify freshness: alef verify --exit-code
defmodule Xberg.SummaryStrategy do
@moduledoc "Summarisation strategy."
@typedoc "Summarisation strategy."
@type t :: :extractive | :abstractive
@extractive :extractive
@abstractive :abstractive
@doc "Pure-Rust extractive summary (TextRank over the chunk graph). Deterministic, fast, no external service required."
@spec extractive() :: t()
def extractive, do: @extractive
@doc "Abstractive summary produced by liter-llm. Requires `liter-llm` feature and a configured `LlmConfig`. Token usage is captured in [`ExtractedDocument::llm_usage`](super::extraction::ExtractedDocument::llm_usage)."
@spec abstractive() :: t()
def abstractive, do: @abstractive
end