Day 3 presentation1 / 16

Zero to MVP AI Bootcamp

AI qualification

Replace the sample result with one focused AI job that is useful, grounded, testable, and bounded.

Today you ship

Live AI lead qualification with structured recommendations and tested guardrails.

Scroll to move through the presentation.

Learning objectives2 / 16

By the end of today

  1. 1Explain what the model receives and why it can make mistakes.
  2. 2Define one narrow AI job with observable success criteria.
  3. 3Create a system prompt with role, rules, output, and refusal behavior.
  4. 4Keep model credentials and protected calls on the server.
  5. 5Test normal, unclear, and out-of-scope lead submissions.
Run of show3 / 16

Today’s learning path

  1. Module 140 min

    How the recommendation is produced

  2. Module 245 min

    The qualification contract

  3. Module 340 min

    Grounding and guardrails

  4. Module 435 min

    Integrate and inspect

  5. Guided build

    AI Lead Assistant · Stage 3

    Build, test, checkpoint, and ship.

Module 1 · Learn · 40 min4 / 16

How the recommendation is produced

The AI does not understand the business automatically. It receives instructions, approved business facts, and the visitor's answers, then generates a likely response from that context.

A real example

Two visitors answer differently. One needs more leads and receives a campaign recommendation; another has traffic but poor conversion and receives a website audit.

Technical terms

Context
The instructions and information supplied to the model for this request.
Hallucination
A confident-sounding answer that is unsupported or invented.
Module 1 · Apply it5 / 16

Apply the concept

Predict how three different lead submissions should change the recommendation.

  1. 1Separate the permanent instructions from the visitor's answers.
  2. 2Highlight which approved business facts support the recommendation.
  3. 3Predict the result for three different lead profiles.
  4. 4Compare your predictions with the model and inspect unsupported claims.

Use this prompt

Using only the supplied business services and lead answers, recommend one service. Return: category, recommendation, reason tied to the answers, confidence, and next step. If the information is insufficient, ask for human follow-up.

Success looks like

Different lead answers produce relevant differences, and every claim can be traced to supplied information.

Watch for

  • If the result invents a service, strengthen the instruction to use only the approved list.
  • If every lead receives the same result, make the matching criteria and examples more distinct.
Module 2 · Learn · 45 min6 / 16

The qualification contract

The qualification contract is the product rulebook for the AI. It defines the job, available information, required answer shape, and behavior when a request does not fit.

A real example

The assistant may recommend one approved service and explain why. It may not promise prices, legal outcomes, or services the business does not offer.

Technical terms

System prompt
Instructions the application sends with every model request.
Structured output
A response with required named fields instead of free-form text.
Module 2 · Apply it7 / 16

Apply the concept

Draft and peer-review the shared system prompt in plain language.

  1. 1Write the assistant's role and one narrow job.
  2. 2List approved inputs, services, and decision rules.
  3. 3Define every required output field.
  4. 4Add explicit refusal and human-follow-up behavior.

Use this prompt

Review this qualification contract as a product tester. Identify ambiguous rules, missing output fields, unsupported promises, and cases that need human follow-up. Do not rewrite it until you explain the risks.

Success looks like

Two classmates can read the contract and agree on what the assistant should return for the same lead.

Watch for

  • If the rulebook becomes long, remove background information that does not change a decision.
  • If an output field is subjective, add a concrete definition or example.
Module 3 · Learn · 40 min8 / 16

Grounding and guardrails

Grounding gives the AI trusted business information. Guardrails define what it may do with that information and how it should respond when the request is unsafe, unrelated, or uncertain.

A real example

The business offers audits and campaigns but not custom mobile apps. A mobile-app request should be redirected to a consultation rather than inventing an app service.

Technical terms

Grounding
Supplying trusted facts that the AI should use for its answer.
Guardrail
A rule or check that limits unsafe or off-scope behavior.
Module 3 · Apply it9 / 16

Apply the concept

Write five normal cases and five boundary cases with expected behavior.

  1. 1Create one approved source containing services and matching rules.
  2. 2Validate required lead answers before making a model request.
  3. 3Write normal, unclear, unsupported, and malicious test cases.
  4. 4Define the safe response and human route for each failure type.

Use this prompt

Create ten test cases for this lead assistant: five normal, two unclear, two unsupported, and one malicious. For each, state the expected recommendation or safe fallback. Use only the supplied business facts.

Success looks like

The assistant stays within approved services, asks for help when uncertain, and never reveals secrets or hidden instructions.

Watch for

  • If refusal messages feel unfriendly, include one useful next action.
  • If the model ignores a rule, add validation outside the prompt rather than relying on wording alone.
Module 4 · Learn · 35 min10 / 16

Integrate and inspect

The browser should never hold the private model key. It sends lead answers to protected server code, which calls the model, validates the response, and returns only safe result data.

A real example

The visitor submits the form. The screen shows progress. The server obtains a structured recommendation. The result appears, or the visitor sees a useful retry message.

Technical terms

Endpoint
A protected address the interface uses to request server work.
API key
A private credential that authorizes use of an external service.
Module 4 · Apply it11 / 16

Apply the concept

Trace one submission from the form to the model and back to the result screen.

  1. 1Create the protected qualification endpoint.
  2. 2Load the model key from a server-side environment variable.
  3. 3Validate submitted answers and model output.
  4. 4Connect the form and test success, timeout, malformed output, and retry.

Use this prompt

Implement the smallest protected qualification endpoint for the existing form. Keep the API key server-side, validate input and structured output, preserve current UI states, and list every changed file before I test it.

Success looks like

A real submission returns a structured recommendation, while the browser source and repository contain no model key.

Watch for

  • If the browser shows the key, stop and move the external call into server-side code.
  • If the output breaks the page, log the response shape safely and compare it with the required contract.
Guided project12 / 16

Build brief

AI Lead Assistant · Stage 3

Replace the mocked recommendation with a protected AI call that performs the shared qualification contract.

User story

As a potential customer, I receive a relevant recommendation based on my answers and the business's actual services.

Guided build · Part 113 / 16

Build it step by step

1

Write the AI contract

Define accepted inputs, required output fields, quality rules, and prohibited behavior.

2

Add the protected endpoint

Call the model from server-side code using a private environment variable.

3

Create the system prompt

Include the role, service facts, rules, response structure, and fallback behavior.

Guided build · Part 214 / 16

Build it step by step

4

Validate the response

Reject incomplete output and show a useful retry or human-contact path.

5

Connect the interface

Replace the sample result while preserving loading, error, and retry states.

6

Run ten cases

Test five typical and five boundary submissions, then fix the highest-impact failure.

Ship checkpoint15 / 16

Do not ship until

  • The AI performs lead qualification rather than acting as a generic chatbot.
  • API credentials are absent from the browser and repository.
  • Every result follows the required structure.
  • Recommendations use only the approved business services and facts.
  • Unclear and off-scope requests receive a helpful fallback.
Wrap and prepare16 / 16

Ship it. Show it. Prepare the next move.

Before the next day

  • List the lead and recommendation data that should be saved.
  • Sketch the business dashboard using no more than three screens.
  • Prepare two test email addresses for tomorrow's privacy test.