|
# Phase 2: ๋ฒค์น๋งํฌ ๋ฌธ์ ํ์ด ์์คํ
์๋ฃ |
|
|
|
## โ
๊ตฌํ๋ ์ปดํฌ๋ํธ |
|
|
|
### 1. BenchmarkProblemLoader |
|
- **ํ์ผ**: `absolute_zero_reasoner/testtime/benchmark_loader.py` |
|
- **๊ธฐ๋ฅ**: |
|
- HumanEval+, MBPP+ ๋ฌธ์ ๋ก๋ฉ |
|
- ํ
์คํธ ์ผ์ด์ค ์ถ์ถ (assert ๋ฌธ ํ์ฑ) |
|
- ์๋ฃจ์
๊ฒ์ฆ (๊ตฌ๋ฌธ + ์คํ) |
|
- ๋ฐฐ์น ๋ก๋ฉ ๋ฐ ํต๊ณ ์ ๋ณด ์ ๊ณต |
|
- **๊ธฐ๋ฐ**: ๊ธฐ์กด `load_humaneval_problem` ํจ์ ํ์ฅ |
|
|
|
### 2. InitialSolutionGenerator |
|
- **ํ์ผ**: `absolute_zero_reasoner/testtime/solution_generator.py` |
|
- **๊ธฐ๋ฅ**: |
|
- AZR ์คํ์ผ ๋ชจ๋ธ ๋ก๋ฉ (flash attention, gradient checkpointing) |
|
- Greedy ์์ฑ (AZR evaluation๊ณผ ๋์ผ) |
|
- ํจ์ ์ ์ ์๋ ๋ณต๊ตฌ |
|
- ๋์ฒด ์๋ฃจ์
์์ฑ (๋ฌธ์ ๋ณ ํ
ํ๋ฆฟ) |
|
- **๊ธฐ๋ฐ**: ๊ธฐ์กด `generate_initial_solution` ํจ์ ํด๋์คํ |
|
|
|
### 3. TestTimeLogger |
|
- **ํ์ผ**: `absolute_zero_reasoner/testtime/logger.py` |
|
- **๊ธฐ๋ฅ**: |
|
- ์๊ตฌ์ฌํญ 1: ๋ฒค์น๋งํฌ ๋ฌธ์ + LLM ๋ต๋ณ + ์ ๋ต ์ฌ๋ถ |
|
- ์๊ตฌ์ฌํญ 2: IPO ์ถ์ถ + ํ์คํฌ ์์ฑ ๋ก๊ทธ |
|
- ์๊ตฌ์ฌํญ 3: ํ์คํฌ ์ ํ๋ + reward ๋ก๊ทธ |
|
- ์๊ตฌ์ฌํญ 4: VeRL ํ์ต ์งํ ๋ก๊ทธ |
|
- JSON ํํ ๊ตฌ์กฐํ๋ ๋ก๊ทธ ์ ์ฅ |
|
|
|
### 4. ์ค์ ์์คํ
|
|
- **ํ์ผ**: `absolute_zero_reasoner/testtime/config.py` |
|
- **ํด๋์ค**: `TestTimeConfig`, `BenchmarkConfig` |
|
- **๊ธฐ๋ฅ**: AZR ํธํ + TestTime ํนํ ์ค์ |
|
|
|
## ๐งช ํ
์คํธ ๊ฒฐ๊ณผ |
|
|
|
### ๊ธฐ๋ณธ ๊ธฐ๋ฅ ํ
์คํธ (โ
3/3 ํต๊ณผ) |
|
``` |
|
Configuration: โ
PASS |
|
Logger: โ
PASS |
|
BenchmarkLoader: โ
PASS |
|
``` |
|
|
|
### ๊ฒ์ฆ๋ ๊ธฐ๋ฅ |
|
- โ
MBPP ๋ฌธ์ ๋ก๋ฉ (Mbpp/2 ์ฑ๊ณต) |
|
- โ
๋ฌธ์ ํต๊ณ (378๊ฐ ๋ฌธ์ ํ์ธ) |
|
- โ
๋ก๊น
์์คํ
(5๊ฐ ์นดํ
๊ณ ๋ฆฌ) |
|
- โ
์ค์ ๊ด๋ฆฌ (AZR ํธํ) |
|
|
|
## ๐ ์์ฑ๋ ๊ตฌ์กฐ |
|
|
|
``` |
|
TestTime-RLVR-v2/absolute_zero_reasoner/testtime/ |
|
โโโ __init__.py # ํจํค์ง ์ด๊ธฐํ |
|
โโโ config.py # ์ค์ ํด๋์ค |
|
โโโ benchmark_loader.py # ๋ฒค์น๋งํฌ ๋ก๋ |
|
โโโ solution_generator.py # ์๋ฃจ์
์์ฑ๊ธฐ |
|
โโโ logger.py # ๋ก๊น
์์คํ
|
|
``` |
|
|
|
## ๐๏ธ ์ ๋ฆฌ๋ ํญ๋ชฉ |
|
|
|
- โ
Python ์บ์ ํ์ผ (`__pycache__`, `*.pyc`) ์ญ์ |
|
- โ
๋ถํ์ํ ์ํฌํธ ์ ๋ฆฌ (์์ง ๊ตฌํ๋์ง ์์ ์ปดํฌ๋ํธ ์ฃผ์ ์ฒ๋ฆฌ) |
|
- โ
ํ
์คํธ ํ์ผ์ `/tmp/azr/`์ ์์ ์ ์ฅ |
|
|
|
## ๐ฏ ๋ค์ ๋จ๊ณ (Phase 3) |
|
|
|
Phase 3์์ ๊ตฌํํ **IPO Triple ์ถ์ถ ์์คํ
**: |
|
|
|
1. **IPOTripleExtractor** - AZR Python Executor ๊ธฐ๋ฐ IPO ์ถ์ถ |
|
2. **TripleValidator** - ์ถ์ถ๋ ํธ๋ฆฌํ ๊ฒ์ฆ |
|
3. **AZR ์ฐ๋** - `utils/code_utils/python_executor.py` ํ์ฉ |
|
|
|
### AZR ์ปดํฌ๋ํธ ํ์ฉ ๊ณํ |
|
- `absolute_zero_reasoner/utils/code_utils/python_executor.py` - ์ฝ๋ ์คํ |
|
- `absolute_zero_reasoner/trainer/ppo/azr_ray_trainer.py:641-655` - IPO ์์ฑ ๋ก์ง |
|
- `absolute_zero_reasoner/rewards/reward_managers.py:220-233` - ๊ฒ์ฆ ๋ก์ง |
|
|
|
--- |
|
**์์ฑ ์ผ์**: 2025-07-16 |
|
**์ํ**: โ
์๋ฃ |
|
**ํ
์คํธ**: โ
ํต๊ณผ (3/3) |