Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Select an option

  • Save guersam/feddb780ede0a19d5752281b7d7298b2 to your computer and use it in GitHub Desktop.

Select an option

Save guersam/feddb780ede0a19d5752281b7d7298b2 to your computer and use it in GitHub Desktop.
Reading Methodologies for Software Plan Review in Agentic Pair Programming

에이전틱 페어 프로그래밍에서 소프트웨어 설계 문서 리뷰를 위한 읽기 방법론

1. 서론

소프트웨어 설계 문서 — 아키텍처 문서, RFC, 기능 명세서, API 설계서 — 는 엔지니어링 팀이 생산하는 산출물 중 가장 밀도가 높습니다. 이러한 문서는 학술 논문, 법률 계약서, 안전 명세서와 구조적 특성을 공유합니다. 계층적 의존성, 암묵적 가정, 오해로 인한 높은 비용, 그리고 한 번 읽고 여러 번 실행하는 경향이 그것입니다.

구조적 읽기 방법론은 이러한 특성을 다루기 위해 수십 년간 발전해 왔습니다. SQ3R은 1940년대 군사 훈련을 위해 개발되었고, Fagan Inspection은 1976년 IBM에서 도입되었으며, Perspective-Based Reading은 1990년대 NASA 연구에서 탄생했습니다. 각 방법론은 복잡한 문서에서 의미를 추출하고, 빈틈을 찾아내며, 실행 가능한 판단을 도출하는 체계를 담고 있습니다.

에이전틱 LLM(대규모 언어 모델)은 이제 이러한 설계 문서를 리뷰하는 페어 프로그래밍 파트너로 활용되고 있습니다. 그러나 "이 설계를 리뷰해 줘"나 "어떻게 생각해?"같은 비구조적 프롬프팅은 피상적이고, 아첨적(sycophantic)이거나, 모드가 혼합된 응답을 유발합니다. LLM은 저자의 프레이밍에 동의하고, 그럴듯하지만 일반적인 관찰을 생성하며, 리뷰를 진정으로 가치 있게 만드는 구조적이거나 적대적인 통찰을 도출하지 못합니다.

이 보고서는 에이전틱 LLM의 소프트웨어 설계 문서 리뷰에 단문 프롬프트 트리거로 적용했을 때의 효과를 기준으로 13가지 확립된 읽기 및 리뷰 방법론을 평가합니다. 각 방법론은 LLM 적합도, 리스크 프로파일, 프롬프트 압축성, 커버리지, 산출물 가치의 다섯 가지 차원에서 평가됩니다. 보고서의 결론부에서는 순위별 추천 목록과 일상적인 엔지니어링 활용에 적합한 트리거 문장 후보를 제시합니다.


2. 리뷰와 관련된 LLM 행동 특성

방법론을 평가하기에 앞서, 프롬프팅을 통해 적용한 방법론의 성패를 좌우하는 LLM 행동 특성을 먼저 파악해야 합니다.

2.1 강점

페르소나 민감성. LLM은 역할 부여에 강하게 반응합니다. "리뷰해 줘"라고 포괄적으로 요청하는 것과, 특정 관점(테스터, 공격자, 회의적인 아키텍트)을 부여하는 것은 의미 있게 다른 결과를 만들어 냅니다. 명시적 역할이나 관점을 부여하는 방법론은 이 강점을 직접 활용합니다.

반사실적 추론. LLM은 "만약 ~라면?" 시나리오를 생성하고, 실패 경로를 탐색하며, 입력에 기술되지 않은 상태에 대해 추론할 수 있습니다. "무엇이 잘못될 수 있는가?" 또는 "무엇이 빠져 있는가?"를 묻는 방법론은 이 능력에 잘 부합합니다.

체계적 순회. 구조화된 체크리스트나 순회할 카테고리 집합이 주어지면, LLM은 각 항목을 체계적으로 검토합니다. 명시적 열거가 주어질 때 완전성을 지향하는 것은 LLM의 자연스러운 경향입니다.

질문 생성. LLM은 문서로부터 탐색적 질문을 생성하는 데 뛰어납니다. 답변 주장보다 질문 형성을 중심으로 설계된 방법론은 이 행동에 잘 매핑됩니다.

2.2 실패 모드

아첨 편향(Sycophancy). LLM은 RLHF(인간 피드백 기반 강화 학습)를 통해 인간 평가자가 선호하는 응답을 생성하도록 학습되며, 이는 사용자의 프레이밍에 동의하는 체계적 편향을 만들어 냅니다. SycEval 벤치마크를 활용한 연구에 따르면 프론티어 모델 전반에서 약 58%의 사례에서 아첨 행동이 관찰되었으며, 맥락과 무관하게 약 78.5%의 높은 지속률을 보였습니다. 설계 문서 리뷰 맥락에서 이는 가정을 검증하는 대신 그대로 수용하는 형태로 나타납니다.

거짓 양성(False Positives). "문제를 찾아라"라고 지시하면, LLM은 설계가 건전하더라도 그럴듯한 문제를 생성합니다. 이는 지시 추종 최적화의 결과입니다. 모델은 "문제를 찾아라"를 실제로 문제가 있을 때만 산출하라는 조건부 요청이 아니라, 문제 형태의 출력을 생성하라는 지시로 해석합니다.

폐쇄 세계 추론(Closed-World Reasoning). LLM은 제공된 문서를 관련 정보의 전체 범위로 취급합니다. 명시적으로 프롬프팅하지 않는 한 "여기에 언급되지 않은 것은 무엇인가?" 또는 "어떤 외부 제약이 존재할 수 있는가?"라고 자발적으로 묻는 경우가 거의 없습니다. 소프트웨어 설계 문서에서 가장 치명적인 결함 범주인 누락이 탐지되지 않는 이유가 바로 이것입니다.

역할 혼합(Role Conflation). "이 설계를 정확성 측면에서 리뷰하고, 개선 사항도 제안하고, 구현도 도와줘"같은 복합 지시를 받으면, LLM은 모드를 혼합합니다. 비평자와 협력자 사이를 오가며 양쪽 모두의 역할이 약해집니다. 한 번에 하나의 관여 모드를 강제하는 방법론은 이 실패를 완화합니다.


3. 방법론 카탈로그

이 섹션에서는 평가 대상 각 방법론의 기원, 핵심 원칙, 구조적 메커니즘을 기술합니다.

3.1 SQ3R (Survey, Question, Read, Recite, Review)

Francis Robinson이 1940년대 군사 훈련을 위해 개발한 방법론입니다. 읽기 과정을 다섯 단계로 구성합니다: 문서 구조를 훑어보고(survey), 읽기 전에 질문을 생성하며(question), 답을 찾으며 능동적으로 읽고(read), 발견한 내용을 복기하고(recite), 종합적으로 검토합니다(review). 핵심 통찰은 질문 생성이 읽기에 선행할 때 이해도가 극적으로 향상된다는 것입니다.

3.2 PQ4R (Preview, Question, Read, Reflect, Recite, Review)

1972년 Thomas와 Robinson이 도입한 SQ3R의 확장입니다. 읽기와 복기 사이에 성찰(reflect) 단계를 추가하여, 새로운 정보를 기존 지식과 명시적으로 연결하도록 합니다. 이해와 기억 유지를 동시에 강조합니다.

3.3 Fagan Inspection

1976년 IBM의 Michael Fagan이 도입한 공식적인 역할 기반 그룹 검사 프로세스입니다. 정의된 진입/퇴출 기준, 구분된 단계(계획, 개요, 준비, 검사 회의, 재작업, 후속 조치), 특정 참여자 역할(중재자, 저자, 검사자, 독자)을 갖추고 있습니다. 초기 단계에 적용할 경우 결함 전파 비용을 10~100배 줄이는 것으로 실증되었습니다.

3.4 체크리스트 기반 읽기 (Checklist-Based Reading, CBR)

리뷰어가 알려진 결함 유형, 품질 속성, 관심 사항의 사전 정의된 체크리스트를 따르는 소프트웨어 검사 기법입니다. 산업계에서 널리 채택되었으며, 효과는 체크리스트의 품질에 크게 좌우됩니다. 연구 조사에 따르면 117개 이상의 공개된 검사 체크리스트가 카탈로그화되어 있습니다.

3.5 관점 기반 읽기 (Perspective-Based Reading, PBR)

메릴랜드 대학에서 개발하고 1990년대 NASA 고다드 우주비행센터에서 검증한 방법론입니다. 각 검사자가 특정 이해관계자 관점(사용자, 설계자, 테스터)에서 맞춤형 시나리오를 사용하여 문서를 읽습니다. 서로 다른 검사자가 다른 관점을 맡아 관점별 커버리지를 확보합니다. 임의적 읽기보다 체계적이고 범용 체크리스트보다 집중적인 방법론으로 설계되었습니다.

