SuperAPI AI Directory

iterative-academic-writer

Testing & quality

View repository

Updated 10-15 20:04

About this skill

Iterative Academic Writer

This is a skill for writing academic documents through a repetitive quality improvement loop. Structure is designed with academic-planner, quality is evaluated with academic-reviewer, and hallucinations are completely excluded through Fact Checking.

When to Use

Use this skill in the following situations:

  • Writing specific sections of a paper (Introduction, Methods, Results, Discussion, etc.)
  • Writing a research proposal
  • Writing technical documentation
  • Writing review papers/survey papers
  • Any situation requiring academic writing

Workflow Overview

┌───────────────────────────────────────────────────────────────────────────────┐
│                    Iterative Academic Writer                                   │
├───────────────────────────────────────────────────────────────────────────────┤
│                                                                               │
│  Phase 1: 정보 수집 및 Fact Base 구축                                          │
│  ┌─────────────────────────────────────────────────────────────────────────┐  │
│  │  • 사용자 요청 분석 (주제, 범위, 목적)                                    │  │
│  │  • 관련 프로젝트 파일 탐색 (코드, 문서, 결과)                             │  │
│  │  • WebSearch로 관련 논문/자료 검색                                       │  │
│  │  • → Fact Base 구축 (검증 가능한 사실만 기록)                             │  │
│  └─────────────────────────────────────────────────────────────────────────┘  │
│                                      │                                        │
│                                      ▼                                        │
│  Phase 2: 글 구조 계획 (academic-planner 에이전트)                            │
│  ┌─────────────────────────────────────────────────────────────────────────┐  │
│  │  • 전체 문서 구조 설계 (섹션 순서, 각 섹션 핵심 메시지)                    │  │
│  │  • 정의가 필요한 전문 용어 목록 작성                                      │  │
│  │  • 비교-대조가 필요한 개념 쌍 식별                                        │  │
│  │  • 문단 간 논리적 흐름 설계                                               │  │
│  │  • → 문서 Blueprint 출력                                                  │  │
│  └─────────────────────────────────────────────────────────────────────────┘  │
│                                      │                                        │
│                                      ▼                                        │
│  Phase 3: 초안 작성 (Blueprint 기반)                                          │
│  ┌─────────────────────────────────────────────────────────────────────────┐  │
│  │  • Blueprint의 구조를 따라 줄글 형태로 작성                               │  │
│  │  • 모든 전문 용어에 정의 포함                                             │  │
│  │  • 비교-대조 설명 방식 적극 활용                                          │  │
│  │  • 두괄식 구조 준수 (문단 첫 문장 = 핵심 주장)                            │  │
│  └─────────────────────────────────────────────────────────────────────────┘  │
│                                      │                                        │
│                                      ▼                                        │
│  Phase 4: 반복 개선 루프                                                      │
│  ┌─────────────────────────────────────────────────────────────────────────┐  │
│  │                                                                         │  │
│  │    ┌────────────────┐    ┌────────────────┐    ┌────────────────┐      │  │
│  │    │  Academic      │───▶│  Academic      │───▶│  Fact          │      │  │
│  │    │  Writer        │    │  Reviewer      │    │  Checker       │      │  │
│  │    │  (재작성)       │    │  (품질 평가)   │    │  (사실 검증)    │      │  │
│  │    └────────────────┘    └───────┬────────┘    └───────┬────────┘      │  │
│  │           ▲                      │                     │               │  │
│  │           │                      ▼                     ▼               │  │
│  │           │            ┌──────────────────────────────────┐            │  │
│  │           │            │     Issues Found?                │            │  │
│  │           │            │  • 품질 이슈 (Critical/Warning)   │            │  │
│  │           │            │  • Hallucination 발견             │            │  │
│  │           │            └───────────────┬──────────────────┘            │  │
│  │           │                            │                               │  │
│  │           │         Yes                │           No                  │  │
│  │           └────────────────────────────┤                               │  │
│  │                                        ▼                               │  │
│  │                              ┌────────────────┐                        │  │
│  │                              │   Complete!    │                        │  │
│  │                              │  Final Document│                        │  │
│  │                              └────────────────┘                        │  │
│  │                                                                         │  │
│  └─────────────────────────────────────────────────────────────────────────┘  │
│                                                                               │
└───────────────────────────────────────────────────────────────────────────────┘

Phase 1: Information Gathering and Fact Base Construction

Step 1.1: Analyze User Request

