PTENES
MODULE 4.3

🪜 Choosing the pyramid level for each case

The solution pyramid applied to a specific case: when deterministic methods are enough, when AI in one step is the way to go, when an agent is justified—and why to document the decision.

6
Topics
~45
Minutes
Plan
Level
Decision
Type

Every AI recommendation starts with a question: what’s the lowest level of the pyramid that solves this problem? Unnecessary escalation is the main reason expensive projects deliver less than expected.

cost · risk ↑ 🛰️ Agent autonomy · tools · $$$$$ 🤖 AI in one step language · image · prediction · $$$ 🧱 Deterministic — rules, automation, SaaS predictable · inexpensive · reliable · $ start here ↓

Amber solutions pyramid—the lowest tier that solves the problem is always the best answer.

1

🧱 When deterministic is enough

Most use cases that come in as “AI projects” can be solved at the foundation: with rules, automation, integrations, or a better SaaS. This isn't weakness—it's the most valuable recommendation.

✅ Signs that deterministic logic is enough

  • •The rules are clear, explicit, and don’t change often
  • •The problem requires 100% accuracy (or accuracy that can be verified and audited)
  • •The volume is low and the frequency doesn’t justify sophisticated automation
  • •There isn’t enough historical data to train or validate AI
  • •An existing SaaS product already solves the problem at a lower cost

Examples in the database

  • • Email triage by sender and keywords
  • • Calculate discounts by volume tier
  • • Route tickets by fixed category
  • • Generate a monthly report using a template

When AI “replaced” deterministic logic — and got it wrong

  • • Classify fixed categories with an LLM (a rule does the same thing for R$0)
  • • Generate a report with an LLM (a template does the same thing)
  • • “Understand” a structured form (parsing JSON already does the job)
2

🤖 When the use case calls for AI in one step

The middle of the pyramid is where AI truly adds value: natural language, images, probabilistic predictions, ambiguity. The workflow remains deterministic before and after — AI is used surgically where rules can’t solve the problem.

📐 The deterministic wrapper pattern

// Structured input
recebe_texto_do_cliente()
↓ deterministic: cleans, normalizes, validates
chama_ia(texto_limpo) // ← the only step with AI
↓ AI: classifies intent
valida_saída_da_ia(resultado)
↓ deterministic: routes, logs, notifies
entrega_resultado_ao_sistema()
✓ Ideal for AI in one step
  • • Classify intent in free-form text
  • • Extract entities from documents
  • • Summarize long texts
  • • Detect sentiment in reviews
  • • Predict churn using numerical features
Advantages of the standard
  • • End-to-end testable workflow
  • • Replaceable AI module
  • • Clearly defined fallback to a human
  • • Controlled API costs
  • • Auditable: you know where the error occurred
3

🛰️ When an agent is justified

Agents are suited to cases that require multiple chained autonomous decisions with tools. They’re rare in typical consulting — and they should be.

Criteria for justifying an agent

  • ✓Multiple sequential decisions that are impossible to predefine
  • ✓Tools (APIs, code, searches) needed to solve the problem
  • ✓The cost of an error per action is tolerable and reversible
  • ✓Human oversight available for review

Signs that an agent is overkill

  • ✗The workflow has well-defined steps (workflow solves this)
  • ✗An error is costly or irreversible
  • ✗The team doesn’t have the capacity to supervise
  • ✗The main justification is “it seems more advanced”

💡 Practical tip

For most consulting projects, AI in one step is all you need. If someone suggests an agent, ask: "What happens when the agent makes a wrong decision?" If there’s no satisfactory answer, the answer is an AI workflow.

4

📐 Cost × risk × time by level

Each level of the pyramid has a distinct cost, risk, and time profile. Presenting this comparison to the client—with real estimates—is part of the business case.

Level Build cost Operating cost Risk Average time
🧱 Deterministic $ $ (almost zero) Low 1–4 wks
🤖 AI in one step $$$ $$ (API + monitoring) Medium 4–12 weeks
🛰️ Agent $$$$$ $$$$ (API + oversight) High 12–24 wks

📊 How to use the table with the client

Present the three options side by side with real numbers from the client’s context. Let them see the difference. In most cases, they’ll choose the lowest level that solves the problem — without you needing to argue for it.

5

🧪 Hybrid: deterministic with surgical AI

The most mature and recommended pattern for production: keep the business logic in deterministic code and use AI only where rules can’t solve the problem — as a replaceable module, with an explicit fallback.

⚙️ Why the hybrid is more robust

Testability

The deterministic flow can be tested with unit tests. The AI module can be tested separately with a set of cases.

Replaceability

If a better model comes along, only the AI module changes—the rest of the system stays intact.

Fallback

If AI is unavailable, the workflow can continue with a rule or escalation to a human—without stopping everything.

Auditability

Knows exactly where AI was called, with what input, and with what output. Essential for compliance.

6

✅ Decide on the level and record why

The decision about which level to use should be explicit and documented. It doesn’t need to be long — three questions are enough. The record protects the consultant, aligns the team, and enables an informed review when the context changes.

📝 Decision record template

Use case: Support email triage
Selected level: AI in one step (intent classification)
Why not deterministic: the client's vocabulary varies too much for fixed rules to cover it well
Why not an agent: routing after classification is deterministic and well-defined
Criterion for review: if accuracy falls below 85% or API costs exceed R$500/month

💡 Practical tip

Treat the decision log as part of the project deliverable—not as bureaucracy. It’s what turns a consulting project into a knowledge asset for the client and for you.

🎒 Module summary

✓
Start at the foundation — deterministic solutions handle most cases with less cost and risk.
✓
AI in one step for language and ambiguity — narrowly scoped, with a deterministic wrapper.
✓
Agents are the exception, not the rule — explicitly justify it, with the cost and a supervision plan.
✓
Hybrid is the mature default — deterministic as the container, AI as a replaceable module.
✓
Record the decision — chosen level, why not the others, and review criteria.

Next module:

4.4 — Pilot, proof of concept, and success metrics