Class OpenSearchSinkScaffold
java.lang.Object
ai.pipestream.module.pipelineprobe.moduletest.scaffold.OpenSearchSinkScaffold
- All Implemented Interfaces:
StepScaffold
opensearch-sink scaffold, e2e-faithful: provisions exactly what a pipeline
crawl provisions before the sink sees a doc —
- the full 2×2 vector-set registration (sentence-10-3 + sentences_internal
× minilm + paraphrase-minilm) via
EmbedderFixturesRegistrar, matching what the captured corpus docs actually carry; - an IndexPlan with a PINNED id and the caller-chosen
IndexingStrategy(NESTED / SEPARATE_INDICES / CHUNK_COMBINED — the same three the e2e exercises; default CHUNK_COMBINED, the e2e default), gated on READY like the crawl gates dispatch; - the semantic centroid configs assigned to the index, so the sink can write the document/section/paragraph centroid SPRs the corpus carries ("KNN field not provisioned at bind time" otherwise).
StreamMetadata.context_params — what
OpenSearchSinkOptionsParser reads.
The index name is unique per session so every run writes into a clean
index; cleanup() destroys the plan, all derived indices, and the
redis streams (with the background sweep for late bulk writes).
-
Constructor Summary
ConstructorsConstructorDescriptionOpenSearchSinkScaffold(OpenSearchTestSetupService setup, EmbedderFixturesRegistrar registrar, ai.pipestream.opensearch.v1.IndexingStrategy strategy) Creates the opensearch-sink scaffold, choosing a unique per-session index name so each run writes into a clean index. -
Method Summary
Modifier and TypeMethodDescriptionvoidcleanup()Destroy this session's plan, index (all strategy-derived indices incl.info()What the scaffold provisioned, for display/logging.module()The module/step this scaffold targets (e.g.voidprepare()Provision external state (vector sets, fresh index, …).ai.pipestream.data.v1.PipeStreamwrap(ai.pipestream.data.v1.PipeDoc doc) Turn a corpus doc into the step's expected input PipeStream (directives, context_params, …).Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface StepScaffold
corpusDoc, corpusName, corpusSize
-
Constructor Details
-
OpenSearchSinkScaffold
public OpenSearchSinkScaffold(OpenSearchTestSetupService setup, EmbedderFixturesRegistrar registrar, ai.pipestream.opensearch.v1.IndexingStrategy strategy) Creates the opensearch-sink scaffold, choosing a unique per-session index name so each run writes into a clean index.- Parameters:
setup- the OpenSearch test setup service used to provision the plan and indicesregistrar- the embedder fixtures registrar used to register vector sets and semantic configsstrategy- the indexing strategy to provision the index plan with
-
-
Method Details
-
module
Description copied from interface:StepScaffoldThe module/step this scaffold targets (e.g."chunker").- Specified by:
modulein interfaceStepScaffold- Returns:
- the module/step name this scaffold targets
-
prepare
public void prepare()Description copied from interface:StepScaffoldProvision external state (vector sets, fresh index, …). Called once per session.- Specified by:
preparein interfaceStepScaffold
-
wrap
public ai.pipestream.data.v1.PipeStream wrap(ai.pipestream.data.v1.PipeDoc doc) Description copied from interface:StepScaffoldTurn a corpus doc into the step's expected input PipeStream (directives, context_params, …).- Specified by:
wrapin interfaceStepScaffold- Parameters:
doc- the corpus document to wrap- Returns:
- the
PipeStreamshaped as the step expects
-
cleanup
public void cleanup()Destroy this session's plan, index (all strategy-derived indices incl. centroid side-indices via the prefix sweep), vector-set bindings, and redis streams. The shared recipes survive for the next run.- Specified by:
cleanupin interfaceStepScaffold
-
info
Description copied from interface:StepScaffoldWhat the scaffold provisioned, for display/logging.- Specified by:
infoin interfaceStepScaffold- Returns:
- a map describing what the scaffold provisioned; empty by default
-