Is it possible for a plugin to avail services of build in AI

I have been thinking about an idea for some functionality in IntelliJ IDE - the idea is to have a context menu item on the nodes of the library dependency, wherever it appears in the UI and based on the GAV of the dependency try to figure out the VCS (git) repository location either by parsing the pom.xml for scm tag and if it fail, try to make use of the built-in AI agent in IntelliJ to apply some heuristic to figure it out. Once located then the repository URL could be opened in the browser - and if the path to the class inside the dependency .jar is known, then use that to open that in the browser as well. Then the user could explore the blame and history etc.

I was trying to figure out if there is a way to invoke the agent programmatically so that I can invoke the fuzzy matching from a plugin.

So far I have solved the problem of finding the GAV + path from the location like this:

~/.gradle/caches/modules-2/files-2.1/org.springframework.boot/spring-boot/3.5.6/a02f486ab700dad1f81e54cb37651d92a3f9d700/spring-boot-3.5.6.jar!/org/springframework/boot/SpringApplication.class

I can (easily) figure out:

org.springframework.boot:spring-boot:3.5.6

org/springframework/boot/SpringApplication.java

And using the logic described above want to get to this URL (note the correct tag in the URL):

(I want to use built in AI to locate the correct repository URL).

BTW once the URL is correctly located a lot more features could be added e.g. import as project and so on.

Any pointers are welcome.

Regards,

Sandip