chore: refactor retrieval pipeline to chunk-first RRF with derived entities and slimmer eval surface.

Collapse the multi-strategy entity engine into one benchmarked chunk retrieval path, derive entities from retrieved chunks, and update consumers, docs, and clippy fixes across the workspace.
This commit is contained in:
Per Stark
2026-05-30 22:19:08 +02:00
parent c70141de35
commit 5c2d2e24d3
38 changed files with 1049 additions and 2614 deletions
+1
View File
@@ -95,6 +95,7 @@ pub(crate) async fn init_with_config(config: AppConfig) -> anyhow::Result<Shared
}
#[cfg(test)]
#[allow(dead_code)] // helpers are shared across binary test targets
pub(crate) mod tests {
use std::path::Path;
+4 -1
View File
@@ -11,8 +11,9 @@ use html_router::{
use super::SharedServices;
/// Builds the Minne API and HTML route subtrees without fixing the outer Axum state
/// type. SaaS consumers can merge additional routers and attach their own `AppState`
/// type. `SaaS` consumers can merge additional routers and attach their own `AppState`
/// as long as it implements `FromRef` for `ApiState` and `HtmlState`.
#[allow(dead_code)] // used by server/main binaries, not worker
pub fn minne_routes<S>(api_state: &ApiState, html_state: &HtmlState) -> Router<S>
where
S: Clone + Send + Sync + 'static,
@@ -24,6 +25,7 @@ where
.merge(html_routes(html_state))
}
#[allow(dead_code)] // used by server/main binaries, not worker
pub fn build_api_state(services: &SharedServices) -> ApiState {
ApiState {
db: Arc::clone(&services.db),
@@ -32,6 +34,7 @@ pub fn build_api_state(services: &SharedServices) -> ApiState {
}
}
#[allow(dead_code)] // used by server/main binaries, not worker
pub async fn build_html_state(services: &SharedServices) -> anyhow::Result<HtmlState> {
let session_store = Arc::new(
services
+1
View File
@@ -75,6 +75,7 @@ struct AppState {
}
#[cfg(test)]
#[allow(clippy::expect_used)]
mod tests {
use super::*;
use axum::{