3.6 Six Thinking Hats (여섯 가지 사고 모자)

1985년 Edward de Bono가 체계화한 방법론입니다. 여섯 가지 고유한 사고 모드를 순환하며 그룹 사고를 구조화하며, 각 모드는 색상으로 구분된 모자로 표현됩니다: White(사실과 데이터), Red(감정과 직관), Black(비판적 판단), Yellow(낙관과 이점), Green(창의적 대안), Blue(프로세스 관리). 모든 참여자가 동시에 같은 모드를 취하는 병렬적 사고를 강제하여 서로 다른 사고 스타일 간의 비생산적 충돌을 방지합니다.

3.7 사전 부검 분석 (Pre-Mortem Analysis)

Gary Klein이 개발한 방법론입니다. 사후 부검(post-mortem)이 사후에 실패 원인을 분석하는 것과 달리, Pre-Mortem은 프로젝트가 이미 실패했다고 가정하고 그럴듯한 원인을 역추적하도록 요청합니다. 낙관 편향과 우려 제기에 대한 사회적 압력을 극복하기 위해 설계되었습니다.

3.8 ATDD 스타일 리뷰 (Acceptance Test-Driven Development)

인수 테스트 주도 개발 방법론에서 차용한 접근법입니다. 리뷰어가 테스트 가능한 인수 기준을 도출한다는 명시적 목표를 가지고 설계 문서를 읽습니다. 구체적이고 검증 가능한 테스트로 표현할 수 없는 요구사항은 명세 부족으로 표시됩니다.

3.9 HAZOP (Hazard and Operability Study, 위험성 및 운전성 분석)

1960~70년대 화학 공정 산업에서 개발되었습니다. 시스템 설계의 각 파라미터에 가이드워드(NO, MORE, LESS, REVERSE, OTHER THAN, PART OF, AS WELL AS)를 체계적으로 적용하여 의도된 운영으로부터의 이탈을 식별합니다. 다학제 팀과 확정된 시스템 설계가 필요합니다.

3.10 STPA (System-Theoretic Process Analysis)

MIT의 Nancy Leveson이 STAMP 프레임워크의 일환으로 개발한 방법론입니다. 시스템을 계층적 제어 구조로 모델링하고, 불안전한 제어 행위가 어떻게 발생할 수 있는지를 분석합니다. 이때 구성 요소의 고장뿐 아니라 결함 있는 요구사항, 설계 오류, 불안전한 상호작용도 분석 대상에 포함합니다. 전통적 방법론(FMEA, HAZOP)이 놓치는 소프트웨어 관련 및 상호작용 관련 위험을 발견하는 것으로 실증되었습니다.

3.11 IRAC (Issue, Rule, Application, Conclusion)

법률 분석의 표준 프레임워크로, 로스쿨과 법률 실무에서 사용됩니다. 먼저 법적 쟁점을 식별하고, 적용 가능한 규칙을 진술하며, 규칙을 구체적 사실에 적용한 뒤, 결론을 제시하는 순서로 분석을 구조화합니다. 핵심 원칙은 쟁점 식별과 규칙 적용의 분리입니다.

3.12 FMEA (Failure Mode and Effects Analysis, 고장 모드 및 영향 분석)

상향식 신뢰성 분석 기법입니다. 각 구성 요소에 대해 가능한 모든 고장 모드를 열거하고, 각 고장이 시스템에 미치는 영향을 파악하며, 심각도와 확률을 평가하고, 탐지 메커니즘을 식별합니다. 제조, 항공우주, 자동차 산업에서 널리 사용됩니다.

3.13 Devil's Advocate / Red Team Review (악마의 대변인 / 레드팀 리뷰)

단일 방법론이 아니라 적대적 리뷰 관행의 집합입니다. 리뷰어에게 결함 발견, 가정 도전, 설계에 대한 반론의 역할이 명시적으로 부여됩니다. 군사 정보 분석, 정책 검토, 보안 평가에서 활용됩니다.


4. 비교 평가

4.1 평가 차원

각 방법론은 다섯 가지 차원에서 평가됩니다:

  • LLM 적합도(LLM Fit) — 방법론이 LLM의 강점(페르소나 민감성, 반사실적 추론, 체계적 순회, 질문 생성)을 얼마나 잘 활용하는가. High / Medium / Low 등급.
  • 리스크 프로파일(Risk Profile) — 방법론이 어떤 LLM 실패 모드(아첨, 거짓 양성, 폐쇄 세계 추론, 역할 혼합)에 취약하며, 그 심각도는 어느 수준인가. Low Risk / Medium Risk / High Risk 등급.
  • 프롬프트 압축성(Prompt Compressibility) — 핵심 원칙을 잃지 않으면서 단일 트리거 문장으로 얼마나 간결하게 표현할 수 있는가. High / Medium / Low 등급.
  • 커버리지(Coverage) — 어떤 리뷰 공백을 다루는가. 코드: S = 이해관계자 관심사, T = 테스트 가능성, F = 실패 모드, C = 완전성, N = 일관성, A = 가정.
  • 산출물 가치(Artefact Value) — 리뷰 자체 이상의 유용한 부산물을 생성하는가. High / Medium / Low 등급(산출물 유형 명시).

4.2 비교표

방법론 LLM Fit 주요 리스크 리스크 심각도 프롬프트 압축성 Coverage 산출물 가치 주요 산출물
SQ3R Medium 역할 혼합 Medium Medium C, A Low 질문 목록
PQ4R Medium 역할 혼합 Medium Low C, A Low 질문, 성찰 내용
Fagan Inspection Low N/A (프로세스 의존) Low Low C, N, F Medium 결함 로그
CBR High 거짓 양성 High High C, N, T, F Medium 체크리스트 결과
PBR High 아첨 (부분적) Medium High S, T, F, A High 다관점 발견 사항
Six Thinking Hats High 역할 혼합 Medium Medium S, F, A, C Medium 구조화된 관찰
Pre-Mortem High 거짓 양성 Medium High F, A, S High 리스크 로그, 실패 시나리오
ATDD-Style High 폐쇄 세계 추론 Medium High T, C, N High 인수 기준
HAZOP High 거짓 양성 Medium Medium F, C, N High 이탈 기록부
STPA Medium 폐쇄 세계 추론 High Low F, S, A, N High 제어 구조, 불안전 행위
IRAC High 아첨 Low High A, N, C Medium 쟁점-해결 쌍
FMEA High 거짓 양성 High Medium F, C High 고장 모드 기록부
Devil's Advocate High 거짓 양성 High High F, A, S Low 반론 목록

4.3 차원별 분석

LLM 적합도가 가장 높은 방법론: CBR, PBR, Pre-Mortem, ATDD-Style Review, IRAC, Devil's Advocate가 모두 High로 평가됩니다. 이들은 공통적으로 LLM에게 지시 추종 모델이 처리하기 적합한 구체적이고 제한된 역할이나 작업 구조를 부여합니다. PBR과 Six Thinking Hats는 특히 페르소나 민감성을, CBR과 FMEA는 체계적 순회를 활용합니다.

리스크가 가장 낮은 방법론: IRAC는 전반적으로 가장 낮은 리스크 프로파일을 보입니다. 쟁점을 식별하고, 적용할 원칙을 진술하며, 적용한 뒤 결론을 내리는 구조가 아첨에 저항하는 자기 완결적 추론 체인을 자연스럽게 만들어 내기 때문입니다. 모델은 규칙을 적용하기 전에 반드시 쟁점을 식별해야 하며, 이는 표면적 검증이 아닌 문서와의 실질적 관여를 강제합니다. Fagan Inspection은 리스크가 낮지만 LLM 적합도도 낮은데, 그 가치가 단일 LLM이 복제할 수 없는 다인 프로세스 역학에서 나오기 때문입니다.

프롬프트 압축성이 가장 높은 방법론: Pre-Mortem, ATDD-Style Review, IRAC, Devil's Advocate, CBR, PBR은 모두 단일 문장으로 효과적으로 표현할 수 있습니다. SQ3R, PQ4R, STPA는 그 가치가 순차적 단계 전환에서 나오므로 단일 문장으로는 강제할 수 없어 압축이 어렵습니다.

커버리지가 가장 넓은 방법론: PBR과 STPA는 구조적으로 시스템을 다각도에서 검토하도록 설계되어 가장 넓은 커버리지를 제공합니다. 다만 STPA의 커버리지 이점은 LLM 맥락에서의 낮은 프롬프트 압축성으로 상쇄됩니다.

산출물 가치가 가장 높은 방법론: Pre-Mortem(리스크 로그, 실패 시나리오), ATDD-Style Review(인수 기준), HAZOP(이탈 기록부), STPA(제어 구조, 불안전 제어 행위)는 모두 리뷰 자체를 넘어서는 가치 있는 산출물을 생성합니다. ATDD-Style Review는 특히 주목할 만한데, 인수 기준을 구현 및 테스트 워크플로에서 직접 소비할 수 있기 때문입니다.


