Rapid.Agentic.AI.Framework
2.0.0
See the version list below for details.
dotnet add package Rapid.Agentic.AI.Framework --version 2.0.0
NuGet\Install-Package Rapid.Agentic.AI.Framework -Version 2.0.0
<PackageReference Include="Rapid.Agentic.AI.Framework" Version="2.0.0" />
<PackageVersion Include="Rapid.Agentic.AI.Framework" Version="2.0.0" />
<PackageReference Include="Rapid.Agentic.AI.Framework" />
paket add Rapid.Agentic.AI.Framework --version 2.0.0
#r "nuget: Rapid.Agentic.AI.Framework, 2.0.0"
#:package Rapid.Agentic.AI.Framework@2.0.0
#addin nuget:?package=Rapid.Agentic.AI.Framework&version=2.0.0
#tool nuget:?package=Rapid.Agentic.AI.Framework&version=2.0.0
Rapid.Agentic.AI.Framework
Rapid.Agentic.AI.Framework is a lightweight .NET library that simplifies integration with Retrieval-Augmented Generation (RAG) systems and Ollama LLMs. It provides intuitive gateway interfaces for building intelligent applications that can chat, generate content, and ingest domain-specific documents such as PDFs.
โจ Features
- ๐ค Ollama Integration: Send prompts and receive completions from local or remote Ollama servers.
- ๐ Document Ingestion: Upload and convert PDFs into vectorized knowledge for retrieval.
- ๐ง RAG-Powered Answers: Ask questions based on your custom data (uploaded documents).
- ๐งผ Stateful & Stateless Chat: Clearable chat histories to manage conversational memory.
๐ RAG Gateway (IRagGateway
)
- Upload and process PDF documents
- Query domain-specific knowledge with context
- Generate answers and summaries
- Statefull and Stateless by default, with optional history reset
๐ค Ollama Gateway (IOllamaGateway
)
- Lightweight prompt-based chat and content generation
- Statefull and Stateless by default, with optional history reset
๐งช Use Cases
- RAG-enabled customer support systems
- AI-driven PDF analysis tools
- Developer tools for querying technical documentation
- AI assistants embedded in enterprise software
๐ฆ Installation
Install from NuGet.org:
dotnet add package Rapid.Agentic.AI.Framework
Or via Package Manager Console:
Install-Package Rapid.Agentic.AI.Framework
๐ Getting Started
๐ฆ Prerequisites
- .NET 6 or later
- Ollama running locally (default port
http://localhost:11434
) - A downloaded model (e.g.,
llama3
,llama3.2:1b
, etc.)
๐งฑ Example Model Names
- llama3
- llama3.2:1b
- mistral
Any other model available through Ollama
Ensure the model is already pulled by running:
ollama run llama3.2:1b
๐งช Usage
๐ญ 1. Factory Class
public interface IAgenticClientFactory
{
IRagGateway CreateRagGateway(string ollamaUrl, string model, string dbPath = "rag.db");
IOllamaGateway CreateOllamaGateway(string ollamaUrl, string model);
}
๐ 1. RAG Gateway
public interface IRagGateway
{
Task<string> ChatAsync(string question);
void ClearChatHistory();
Task<string> GenerateAsync(string question, bool enableStreaming);
Task UploadFileAsync(string pdfPath);
}
โจ 1. Usage example - Summarizing a PDF document
var factory = new AgenticClientFactory();
var rag = factory.CreateRagGateway("http://localhost:11434", "llama3");
await rag.UploadFileAsync("documents/manual.pdf");
string summary = await rag.GenerateAsync("Summarize the manual.", enableStreaming: false);
Console.WriteLine(summary);
โจ 2. Usage example - Reviewing c# source code
var factory = new AgenticClientFactory();
var rag = factory.CreateRagGateway("http://localhost:11434", "llama3");
await rag.UploadFileAsync("documents/MyAlgorithm.cs");
string summary = await rag.GenerateAsync("Review the cs file", enableStreaming: false);
Console.WriteLine(summary);
โจ 3. Usage example - without uploading local file
var factory = new AgenticClientFactory();
var rag = factory.CreateRagGateway("http://localhost:11434", "llama3");
string summary = await rag.GenerateAsync("What are the best tourist places in Bangalore", enableStreaming: false);
Console.WriteLine(summary);
โจ 4. Chat Usage example (Multi-Turn) - Reviewing c# source code and asking for fix
var factory = new AgenticClientFactory();
var rag = factory.CreateRagGateway("http://localhost:11434", "llama3");
await rag.UploadFileAsync("documents/MyAlgorithm.cs");
string summary = await rag.ChatAsync("Review the cs file", enableStreaming: false);
Console.WriteLine(summary);
string modifiedsummary = await rag.ChatAsync("Provide me top review comments with potential fix", enableStreaming: false);
Console.WriteLine(modifiedsummary);
๐ To Clear Chat History:
rag.ClearChatHistory();
๐ค 2. IOllamaGateway
public interface IOllamaGateway
{
string ChatAsync(string prompt, string model = "");
void ClearChatHistory();
string GenerateAsync(string prompt, string model = "");
}
โจ 1. Chat Usage example with Context (Multi-Turn)
var factory = new AgenticClientFactory();
var ollama = factory.CreateOllamaGateway(ollamaUrl, myModel);
string response = ollama.ChatAsync("Tell me about India?");
Console.WriteLine(response);
string responseUpdated = ollama.ChatAsync("What are the best tourist places?");
Console.WriteLine(responseUpdated);
ollama.ClearChatHistory();
โจ 1. Content generation Usage example
var factory = new AgenticClientFactory();
var ollama = factory.CreateOllamaGateway(ollamaUrl, myModel);
string response = ollama.GenerateAsync("Tell me about India?");
Console.WriteLine(response);
๐ To Clear Chat History:
OllamaClient.ClearChatHistory();
๐ License
The Core Framework is not open-source, but is freely distributed via NuGet.
For commercial use, licensing, or integration support:
๐ง support@vedicaai.com or aruna.devadiga@gmail.com
๐ Support & Contributions
This framework is not open source, but it is freely distributed via NuGet. If you encounter issues, bugs, or have suggestions, feel free to reach out to the maintainers or submit feedback via the appropriate support channels.
๐ง support@vedicaai.com or aruna.devadiga@gmail.com
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET | net8.0 is compatible. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. net9.0 was computed. net9.0-android was computed. net9.0-browser was computed. net9.0-ios was computed. net9.0-maccatalyst was computed. net9.0-macos was computed. net9.0-tvos was computed. net9.0-windows was computed. net10.0 was computed. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
-
net8.0
- HtmlAgilityPack (>= 1.12.1)
- Microsoft.Data.Sqlite (>= 9.0.5)
- PdfPig (>= 0.1.10)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
Version | Downloads | Last Updated |
---|---|---|
3.2.6 | 62 | 9/7/2025 |
3.2.3 | 59 | 9/6/2025 |
3.2.0 | 64 | 9/6/2025 |
3.1.1 | 66 | 8/16/2025 |
3.1.0 | 60 | 8/16/2025 |
3.0.1 | 57 | 8/16/2025 |
3.0.0 | 68 | 8/16/2025 |
2.1.9 | 59 | 8/16/2025 |
2.1.8 | 132 | 8/14/2025 |
2.1.7 | 305 | 6/12/2025 |
2.1.6 | 215 | 6/9/2025 |
2.1.4 | 144 | 6/2/2025 |
2.1.3 | 153 | 5/29/2025 |
2.1.2 | 146 | 5/29/2025 |
2.1.1 | 149 | 5/25/2025 |
2.1.0 | 153 | 5/25/2025 |
2.0.5 | 102 | 5/25/2025 |
2.0.2 | 80 | 5/24/2025 |
2.0.0 | 123 | 5/23/2025 |
1.0.1 | 161 | 5/21/2025 |
- Complete RAG Framework implementation added
- OllamaGateway for easy integration with Ollama