Synthetic biology is a highly specialized discipline characterized by diverse and heterogeneous knowledge sources. Leveraging large language models (LLMs) to achieve accurate, context-aware domain-specific question answering remains a significant challenge, particularly due to persistent issues such as knowledge gaps and hallucinations. To address this, we propose APMSR (Adaptive Prompt and Multi-Source Retrieval), an optimization strategy that integrates adaptive prompt generation based on question features with dynamic multi-source knowledge retrieval, guided by the LinUCB algorithm. This approach balances exploration and exploitation to enhance the relevance and precision of domain-specific information retrieval. We implemented APMSR in a question-answering system tailored to synthetic biology and evaluated its performance on complex, professional-level queries. Experimental results demonstrate that the APMSR-optimized system achieves up to 93% accuracy on multiple-choice and true/false questions. These improvements in accuracy and robustness highlight the potential of combining LLMs with retrieval-augmented strategies for advanced domain-specific question answering.
Wang et al. (Thu,) studied this question.