• 문서 유형 식별
  - 논문 섹션 (Introduction, Methods, Results, Discussion, Conclusion)
  - 연구 제안서 (Research Proposal)
  - 기술 문서 (Technical Document)
  - 리뷰 논문 (Survey/Review Paper)

• 주제 및 범위 파악
  - 구체적인 연구 주제
  - 다룰 범위와 깊이
  - 제외할 내용

• 목표 독자 확인
  - 해당 분야 전문가
  - 인접 분야 연구자
  - 일반 독자

Step 1.2: Collect Related Materials

• 프로젝트 파일 탐색
  - 코드 파일: 구현 세부사항 확인
  - 결과 파일: 실험 결과, 수치 확인
  - 기존 문서: README, CLAUDE.md 등

• CLAUDE.md 확인
  - 프로젝트 개요
  - 핵심 컴포넌트 설명
  - 기술적 세부사항

• 사용자 제공 자료 검토
  - 참고 논문
  - 데이터
  - 추가 요구사항

Step 1.3: Background Research with WebSearch

• 관련 논문 검색
  - 인용할 핵심 논문 수집
  - 저자, 연도, 제목, 학회/저널 정확히 기록

• 기존 연구 동향 파악
  - 관련 연구 현황
  - 최신 발전 상황

• 기술 용어 정의 확인
  - 표준 정의 수집
  - 분야별 용어 차이 확인

Step 1.4: Build Fact Base

⚠️ CRITICAL: Record only verifiable facts

Fact Base 구조:

✓ Verified Facts:
- "[사실 1]"
  Source: [파일 경로 / 논문 / URL]
  Verified: ✓

- "[사실 2]"
  Source: [파일 경로 / 논문 / URL]
  Verified: ✓

⚠️ Needs Verification:
- "[확인 필요 사실]"
  Claimed Source: [주장된 출처]
  Action: WebSearch 필요

✗ Rejected (Hallucination):
- "[검증 실패 사실]"
  Reason: [실패 이유]

Phase 2: Plan Writing Structure (call academic-planner)

Call academic-planner agent

Task tool 사용:
- subagent_type: "general-purpose"
- prompt: 다음 내용을 포함하여 academic-planner 역할 수행 요청

  "다음 정보를 바탕으로 학술 문서의 Blueprint를 작성해주세요.

  [문서 유형]: {논문 섹션/연구 제안서/기술 문서}
  [주제]: {구체적 주제}
  [수집된 Fact Base]: {검증된 사실 목록}
  [목표 독자]: {독자 유형}

  Blueprint에 포함할 내용:
  1. 전체 구조 (섹션별 핵심 메시지)
  2. 정의가 필요한 전문 용어 목록
  3. 비교-대조가 필요한 개념 쌍
  4. 문단 흐름 (두괄식 첫 문장 초안)"

Confirm after receiving Blueprint

□ 모든 전문 용어가 정의 목록에 포함되었는가?
□ 새로운 방법에 대한 비교-대조가 계획되었는가?
□ 각 문단의 첫 문장이 핵심 주장을 담고 있는가?
□ 문단 간 논리적 연결이 계획되었는가?

Phase 3: Draft Writing (based on Blueprint)

Writing Principles

Follow the Blueprint structure and write in compliance with the following principles:

1. Definition First

Define all technical terms first in the form "X is Y".

✅ 올바른 예시:
"MemGen(Memory Generator)은 latent memory token을 생성하여 LLM의 추론을
보강하는 프레임워크이다. MemGen은 두 개의 핵심 모듈로 구성된다."

❌ 잘못된 예시:
"MemGen을 사용하여 성능을 개선했다." (정의 없이 사용)

2. Compare-Contrast

Explain new approaches in comparison with existing methods.

✅ 올바른 예시:
"기존의 RAG(Retrieval-Augmented Generation)가 외부 데이터베이스를 검색하여
정보를 가져오는 반면, MemGen은 모델 내부에서 압축된 메모리를 생성하여
추론에 활용한다."

❌ 잘못된 예시:
"MemGen은 메모리를 생성한다." (비교 없이 설명)

3. Topic-First Structure

Every paragraph begins with the key claim or conclusion.

✅ 올바른 예시:
"LTPO는 inference 시점에 모델 가중치를 변경하지 않고 latent 표현만을
최적화하는 기법이다. 이 접근 방식은..."

❌ 잘못된 예시:
"최근 연구에서는 여러 방법이 제안되었는데, 그 중 하나가 LTPO이다..."

4. Prose Format

*Do not use bullet points (-, , •) in the body text.

