Prompt Engineering
How we engineer our prompts
Every prompt shipped with Illumind is authored against a template, pinned to a model version, and regression-tested against every new model release. This page documents the patterns we use — and how you can write your own.
Principles
Six rules we don't break
Applied across the library of 200+ prompts. If a prompt violates one, it fails our authoring lint before it can merge.
Role, task, constraints
Every prompt opens with a clear role, a single task, and explicit constraints. Ambiguity is the root of flaky output.
Structured output
Ask for JSON or markdown with a schema when the result feeds another step. Free-form prose only when a human reads it.
Guardrails first
Encode refusals, safe defaults and boundaries before examples. Models obey what they see first, not last.
Regression-tested
Every prompt runs against a pinned test suite on each new model release. We ship the fix before you notice drift.
Examples over adjectives
Two good input/output pairs beat ten adjectives. Examples teach tone, length, and edge cases in one shot.
Chainable by design
Outputs of one prompt are valid inputs of the next. Small, composable prompts win over mega-prompts.
Authoring template
The starting structure
Every prompt in the library begins life from this skeleton. Role is explicit, inputs are typed, constraints precede examples, and the output shape is declared. Freeform copy comes last, if at all.
prompt.tpl
CanonicalYou are a [ROLE] working on [DOMAIN].
Task:
[One-sentence description of what to produce.]
Inputs:
- [input_1]: {{input_1}}
- [input_2]: {{input_2}}
Constraints:
- Produce [format]. Do not add commentary outside the format.
- If [condition], return [safe default] instead of guessing.
- Respect existing patterns: [naming / style / framework].
Output schema:
{
"field_a": "string",
"field_b": ["string"],
"confidence": "low | medium | high"
}
Example:
Input: ...
Output: { ... }Authoring workflow
From draft to library
The path every prompt takes before it reaches your terminal. Same pipeline for the curated library and for prompts your team ships into .aichat/team/.
01
Draft from a template
Start from our authored templates above. Fill role, task, constraints, and a schema. No free-form writing.
02
Pin models & versions
Declare the intended model(s) in frontmatter. Prompts are versioned alongside the model they were tuned against.
03
Regression harness
Add 5–15 input/output pairs. The CI harness runs them on every new model release and on every prompt edit.
04
Ship to the library
Prompts merge to .aichat/team/ or the public prompt library. Users see a 'regression-tested' badge with last run timestamp.
Regression harness
What "tested continuously" means
When a new model version ships we don't trust the changelog — we re-run every prompt against the pinned test suite. Failures open a PR against the prompt. No drift reaches your terminal.
Browse the curated library
200+ production-ready prompts across Security, Testing, DevOps, Refactoring, Data and more. Each one follows the principles on this page.