Configuration Reference
On this page
Every configurable option in the library, in one place. All of these are plain Python constructor/keyword arguments — there is no config-file loader, environment-variable reader, or CLI flag parser anywhere in the source.
PromptEngine(...)
See api/prompt_engine.
PromptEngine.build(...) / PromptRequest
[!WARNING]
max_answer_tokensis not enforced Despite being documented inPromptEngine.build's own docstring as "a hint to the LLM about expected answer length", no code path in the provided source readsrequest.max_answer_tokensafter it's stored. It is not injected into any prompt text and not used to truncate anything. If you need the model to respect an answer-length limit, you must communicate it yourself (e.g. via the LLM API's ownmax_tokensparameter, or by adding a custom guardrail).
ContextManager(...)
GuardrailEngine(...)
PromptOptimizer(...)
ABTestRunner(...)
Enum-valued options at a glance
See api/types for the full member tables of PromptType, PromptStrategy, OutputFormat, QueryComplexity, and UserProfile.
Best practices
- Set
enable_cache=Falsein any environment where prompt inputs vary in ways not captured by the cache key (see api/prompt_engine.md#cache) — e.g. if document metadata or scores matter to your use case but aren't part of the hash. - Don't rely on
max_answer_tokensto constrain model output length; it is currently inert. - If you need
summarize_overflow-style behavior (summarizing docs that don't fit the budget instead of truncating them), you'll need to implement it yourself — the flag exists but does nothing in this version.