Query Modes

The canonical public modes are:

Mode

Purpose

Notes

rag

Grounded document question answering

Default online path

llm_only

Ungrounded generation

No document sources

summarize

Targeted act summary

Requires celex

compare

Act-to-act comparison

Requires celex and compare_celex

Legacy modes such as hybrid, semantic, lexical, graph, search, and qa are normalized to canonical modes for compatibility.

Note

The raw search modes semantic, lexical, and hybrid remain public on the /search endpoint. They are not separate canonical modes on /query.

Runtime decisions

The service can terminate with different response states:

        stateDiagram-v2
    [*] --> grounded
    [*] --> weakly_grounded
    [*] --> clarify
    [*] --> hard_block
    [*] --> llm_only
    

Outcome

Meaning

grounded

Evidence and citations are strong enough for a normal answer.

weakly_grounded

Evidence is partial or repaired, but still usable.

clarify

The question needs narrowing before a grounded answer is possible.

hard_block

The request is anchored to legal facts but the system has no evidence.

llm_only

The runtime intentionally bypasses retrieval for conversational requests.

Source anchors

  • Mode alias resolution: packages/lalandre_core/lalandre_core/utils/mode_aliases.py

  • Shared request and response models: packages/lalandre_rag/lalandre_rag/models/api.py

  • High-level orchestration: packages/lalandre_rag/lalandre_rag/service.py