TIPS: A Prompt Engineering Framework for Code Classification and Generation on Resource-Constrained Systems
Abstract
Recent advances in AI-assisted programming have demonstrated the potential of Large Language Models (LLMs) in complex code classification and generation. However, their high computational demands and reliance on large-scale datasets limit deployment in resource-constrained environments such as educational tools, edge devices, and small-scale development settings. To address these challenges, this paper introduces the Template-Integrated Prompting System (TIPS), a modular prompt engineering framework designed for lightweight and efficient code analysis. TIPS integrates small-model training, semantically guided demonstration selection, and structured prompt templates to construct an interpretable reasoning pipeline that combines few-shot learning with Chain-of-Thought (CoT) reasoning. Experiments on a benchmark dataset of multithreaded Pthread programs show that TIPS achieves higher precision, recall, and F1-scores than traditional classifiers and prompt-based baselines, even under class imbalance. These results demonstrate that model effectiveness depends not only on scale but also on semantic guidance and structured reasoning. TIPS provides a scalable and interpretable solution, with potential applications in education, software development, and intelligent assistance systems, particularly in resource-constrained environments.
Fields of Study & Subjects
Software Engineering Research
Topic Modeling
Machine Learning in Materials Science
Publication details
- Journal / source
- IEEE Access
- Publisher
- Institute of Electrical and Electronics Engineers (IEEE)
- Volume
- 14
- Pages
- 15723–15735
- Publication date
- 1 January 2026
- Language
- EN