Module 1: Why Ethics Matters in AI Engineering

6. The engineer's ethical responsibility

Capsule description

The most common question when AI ethics comes up:

"This is the PM's responsibility, right? Or the legal team's. I just implement."

This capsule shows you why that answer is wrong, in three converging arguments:

  1. Regulatory convergence: emerging standards (EU AI Act, NIST AI RMF, ISO/IEC 42001) assign explicit technical responsibility to the engineer/developer.
  2. Asymmetric information: the engineer holds technical information that PMs/legal don't have and can't have.
  3. Technical causality: technical decisions determine the system's behavior. Ethics gets implemented in code.

Then we translate that responsibility into concrete behavior: what you have to do differently vs. what you did yesterday. And we cover the hard question: what do you do when your PM/company asks you for something unethical?

This is the capsule that closes the mindset shift before the concrete framework (capsules 7-8).


Argument 1: Regulatory convergence

What traditional regulation used to say

Until ~2020, tech regulation treated the product as the subject, not its individual creators. A company could be fined; an engineer was rarely named.

What the emerging regulation says

EU AI Act (effective 2024-2026):

  • Articles 16-29: obligations of providers of AI systems. They include:

    • A risk management system (includes technical risk identification).
    • Data governance: dataset documentation, demographic balance, etc.
    • Technical documentation: the model's technical detail.
    • Record-keeping and logging.
    • Conformity assessment.
    • Post-market monitoring.
  • Every one of these obligations requires technical knowledge. Legal/PM can't meet them without an engineer.

  • Article 50: transparency obligations specific to systems with human-AI interaction. Implementing them requires code changes — the engineer's domain.

NIST AI Risk Management Framework (2023):

  • The "GOVERN" function: culture and policy. Shared legal/eng.
  • The "MAP" function: context, intended users, risks. Eng input is critical.
  • The "MEASURE" function: technical metrics, testing, monitoring. 100% engineering.
  • The "MANAGE" function: treatment of risks. Eng implements.

ISO/IEC 42001 (2023) — AI Management System:

  • A management system standard for AI, similar to ISO 27001 for infosec.
  • It certifies organizations, but the implementation is engineering.
  • Certifiers assess: do you apply bias testing? do you document technical decisions? do you have a technical incident response process?

What this means in practice

Personal liability is starting to appear:

  • In the US, the Algorithmic Accountability Act (proposed) includes disclosure requirements where a "responsible engineer" must certify practices.
  • In the UK, the AI Safety Institute evaluates systems and publishes technical capabilities — with individually identifiable engineers.
  • In Europe, the EU AI Act creates conformity assessment processes where the engineer must attest to technical compliance.

"I just implemented the requirements" stops being a valid defense when the requirements didn't include bias testing and you knew it was necessary.


Argument 2: Asymmetric information

What the engineer knows that nobody else does

When you build an AI system, you get access to information the PM, legal, execs, and QA don't have:

InformationWhy only eng has it
Demographic composition of the training dataOnly accessible by inspecting the datasets
Performance by subgroupRequires disaggregated testing
Features that correlate with protected attributesRequires statistical analysis
Cases where the model fails systematicallyOnly visible in detailed testing
The model's limitationsOnly understandable with an eval framework
Architectural trade-offs (accuracy vs. fairness)Requires knowing the algorithms

If the engineer doesn't raise these issues, nobody else can. PM/legal/exec literally have no way to know about them.

The impossible-delegation problem

The PM says: "Build me a fair system."

What does "fair" mean technically? There are dozens of mathematically distinct definitions:

  • Demographic parity (equal positive rate per group).
  • Equal opportunity (equal true positive rate).
  • Equalized odds (equal TP and FP rate).
  • Calibration (equal predicted probabilities).
  • Counterfactual fairness.
  • Predictive parity.

And they're mutually incompatible in general. You can't satisfy them all simultaneously. You have to choose which one you prioritize based on context.

