Every cheat sheet, one page
Twenty elements, six lines each. Built for printing and for the ten minutes before a vendor call.
Pr · Prompts
- Stable rules in the system prompt; the specific task in the user message.
- Caching the stable part cuts cost up to 90% and latency up to 85% on repeat calls.
- A timestamp in your system prompt silently breaks the cache on every call.
- On Claude, cache reads cost 0.1x base input price; cache writes cost 1.25x.
- Short prompts debug fast. Edit one line of a long one and three behaviours shift.
- Vendor test: can you see, edit and version the instructions it runs on?
Em · Embeddings
- An embedding is 768-1,536 numbers that encode meaning, not the words themselves.
- Safe default: OpenAI text-embedding-3-small, $0.02 per million tokens.
- 100k support articles (~150M tokens) embed for about $3. Storage costs more.
- Never mix models: switching means re-embedding everything from scratch.
- How you chunk documents matters more than which top-tier model you pick.
- Claude scores 3 on Em (bring your own). Gemini scores 9 as one stack.
Cx · Context
- Stable content first, variable content last. That is also what makes caching hit.
- Include only what this step needs. Just-in-case context gets paid for on every call.
- Summarize old turns instead of carrying them verbatim; agents drown in their own history.
- 50,000 tokens a call costs 25x a disciplined 2,000, often for a worse answer.
- A big window is more rope, not a fix: facts buried mid-context still get missed.
- Ask the vendor: what goes into the model's window, and can I see it?
Tr · Tracing
- A trace = input, model, tool calls, output, latency, cost — one run, end to end.
- Agents fail looking like success; only step-level traces catch that.
- OpenTelemetry GenAI conventions are the standard; MCP tool calls covered since 2026.
- Langfuse and Phoenix: free, self-hostable. Managed tiers ~EUR 0-50/month at SMB volume.
- About 15% of GenAI deployments instrument observability at all. The rest fly blind.
- Buyer's question: when this tool gets it wrong, what exactly can you show me?
Lg · LLM
- Two tells: can you see or pick the model, and are per-task costs published?
- Lg scores quality of access, not ownership — a reseller can legitimately score 9.
- Frontier tier runs $5-10 per million input tokens; light models cost cents.
- Output tokens cost 3-6x input; reasoning models bill their thinking as output.
- Cheap model on the routine 95%, frontier on the hard 5% — the biggest single saving.
- Swapping models is easy; the lock-in is everything you built around the model.
Fc · Function calling
- You describe tools; model returns a structured call; your code runs it and reports back
- Buyer's test: three-step task — look up, decide, act — with no human copy-paste
- Fc 9: Zapier, Genspark, Claude, ChatGPT; 8.5: n8n, Make, Windsurf; Cognism 3, Luma AI 2
- Function calling lives inside one app; MCP puts tools on a server any client reuses
- Each tool description costs input tokens on every call — 50+ tools burns thousands
- Budget agents per task, not per message: a five-step run is about five model calls
Vx · Vector store
- Core trick: nearest-neighbour search over embeddings, milliseconds at millions of rows.
- HNSW is the default index — trades a sliver of accuracy for thousand-fold speed.
- pgvector handles ~10M vectors inside the Postgres you already run, for effectively EUR 0.
- Qdrant, Weaviate and Pinecone start earning their fee at tens of millions of vectors.
- Hybrid = vector + keyword. Pure semantic search misses exact error codes and SKUs.
- Trap: a store that won't export your embeddings locks in your whole meaning layer.
Rg · RAG
- Chunk first: 300-500 tokens with modest overlap is the reliable starting point.
- Hybrid search beats pure vector search — keywords catch what meaning blurs.
- Reranking is a cheap second pass; expect roughly 10-20% better answers.
- Model choice matters fourth, after chunking, hybrid search and reranking.
- Demo test: does it cite sources, and say 'I don't know' when it should?
- Embedding a million chunks costs about $10; the LLM call dominates per-question cost.
Gr · Guardrails
- Four types: input filters, output filters, injection defense, human approval gates.
- Guardrails run live on every request, not just during testing or evaluation.
- Prompt injection succeeds over 50% of the time against systems with no protection.
- EU AI Act Article 14: human oversight of high-risk AI is law from 2 August 2026.
- Free or self-hosted: LLM Guard, NeMo Guardrails, Presidio, n8n's Guardrails node.
- Context-layer rails filter before the model sees data; model filters only run after.
Mm · Multimodal
- Multimodal = native image/audio/video in or out, no OCR bolted on the front.
- Gemini 2.5 Flash: $0.30/1M image+video tokens, $1.00/1M audio. Audio costs more.
- Runway Gen-4.5 costs 12 credits/second — $12/mo Standard buys about 52 seconds.
- Gemini 2.5 Pro: 94% on scanned invoices. AWS Textract: 82% on line items.
- Self-host free: Whisper is MIT; Qwen3-VL 7B runs in ~5GB VRAM quantized.
- Make the vendor upload YOUR file in the demo. Curated samples hide the gaps.
Ag · Agents
- Agent = think-act-observe loop; chatbot answers once and stops
- Score three axes: autonomy, reliability, integration depth
- Best agent finished only 30% of office tasks in TheAgentCompany benchmark
- METR: ~5h 50%-success time horizon, doubling every 3-4 months
- Gartner: 40%+ of agentic projects scrapped by end-2027; 130 real vendors
- Self-host free: n8n Community + open SDKs, ~EUR 10-40/mo VPS plus tokens
Ft · Fine-tuning
- Fine-tuning changes behaviour and format, not facts. Facts belong in retrieval.
- Prompt, then few-shot, then RAG. Fine-tune only when those measurably plateau.
- Under ~1,000 clean labelled examples, don't bother — you'll train in your errors.
- Together AI LoRA: $0.48 per 1M training tokens, $4 job minimum. Compute is cheap.
- Self-host: QLoRA on a rented RTX 4090 at $0.69/hr — an 8B run costs under €10.
- Real cost is the dataset, plus a re-run every time the base model moves under you.
Fw · Frameworks & harnesses
- Agent = Model + Harness. Swapping models rarely fixes a broken harness.
- Chain? Raw SDK. Loop with memory? Framework or a deliberate thin harness.
- Frameworks get you to 70-80%; the last 20% means reverse-engineering them.
- Same model, better harness: +13.7 pts on Terminal-Bench 2.0 (LangChain, 2026).
- Heavy abstraction costs tokens — one hand-written RAG used ~2.7x fewer.
- n8n self-hosted: free software, €4-7/mo VPS, unlimited runs. Start there.
Ev · Evaluations
- 30 real cases in a spreadsheet beats any vendor benchmark deck.
- Run the same set before and after every prompt or model change.
- Count rows that got worse. That number is your regression test.
- Vendor accuracy is measured on vendor data, never on your invoices.
- Check grader-vs-human agreement, or your judge is just another opinion.
- Free path: promptfoo or self-hosted Langfuse, EUR 0 licence, ~EUR 20-40/mo server.
Sm · Small models
- Flagship $2/$12 per M tokens; Flash-Lite $0.30/$2.50; Ministral 3B $0.04/$0.04.
- Quantisation: 16-bit weights rounded to 4-bit, ~quarter the memory, small accuracy hit.
- Q4_K_M is the production floor — Q3/Q2 breaks tool calling before it breaks chat.
- Qwen3 8B at Q4: 55 tok/s on an M2 16GB, 82 on M4 Pro. 8B model = ~5 GB on disk.
- Sub-7B models emit malformed tool calls on multi-step plans. Triage duty only.
- Self-host: €0 licence, €150 used RTX 3060 or €1,200 Mac mini, €60-390/yr power.
Ma · Multi-agent
- Handoff, delegation, debate — three shapes; only handoff is usually worth it.
- Anthropic: 15x tokens vs chat; token spend alone explains 80% of the gain.
- MAST: 14 failure modes across 7 frameworks — coordination, not the model.
- Parallel + read-only + independent = good. Sequential + shared state = theatre.
- Demand per-agent traces and per-agent token counts, or you cannot budget it.
- EUR 0.24 per brief single-agent vs EUR 3.70-5.50 multi-agent. Name the payoff.
Sy · Synthetic data
- Test: does the vendor ship generation to customers, not just use it internally?
- 3 of 62 audited tools score here. Empty column = mostly marketing language.
- Real SMB uses: test data, eval sets, privacy-safe exports, thin-set padding.
- Never loop-train on your own model's output. Accumulate real data, don't replace it.
- EDPB, 7 Jul 2026: synthetic data is NOT automatically anonymous under GDPR.
- Free path: MOSTLY AI SDK (Apache-2.0, CPU) or ~$0.14 per 1,000 LLM-made records.
Pc · Protocols
- MCP = agent-to-tool. A2A = agent-to-agent. Different layers, both open.
- Write an MCP server once; every MCP client can call it. N+M, not N×M.
- Spec 2026-07-28 is stateless: no handshake, plain load balancers work.
- Payments layer: ACP + AP2 + MPP (fiat/cards), x402 (stablecoin, no fee).
- Least privilege: read-only tools, scoped token, per-tool audit log.
- Treat every tool output as untrusted input — that is where injection lands.
In · Interpretability
- Interpretability = citations + stated confidence + exportable decision trail.
- Chain-of-thought is a story, not an explanation. Never accept it as evidence.
- Score what the vendor shows customers, not what its research lab publishes.
- Anthropic scores 4.5: world-class research, thin customer-facing surfaces.
- Demo test: reproduce a 6-week-old decision and export it as a file.
- DIY trail: free Langfuse core + ~EUR 30/mo VPS + two days of setup.
Th · Thinking models
- Thinking tokens are billed as output tokens on OpenAI, Google and Anthropic.
- Anthropic minimum thinking budget: 1,024 tokens per call. No small sips.
- Rule of thumb: reasoning on = 5-7x the output bill for the same visible answer.
- Overthinking is real: easy prompts get slower and occasionally less accurate.
- A reasoning trace is a story about the answer, not an audit trail. Log sources.
- Open-weight reasoning is €0 in licence; a 4090 at $0.69/hr is ~$504/month.