Summary
The paper describes a system for executing first-order logic queries on knowledge graphs by using an LLM (Llama-2). The proposed approach:
1. Collects a subgraph around the query entities from the KG
2. Anonymizes the entities and relations in the query and the collected subgraph by converting them into entity and relation ids
2. Prompts the LLM to execute each step of the query graph and passes intermediate answer entities to the next step of execution
- Results on a dataset of complex queries shows improvements over baseline approaches.
- Without any fine-tuning, the LLM is shown to generalize across different underlying knowledge graphs (prior works require at least part of the pipeline to be fine-tuned for each KG)
Strengths
- The proposed approach based on LLMs only observers a subset of the full KG with anonymized entity and relation IDs. This allows the system to:
- Easily generalize to new KGs
- Scale to larger KGs (since the LLM only observes a k-hop subgraph)
- Most existing approaches for KG reasoning need all or part (one-hop link prediction model) to be fine-tuned for each KG
- Authors demonstrate that step-by-step query execution performs significantly better than directly attempting to execute the complex query
- Authors show that other LLMs also seem to handle the task, demonstrating that the performance is not specific to Llama-2
Weaknesses
- The presentation of the paper lacks details of the evaluation protocol
- The paper evaluates the system on the queries generated by [1]. [1] highlights 2 types of answer entities: trivial answers (query can be directly executed on the available KG to gather answers) and non-trivial answers (queries require reasoning about missing edges).
- It is unclear if this paper reports results on the trivial, non-trivial, or combined subsets of answers.
- While the paper reports strong results on all benchmarks, there is no indication of the mechanism by which an LLM "could" solve the task.
- The results are especially surprising given that the LLM only observes anonymized entity and relation names and cannot apply any semantic reasoning
- The LLM only sees a small subset of the KG, so it does not have sufficient information to learn the semantics of the anonymized relations
- The paper misses some relevant work in query execution on KGs
- [2] is a strong baseline that uses learned one-hop link prediction models for each KG and uses them to execute complex queries. The method provides guarantees that the trivial answers will be predicted exactly and shows strong performance on the non-trivial answer entities
- Other competitive baselines include [3] and [4]. [2] provides MRR results for these approaches on the same datasets
- The MRR for the CQD baseline in this paper do not match the corresponding results in [2]
I have reframed these weaknesses as a series of questions in the next section.
---
[1] Ren, H., Hu, W., and Leskovec, J. Query2box: reasoning over knowledge graphs in vector space using box embeddings. In International Conference on Learning Representations, 2020.
[2] Yushi Bai, Xin Lv, Juanzi Li, and Lei Hou. 2023. Answering complex logical queries on knowledge graphs via query computation tree optimization. In Proceedings of the 40th International Conference on Machine Learning (ICML'23)
[3] Chen, X., Hu, Z., and Sun, Y. Fuzzy logic based logical query answering on knowledge graphs. In Proceedings of the AAAI Conference on Artificial Intelligence, volume 36, pp. 3939–3948, 2022.
[4] Zhu, Z., Galkin, M., Zhang, Z., and Tang, J. Neuralsymbolic models for logical queries on knowledge graphs. In Proceedings of the 39th International Conference on Machine Learning, volume 162, pp. 27454–27478, 2022.
Questions
1. Please clarify the evaluation protocol. Is the reported MRR only considering the non-trivial answer set?
2. What is the baseline MRR of directly executing the queries on the KG? e.g. for the 2p query (e1, r1, ?) -> (?, r2, ANS), explicitly returning entities that are connected to e1 by the 2-hop path (r1, r2)? Let's call this baseline DIRECT
3. What is the MRR of returning the answer set of DIRECT combined with a random order of entities from the collected neighborhood subgraph? Let's call this baseline DIRECT+KNN
4. Given that the LLM only observes anonymized entity and relation IDs and a neighborhood subgraph of the full KG, how does the LLM perform better than other approaches?
1. The paper is missing a discussion and examples of when and why it performs better than the baselines (including DIRECT and DIRECT+KNN).
2. In Sec 4.3 the paper claims that the improvement is from "the LLM's ability to capture a broad range of relations...". How is this possible with anonymized relations?
5. Introduction, page 1, para 1: The introduction mentions that the proposed approach handles more complex queries than "constrained" FOL queries. The evaluation datasets in this paper are also FOL queries. How do you support this claim?
- Same claim made on page 2, para 2
6. Section 3.2, Neighborhood retrieval: There seem to be errors in the equations here. It is unclear how the neighborhood graph actually grows.
1. Eq (5): By definitions 1-4, $Q_\tau$ only contains the head entity and relation for each edge in the query graph. Then how do you constrain $t \in E^1_r$
2. Eq (7): Constrains the new graph to contain entities and relations that lie in the previous neighborhood graph. How does the graph ever grow?
3. When collecting the neighborhood subgraph, do you only include edges that are of the same type as the edges in the query graph?
7. Sec 4.5: The line says "over 4096 and less than 4096". I am assuming this is a typo and you only meant "over 4096"? Please clarify
8. Fig 2: The text of the figure seems to convey that the model receives the logical form of the query as input. Why do you then need a query type identifier according to the description of Fig 2?
Rating
3: reject, not good enough
Confidence
3: You are fairly confident in your assessment. It is possible that you did not understand some parts of the submission or that you are unfamiliar with some pieces of related work. Math/other details were not carefully checked.