5. LLM 실패 모드별 취약성 분석

5.1 아첨 취약성

아첨에 가장 취약한 방법론은 LLM을 비판적 태도로 구조적으로 강제하지 않는 것들입니다. SQ3R과 PQ4R은 질문 생성 단계에서 LLM이 설계 문서 자체의 프레이밍에 근거하여 긍정적으로 답변하는 질문을 만들어 낼 수 있어 중간 수준으로 취약합니다. Six Thinking Hats는 LLM이 Black Hat(비판적 판단)을 Yellow Hat(낙관)의 약한 형태로 축소시킬 경우 취약해집니다.

아첨에 구조적으로 저항하는 방법론으로는 Pre-Mortem(프로젝트가 실패했다는 전제가 기본적 긍정 편향을 역전시킴), Devil's Advocate(역할 부여가 명시적으로 반대를 요구함), IRAC(분석 전에 "쟁점"을 식별해야 하므로 기존 주장의 검증이 아닌 잠재적 문제에 대한 관여를 강제함)이 있습니다.

5.2 거짓 양성 취약성

Devil's Advocate와 FMEA가 거짓 양성에 가장 취약합니다. LLM에 설계에 "반론을 제기하라"거나 "모든 고장 모드를 열거하라"고 지시하면, 설계의 실제 품질과 무관하게 실패 형태의 출력을 생성합니다. 이는 리뷰의 신호 대 잡음비를 떨어뜨립니다.

ATDD-Style Review는 "무엇이 잘못되었는가?"가 아니라 "이것을 테스트할 수 있는가?"를 묻기 때문에 거짓 양성에 구조적으로 저항합니다. 출력은 구체적 테스트이거나 특정 공백이며, 둘 다 검증 가능합니다.

5.3 폐쇄 세계 추론 취약성

ATDD-Style Review와 CBR은 문서에 존재하는 내용의 테스트 가능성에 LLM의 주의를 집중시키므로, 부재하는 내용에 대해서는 취약합니다. STPA는 시스템 수준 상호작용을 모델링하여 이를 해결하도록 설계되었으나, LLM이 더 넓은 시스템 환경을 관찰할 수 없는 LLM 맥락에서는 폐쇄 세계 취약성이 오히려 증가합니다.

PBR은 LLM에 자연스럽게 문서에서 다루지 않는 관심사를 떠올리게 하는 관점(예: 최종 사용자, 운영 엔지니어)을 채택하도록 강제함으로써 폐쇄 세계 추론을 부분적으로 완화합니다.

5.4 역할 혼합 취약성

SQ3R, PQ4R, Six Thinking Hats는 단일 응답 내에서 LLM이 모드 간 전환(질문, 읽기, 성찰 또는 모자 교체)을 해야 하므로 역할 혼합에 가장 취약합니다. 강력한 구조적 강제가 없으면 LLM은 이러한 모드를 순차적으로 실행하기보다 혼합합니다.

Pre-Mortem, Devil's Advocate, ATDD-Style Review 같은 단일 모드 방법론은 전체 리뷰에 대해 하나의 명확한 모드를 부여하므로 역할 혼합에 저항합니다.


6. 순위별 추천 목록

비교 평가를 기반으로, 에이전틱 페어 프로그래밍 활용에서의 전반적 효과에 따라 다음 여섯 가지 방법론을 순위별로 제시합니다. LLM 적합도, 리스크 완화, 프롬프트 압축성, 산출물 가치에 가중치를 부여했습니다.

순위 1: Pre-Mortem Analysis (사전 부검 분석)

1위인 이유. Pre-Mortem은 실패를 전제함으로써 LLM의 아첨 편향을 직접 역전시킵니다. "이것이 이미 실패했다고 가정하라"는 지시는 "좋아 보입니다"와 구조적으로 양립할 수 없으며, 모델은 반드시 실패 원인을 생성해야 합니다. 반사실적 추론(LLM의 핵심 강점)을 활용하고, 단일 문장으로 압축 가능하며, 높은 가치의 산출물(구체적 실패 시나리오가 포함된 리스크 로그)을 생성합니다. 주요 취약점인 거짓 양성은 전제의 구체성으로 완화됩니다. "왜 실패했는가?"라고 묻는 것은 "무엇이 잘못될 수 있는가?"보다 더 근거 있는 응답을 유도하는데, 모델이 단절된 목록이 아닌 인과적 서사를 구성해야 하기 때문입니다.

트리거 문장 후보:

"Assume this plan was implemented exactly as written and failed badly in production — write a post-mortem identifying the most likely root causes, with specific references to gaps or assumptions in this document."

"이 설계가 작성된 그대로 구현되었고 프로덕션에서 심각하게 실패했다고 가정하라 — 이 문서의 빈틈이나 가정을 구체적으로 참조하면서, 가장 가능성 높은 근본 원인을 식별하는 포스트모템을 작성하라."

이 문장이 효과적인 이유. "작성된 그대로 구현되었고"라는 구절은 LLM이 설계 자체가 아닌 구현을 탓하는 것을 방지합니다. "프로덕션에서 심각하게 실패했다"는 구체적 시나리오를 설정합니다. "가장 가능성 높은 근본 원인"은 낮은 확률의 실패에 대한 총망라적 열거를 억제합니다. "구체적으로 참조"는 범용적 리스크 범주가 아닌 실제 문서에 출력을 고정시킵니다.

순위 2: ATDD-Style Review (ATDD 스타일 리뷰)

2위인 이유. ATDD-Style Review는 가장 즉시 활용 가능한 산출물인 인수 기준을 생성합니다. 출력이 검증 가능하므로 거짓 양성에 구조적으로 저항합니다 — 구체적 테스트를 작성할 수 있거나 없거나 둘 중 하나입니다. 요구사항에 대해 테스트를 작성하는 행위 자체가 불가피하게 명세 부족을 드러내므로 아첨에도 저항합니다. 약점은 폐쇄 세계 추론으로, 부재하는 내용의 완전성보다 존재하는 내용의 테스트 가능성에 집중하지만, Pre-Mortem과 조합하여 보완할 수 있습니다.

트리거 문장 후보:

"For each requirement and design decision in this plan, write a concrete acceptance test that would verify correct implementation — flag anything that cannot be tested as underspecified."

"이 설계의 각 요구사항과 설계 결정에 대해 올바른 구현을 검증할 구체적 인수 테스트를 작성하라 — 테스트할 수 없는 항목은 명세 부족으로 표시하라."

이 문장이 효과적인 이유. "각 요구사항과 설계 결정"은 체계적 순회를 촉발합니다. "구체적 인수 테스트"는 모호함 대신 구체성을 강제합니다. "테스트할 수 없는 항목은 표시하라"는 LLM에 적대적 태도를 요구하지 않으면서도 기본 모드를 검증에서 공백 탐지로 전환합니다.

순위 3: Perspective-Based Reading (관점 기반 읽기)

3위인 이유. PBR은 가장 강력하고 신뢰할 수 있는 LLM 행동 특성인 페르소나 민감성을 활용합니다. 특정 이해관계자 관점을 부여함으로써 각 관점에서 구조적으로 다른 리뷰를 생성하여, 단일 관점 방법론이 놓치는 커버리지 폭을 다룹니다. 모델이 각 이해관계자에게 자연스러운 관심사를 고려하도록 강제하여 폐쇄 세계 추론을 부분적으로 완화합니다. 약점은 단일 프롬프트에서 다관점 지시가 역할 혼합을 초래할 수 있다는 점이지만, 관점을 명시적으로 지정하고 관점별 구조화된 출력을 요청하면 완화됩니다.

트리거 문장 후보:

"Review this plan separately from three perspectives — the end user who will interact with it, the on-call engineer who will debug it at 3AM, and the attacker who will try to exploit it — and give distinct findings for each."

"세 가지 관점에서 이 설계를 각각 리뷰하라 — 이 시스템과 상호작용할 최종 사용자, 새벽 3시에 이것을 디버깅할 온콜 엔지니어, 이것을 악용하려는 공격자 — 그리고 각 관점에 대해 별개의 발견 사항을 제시하라."

이 문장이 효과적인 이유. 세 가지 명명된 관점은 페르소나 민감성을 활성화할 만큼 구체적이면서도 모드 혼합을 방지할 만큼 적은 수입니다. "각각"과 "별개의 발견 사항"은 구조적 분리를 강제합니다. 선택된 세 관점(사용자, 운영자, 공격자)은 소프트웨어 설계 문서 리뷰에서 가장 흔히 누락되는 이해관계자 범주를 다룹니다.

순위 4: IRAC (소프트웨어 리뷰 적용)

