Why cursor cannot index the other github project in one project?

I have a personal backend service repository and a common front-end repository, and we want use cursor @file function let it know how to modify the interface between the front-end and the back-end. So I clone the front-end repository into the back-end project but cursor cannot index this files. Why? it is important for me.