Install any skill in seconds. Free to start, no credit card required.
Get Started Free →Manages LangChain 1.0 prompts as versioned code: LangSmith prompt hub, Claude XML tags, few-shot selection, and A/B testing.
77% 91%+14 ptsof test cases passed
Passed 20 of 22 test cases with the skill, and 17 of 22 without it.
When configuring dynamic few-shot example selection for standard retrieval-augmented prompting tasks, how many examples should typically be retrieved per query to achieve optimal context efficiency without hitting diminishing returns?
Configures selector retrieval parameter k to a value between 3 and 10
This test ran on v1. v2 is the current version and hasn’t been tested on gemini-3.6-flash yet.
3 of 3 safety checks passed
A team inherits a LangChain 1.0 codebase with 47 prompt strings embedded as
f-string literals across 12 Python files. Nobody knows which version is live in
production. Rollback is git-only — requires a deploy. An A/B test on a single
prompt requires shipping code and running two services in parallel. A user pastes
a JSON snippet containing { into a chat endpoint and the whole thing throws:
KeyError: '"model"'
File ".../langchain_core/prompts/string.py", line ..., in format
That is pain-catalog entry P57 — ChatPromptTemplate.from_messages with
f-string templates treat every brace-delimited identifier as a variable
marker — including ones that appear inside user content. Any literal braces in
user input (code snippets, JSON, LaTeX, CSS selectors) crash the chain. Four
prompt-layer pitfalls this skill fixes:
{ in user inputsystem field,
not a later HumanMessage; reordering middleware silently loses personawith_structured_output(method="function_calling") silently drops
Optional[list[X]] fields; use discriminated unions insteadSections cover: consolidating scattered prompts into a prompts/ module as
ChatPromptTemplate objects, pushing/pulling from the LangSmith prompt hub
(pinning production to 8-char commit hashes), switching to jinja2 template
format, Claude XML-tag conventions (<document>, <example>, <context>),
dynamic few-shot with semantic/MMR selectors, and A/B testing two prompt
versions via feature flag. Pin: langchain-core 1.0.x, langsmith >= 0.1.99,
langchain-anthropic 1.0.x, langchain-openai 1.0.x. Pain-catalog anchors:
P03, P53, P57, P58.
Next to this one in the catalogue, plus more from the same author.