4위인 이유. IRAC의 원칙 — 쟁점을 식별하고, 원칙을 진술하고, 적용하고, 결론을 내린다 — 은 아첨에 구조적으로 저항하는 엄밀하고 자기 완결적인 분석을 생성합니다. 분석하기 전에 먼저 쟁점을 명확히 해야 하므로, 무엇이 잘못되었을 수 있는지에 대한 관여 없이는 "정확해 보입니다"로 기본 설정할 수 없습니다. "법적 규칙"을 "엔지니어링 원칙 또는 모범 사례"로 대체하여 소프트웨어 리뷰에 적용하면, 근거 있고 참조 가능한 분석을 생성합니다. 약점은 커버리지 폭의 한계로, 식별한 쟁점은 분석하지만 포괄적 식별을 구조적으로 보장하지는 않습니다.

트리거 문장 후보:

"For each significant design choice in this plan, state the engineering principle or constraint it should satisfy, analyse whether the plan meets it, and conclude with a clear pass/fail/insufficient-information verdict."

"이 설계의 각 주요 설계 결정에 대해, 충족해야 할 엔지니어링 원칙 또는 제약 조건을 명시하고, 설계가 이를 충족하는지 분석하며, 명확한 통과/실패/정보 부족 판정으로 결론짓라."

이 문장이 효과적인 이유. "각 주요 설계 결정"은 순회를 촉발합니다. "충족해야 할 엔지니어링 원칙 또는 제약 조건"은 LLM이 평가 기준을 평가 전에 명확히 하도록 강제하며, 이것이 핵심적인 아첨 방지 메커니즘입니다. "통과/실패/정보 부족"은 흔히 누락되는 "판단할 수 없음" 범주를 포함하는 구조화된 출력을 제공합니다.

순위 5: HAZOP (가이드워드 리뷰 적용)

5위인 이유. HAZOP의 가이드워드 접근법(NO, MORE, LESS, REVERSE, OTHER THAN, PART OF, AS WELL AS)은 공정 엔지니어링에서 소프트웨어 설계로 적용할 때 체계적 이탈 분석을 위한 강력한 트리거입니다. 데이터 흐름, API 파라미터, 상태 전이, 제어 경로에 적용하면 설계 문서 작성자가 고려하지 않았을 가능성이 높은 시나리오를 기계적으로 생성합니다. 체계적 순회와 반사실적 추론을 모두 활용합니다. 약점은 거짓 양성 생성으로, 모든 파라미터에 가이드워드를 적용하면 가치가 낮은 이탈이 다수 생성되지만, LLM에 그럴듯한 심각도로 필터링하도록 지시하면 완화됩니다.

트리거 문장 후보:

"Apply HAZOP-style guideword analysis to the key data flows and state transitions in this plan: for each, consider what happens if the value is missing, duplicated, reversed, delayed, partial, or comes from an unexpected source — report only deviations that would cause user-visible or data-integrity impact."

"이 설계의 핵심 데이터 흐름과 상태 전이에 HAZOP 스타일 가이드워드 분석을 적용하라: 각 항목에 대해 값이 누락, 중복, 반전, 지연, 불완전하거나 예상치 못한 출처에서 올 경우 무슨 일이 발생하는지 고려하라 — 사용자에게 보이는 영향이나 데이터 무결성 영향을 초래할 이탈만 보고하라."

이 문장이 효과적인 이유. 가이드워드가 문장에 직접 내장되어 HAZOP에 대한 사전 지식이 필요 없습니다. "핵심 데이터 흐름과 상태 전이"는 분석 범위를 고가치 대상으로 한정합니다. "사용자에게 보이는 영향이나 데이터 무결성 영향을 초래할 이탈만"은 거짓 양성을 줄이는 심각도 필터를 적용합니다.

순위 6: Devil's Advocate (구조화된 악마의 대변인)

6위인 이유. Devil's Advocate는 페르소나 민감성과 반사실적 추론을 활용하며 단일 문장으로 쉽게 압축됩니다. Pre-Mortem보다 낮은 순위인 이유는 Pre-Mortem의 근거 부여(grounding) 구조적 메커니즘이 없기 때문입니다. 비구조적인 "이것에 반론을 제기하라"는 지시는 품질이 천차만별인 반론 목록을 만들어 내는 반면, Pre-Mortem의 "왜 실패했는지 설명하라"는 인과적 서사를 생성합니다. 그러나 LLM에 증거와 함께 가장 강력한 단일 반론을 식별하도록 요구하는 구조화된 변형은 효과적입니다.

트리거 문장 후보:

"Play devil's advocate: identify the single weakest design decision in this plan, explain why it will cause the most damage, and propose a specific alternative — do not list multiple concerns, commit to one."

"악마의 대변인 역할을 하라: 이 설계에서 가장 취약한 단일 설계 결정을 식별하고, 왜 그것이 가장 큰 피해를 초래할지 설명하며, 구체적 대안을 제시하라 — 여러 우려 사항을 나열하지 말고 하나에 집중하라."

이 문장이 효과적인 이유. "가장 취약한 단일"은 우선순위화를 강제하고 모호한 우려의 산탄식 나열을 방지합니다. "왜 가장 큰 피해를 초래할지 설명하라"는 단순 주장이 아닌 인과적 논증을 요구합니다. "구체적 대안을 제시하라"는 건설적 관여를 강제합니다. "여러 우려 사항을 나열하지 말고 하나에 집중하라"는 명시적 모드 혼합 방지 지시입니다.


7. 단일 패스 리뷰를 위한 최적 순서

단일 리뷰 세션에서 방법론을 결합하려는 엔지니어를 위해, 다음 세 문장 시퀀스는 상호 보완적인 공백을 다루며 철저함과 효율성의 균형을 맞춥니다:

문장 1 (커버리지와 산출물): ATDD-Style 트리거를 사용하여 인수 기준을 생성하고 명세 부족을 드러냅니다. 가장 높은 가치의 산출물을 생성하고, 설계가 무엇을 하겠다고 주장하는지를 확립합니다.

문장 2 (적대적 심층 분석): Pre-Mortem 트리거를 사용하여 인수 기준이 포착하지 못하는 실패 시나리오를 식별합니다 — 시스템적 리스크, 아키텍처 약점, 잘못된 가정.

문장 3 (이해관계자 폭): PBR 트리거를 사용하여 설계 문서 자체의 프레이밍에 대표되지 않는 이해관계자에 특화된 관심사를 포착합니다.

이 시퀀스는 건설적 분석(무엇이 참이어야 하는가?)에서 적대적 분석(무엇이 잘못될 것인가?)으로, 다시 이해관계자 분석(누가 대표되지 않는가?)으로 이동하여 중복 없이 상호 보완적인 공백을 다룹니다.


8. LLM 활용에 비추천하는 방법론

8.1 SQ3R과 PQ4R

인간 인지 프로세스 — 구체적으로 인간 기억의 인코딩 및 인출 역학 — 을 위해 설계된 방법론입니다. 그 가치는 독자가 수동적이 아닌 능동적으로 읽도록 강제하는 데서 나옵니다. LLM에는 수동적 읽기 모드가 없으며 전체 입력을 동시에 처리합니다. 순차적 단계 구조(훑어보기, 질문, 읽기, 복기, 검토)를 단일 프롬프트에서 의미 있게 강제할 수 없고, 시도하면 역할 혼합이 발생합니다. 질문 생성 단계는 단독으로는 가치 있지만 ATDD-Style이나 IRAC 접근법으로 더 잘 포착됩니다.

8.2 Fagan Inspection

Fagan Inspection의 가치는 회의 중 중재자, 저자, 검사자 간 상호작용이라는 다인 프로세스 역학에서 나옵니다. 단일 LLM은 이러한 역학을 복제할 수 없습니다. Fagan의 체크리스트와 역할 구성 요소는 각각 CBR과 PBR로 더 잘 다룰 수 있습니다. 프로세스 오버헤드(진입/퇴출 기준, 재작업 추적, 후속 조치)에는 의미 있는 LLM 대응물이 없습니다.

8.3 STPA

STPA는 평가 대상 중 시스템 수준 위험 — 특히 구성 요소 고장이 아닌 불안전한 상호작용에서 발생하는 위험 — 을 발견하는 데 가장 강력한 방법론입니다. 그러나 프롬프트 압축성이 가장 낮은 방법론이기도 합니다. 의미 있는 STPA를 수행하려면 계층적 제어 구조를 구축하고, 제어 행위를 식별하며, 각 제어 행위가 어떻게 불안전할 수 있는지를 판단하고, 인과적 시나리오를 식별하는 다단계 분석 프로세스가 필요한데, 이를 단일 문장으로 촉발할 수 없습니다. STPA는 다회차 LLM 상호작용을 활용하는 전용 안전 분석 워크플로에 권장되며, 단문 설계 문서 리뷰 트리거로는 적합하지 않습니다.

