Part IV — Expert Production Engineering · Chapter 26 · Lesson 1 of 6 · 1 min read
Lesson 1: Architecture Brief and Threat Model
Lesson level: Expert
Purpose: Begin with contracts and authority boundaries before choosing deployment mechanisms.
Learning Objectives
- Implement the stage contract within the capstone architecture.
- Preserve capability and portable-value boundaries.
- Produce normal, boundary, and failure evidence.
1.1 Concepts
Capstone scenario: a support-case decision service receives synthetic case records, evaluates a typed PeaLang policy, returns priority and reason codes, and publishes aggregated service-demand analytics. Machine learning is optional and may forecast demand; it must not silently replace the deterministic priority policy. The host owns identity, data acquisition, capability admission, resource budgets, final enforcement, durable evidence, and deployment.
1.2 Annotated Example
Illustrative contract: input is a string-keyed map with case_id, service_impact, affected_users, and security_relevant; output contains priority, response_minutes, and reason_code. Accept only documented field types and ranges. Threat boundaries include uploaded rules, host calls, ingestion credentials, artifact storage, prediction interfaces, and cluster access. Do not put secrets or raw customer data into the script boundary.
1.3 Guided Practice
Draw data and authority flows. Identify which components can read credentials, load artifacts, alter policy, route requests, and persist decisions.
1.4 Common Mistakes
Avoid vague ownership, a script capable of arbitrary persistence, hidden network calls, or an optional model presented as policy authority.
1.5 Hands-On Lab
- Write the exact schemas, invalid-input policy, permitted operations, and non-goals.
- Assign responsibility by component or role, not assumed individual names.
- Build threat/control/test rows for tampering, disclosure, resource abuse, and denied authority.
- Choose an isolated synthetic-data test environment and acceptance gates.
Deliverable: Stage implementation or design, contract, fixture evidence, and unresolved items. Do not advance a failed mandatory contract as passed.
1.6 Review Questions
What remains exclusively under host control? Why must optional ML not redefine policy? Which trust boundaries need negative tests?
1.7 Applied Challenge
Have a second engineer reconstruct the architecture from the brief and identify one untested failure boundary.
Lesson Summary
Begin with contracts and authority boundaries before choosing deployment mechanisms.
Lesson status: Draft complete; ready for review.