cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

CAP LLM Plugin needs cds.connect.to('db').

adamharkus
Participant
0 Kudos
394

I've installed the CAP LLM Plugin (v.1.3.3). 

However, for the getRagResponse() and similaritySearch() methods, the db is not connected, even if I set in in the calling script.

For now I've put in the workaround to the plugin to connected to the db on init.

Any ideas why I need to forced the connect directly in the plugin?

 

 

   try {
      // Connect to the 'db' service
      this.db = await cds.connect.to('db');
      console.log('Database connection established.');
    } catch (error) {
        console.error('Failed to connect to the database:', error);
        throw error;
    }​

 

 

 

Accepted Solutions (0)

Answers (0)