That choice is inherently technical + ethical combined. The PM can't make it without understanding the mathematical trade-off. Legal can't make it without understanding the concrete impact. Only the engineer is in a position to propose the informed choice.

And if the engineer doesn't propose one, someone less informed decides, or the decision gets left as a default (= chosen implicitly, usually badly).

The analogy with security engineering

Comparable: in security engineering, we don't say "the SOC 2 auditor is responsible for security." The engineer is responsible. The auditor verifies that the engineer applied the right practices.

Same in AI ethics: the engineer is responsible. Auditors/legal verify.


Argument 3: Technical causality

Ethics gets implemented in code

Concrete examples of technical decisions that are ethical decisions:

Decision 1: which dataset do you use?

  • Apparently a technical decision.
  • Ethical implication: it defines who is well/poorly represented, and what patterns the model learns.
  • Who makes it: the engineer.

Decision 2: which features do you include?

  • Apparently a technical decision.
  • Ethical implication: it defines what information about people you use, and what proxies can emerge.
  • Who makes it: the engineer.

Decision 3: what confidence threshold do you use for a "match"?

  • Apparently a technical decision.
  • Ethical implication: it defines the false positive vs. false negative rate. In contexts like healthcare or policing, it defines lives affected.
  • Who makes it: the engineer.

Decision 4: do you do bias testing?

  • Apparently a technical decision.
  • Ethical implication: it defines whether you detect disparate impact before or after the deploy.
  • Who makes it: the engineer.

Decision 5: what do you log?

  • Apparently a technical decision.
  • Ethical implication: it defines which personal data persists, and the exposure surface.
  • Who makes it: the engineer.

Decision 6: how do you handle model errors?

  • Apparently a technical decision.
  • Ethical implication: it defines how the system fails — silently, loudly, with a human fallback, with no fallback.
  • Who makes it: the engineer.

Every one of these decisions is made in code. Every one is simultaneously technical and ethical. Ethics doesn't live in some "values" document — it lives in engine.py:line_47.

Implication: the separation is impossible

It's impossible to separate "engineering" from "ethics" in AI. Every eng decision is an eng decision AND an ethics decision at the same time.

Pretending otherwise is like a surgeon saying "I just operate, the consequences are the hospital's." The consequences are the direct result of how you operate.


What this means day to day

Translated into concrete behavior:

Before (passive mindset)

  • You get a ticket: "implement feature X."
  • You implement feature X.
  • Tests pass, commit, PR.
  • "My responsibility ends when the code compiles and the tests pass."

After (responsible mindset)

  • You get a ticket: "implement feature X."
  • Before starting: I ask whether feature X affects people, who, and how.
  • If it applies: I run an Ethics Impact Analysis (capsules 7-8) up front.
  • During implementation: I include bias testing in the code, not after.
  • Before the PR: I run disaggregated testing where it applies. I report the results explicitly.
  • In the PR description: I document the model's known limitations.
  • If I detect an ethical problem: I raise it with the PM/team, blocking the merge if it's severe.
  • My responsibility ends when: the deployed system operates within verified ethical bounds, NOT just when the code compiles.

Concretely, what changes

PracticeBeforeAfter
Acceptance criteria"Tests pass, performance > X""Tests pass, performance > X, bias testing < Y per subgroup, model card documented"
Code reviewPerformance, correctnessPerformance, correctness, fairness implications, privacy implications
Deploy gateManual QAManual QA + bias gate (CI test) + privacy review
Post-deployMonitor errorsMonitor errors + disparate impact metrics + fairness drift
DocumentationCode comments, API docsCode comments, API docs, model card, ethics impact analysis

The hard question: what do you do when you're asked for something unethical?

Let's be realistic. Sometimes, you're going to get requests you know aren't ethical:

  • "Let's ship without bias testing, we'll fix it as we go."
  • "Let's not document the limitations, it'll scare the customers."
  • "Use this dataset even though we don't have clear consent."
  • "Approve the deploy even though the disparate impact is > 4/5 rule."

What do you do?

Step 1: document it technically

