You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
const ragApplication = await new RAGApplicationBuilder()
.setModel(new Ollama({ modelName: llamaVersion, baseUrl: llamaHostUrl }))
.setEmbeddingModel(new OllamaEmbeddings({ model: 'nomic-embed-text', baseUrl: llamaHostUrl }))
.setVectorDatabase(new HNSWDb())
.build();
ragApplication.addLoader(new UrlLoader({url: "https://www.forbes.com/profile/elon-musk"}));
const ragResponse = await ragApplication.query('What is the net worth of Elon Musk today?');
console.log('response: ',ragResponse);
output:
response: {
id: '6b8b201d-a839-470e-b675-5603891934e8',
timestamp: 2024-11-07T13:10:45.224Z,
content: "I don't have the most up-to-date information on Elon Musk's current net worth. My knowledge cutoff is December 2023, and I may not have reflected any recent changes in his wealth. For the most accurate and current information, I recommend checking reputable financial news sources or Elon Musk's official social media accounts.",
actor: 'AI',
sources: [],
tokenUse: { inputTokens: 'UNKNOWN', outputTokens: 'UNKNOWN' }
}
Not working with any url for me. Help me to fix this.
The text was updated successfully, but these errors were encountered:
I tried the following code.
output:
Not working with any url for me. Help me to fix this.
The text was updated successfully, but these errors were encountered: