buildUserContextBlock function presentation ✓ 100.0%
Last updated: 2026-03-03T11:04:37.495Z
Metrics
LOC: 7
Complexity: 3
Params: 1
Coverage: 100.0% (2/2 lines, 14x executed)
Signature
buildUserContextBlock(userContext?: string): : string
Summary
Builds the optional user-context block to inject into the prompt. Returns an empty string when no context is present.
Source Code
function buildUserContextBlock(userContext?: string): string {
if (!userContext || userContext.trim().length === 0) return "";
return (
`\nADDITIONAL CONTEXT PROVIDED BY THE USER (use this to guide the generated values):\n` +
`"""\n${userContext.trim()}\n"""\n`
);
}
No outgoing dependencies.
Impact (Incoming)
| Source | Type |
|---|---|
| buildPrompt | calls |