8.4 FMEA

FMEA의 상향식 구성 요소별 열거는 LLM의 체계적 순회에 적합하지만 거짓 양성에 매우 취약합니다. 의미 있는 확률 추정치(LLM이 제공할 수 없는)가 없으면, FMEA는 발생 가능성과 무관하게 상상 가능한 모든 고장 모드의 나열로 퇴화합니다. HAZOP의 가이드워드 접근법은 이탈 기반 프레이밍을 통해 더 나은 잡음 필터링으로 유사한 커버리지를 제공합니다.


9. 전이 잠재력이 있는 덜 알려진 방법론

9.1 IRAC과 CREAC (법률 분석)

이미 추천 목록에 포함되어 있습니다. 법률 분석 전통의 쟁점 식별과 규칙 적용과 결론의 분리 원칙은 소프트웨어 설계 문서 리뷰에 놀라울 정도로 잘 매핑됩니다. CREAC 변형(Conclusion, Rule, Explanation, Application, Conclusion)은 특히 흥미로운데, 결론을 먼저 제시한 뒤 정당화하도록 요구하기 때문입니다. 이를 "각 설계 결정에 대해 판정을 먼저 제시한 뒤 정당화하라"로 적용하면, LLM이 핵심 발견을 모호한 문단 속에 묻어버리는 것을 방지할 수 있습니다.

9.2 SBAR (Situation, Background, Assessment, Recommendation)

의료 분야에서 환자 인계 시 오류를 줄이기 위해 개발된 임상 커뮤니케이션 방법론입니다. SBAR은 커뮤니케이션을 현재 상황 진술, 관련 배경 제공, 임상 평가 제시, 구체적 권고안 제안으로 구조화합니다. 소프트웨어 설계 문서 리뷰의 출력 형식 규율로 잘 전이됩니다: "각 우려 사항에 대해 상황(설계가 명시하는 내용), 배경(관련 원칙), 평가(원칙 충족 여부), 권고안(변경 사항)을 진술하라."

9.3 수술 안전 체크리스트 (WHO 모델)

WHO 수술 안전 체크리스트는 세 가지 시간적 관문 — 마취 전, 절개 전, 수술실 퇴실 전 — 을 사용하며, 각 관문마다 소수의 핵심 확인 항목이 있습니다. 전이 가능한 통찰은 "관문" 개념입니다: 소프트웨어 설계를 세 시간적 관문(구현 시작 전, 첫 통합 전, 프로덕션 배포 전)에서 각기 다른 핵심 질문으로 리뷰하는 것입니다. 이는 단일 프롬프트 기법보다는 프로세스 설계에 가깝지만, 시간 범위가 한정된 핵심 질문이라는 개념은 트리거 문장 설계에 참고할 수 있습니다.

9.4 적대적 협력 (Adversarial Collaboration, 학술)

심리학과 경제학에서, 가설에 대해 의견이 다른 연구자들이 양측 모두가 결정적이라고 동의하는 실험을 함께 설계하는 관행입니다. 설계 문서 리뷰로 전이하면 다음과 같은 개념이 됩니다: "이 설계에서, 틀릴 경우 전체 설계를 무효화할 가정을 식별하라 — 그리고 이견을 해소할 증거를 명시하라." 이는 LLM에 약점을 식별하는 것뿐 아니라 해결 기준까지 명시하도록 강제하는 Devil's Advocate의 변형입니다.


10. 트리거 문장 요약 참조

순위 방법론 트리거 문장 (영문 원문) 트리거 문장 (한국어)
1 Pre-Mortem "Assume this plan was implemented exactly as written and failed badly in production — write a post-mortem identifying the most likely root causes, with specific references to gaps or assumptions in this document." "이 설계가 작성된 그대로 구현되었고 프로덕션에서 심각하게 실패했다고 가정하라 — 이 문서의 빈틈이나 가정을 구체적으로 참조하면서, 가장 가능성 높은 근본 원인을 식별하는 포스트모템을 작성하라."
2 ATDD-Style "For each requirement and design decision in this plan, write a concrete acceptance test that would verify correct implementation — flag anything that cannot be tested as underspecified." "이 설계의 각 요구사항과 설계 결정에 대해 올바른 구현을 검증할 구체적 인수 테스트를 작성하라 — 테스트할 수 없는 항목은 명세 부족으로 표시하라."
3 PBR "Review this plan separately from three perspectives — the end user who will interact with it, the on-call engineer who will debug it at 3AM, and the attacker who will try to exploit it — and give distinct findings for each." "세 가지 관점에서 이 설계를 각각 리뷰하라 — 이 시스템과 상호작용할 최종 사용자, 새벽 3시에 이것을 디버깅할 온콜 엔지니어, 이것을 악용하려는 공격자 — 그리고 각 관점에 대해 별개의 발견 사항을 제시하라."
4 IRAC "For each significant design choice in this plan, state the engineering principle or constraint it should satisfy, analyse whether the plan meets it, and conclude with a clear pass/fail/insufficient-information verdict." "이 설계의 각 주요 설계 결정에 대해, 충족해야 할 엔지니어링 원칙 또는 제약 조건을 명시하고, 설계가 이를 충족하는지 분석하며, 명확한 통과/실패/정보 부족 판정으로 결론짓라."
5 HAZOP "Apply HAZOP-style guideword analysis to the key data flows and state transitions in this plan: for each, consider what happens if the value is missing, duplicated, reversed, delayed, partial, or comes from an unexpected source — report only deviations that would cause user-visible or data-integrity impact." "이 설계의 핵심 데이터 흐름과 상태 전이에 HAZOP 스타일 가이드워드 분석을 적용하라: 각 항목에 대해 값이 누락, 중복, 반전, 지연, 불완전하거나 예상치 못한 출처에서 올 경우 무슨 일이 발생하는지 고려하라 — 사용자에게 보이는 영향이나 데이터 무결성 영향을 초래할 이탈만 보고하라."
6 Devil's Advocate "Play devil's advocate: identify the single weakest design decision in this plan, explain why it will cause the most damage, and propose a specific alternative — do not list multiple concerns, commit to one." "악마의 대변인 역할을 하라: 이 설계에서 가장 취약한 단일 설계 결정을 식별하고, 왜 그것이 가장 큰 피해를 초래할지 설명하며, 구체적 대안을 제시하라 — 여러 우려 사항을 나열하지 말고 하나에 집중하라."

11. 결론

에이전틱 LLM 설계 문서 리뷰에 가장 효과적인 읽기 방법론은 세 가지 구조적 속성을 공유합니다. 첫째, 아첨적 동의와 구조적으로 양립할 수 없는 특정 관여 모드를 부여합니다 — Pre-Mortem은 실패를 전제하고, ATDD는 테스트 가능성을 요구하며, IRAC는 분석 전에 쟁점 식별을 요구합니다. 둘째, 정성적 의견이 아닌 구체적이고 검증 가능한 산출물을 생성합니다 — 인수 기준, 실패 시나리오, 통과/실패 판정, 이탈 기록부. 셋째, 사용자에게 사전 방법론 지식을 요구하지 않는 단일 문장으로 압축됩니다.

LLM 맥락에서 성능이 저조한 방법론은 인간 인지 한계를 위해 설계된 것(SQ3R, PQ4R), 다인 프로세스 역학에 의존하는 것(Fagan), 또는 깊은 다단계 분석 워크플로를 필요로 하는 것(STPA)입니다. 이는 원래 맥락에서의 가치를 부정하는 것이 아니라, 에이전틱 LLM 상호작용의 고유한 강점과 제약을 반영합니다.

일상적 엔지니어링 활용에서, Pre-Mortem 트리거 문장 하나만으로도 가장 치명적인 리뷰 공백 — 인간 저자와 아첨적 LLM 모두가 기존 설계를 도전하기보다 검증하려는 경향 — 을 다룹니다. ATDD-Style 트리거를 추가하면 모호한 요구사항을 테스트 가능한 명제로 전환하는 두 번째로 높은 가치의 개선을 제공합니다. 특별한 지식도 다단계 프롬프팅도 필요 없는 이 두 문장의 조합은, 무시할 수 있는 추가 비용으로 비구조적 프롬프팅보다 실질적으로 더 나은 리뷰를 제공합니다.

Reading Methodologies for Software Plan Review in Agentic Pair Programming

1. Introduction

Software plans — architecture documents, RFCs, feature specifications, and API designs — are among the densest artefacts an engineering team produces. They share structural properties with academic texts, legal contracts, and safety specifications: layered dependencies, implicit assumptions, high cost of misunderstanding, and a tendency to be read once and acted on many times.

Structured reading methodologies have existed for decades to address exactly these properties. SQ3R was developed in the 1940s for military personnel; Fagan Inspection was introduced at IBM in 1976; Perspective-Based Reading emerged from NASA research in the 1990s. Each encodes a discipline for extracting meaning, finding gaps, and producing actionable judgement from complex documents.

