Skip to content

armgit / xerj

Public Imported from GitHub
0

AI search engine and MCP server for bots and agents. One Rust binary indexes code, docs, logs, JSONL/CSV and PDFs for BM25 full-text, vector and hybrid search, code search without grep, agent memory and RAG. Elasticsearch-compatible API; Corpus Hub serves hundreds of reference memory corpora.

polish(rustdoc): ManagedSchema::add_field does not call is_compatible_with (#1570)

xerj-orgd296e069c430
diff --git a/engine/crates/xerj-common/src/schema.rs b/engine/crates/xerj-common/src/schema.rs
index 91b5c0ce3..5e0dc1cd5 100644
--- a/engine/crates/xerj-common/src/schema.rs
+++ b/engine/crates/xerj-common/src/schema.rs
@@ -102,8 +102,9 @@ impl ManagedSchema {
///
/// Fails if:
/// - A field with the same name already exists.
- /// - The field type is incompatible with an existing field (checked via
- /// [`is_compatible_with`]).
+ /// - The field config is invalid (checked by [`validate_field_config`]:
+ /// empty, padded or `_`-prefixed name, missing or zero vector
+ /// `dimensions`, non-positive boost, an indexed `binary` field).
pub fn add_field(&mut self, field: FieldConfig) -> Result<(), XerjError> {
validate_field_config(&field)?;
self.schema.add_field(field)