Pith. sign in

REVIEW 2 cited by

Enhancing LLM Code Generation with Ensembles: A Similarity-Based Selection Approach

Not yet reviewed by Pith; the record is open.

This paper has not been read by Pith yet. Machine review is queued; the pith claim, tier, and objections will appear here once it completes.

SPECIMEN: schema-true, not a live event

T0 review · schema-true

One-sentence machine reading of the paper's core claim.

pith:XXXXXXXX · record.json · timestamp

arxiv 2503.15838 v2 pith:YYNRXH3N submitted 2025-03-20 cs.SE

classification cs.SE
keywords accuracyapproachllmscodeensemblegenerationrespectivelybeen
verification ladder T0 review T1 audit T2 compute T3 formal
0 comments
read the original abstract

Ensemble learning has been widely used in machine learning to improve model robustness, accuracy, and generalization, but has not yet been applied to code generation tasks with large language models (LLMs). We propose an ensemble approach for LLMs in code generation. Instead of relying on the output of a single model, we generate multiple candidate programs from different LLMs and apply a structured voting mechanism to select the most reliable solution. For voting, we compute syntactic and semantic similarity using CodeBLEU and behavioral equivalence using CrossHair's differential behavior analysis. By aggregating these similarity scores, we select the program that best aligns with the consensus among the candidates. We show through experiments that our ensemble approach consistently outperforms standalone LLMs on the well-known HumanEval and the more challenging LiveCodeBench datasets, achieving an accuracy of 90.2% and 50.2%, respectively, on the two datasets. In comparison, the best-performing LLM (GPT-4o) has an accuracy of 83.5% and 43.4%, respectively. Furthermore, even when restricted to free open-source models, our method achieves an accuracy of 80.5% and 41.6%, respectively, demonstrating the viability of our approach in resource-constrained settings.

Discussion (0). Continue with ORCID to comment.

Forward citations

Cited by 2 Pith papers

Reviewed papers in the Pith corpus that reference this work. Sorted by Pith novelty score. Full citation record

  1. PatchIsland: Orchestration of LLM Agents for Continuous Vulnerability Repair

    cs.CR 2026-01 conditional novelty 6.0 of 10

    An orchestrated ensemble of LLM agents with patch-based deduplication patched 31 of 43 confirmed vulnerabilities in the AIxCC final and 84 of 92 in an internal benchmark.

  2. Trae Agent: An LLM-based Agent for Software Engineering with Test-time Scaling

    cs.SE 2025-07 conditional novelty 5.0 of 10

    Trae Agent combines parallel patch generation, hierarchical pruning, and agent-based majority-vote selection to reach 75.20% Pass@1 on SWE-bench Verified, the current leaderboard leader.

Pith tools