✅ 올바른 예시:
"MemGen은 세 가지 핵심 기능을 제공한다. 첫째, Memory Weaver는 과거 경험을
압축된 latent로 변환한다. 둘째, Memory Trigger는 메모리 삽입 시점을 결정한다.
셋째, LTPO는 inference 시 latent를 최적화한다."

❌ 잘못된 예시:
"MemGen의 핵심 기능:
- Memory Weaver
- Memory Trigger
- LTPO"

5. Minimal Adjectives

Remove unnecessary modifiers and use specific figures when needed.

✅ 올바른 예시:
"실험 결과 87%의 정확도를 달성했으며, 이는 baseline 대비 12%p 향상이다."

❌ 잘못된 예시:
"실험 결과 매우 높은 정확도를 달성했으며, 이는 상당히 큰 향상이다."

금지어: 매우, 상당히, 아주, 굉장히, 크게, 작게 (수치 없이 단독 사용)

6. Beginner Understandability

Readers without background knowledge must be able to understand the text.

• "무엇을" → "왜" → "어떻게" 순서로 설명
• 복잡한 개념은 점진적으로 구축 (쉬운 것 → 어려운 것)
• 모든 전문 용어가 정의되기 전에 사용되지 않음

Phase 4: Iterative Improvement Loop

Step 4.1: Quality Evaluation (call academic-reviewer)

Task tool 사용:
- subagent_type: "general-purpose"
- prompt: academic-reviewer 역할로 다음 문서 평가 요청

  "다음 학술 문서를 평가해주세요.

  [문서 내용]:
  {작성된 초안}

  평가 기준:
  1. 구조: 두괄식, 줄글 형태, 문단 간 흐름
  2. 이해도: 용어 정의, 비교-대조, 초심자 이해 가능성
  3. 간결성: 수식어 최소화, 객관적 표현
  4. 사실성: Hallucination 검사, 인용 정확성

  JSON 형식으로 결과를 반환해주세요."

Step 4.2: Fact Checking (Hallucination Prevention) - CRITICAL

⚠️ HARD CONSTRAINT: Not even a single hallucination is allowed.

4.2.1: Verification Methods by Hallucination Type

Hallucination Type Verification Method Tool
Fabricated paper citations Verify existence and content of the paper WebSearch
Incorrect author/year Check actual paper metadata WebSearch
Exaggerated performance claims Directly cross-check with experiment result files Read tool
Nonexistent concepts Verify existence of the term/technique WebSearch
Incorrect figures/statistics Cross-check with original data Read tool
False causal relationships Verify logical structure Direct analysis

4.2.2: Verification Process

문서의 모든 사실적 주장에 대해:

