# Leveraging Large Language Models for Sensor Data Retrieval
## 6 Conclusions and Future Work  
This paper proposed an innovative method for searching relevant sensor data, encompassing two key components: data gathering and data retrieval. The former employs LLMs to convert sensor data into a reusable format, when necessary, showcasing the potential of language models in promoting FAIR compliance for sensor data. The latter utilises LLMs to create word embedding representations of tabular data, providing semantic search capabilities to extract the most relevant indexed sensor datasets for augmenting user-provided data. Several contributions were made in this paper to achieve these goals. First, an architecture was proposed to automate the alignment of sensor data with the FAIR principles. This architecture leverages LLMs to facilitate the transformation of data during the data gathering phase. Additionally, an approach is developed for indexing sensor data that comply with FAIR principles, thereby facilitating their retrieval. This approach utilises word embeddings to generate vectors that semantically represent sensor data, aiding in efficient retrieval. Furthermore, a framework is introduced to integrate both data gathering and retrieval approaches, enhancing the searchability of sensor data. In order to demonstrate the practical application of these contributions, a case study was presented within the domain of smart farming. This case study illustrates the transformation of relevant sensor data into a FAIR-compliant format, consequently improving their accessibility and searchability. The evaluation of the proposed approach involved comparing the performance of different LLMs in generating representative word embeddings for each table in order to retrieve relevant sensor data for a given tabular query. An evaluation dataset containing 1299 CSV files with sensor data was specifically gathered for this task. The evaluation measured the P@1 and MRR of the retrieval system. The performance of the different language models varied, with the _big-base-en-v1.5_ model exhibiting exceptional accuracy with a precision of 0.90 and MRR of 0.94. In contrast, the _UAE-Large-V1_ model showed the poorest scores in precision and MRR, despite being the top-performing model in NLP tasks according to the MTEB leaderboard. The fact that this model was fine-tuned on a wide range of data suggests that the model may struggle to provide representative embeddings for the experimental data without prior fine-tuning. The study also evaluated the indexing and retrieval execution times for each model. The time taken for indexing a table was low for all the models, ranging between 60 and 160 milliseconds. On the contrary, the retrieval operation required notably more time, taking into account that this process implied retrieving the top-k comparable columns for each column in the query table, computing similarity scores, and re-ranking the results. Future work involves enhancing the retrieval component by fine-tuning language models specifically on sensor data, which could improve their ability to generate representative embeddings for these datasets. Moreover, further exploring the effectiveness of smaller models, such as _big-small-en-v1.5_, might offer a lightweight and efficient solution for real-time systems. Furthermore, the application to other scenarios is a future line that must be explored to demonstrate the effectiveness and flexibility of the proposed system across a wide range of domains. **Author Contributions:** Conceptualisation, J.-N.M. and D.T. ; methodology, J.-N.M. and D.T. ; software, A.B. and A.M.; validation, A.B., A.M. and D.T. ; formal analysis, A.B. and D.T. ; investigation, A.B. and D.T. ; resources, A.M.; data curation, A.B. and A.M.; writing--original draft preparation, A.B., A.M., D.T. and J.-N.M.; writing--review & editing, J.-N.M. and D.T. ; visualisation, A.B. and D.T. ; supervision, J.-N.M. and D.T. ; project administration, J.-N.M.; funding acquisition, J.-N.M. All authors have read and agreed to the published version of the manuscript.