Leveraging Metamemory Mechanisms for Enhanced Data-Free Code Generation in LLMs
Automated code generation using large language models (LLMs) has gained attention due to its efficiency and adaptability. However, real-world coding tasks or benchmarks like HumanEval and StudentEval often lack dedicated training datasets, challenging existing few-shot prompting approaches that rely on reference examples. Inspired by human metamemory-a cognitive process involving recall and evaluation-we present a novel framework (namely M^2WF) for improving LLMs' one-time code generation. This approach enables LLMs to autonomously generate, evaluate, and utilize synthetic examples to enhance reliability and performance. Unlike prior methods, it minimizes dependency on curated data and adapts flexibly to various coding scenarios. Our experiments demonstrate significant improvements in coding benchmarks, offering a scalable and robust solution for data-free environments. The code and framework will be publicly available on GitHub and HuggingFace.
Code (0)
등록된 구현이 없습니다.
Tasks
Code GenerationHumanEvalMethods 이 논문이 사용한 방법론
Similar Papers 제목 키워드 기반
BERT-JAM: Boosting BERT-Enhanced Neural Machine Translation with Joint Attention
BERT-enhanced neural machine translation (NMT) aims at leveraging BERT-encoded representations for translation tasks. A recently proposed approach uses attention mechanisms to fuse Transformer's encoder and decoder layer…
DecoderMachine TranslationNMTTranslationAngle Domain Guidance: Latent Diffusion Requires Rotation Rather Than Extrapolation
Classifier-free guidance (CFG) has emerged as a pivotal advancement in text-to-image latent diffusion models, establishing itself as a cornerstone technique for achieving high-quality image synthesis. However, under high…
Image GenerationParameter-Free Bio-Inspired Channel Attention for Enhanced Cardiac MRI Reconstruction
Attention is a fundamental component of the human visual recognition system. The inclusion of attention in a convolutional neural network amplifies relevant visual features and suppresses the less important ones. Integra…
MRI ReconstructionSpecAttn: Speculating Sparse Attention
Large Language Models (LLMs) face significant computational bottlenecks during inference due to the quadratic complexity of self-attention mechanisms, particularly as context lengths increase. We introduce SpecAttn, a no…
Object Isolated Attention for Consistent Story Visualization
Open-ended story visualization is a challenging task that involves generating coherent image sequences from a given storyline. One of the main difficulties is maintaining character consistency while creating natural and …
ObjectStory Visualization