org.llm4s.llmconnect.middleware.InputSanitizationMiddleware
Middleware that sanitizes and validates input prompts.
Can enforce max length limits and reject inputs containing forbidden patterns.
Attributes
-
Graph
-
-
Supertypes
-
class Object
trait Matchable
class Any
Members list
Human-readable name for logging/debugging.
Human-readable name for logging/debugging.
Attributes
-
Definition Classes
-
Wrap the given LLMClient, returning a new client with added behavior.
Wrap the given LLMClient, returning a new client with added behavior.
Implementations should delegate all LLMClient methods to next, adding behavior before/after delegation as needed.
Value parameters
-
next
-
the next client in the pipeline
Attributes
-
Returns
-
a new LLMClient with this middleware's behavior added
-
Definition Classes
-