
Large language models (LLMs) can read messy text, summarise it, classify it and draft replies. Placed inside an automation, that means tasks that used to need a human reading every message can run on their own. But an LLM is also a component that is occasionally wrong, so using it well is as much about design as about prompts.
Where LLMs fit well in a workflow
- Classification. Decide whether an incoming message is a sales enquiry, a support question or spam.
- Extraction. Pull a name, date, budget or order number out of free text and return it as structured fields.
- Summarisation. Turn a long email thread or meeting transcript into a few lines.
- Drafting. Prepare a reply for a person to review and send.
- Translation and rewriting. Adapt tone or language.
Where they are a poor fit
- Exact arithmetic or anything where a rule can be written plainly. Use ordinary logic.
- Decisions with legal or financial consequences and no human check.
- Facts the model cannot know, such as your current stock level, unless you pass them in.
Techniques that make results reliable
Be specific in the prompt
State the role, the task, the allowed outputs and the format. “Classify this message as exactly one of: sales, support, spam” works far better than “what is this about”.
Ask for structured output
Request JSON with named fields, and validate it before using it. A downstream step should never have to guess what the model meant.
Give examples
Two or three short examples of input and desired output (few-shot prompting) steer the model more than long instructions do.
Ground the model in your data
If the answer depends on your pricing, policy or documentation, include the relevant text in the prompt (retrieval) instead of relying on the model’s memory.
Keep a human in the loop where it matters
For outgoing messages, have the workflow create a draft or send a notification for approval. Automate the reading; keep the sending supervised until you trust the results.
Practical safeguards
- Validate outputs. Check that the category is in the allowed list and that required fields exist; route failures to a review queue.
- Treat input as untrusted. A message can contain text such as “ignore your instructions”. Never let model output trigger sensitive actions directly, and keep secrets out of prompts.
- Log inputs and outputs so you can see what went wrong and improve the prompt.
- Control cost and speed. Use a smaller, cheaper model for simple classification, and add timeouts and retries.
- Mind privacy. Know what data you send to a provider and whether that fits your obligations.
Example: triaging a contact form
A webhook receives the form submission. An LLM step classifies the message, extracts the topic and urgency as JSON, and writes a one-sentence summary. A branch then routes the entry: urgent enquiries notify you immediately, normal ones are logged in a spreadsheet, and spam is dropped. A reply draft is prepared but not sent. The whole chain is easy to follow, and every decision is recorded.
Key takeaways
Use LLMs for language tasks where a bit of flexibility is valuable, wrap them in validation, and keep people in charge of consequential actions. Start with one narrow job, measure it, and expand from there.