{"name":"test-llm-app-outputs","description":"Sets up a small eval for an AI feature, using a fixed list of inputs with expected answers, a few automatic scores, and an LLM judge for the rest. Use when the user wants to measure output quality, compare two prompts with a judge, or catch a regression before release.","category":"backend","tags":["llm","quality"],"models":["any"],"proven":false,"passing_families":0,"model_testing":"Not yet model-tested; testing Jan 2027","url":"https://theskillvault.ai/skills/test-llm-app-outputs","api_url":"https://theskillvault.ai/api/skills/test-llm-app-outputs","raw_url":"https://theskillvault.ai/api/skills/test-llm-app-outputs/raw","body":"# Test an LLM feature with an eval set\n\nA demo chat is not a test. Freeze a list of inputs, score the outputs, and keep the scores so a later prompt change cannot quietly get worse.\n\n## When to use\n- You need to know if an AI feature still answers well.\n- You want to compare two prompts or two models on the same cases.\n- A change should fail when quality drops.\n\n## When not to use\n- You still need to build the chat route. Use build-ai-chatbot-api-route.\n- You still need retrieval over your docs. Use build-rag-search-over-docs.\n- You want a normal unit test of your own code. Use the test skill for that stack.\n\n## Steps\n1. Write 20 to 50 cases in a file your repo already stores. Each case has an input, an expected answer when one exists, and a tag such as happy, refusal or edge.\n2. Run the feature on every case. Save the output beside the input. Do not keep only the pretty ones.\n3. Score the easy cases by exact match. A label, a number or a short fact can be compared to the expected answer.\n4. For prose, pick one score that fits the task. Word overlap fits a summary or a translation. A short rubric fits an open answer.\n5. Use an LLM judge only for what the score cannot see. Pass the input, the output, the rubric and the expected answer if you have one. Ask for a number and one reason. Prefer a judge that is not the model under test.\n6. Keep the expected answers away from the feature. It must not see them.\n7. Save the run. Next time, fail the check when a tracked score falls past a line you chose.\n8. Read the worst cases yourself before you change the prompt.\n\n## Gotchas\n- A judge that shares the feature's prompt will praise its own style. Spot-check a handful of scores.\n- Do not put API keys, passwords or customer personal data in the case file or the judge prompt.\n- A high overlap score can hide a wrong fact. Read the failures.\n- Famous trivia questions will not catch your product bugs. Use cases from real traffic, with personal data removed.\n\n## Portability\nWorks with any model provider. Exact match and a small judge prompt do not need one vendor SDK. If you use a hosted eval product, keep the same cases so the scores stay comparable.\n\n## Done when\n- The case file is in version control, with expected answers where they exist.\n- One command prints the scores and the worst cases.\n- A drop past your line fails the check.\n- No secret or personal data is in the cases.\n\n## Example prompt\n\"Add an eval set for this support-reply feature. Include expected answers for the factual cases and an LLM judge for tone. Fail the check if the score drops.\"\n\n---\nAdapted from \"llm-evaluation\" in wshobson/agents (MIT, Copyright (c) 2024 Seth Hobson). See LICENSE.txt.","files":["LICENSE.txt"],"license":"MIT","license_name":"MIT License","license_url":"https://opensource.org/license/mit","attribution":"Based on work by Seth Hobson (wshobson/agents, llm-evaluation) (Copyright (c) 2024 Seth Hobson, MIT License), https://github.com/wshobson/agents/tree/7e2fb559cf4b824b27f1fec49fe88f7511066d26/plugins/llm-application-dev/skills/llm-evaluation; adapted by TheSkillVault, https://theskillvault.ai","install":{"claude_code":"curl -fsSL --create-dirs 'https://theskillvault.ai/api/skills/test-llm-app-outputs/raw' -o ~/'.claude/skills/test-llm-app-outputs/SKILL.md' && curl -fsSL --create-dirs 'https://theskillvault.ai/api/skills/test-llm-app-outputs/files/LICENSE.txt' -o ~/'.claude/skills/test-llm-app-outputs/LICENSE.txt'","cursor":"curl -fsSL --create-dirs 'https://theskillvault.ai/api/skills/test-llm-app-outputs/raw' -o '.cursor/skills/test-llm-app-outputs/SKILL.md' && curl -fsSL --create-dirs 'https://theskillvault.ai/api/skills/test-llm-app-outputs/files/LICENSE.txt' -o '.cursor/skills/test-llm-app-outputs/LICENSE.txt'","agents":"curl -fsSL --create-dirs 'https://theskillvault.ai/api/skills/test-llm-app-outputs/raw' -o '.agents/skills/test-llm-app-outputs/SKILL.md' && curl -fsSL --create-dirs 'https://theskillvault.ai/api/skills/test-llm-app-outputs/files/LICENSE.txt' -o '.agents/skills/test-llm-app-outputs/LICENSE.txt'","mcp_url":"https://theskillvault.ai/mcp","cursor_mcp_deeplink":"cursor://anysphere.cursor-deeplink/mcp/install?name=theskillvault&config=eyJ1cmwiOiJodHRwczovL3RoZXNraWxsdmF1bHQuYWkvbWNwIn0%3D","mcp_config":{"mcpServers":{"theskillvault":{"url":"https://theskillvault.ai/mcp"}}}},"bundles":[],"tested_on":[{"family":"chatgpt","name":"ChatGPT","outcome":null,"date":null,"source":null,"counts":false,"stale":false},{"family":"claude","name":"Claude","outcome":null,"date":null,"source":null,"counts":false,"stale":false},{"family":"gemini","name":"Gemini","outcome":null,"date":null,"source":null,"counts":false,"stale":false},{"family":"grok","name":"Grok","outcome":null,"date":null,"source":null,"counts":false,"stale":false},{"family":"llama","name":"Llama","outcome":null,"date":null,"source":null,"counts":false,"stale":false},{"family":"deepseek","name":"DeepSeek","outcome":null,"date":null,"source":null,"counts":false,"stale":false},{"family":"mistral","name":"Mistral","outcome":null,"date":null,"source":null,"counts":false,"stale":false},{"family":"qwen","name":"Qwen","outcome":null,"date":null,"source":null,"counts":false,"stale":false},{"family":"kimi","name":"Kimi K","outcome":null,"date":null,"source":null,"counts":false,"stale":false}],"proven_rule":{"threshold":5,"window_days":365,"computed_at":"2026-11-29T03:42:30.374Z"}}