├─ [논문 인용] → WebSearch로 논문 존재 및 내용 확인
│   예: "Zhang et al. (2024)에 따르면..."
│   검증: 논문 존재 여부, 저자, 연도, 내용 일치 확인
│
├─ [수치 데이터] → 원본 데이터와 대조
│   예: "87% 정확도 달성"
│   검증: results/*.json 또는 원본 논문에서 확인
│
├─ [기술적 주장] → 코드/문서에서 직접 확인
│   예: "Weaver는 8개의 latent를 생성한다"
│   검증: 코드 파일에서 해당 설정 확인
│
└─ [개념 정의] → WebSearch로 표준 정의 확인
    예: "LTPO는 latent를 최적화하는 기법이다"
    검증: 원본 논문 또는 공식 정의 확인

4.2.3: Fact Base Update

Clearly record verification results:

✓ Verified:
- "LTPO lr=0.03" (config.yaml:36)
- "Titans 논문 2025년" (WebSearch: arXiv:2501.00663)

✗ HALLUCINATION DETECTED:
- "99% 정확도 달성" → 실제: 87% (results/exp1.json)
- "Kim et al. (2024)" → WebSearch: 해당 논문 없음

⚠️ Unverifiable:
- "업계 표준 방식" → 출처 필요

4.2.4: Actions upon Discovering Hallucination

  1. Immediately delete or revise the relevant content
  2. Replace with correct information (use only verified facts)
  3. Exclude unverifiable content from the document
  4. Proceed to the next iteration after re-verification

Absolutely prohibited:

  • Mentioning figures without verification ❌
  • Citing papers not read ❌
  • Explaining technical details without confirmation ❌
  • Presenting speculative content as fact ❌

Step 4.3: Check Termination Conditions

Success conditions (all must be met):

Condition Requirement
Critical issues 0건
Hallucination count 0건 (Hard Constraint)
Overall score ≥ 80

If conditions are met: Save the final document and complete If conditions are not met: Proceed to Step 4.4

Step 4.4: Rewrite (based on feedback)

Revise based on academic-reviewer feedback:

1. [Critical Issues 수정]
   - 용어 미정의 → 정의 추가
   - 두괄식 위반 → 문단 첫 문장 수정
   - 비교-대조 누락 → 기존 방식과의 비교 추가

2. [Hallucination 제거]
   - 검증 실패 인용 → 삭제 또는 실제 인용으로 대체
   - 허위 수치 → 검증된 수치로 대체

3. [Warning 개선]
   - 수식어 과다 → 구체적 수치로 대체
   - 주관적 표현 → 객관적 표현으로 수정

4. [흐름 개선]
   - 접속어 추가
   - 문단 간 연결 강화

Step 4.5: Iteration Control

최대 반복 횟수: 5회

IF iteration > 5:
    → 현재 최선 버전 저장
    → 미해결 이슈 사용자에게 보고
    → 수동 개입 요청

Quality Checklist

Before final confirmation, verify the following items:

Category Item Check
Definition Have all technical terms been defined in the form "X is Y"? □
Comparison Has the new approach been compared with existing methods? □
Comprehensibility Can it be understood without background knowledge? □
Conclusion first Does every paragraph begin with its key claim? □
Flow Are the connections between paragraphs and sentences natural? □
Prose Are there no bullet points in the body text? □
Conciseness Are there no unnecessary modifiers? □
Factuality Have all claims been verified? □
Citation Are all citations accurate? □

Progress Reporting

Report progress to the user during execution:

[Phase 1] 정보 수집...
  ✓ 사용자 요청 분석 완료
  ✓ 프로젝트 파일 탐색 완료
  ✓ WebSearch 배경 조사 완료
  ✓ Fact Base 구축 완료 (검증된 사실: N건)

[Phase 2] 글 구조 계획 (academic-planner)...
  ✓ Blueprint 생성 완료
  ✓ 정의 필요 용어: N개
  ✓ 비교-대조 대상: N쌍

[Phase 3] 초안 작성...
  ✓ Blueprint 기반 줄글 작성 완료

[Phase 4-1] 품질 평가 (academic-reviewer)...
  → Critical: N건
  → Hallucination: N건
  → Warning: N건
  → Score: XX/100

[Phase 4-2] Fact Checking...
  → 검증 완료: N/M
  → Hallucination 제거: N건

[Phase 4-3] 재작성...
  ✓ Critical 이슈 수정 완료

[Phase 4-4] 재평가...
  → Critical: 0건
  → Hallucination: 0건
  → Score: XX/100

✅ 완료! 최종 문서 생성

Usage Examples

Example 1: Writing the Methods Section

사용자: "MemGen 프로젝트의 Methods 섹션을 작성해줘"

Claude:
[Phase 1] 정보 수집...
  ✓ memgen/ 디렉토리 분석
  ✓ CLAUDE.md에서 아키텍처 정보 확인
  ✓ WebSearch로 관련 논문 검색

[Phase 2] 글 구조 계획...
  ✓ Blueprint: Overview → Weaver → Trigger → LTPO
  ✓ 정의 필요 용어: 5개

[Phase 3] 초안 작성...

[Phase 4] 반복 개선...
  Iteration 1: Score 72 → Critical 2건 수정
  Iteration 2: Score 85 → Warning 1건 개선

✅ 완료! Score: 88/100

Example 2: Writing the Introduction

사용자: "LLM 중독 연구에 대한 Introduction을 작성해줘"

Claude:
[Phase 1] 정보 수집...
  ✓ llm_addiction/ 프로젝트 분석
  ✓ 실험 결과 파일 확인
  ✓ WebSearch로 관련 심리학/AI 논문 검색

[Phase 2] 글 구조 계획...
  ✓ Blueprint: 배경 → 문제 정의 → 기존 한계 → 기여점

[Phase 3] 초안 작성...

[Phase 4] 반복 개선...

✅ 완료!

Precautions

  1. Write based on the Fact Base: Do not include unverified information in the document
  2. Citation Accuracy: Verify all paper citations with WebSearch before use
  3. Maximum Iteration Limit: Request manual intervention after exceeding 5 iterations
  4. Incremental Improvement: Do not try to perfect everything at once; improve step by step
  5. Reader-Centered: Always write with the target reader's comprehension in mind