Agentic LLMs are now used as pair programming partners for reviewing such plans. However, unstructured prompting — "review this plan" or "what do you think?" — reliably triggers shallow, sycophantic, or mode-blended responses. The LLM agrees with the author's framing, produces plausible-sounding but generic observations, and fails to surface the structural or adversarial insights that make a review genuinely valuable.

This report evaluates thirteen established reading and review methodologies for their effectiveness when adapted as single-sentence prompt triggers for agentic LLM review of software plans. Each methodology is assessed against five dimensions: LLM fit, risk profile, prompt compressibility, coverage, and artefact value. The report concludes with a ranked shortlist and candidate trigger sentences suitable for everyday engineering use.


2. LLM Behavioural Characteristics Relevant to Review

Before evaluating methodologies, it is necessary to identify the LLM behavioural traits that determine whether a methodology will succeed or fail when applied through prompting.

2.1 Strengths

Persona sensitivity. LLMs respond strongly to role assignment. Asking an LLM to adopt a specific perspective (tester, attacker, sceptical architect) produces meaningfully different outputs from asking it to "review" generically. Methodologies that assign explicit roles or viewpoints exploit this strength directly.

Counterfactual reasoning. LLMs are capable of generating "what if" scenarios, exploring failure paths, and reasoning about states that are not described in the input. Methodologies that ask "what could go wrong?" or "what is missing?" align with this capability.

Exhaustive traversal. Given a structured checklist or a set of categories to traverse, LLMs will systematically walk through each item. They are naturally inclined toward completeness when given an explicit enumeration to follow.

Question generation. LLMs are effective at generating probing questions from a document. Methodologies built around question-formulation rather than answer-assertion map well onto this behaviour.

2.2 Failure Modes

Sycophancy. LLMs are trained via RLHF to produce responses that human evaluators prefer, which creates a systematic bias toward agreement with the user's framing. Research using the SycEval benchmark found sycophantic behaviour in approximately 58% of cases across frontier models, with high persistence rates of around 78.5% regardless of context. In a plan review context, this manifests as validating the plan's assumptions rather than interrogating them.

False positives. When asked to "find problems," LLMs will generate plausible-sounding issues even when the plan is sound. This is a consequence of the instruction-following optimisation: the model interprets "find problems" as a directive to produce problem-shaped outputs, not as a conditional request to produce them only if they exist.

Closed-world reasoning. LLMs treat the provided document as the complete universe of relevant information. They rarely ask "what is not mentioned here?" or "what external constraints might exist?" unless explicitly prompted to do so. This means omissions — often the most critical category of defect in a software plan — go undetected.

Role conflation (mode-blending). When given a compound instruction ("review this plan for correctness, suggest improvements, and also help me implement it"), LLMs blend modes. They oscillate between critic and collaborator, weakening both roles. Methodologies that enforce a single mode of engagement at a time mitigate this failure.


3. Methodology Catalogue

This section describes each methodology evaluated, including its origin, core discipline, and structural mechanism.

3.1 SQ3R (Survey, Question, Read, Recite, Review)

Developed by Francis Robinson in the 1940s for military training. The methodology structures reading into five sequential phases: survey the document's structure, generate questions before reading, read actively for answers, recite findings, and review for synthesis. Its core insight is that comprehension improves dramatically when reading is preceded by question generation.

3.2 PQ4R (Preview, Question, Read, Reflect, Recite, Review)

An extension of SQ3R introduced in 1972 by Thomas and Robinson. Adds a reflection phase between reading and recitation, where the reader explicitly connects new information to existing knowledge. Emphasises both comprehension and retention.

3.3 Fagan Inspection

Introduced by Michael Fagan at IBM in 1976. A formal, role-based group inspection process with defined entry/exit criteria, distinct phases (planning, overview, preparation, inspection meeting, rework, follow-up), and specific participant roles (moderator, author, inspector, reader). Empirically shown to reduce defect propagation costs by 10-100x when applied early.

3.4 Checklist-Based Reading (CBR)

A software inspection technique where reviewers follow a predefined checklist of known defect types, quality attributes, or concerns. Widely adopted in industry. Effectiveness depends heavily on checklist quality. Research surveys have catalogued over 117 published inspection checklists.

3.5 Perspective-Based Reading (PBR)

Developed at the University of Maryland and validated at NASA's Goddard Space Flight Center in the 1990s. Each inspector reads the document from a specific stakeholder perspective (user, designer, tester) using a tailored scenario. Different inspectors adopt different perspectives, ensuring coverage across viewpoints. Designed to be more systematic than ad hoc reading and more focused than generic checklists.

3.6 Six Thinking Hats

Formulated by Edward de Bono in 1985. Structures group thinking by cycling through six distinct modes, each represented by a coloured hat: White (facts and data), Red (feelings and intuition), Black (critical judgement), Yellow (optimism and benefits), Green (creative alternatives), and Blue (process management). Enforces parallel thinking — all participants adopt the same mode simultaneously — to prevent unproductive conflict between different thinking styles.

3.7 Pre-Mortem Analysis

Developed by Gary Klein. Unlike a post-mortem, which analyses why something failed after the fact, a pre-mortem asks participants to assume the project has already failed and work backward to identify plausible causes. Designed to overcome optimism bias and social pressure against raising concerns.

3.8 ATDD-Style Review (Acceptance Test-Driven Development)

Adapted from acceptance test-driven development methodology. The reviewer reads the plan with the explicit goal of deriving testable acceptance criteria. Any requirement that cannot be expressed as a concrete, verifiable test is flagged as underspecified.

3.9 HAZOP (Hazard and Operability Study)

Developed in the chemical process industry in the 1960s-70s. Uses guidewords (NO, MORE, LESS, REVERSE, OTHER THAN, PART OF, AS WELL AS) applied systematically to each parameter of a system design to identify deviations from intended operation. Requires a multidisciplinary team and a firm system design.

3.10 STPA (System-Theoretic Process Analysis)

Developed by Nancy Leveson at MIT as part of the STAMP framework. Models systems as hierarchical control structures and analyses how unsafe control actions can arise — not just from component failures, but from flawed requirements, design errors, and unsafe interactions. Empirically shown to find hazards that traditional methods like FMEA and HAZOP miss, particularly software-related and interaction-related hazards.

3.11 IRAC (Issue, Rule, Application, Conclusion)

The standard framework for legal analysis, used in law schools and legal practice. Structures analysis by first identifying the legal issue, then stating the applicable rule, then applying the rule to the specific facts, and finally stating the conclusion. Its core discipline is the separation of issue identification from rule application.

3.12 FMEA (Failure Mode and Effects Analysis)

A bottom-up reliability analysis technique. For each component, the analyst enumerates all possible failure modes, determines the effect of each failure on the system, assesses severity and probability, and identifies detection mechanisms. Widely used in manufacturing, aerospace, and automotive engineering.

3.13 Devil's Advocate / Red Team Review

Not a single methodology but a family of adversarial review practices. The reviewer is explicitly assigned the role of finding flaws, challenging assumptions, and arguing against the plan. Used in military intelligence analysis, policy review, and security assessment.


4. Comparative Evaluation

4.1 Evaluation Dimensions

Each methodology is evaluated against five dimensions:

  • LLM Fit — How well the methodology exploits LLM strengths (persona sensitivity, counterfactual reasoning, exhaustive traversal, question generation). Rated High / Medium / Low.
  • Risk Profile — Which LLM failure modes (sycophancy, false positives, closed-world reasoning, role conflation) the methodology is vulnerable to, and how severely. Rated Low Risk / Medium Risk / High Risk.
  • Prompt Compressibility — How concisely the methodology can be expressed as a single triggering sentence without losing its core discipline. Rated High / Medium / Low.
  • Coverage — Which review gaps it addresses. Coded as: S = Stakeholder concerns, T = Testability, F = Failure modes, C = Completeness, N = Consistency, A = Assumptions.
  • Artefact Value — Whether it produces useful byproducts beyond the review itself. Rated High / Medium / Low, with artefact type noted.

4.2 Comparative Table

Methodology LLM Fit Primary Risk Risk Severity Prompt Compress. Coverage Artefact Value Key Artefacts
SQ3R Medium Role conflation Medium Medium C, A Low Questions list
PQ4R Medium Role conflation Medium Low C, A Low Questions, reflections
Fagan Inspection Low N/A (process-dependent) Low Low C, N, F Medium Defect log
Checklist-Based Reading High False positives High High C, N, T, F Medium Checklist results
Perspective-Based Reading High Sycophancy (partial) Medium High S, T, F, A High Multi-perspective findings
Six Thinking Hats High Role conflation Medium Medium S, F, A, C Medium Structured observations
Pre-Mortem High False positives Medium High F, A, S High Risk log, failure scenarios
ATDD-Style Review High Closed-world reasoning Medium High T, C, N High Acceptance criteria
HAZOP High False positives Medium Medium F, C, N High Deviation register
STPA Medium Closed-world reasoning High Low F, S, A, N High Control structure, unsafe actions
IRAC High Sycophancy Low High A, N, C Medium Issue-resolution pairs
FMEA High False positives High Medium F, C High Failure mode register
Devil's Advocate High False positives High High F, A, S Low Objections list

