liveBook · Manning

Garbage in, garbage out

As explained in Software Testing with Generative AI

The principle that poor or insufficient input tends to produce poor or insufficient output from a computational process.

Garbage in, garbage out means that poor training data, weak instructions, or missing context tend to produce poor computational results. With LLMs, response quality depends partly on the quality and specificity of the input. section 2.2.2 section 1.2.2

Apply the principle when using AI for software development and testing:

  • Question suggestions produced from potentially poor or inconsistent training data rather than accepting them blindly. section 2.2.2
  • Replace vague requests with clear roles, context, constraints, quality characteristics, and concrete acceptance criteria. section 5.2.1 section 1.2.2
  • Keep human judgment in control: useful output still requires review because generic or flawed suggestions can damage testing quality. section 2.2.2 section 5.2.1

From vague request to useful test ideas

“Create tests for a file upload feature” can produce a broad list of security, privacy, compliance, and performance risks that needs substantial reworking. A stronger prompt identifies the tester’s role, asks for risks affecting Functionality, Data Integrity, and Security, and supplies acceptance criteria such as supported formats, a 20MB limit, progress updates, access restrictions, and audit reporting. section 5.2.1 section 1.2.2

How Software Testing with Generative AI covers it

How deep it goes
Explains the principle through training-data and prompt examples, then stops short of formal model internals.
Examples
Uses flawed training data, Copilot suggestions, and vague versus contextual file-upload test prompts.
What it assumes
Assumes familiarity with LLM-assisted development and testing, while illustrating prompt quality through concrete examples.
What you can do after
Evaluate and improve LLM inputs while verifying generated code and testing suggestions before using them.
How it connects
Connects prompt engineering, data provenance, software testing, and human judgment.

Also explained in

Compare how 2 books explain garbage in, garbage out →

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Software Testing with Generative AI. The section links point to the parts of the book it draws on.