Don't open with "this is ethically wrong" (that polarizes). Open with technical information:

"I wanted to share my technical analysis before we make the decision. I measured disparate impact and the current ratio is 0.65, below the legal threshold of 0.80 (4/5 rule). That means exposure to [GDPR Art X / NYC AEDT / etc.]. My estimates of the legal exposure are [Y]. The cost of fixing it before deploy is [Z]."

This converts the debate from "values" to "verifiable facts + risk assessment."

Step 2: offer alternatives

Identifying the problem with no alternative is just "blocking." Identifying it with an alternative is "engineering."

"If the deadline is critical, there are three options: A) Ship with the bias issue — expected risk of $4M. B) Ship with reduced scope (not affecting group X) — takes 2 more weeks. C) Postpone 4 weeks to implement the full mitigation. I recommend C based on the risk math."

Step 3: escalate if it doesn't get resolved

If your PM/team doesn't respond:

  1. Escalate to the manager: "I wanted to bring you this issue because it carries legal exposure."
  2. Escalate to security/legal: depending on severity.
  3. Document it in writing: an email with your concerns + the technical analysis. This creates a paper trail that protects you individually and the company institutionally.

Step 4: the last line — disagree and commit, or disagree and resign

Many companies have a "disagree and commit" culture — you argue, but if the decision goes against you, you get in line.

That works for reasonable product decisions. It does not work for decisions that cause significant harm and you know it.

The last line: there are decisions where your only ethical option is not to participate. Walk away from the feature. Walk away from the project. In the extreme, walk away from the job.

This is NOT the first move. It's the last option, after documenting, offering alternatives, escalating. But it exists, and it's valid.

Whistleblowing: if the problem is severe (harm to people at scale), and the company doesn't respond, reporting externally is sometimes the right option. It carries real personal costs (Christopher Wylie, Frances Haugen). But it also carries legal protections (Sarbanes-Oxley, the EU Whistleblower Directive).


The culturally correct answer vs. the ethically correct one

Sometimes, the company's culture pushes you toward a culturally correct answer ("ship fast, we'll iterate") that is ethically wrong.

Culture doesn't excuse you. The EU AI Act doesn't accept "it's my company's culture" as a defense. Neither does GDPR. Neither does a court.

Your personal responsibility doesn't end at "my PM said so." It ends at "I acted with technical due diligence, documented my concerns, escalated appropriately, and only then participated / didn't participate."


Traps and common mistakes

1. "I'm junior, I have no power"

Yes, you do. You have technical information your manager doesn't. Raising technical issues with analysis behind them is exactly what's expected of a junior engineer.

If your manager repeatedly ignores you despite solid analysis, that's an indicator of a toxic culture — and you should consider leaving.

2. "I don't get paid to think about ethics"

You get paid to build systems that work. Systems that don't work correctly (bias, harm) aren't an "ethical optional" — they're technically defective. Your job includes preventing defects.

3. "Better to ask forgiveness than permission"

In security: terrible idea. In privacy: terrible idea. In AI ethics: terrible idea.

The consequences of "we'll fix it later" are the 500x costs from capsule 05.

4. "I just write code, other people make the decisions"

Technical decisions ARE the ethical decisions. Whoever writes the code makes decisions, whether you want to or not.

Accepting that responsibility is what separates a "developer" from an "engineer." A developer executes requirements. An engineer evaluates requirements against technical + ethical + legal reality and proposes alternatives when necessary.


Self-check

1. Why isn't "I just met the requirements" a valid defense under the EU AI Act?

Because the EU AI Act assigns specific technical obligations to the provider that only the engineer can meet:

  • Data governance (Art 10): document the demographic composition of the datasets.
  • Technical documentation (Art 11): the model's detail.
  • Risk management (Art 9): identify and mitigate technical risks.
  • Conformity assessment (Art 43): attest to compliance.

If the PM's requirements don't include bias testing, and you know it's a legal requirement, you're the one who had the information to know it was missing. "The PM didn't ask me for it" doesn't excuse you, because you were the one technically responsible.