4.3 Dimension Analysis

Highest LLM Fit: Checklist-Based Reading, Perspective-Based Reading, Pre-Mortem, ATDD-Style Review, IRAC, and Devil's Advocate all score high. These methodologies share a common property: they give the LLM a specific, constrained role or task structure that aligns with how instruction-following models process directives. PBR and Six Thinking Hats particularly exploit persona sensitivity, while CBR and FMEA exploit exhaustive traversal.

Lowest Risk: IRAC has the lowest overall risk profile because its structure (identify the issue, state the applicable principle, apply it, conclude) naturally produces self-contained reasoning chains that resist sycophancy — the model must identify an issue before it can apply a rule to it, which forces genuine engagement with the document rather than surface-level validation. Fagan Inspection has low risk but also low LLM fit because its value derives from multi-person process dynamics that a single LLM cannot replicate.

Highest Prompt Compressibility: Pre-Mortem, ATDD-Style Review, IRAC, Devil's Advocate, CBR, and PBR can all be effectively expressed in a single sentence. SQ3R, PQ4R, and STPA are difficult to compress because their value comes from sequential phase transitions that a single sentence cannot enforce.

Broadest Coverage: PBR and STPA provide the broadest coverage because they are structurally designed to examine a system from multiple angles. However, STPA's coverage advantage is offset by its low prompt compressibility in the LLM context.

Highest Artefact Value: Pre-Mortem (risk logs, failure scenarios), ATDD-Style Review (acceptance criteria), HAZOP (deviation registers), and STPA (control structures, unsafe control actions) all produce artefacts that have value beyond the review itself. ATDD-Style Review is particularly notable because acceptance criteria can be directly consumed by implementation and testing workflows.


5. Vulnerability Analysis by LLM Failure Mode

5.1 Sycophancy Vulnerability

Methodologies most vulnerable to sycophancy are those that do not structurally force the LLM into a critical stance. SQ3R and PQ4R are moderately vulnerable because their question-generation phase may produce questions that the LLM then answers affirmatively based on the plan's own framing. Six Thinking Hats is vulnerable if the LLM collapses the Black Hat (critical judgement) into a weak form of the Yellow Hat (optimism).

Methodologies that structurally resist sycophancy include Pre-Mortem (the premise is that the project has failed, which inverts the default affirmation bias), Devil's Advocate (the role assignment explicitly requires disagreement), and IRAC (the requirement to identify an "issue" before analysis forces engagement with potential problems rather than validation of existing claims).

5.2 False Positive Vulnerability

Devil's Advocate and FMEA are most vulnerable to false positives. When an LLM is told to "argue against" a plan or to "enumerate all failure modes," it will generate failure-shaped outputs regardless of the plan's actual quality. This produces noise that degrades the signal-to-noise ratio of the review.

ATDD-Style Review is structurally resistant to false positives because it asks "can this be tested?" rather than "what is wrong?" — the output is either a concrete test or a specific gap, both of which are verifiable.

5.3 Closed-World Reasoning Vulnerability

ATDD-Style Review and CBR are vulnerable because they focus the LLM's attention on what is present in the document rather than what is absent. STPA is designed to address this by modelling system-level interactions, but its closed-world vulnerability increases in the LLM context because the model cannot observe the broader system environment.

PBR partially mitigates closed-world reasoning by forcing the LLM to adopt perspectives (e.g., end user, operations engineer) that naturally surface questions about concerns not addressed in the document.

5.4 Role Conflation Vulnerability

SQ3R, PQ4R, and Six Thinking Hats are most vulnerable to role conflation because they require the LLM to transition between modes (questioning, reading, reflecting, or switching hats) within a single response. Without strong structural enforcement, the LLM blends these modes rather than executing them sequentially.

Single-mode methodologies like Pre-Mortem, Devil's Advocate, and ATDD-Style Review are resistant to role conflation because they assign a single, clear mode for the entire review.


6. Ranked Shortlist

Based on the comparative evaluation, the following six methodologies are ranked by their overall effectiveness for agentic pair programming use, weighting LLM fit, risk mitigation, prompt compressibility, and artefact value.

Rank 1: Pre-Mortem Analysis

Why it ranks first. Pre-Mortem directly inverts the LLM's sycophancy bias by presupposing failure. The instruction "assume this has already failed" is structurally incompatible with "this looks good" — the model must generate failure explanations. It exploits counterfactual reasoning (a core LLM strength), compresses to a single sentence, and produces a high-value artefact (a risk log with specific failure scenarios). Its primary vulnerability — false positives — is mitigated by the specificity of the presupposition: asking "why did this fail?" produces more grounded responses than asking "what could go wrong?" because the model must construct a causal narrative rather than a disconnected list.

Candidate trigger sentence:

"Assume this plan was implemented exactly as written and failed badly in production — write a post-mortem identifying the most likely root causes, with specific references to gaps or assumptions in this document."

Why this sentence works. The phrase "implemented exactly as written" prevents the LLM from blaming implementation rather than the plan itself. "Failed badly in production" sets a concrete scenario. "Most likely root causes" discourages exhaustive enumeration of low-probability failures. "Specific references" anchors the output to the actual document rather than generic risk categories.

Rank 2: ATDD-Style Review

Why it ranks second. ATDD-Style Review produces the most immediately actionable artefact: a set of acceptance criteria. It is structurally resistant to false positives because its output is verifiable — either a concrete test can be formulated or it cannot. It resists sycophancy because the act of writing a test against a requirement inevitably surfaces underspecification. Its weakness is closed-world reasoning — it focuses on testability of what is present rather than completeness of what is absent — but this is addressable by combining it with Pre-Mortem.

Candidate trigger sentence:

"For each requirement and design decision in this plan, write a concrete acceptance test that would verify correct implementation — flag anything that cannot be tested as underspecified."

Why this sentence works. "Each requirement and design decision" triggers exhaustive traversal. "Concrete acceptance test" forces specificity over vagueness. "Flag anything that cannot be tested" inverts the default mode from validation to gap-detection without requiring the LLM to adopt an adversarial stance.

Rank 3: Perspective-Based Reading

Why it ranks third. PBR exploits persona sensitivity, the strongest and most reliable LLM behavioural characteristic. By assigning specific stakeholder perspectives, it produces structurally different reviews from each viewpoint, addressing the coverage breadth that single-perspective methods miss. It partially mitigates closed-world reasoning by forcing the model to consider concerns natural to each stakeholder. Its weakness is that multi-perspective instructions in a single prompt risk role conflation; however, specifying the perspectives explicitly and requesting structured output by perspective mitigates this.

Candidate trigger sentence:

"Review this plan separately from three perspectives — the end user who will interact with it, the on-call engineer who will debug it at 3AM, and the attacker who will try to exploit it — and give distinct findings for each."

Why this sentence works. Three named perspectives are specific enough to activate persona sensitivity but few enough to prevent mode-blending. "Separately" and "distinct findings for each" enforce structural separation. The three perspectives chosen (user, operator, adversary) cover the three most commonly missed stakeholder categories in software plan reviews.

Rank 4: IRAC (Adapted for Software Review)

Why it ranks fourth. IRAC's discipline — identify the issue, state the principle, apply it, conclude — produces rigorous, self-contained analysis that is structurally resistant to sycophancy. The requirement to first articulate an issue before analysing it means the LLM cannot default to "this looks correct" without first engaging with what might be incorrect. When adapted for software review (replacing "legal rule" with "engineering principle or best practice"), it produces well-reasoned, referenceable analysis. Its weakness is limited coverage breadth — it analyses issues it identifies but does not structurally ensure comprehensive identification.

Candidate trigger sentence:

"For each significant design choice in this plan, state the engineering principle or constraint it should satisfy, analyse whether the plan meets it, and conclude with a clear pass/fail/insufficient-information verdict."

Why this sentence works. "Each significant design choice" triggers traversal. "Engineering principle or constraint it should satisfy" forces the LLM to articulate the evaluation criterion before evaluating — this is the key anti-sycophancy mechanism. "Pass/fail/insufficient-information" provides a structured output that includes the often-missing "I can't tell" category.

Rank 5: HAZOP (Adapted as Guideword Review)

