- Prompt-level techniques — what a single model call is asked to do and how the ask is phrased.
- Context engineering — what fills the context window: what gets written, selected, compressed and isolated.
- Agentic workflow patterns — how many calls, in what shape, with which gates: chains, routing, parallel workers, evaluators, waves, phases.
Prompt-level techniques
These all reduce to instructions and message shape —createAgent’s
instructions / prompt, seeded session turns, and output schemas.
Two rules of thumb:
- Instructions steer; machinery enforces. Anything that must never happen
(no deletes, no prod writes) goes in
permissions, guardrails and tools — not the prompt. - Techniques that spend more tokens (self-consistency, trees, critiques) pay
off where a wrong answer is expensive; watch
result.usage/limitsand budget them like any other spend.
Context engineering
The four operations, and where each lives in the SDK:Agentic workflow patterns
The canonical shapes (Anthropic’s “building effective agents” taxonomy) and the community terms that named two of them — all runnable in the repo:Typed decisions (“System One” style)
Some steps shouldn’t generate text at all — they should decide: classify, route, score, verify. The pattern (TypeSafe’s Jev makes a whole model of it) is a typed probabilistic decision: unstructured state in,{ action, confidence } out, and the workflow branches on it. In Lousho that’s an
agent with an output schema feeding a flow’s oneOf — and a confidence
floor that routes low-confidence calls to a human instead of acting on a
guess:
needs-human instead of patching.
Where to go next
- Structured output, evals
(
llmJudge,llmCritique) for the decide/score primitives - Flows for deterministic pipelines and phase gating
- Sub-agents and handoffs for parallel and transfer patterns
- Memory, compaction, skills, tool search for the context layer
- Approvals and guardrails for the gates that keep bounded autonomy safe