Terminal-Bench 2.1terminalRStanCSV
Sample a hierarchical beta-binomial model with RStan
Implement and run the specified hierarchical Bayesian model in RStan, then save reproducible posterior means for alpha and beta.
mcmc-sampling-stan
Normalized profile
What this task asks for
Implement and run the specified hierarchical Bayesian model in RStan, then save reproducible posterior means for alpha and beta. Model y_i as Binomial(n_i, theta_i) and theta_i as Beta(alpha, beta). Use prior proportional to (alpha + beta)^(-5/2). Sample four chains with 100,000 iterations each and seed 1. Write one posterior mean per result file.
Intent
- model training
- systems setup
- data transformation
Work surfaces
- probabilistic model
- sampling pipeline
- posterior estimates
Technology
- RStan 2.32.7
- Stan
- MCMC
- beta-binomial model
Expected artifacts
- /app/hierarchical_model.stan
- /app/analysis.R
- /app/posterior_alpha_mean.txt
- /app/posterior_beta_mean.txt
What makes it difficult
- quantitative performance, accuracy, or resource constraints
- specialized algorithmic or domain reasoning
- cross-language or cross-format integration
- changes span multiple components or interfaces
Published evidence
Model × harness outcomes
Counts are tied to these exact configurations. Harnesses are not treated as equivalent across benchmarks.
- Models
- 13
- Configurations
- 20
- Trials
- 100
Showing 20 of 20 configurations
| Model | Harness | Effort | Result | Passes |
|---|---|---|---|---|
| claude-fable-5anthropic · 2026-06-07 | claude-code2.1.167 | xhigh | All passed | 5/5 |
| claude-fable-5anthropic · 2026-06-05 | terminus-22.0.0 | high | All passed | 5/5 |
| claude-opus-4-7anthropic · 2026-05-01 | claude-code2.1.123 | max | All passed | 5/5 |
| claude-opus-4-7anthropic · 2026-05-01 | terminus-22.0.0 | max | All passed | 5/5 |
| claude-opus-4-8anthropic · 2026-07-09 | claude-code2.1.205 | high | All passed | 5/5 |
| claude-sonnet-5anthropic · 2026-07-09 | claude-code2.1.205 | high | All passed | 5/5 |
| gemini-3-pro-previewgemini · 2026-05-01 | gemini-cli0.40.0 | high | All passed | 5/5 |
| gemini-3-pro-previewgemini · 2026-05-01 | terminus-22.0.0 | high | All passed | 5/5 |
| gemini-3.1-pro-previewgemini · 2026-05-05 | gemini-cli0.40.0 | high | Mixed1 errors | 4/5 |
| gemini-3.1-pro-previewgemini · 2026-05-05 | terminus-22.0.0 | high | Mixed1 errors | 4/5 |
| glm-5.1zai · 2026-05-01 | claude-code2.1.123 | max | Mixed1 errors | 4/5 |
| gpt-5.5openai · 2026-05-01 | codex0.125.0 | xhigh | All passed | 5/5 |
| gpt-5.5openai · 2026-05-01 | terminus-22.0.0 | xhigh | Mixed1 errors | 4/5 |
| gpt-5.6-lunaopenai · 2026-07-10 | codex0.144.0 | max | Mixed | 3/5 |
| gpt-5.6-lunaopenai · 2026-07-11 | codex0.144.1 | max | Mixed | 3/5 |
| gpt-5.6-solopenai · 2026-07-10 | codex0.144.0 | max | All passed | 5/5 |
| gpt-5.6-terraopenai · 2026-07-10 | codex0.144.0 | max | All passed | 5/5 |
| gpt-5.6-terraopenai · 2026-07-11 | codex0.144.1 | max | All passed | 5/5 |
| grok-4.5cursor · 2026-07-09 | cursor-cli2026.07.08-0c04a8a | default | Mixed | 3/5 |
| muse-spark-1.1openai · 2026-07-09 | mini-swe-agent2.4.5 | xhigh | All passed | 5/5 |