Why it ranks fifth. HAZOP's guideword approach (NO, MORE, LESS, REVERSE, OTHER THAN, PART OF, AS WELL AS) is a powerful trigger for systematic deviation analysis when adapted from process engineering to software design. Applied to data flows, API parameters, state transitions, and control paths, guidewords mechanically generate scenarios the plan author likely did not consider. This exploits both exhaustive traversal and counterfactual reasoning. Its weakness is false positive generation — applying guidewords to every parameter produces many low-value deviations — but this is mitigated by instructing the LLM to filter for plausible severity.

Candidate trigger sentence:

"Apply HAZOP-style guideword analysis to the key data flows and state transitions in this plan: for each, consider what happens if the value is missing, duplicated, reversed, delayed, partial, or comes from an unexpected source — report only deviations that would cause user-visible or data-integrity impact."

Why this sentence works. The guidewords are embedded directly in the sentence, requiring no prior knowledge of HAZOP. "Key data flows and state transitions" scopes the analysis to high-value targets. "Report only deviations that would cause user-visible or data-integrity impact" applies a severity filter that reduces false positives.

Rank 6: Devil's Advocate (Structured)

Why it ranks sixth. Devil's Advocate exploits persona sensitivity and counterfactual reasoning and compresses trivially to a single sentence. It ranks lower than Pre-Mortem because it lacks Pre-Mortem's structural mechanism for grounding — an unstructured "argue against this" instruction produces a list of objections of wildly varying quality, while Pre-Mortem's "explain why it failed" produces causal narratives. However, a structured variant that requires the LLM to identify its strongest single objection, with evidence, is effective.

Candidate trigger sentence:

"Play devil's advocate: identify the single weakest design decision in this plan, explain why it will cause the most damage, and propose a specific alternative — do not list multiple concerns, commit to one."

Why this sentence works. "Single weakest" forces prioritisation and prevents a shotgun list of vague concerns. "Explain why it will cause the most damage" requires a causal argument rather than an assertion. "Propose a specific alternative" forces constructive engagement. "Do not list multiple concerns, commit to one" is an explicit anti-mode-blending instruction.


7. Optimal Sequencing for Single-Pass Review

For engineers who want to combine methodologies in a single review session, the following three-sentence sequence balances thoroughness with efficiency by addressing complementary gaps:

Sentence 1 (Coverage and Artefacts): Use the ATDD-Style trigger to generate acceptance criteria and surface underspecification. This produces the highest-value artefact and establishes what the plan claims to do.

Sentence 2 (Adversarial Depth): Use the Pre-Mortem trigger to identify failure scenarios that the acceptance criteria would not catch — systemic risks, architectural weaknesses, and incorrect assumptions.

Sentence 3 (Stakeholder Breadth): Use the Perspective-Based Reading trigger to catch concerns specific to stakeholders whose interests are not represented in the plan's own framing.

This sequence moves from constructive analysis (what should be true?) to adversarial analysis (what will go wrong?) to stakeholder analysis (who is not represented?), covering complementary gaps without redundancy.


8. Methodologies Not Recommended for LLM Use

8.1 SQ3R and PQ4R

These methodologies are designed for human cognitive processes — specifically, the encoding and retrieval dynamics of human memory. Their value derives from forcing the reader to engage actively rather than passively. LLMs do not have passive reading modes; they process the entire input simultaneously. The sequential phase structure (survey, question, read, recite, review) cannot be meaningfully enforced in a single prompt, and attempting to do so produces role conflation. The question-generation step is valuable in isolation but is better captured by ATDD-Style or IRAC approaches.

8.2 Fagan Inspection

Fagan Inspection's value derives from its multi-person process dynamics — the interaction between moderator, author, and inspectors during a meeting. A single LLM cannot replicate these dynamics. The checklist and role components of Fagan are better addressed by CBR and PBR respectively. The process overhead (entry/exit criteria, rework tracking, follow-up) has no meaningful LLM analogue.

8.3 STPA

STPA is the most powerful methodology evaluated for finding system-level hazards, particularly those arising from unsafe interactions rather than component failures. However, it is the least prompt-compressible methodology in the set. Meaningful STPA requires constructing a hierarchical control structure, identifying control actions, determining how each control action could be unsafe, and identifying causal scenarios — a multi-step analytical process that cannot be triggered by a single sentence. STPA is recommended for dedicated safety analysis workflows with multi-turn LLM interaction, not for single-sentence plan review triggers.

8.4 FMEA

FMEA's bottom-up component-by-component enumeration is well-suited to LLM exhaustive traversal but highly vulnerable to false positives. Without meaningful probability estimates (which LLMs cannot provide), FMEA degenerates into an enumeration of all conceivable failure modes regardless of likelihood. HAZOP's guideword approach provides similar coverage with better noise filtering through its deviation-based framing.


9. Lesser-Known Methodologies with Transfer Potential

9.1 IRAC and CREAC (Legal Analysis)

Already included in the shortlist. The legal analysis tradition's discipline of separating issue identification from rule application from conclusion maps remarkably well onto software plan review. The CREAC variant (Conclusion, Rule, Explanation, Application, Conclusion) is particularly interesting because it requires stating the conclusion first, then justifying it — which can be adapted as "state your verdict on each design decision, then justify it" to prevent the LLM from burying critical findings in hedged paragraphs.

9.2 SBAR (Situation, Background, Assessment, Recommendation)

Developed for clinical communication in medicine to reduce errors during patient handoffs. SBAR structures communication as: state the current situation, provide relevant background, give your clinical assessment, and make a specific recommendation. This transfers well to software plan review as a output format discipline: "For each concern, state the situation (what the plan says), the background (what principle it relates to), your assessment (whether it satisfies the principle), and your recommendation (what to change)."

9.3 Surgical Safety Checklist (WHO Model)

The WHO Surgical Safety Checklist uses three temporal gates — before induction, before incision, before leaving the operating room — each with a small number of critical verification items. The transferable insight is the "gate" concept: reviewing a software plan at three temporal gates (before implementation starts, before the first integration, before production deployment) with different critical questions at each gate. This is more of a process design than a single-prompt technique, but the concept of temporally-scoped critical questions can inform trigger sentence design.

9.4 Adversarial Collaboration (Academic)

A practice in psychology and economics where researchers who disagree on a hypothesis design an experiment together that both agree would be decisive. Transferred to plan review, the concept becomes: "Identify the assumption in this plan that, if wrong, would invalidate the entire design — then specify what evidence would resolve the disagreement." This is a variant of Devil's Advocate that forces the LLM to not only identify weaknesses but to specify resolution criteria.


10. Summary Trigger Sentence Reference

Rank Methodology Trigger Sentence
1 Pre-Mortem "Assume this plan was implemented exactly as written and failed badly in production — write a post-mortem identifying the most likely root causes, with specific references to gaps or assumptions in this document."
2 ATDD-Style "For each requirement and design decision in this plan, write a concrete acceptance test that would verify correct implementation — flag anything that cannot be tested as underspecified."
3 Perspective-Based Reading "Review this plan separately from three perspectives — the end user who will interact with it, the on-call engineer who will debug it at 3AM, and the attacker who will try to exploit it — and give distinct findings for each."
4 IRAC (Adapted) "For each significant design choice in this plan, state the engineering principle or constraint it should satisfy, analyse whether the plan meets it, and conclude with a clear pass/fail/insufficient-information verdict."
5 HAZOP (Adapted) "Apply HAZOP-style guideword analysis to the key data flows and state transitions in this plan: for each, consider what happens if the value is missing, duplicated, reversed, delayed, partial, or comes from an unexpected source — report only deviations that would cause user-visible or data-integrity impact."
6 Devil's Advocate "Play devil's advocate: identify the single weakest design decision in this plan, explain why it will cause the most damage, and propose a specific alternative — do not list multiple concerns, commit to one."

11. Conclusion

The most effective reading methodologies for agentic LLM plan review share three structural properties. First, they assign a specific mode of engagement that is structurally incompatible with sycophantic agreement — Pre-Mortem presupposes failure, ATDD demands testability, IRAC demands issue identification before analysis. Second, they produce concrete, verifiable artefacts rather than qualitative opinions — acceptance criteria, failure scenarios, pass/fail verdicts, deviation registers. Third, they compress to a single sentence that requires no prior methodological knowledge from the user.

The methodologies that perform poorly in the LLM context are those designed for human cognitive limitations (SQ3R, PQ4R), multi-person process dynamics (Fagan), or deep multi-step analytical workflows (STPA). This does not diminish their value in their original contexts; it reflects the specific strengths and constraints of agentic LLM interaction.

For everyday engineering use, the Pre-Mortem trigger sentence alone addresses the most critical review gap — the tendency of both human authors and sycophantic LLMs to validate existing plans rather than challenge them. Adding the ATDD-Style trigger produces the second-highest-value improvement by converting vague requirements into testable assertions. The combination of these two sentences, requiring no special knowledge and no multi-step prompting, provides a materially better review than unstructured prompting at negligible additional cost.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment