FulltextSearchStoreConfig: {
    adapter: FullTextSearchAdapter;
    enrichEntitiesForIndex?: (
        typeName: string,
        entities: Record<string, unknown>[],
    ) => Promise<Record<string, unknown>[]>;
    enrichEntityForIndex?: (
        typeName: string,
        entity: Record<string, unknown>,
    ) => Promise<Record<string, unknown>>;
    existingIndexTypes?: string[];
    idCodec?: IndexIdCodec;
    idCodecForType?: (typeName: string) => IndexIdCodec | undefined;
    indexNameForType?: (typeName: string) => string;
    primaryFields: PrimaryFieldDeclaration;
    primaryStore: PrimaryStore<R>;
    schema: JSONSchema7;
    scopeToIndexField?: Record<string, string>;
    searchFacetSchema: SearchFacetSchema;
    storeId?: string;
}

Type Parameters

  • R extends SchemaRegistry = SchemaRegistry

Type declaration

  • adapter: FullTextSearchAdapter
  • OptionalenrichEntitiesForIndex?: (
        typeName: string,
        entities: Record<string, unknown>[],
    ) => Promise<Record<string, unknown>[]>

    Batch enricher for importMany (one call per listed chunk). When set, it replaces enrichEntityForIndex on that path; single imports and sync keep using enrichEntityForIndex.

  • OptionalenrichEntityForIndex?: (
        typeName: string,
        entity: Record<string, unknown>,
    ) => Promise<Record<string, unknown>>

    Optional enricher run before projecting an entity into an index document (e.g. merge materialized calc fields). Core stays calc-engine-free — callers / CLI supply the callback.

  • OptionalexistingIndexTypes?: string[]

    Type names whose indexes already exist — skip ensureIndex in prepareFulltextIndexes.

  • OptionalidCodec?: IndexIdCodec

    Global document id codec (default: base64url full IRI).

  • OptionalidCodecForType?: (typeName: string) => IndexIdCodec | undefined

    Per-type codec override (e.g. legacy hex ids for one index).

  • OptionalindexNameForType?: (typeName: string) => string
  • primaryFields: PrimaryFieldDeclaration
  • primaryStore: PrimaryStore<R>
  • schema: JSONSchema7
  • OptionalscopeToIndexField?: Record<string, string>
  • searchFacetSchema: SearchFacetSchema
  • OptionalstoreId?: string