proposit-core
    Preparing search index...

    Function createConclusionSelectionStage

    • Build the conclusion-selection stage with optional caller overrides. The inner llmStage asks the model for a confidence-ranked conclusionCandidates list (best first). The wrapper resolves a single conclusionMiniId: the first candidate that is a known normal claim, else a deterministic relation-graph fallback (selectFallbackConclusion), else null — in which case it emits a NO_SINGLE_CONCLUSION ProcessingFailure (severity warning) that drives finalize's { argument: null, failureText: "No single conclusion could be selected." }. The resolved id flows downstream to formula-compilation; the model's raw ranked list is preserved on the output for consumers that want to offer alternates.

      Parameters

      Returns TStage<
          {
              conclusionCandidates: string[];
              conclusionMiniId: string
              | null;
              rationale: string;
          },
      >