Package org.mockserver.llm.analysis
Class OptimisationSignals
java.lang.Object
org.mockserver.llm.analysis.OptimisationSignals
Deterministic optimisation-signal detectors over the assembled calls of an
LlmOptimisationReport. Pure: same calls in, same signals out — no
network, no LLM, no randomness.
Each detector emits at most one LlmOptimisationReport.Signal (per id) and gives the user's
downstream LLM a concrete lever: prompt caching, retrieval tools, replacing an
LLM-mediated step with a direct endpoint, trimming tool output, constraining
output, or removing duplicate retries. Thresholds are v1 constants (see §6 of
the contract — no new config beyond the max-calls bound applied upstream).
Cost figures defer to LlmPricing via the
already-computed per-call cost, scaled by the wasted-token fraction.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiondetect(List<LlmOptimisationReport.Call> calls) detect(List<LlmOptimisationReport.Call> calls, List<String> providers, long cachedInputTokens)
-
Constructor Details
-
OptimisationSignals
public OptimisationSignals()
-
-
Method Details
-
detect
-
detect
public List<LlmOptimisationReport.Signal> detect(List<LlmOptimisationReport.Call> calls, List<String> providers, long cachedInputTokens)
-