Under the EU AI Act, the provider is responsible, and the engineer is designated as the responsible person within the provider for technical functions. Personal liability is emerging.

2. Why are there technical decisions only the engineer can make correctly?

Because they require technical information only eng has + knowledge of the mathematical trade-offs.

Example: the PM asks for a "fair system." There are dozens of definitions of "fair" that are mathematically incompatible. Only the engineer:

  • Knows the multiple definitions exist.
  • Knows they're incompatible.
  • Can measure which one has what impact on the outputs.
  • Can recommend which to prioritize given the context.

If the engineer doesn't propose the informed decision, someone less informed decides (typically, you end up with the worst technical option by accident).

That's the responsibility: not "think harder," but surface the information and propose the decision to the right stakeholder.

3. How do you escalate an ethical problem without sounding dramatic or preachy?

Talk numbers, not values.

❌ "This isn't ethical, we shouldn't do it." ✅ "My analysis shows a disparate impact ratio of 0.65 vs. the legal threshold of 0.80. I estimate regulatory exposure of $X. The cost of fixing it before deploy is $Y. I recommend option [specific]."

The first sentence polarizes. The second is engineering management.

Document it in writing. An email/ticket is a paper trail that protects you individually and creates an institutional record.

Offer concrete alternatives. Not "let's not do this" but "let's do A, B, or C; I recommend B."

Escalate progressively. Manager → security/legal → exec. Without skipping levels unnecessarily, but without stalling either.

4. When is it ethical to walk away from a feature/project/company?

When:

  1. You've documented the issue with clear technical analysis.
  2. You've proposed alternatives that are concrete and executable.
  3. You've escalated to your manager + the appropriate escalations.
  4. The final decision is to proceed with a course of action you know causes significant harm.
  5. Your participation would be material to that harm happening.

When all 5 hold, not participating is the right answer. Walk away from the feature first, from the project if necessary, from the role if that's the only option.

It is NOT the first response. It's the last one, after the procedures. But it exists, and it's ethically valid (even required in some professions — doctors, pilots, civil engineers).

External whistleblowing: the most extreme response, valid only when the harm is significant (at scale, irreversible) and the company doesn't respond internally. It has real personal costs but also legal protections in most jurisdictions.


Summary and next step

  • The engineer's ethical responsibility is direct, not derived, based on three arguments:
    • Regulatory convergence: the EU AI Act, NIST AI RMF, and ISO 42001 assign explicit technical responsibility.
    • Asymmetric information: only the engineer has the information to detect the issues.
    • Technical causality: ethics gets implemented in code.
  • Translated into behavior: bias testing in CI, model cards, disaggregated metrics, ethics impact analysis pre-deploy.
  • When you're asked for something unethical: document it technically, offer alternatives, escalate, and as a last resort, don't participate.
  • Culture doesn't excuse you: "it's how we do things here" is not a defense under regulation or conscience.

Checkpoint: you should be able to articulate why "I just implemented the requirements" stops being a valid defense under modern regulation.

Bridge to the next capsule: capsules 1-6 were motivation + context + responsibility. Capsule 07 finally gives you the concrete tool: the Ethics Impact Analysis framework, step by step. You'll learn how to identify stakeholders, map failure modes, score severity, prioritize risks, and produce a professional document that's the equivalent of a "threat model" in security. Capsule 08 is the mini-project: applying it to a real system.


Resources

  1. EU AI Act — Provider obligations (Art 16-29) — legal reference.
  2. NIST AI RMF — Responsibilities — the US framework.
  3. ISO/IEC 42001:2023 — AI Management Systems — international standard.
  4. ACM Code of Ethics — Professional responsibility — professional standard.
  5. Christopher Wylie — Mindf*ck book — a tech whistleblowing case study.

Next: 07-ethics-impact-analysis-framework.md — The concrete framework for doing an Ethics Impact Analysis.

Capsule 06 of 08 — Module 1 — AI Ethics & Compliance Guide