SimpleRag 0.0.1-preview8
This is a prerelease version of SimpleRag.
There is a newer prerelease version of this package available.
See the version list below for details.
See the version list below for details.
dotnet add package SimpleRag --version 0.0.1-preview8
NuGet\Install-Package SimpleRag -Version 0.0.1-preview8
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="SimpleRag" Version="0.0.1-preview8" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="SimpleRag" Version="0.0.1-preview8" />
<PackageReference Include="SimpleRag" />
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add SimpleRag --version 0.0.1-preview8
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
#r "nuget: SimpleRag, 0.0.1-preview8"
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package SimpleRag@0.0.1-preview8
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=SimpleRag&version=0.0.1-preview8&prerelease
#tool nuget:?package=SimpleRag&version=0.0.1-preview8&prerelease
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
This Repo is in an Early Preview state, meaning that everything is subject to change
SimpleRag
A Simple and Opinionated AI RAG Solutions for SourceCode, where you just need to setup and point to your source and we take care of the rest.
Getting Started
Step 1: Install SimpleRag Nuget + your Embedding Generator (in this sample Azure OpenAI via Semantic Kernel and SQL Server 2025 as VectorStore)
dotnet add package SimpleRag
dotnet add package Microsoft.SemanticKernel
dotnet add package Microsoft.SemanticKernel.Connectors.SqlServer
Step 2: Setup Dependency Injection of Embedding Generator and SimpleRag
string endpoint = builder.Configuration["AiEndpoint"]!;
string key = builder.Configuration["AiKey"]!;
string embeddingDeploymentName = builder.Configuration["AiEmbeddingDeploymentName"]!;
string sqlServerConnectionString = builder.Configuration["SqlServerConnectionString"]!;
string githubToken = builder.Configuration["GitHubToken"]!;
//Setup Embedding Generator
builder.Services.AddAzureOpenAIEmbeddingGenerator(embeddingDeploymentName, endpoint, key);
//Setup SimpleRag (use .AddSimpleRag(...) instead if you do not wish to use GitHub as Datasource)
builder.Services.AddSimpleRagWithGitHubIntegration(new VectorStoreConfiguration(Constants.VectorStoreName, Constants.MaxRecords), options => new SqlServerVectorStore(sqlServerConnectionString, new SqlServerVectorStoreOptions
{
EmbeddingGenerator = options.GetRequiredService<IEmbeddingGenerator<string, Embedding<float>>>()
}), githubToken);
Step 3: Ingest Data into your VectorStore (in this sample the TrelloDotNet open-source repo)
public class IngestionExample(Ingestion ingestion)
{
public async Task Sync()
{
string gitHubOwner = "rwjdk";
string gitHubRepo = "TrelloDotNet";
await ingestion.IngestAsync(
[
new CSharpDataSourceGitHub
{
CollectionId = Constants.CollectionId,
Id = Constants.SourceIdCode,
Recursive = true,
Path = "src",
FileIgnorePatterns = "TrelloDotNet.Tests",
GitHubOwner = gitHubOwner,
GitHubRepo = gitHubRepo,
},
new MarkdownDataSourceGitHub
{
CollectionId = Constants.CollectionId,
Id = Constants.SourceIdMarkdownInCode,
Recursive = true,
Path = "/",
GitHubOwner = gitHubOwner,
GitHubRepo = gitHubRepo,
LevelsToChunk = 3,
}
], onProgressNotification: NotifyProgress);
}
private void NotifyProgress(ProgressNotification obj)
{
Console.WriteLine(obj.GetFormattedMessageWithDetails());
}
}
Step 4: Search your VectorStore
public class SearchExample(Search search)
{
public async Task<string> SearchAsync(string question)
{
SearchResult searchResult = await search.SearchAsync(new SearchOptions
{
SearchQuery = searchQuery,
NumberOfRecordsBack = 10,
Filter = entity => entity.SourceCollectionId == Constants.CollectionId
});
return searchResult.GetAsStringResult();
}
}
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. |
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
-
net8.0
- JetBrains.Annotations (>= 2024.3.0)
- Microsoft.CodeAnalysis.CSharp (>= 4.8.0)
- Microsoft.CodeAnalysis.CSharp.Workspaces (>= 4.8.0)
- Microsoft.Extensions.DependencyInjection (>= 9.0.5)
- Microsoft.Extensions.VectorData.Abstractions (>= 9.5.0)
- Octokit (>= 14.0.0)
- Polly (>= 8.5.2)
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 |
---|---|---|
0.0.1-preview9 | 41 | 7/12/2025 |
0.0.1-preview8 | 41 | 7/12/2025 |
0.0.1-preview7 | 66 | 7/11/2025 |
0.0.1-preview6 | 108 | 7/10/2025 |
0.0.1-preview5 | 117 | 7/3/2025 |
0.0.1-preview4 | 111 | 7/2/2025 |
0.0.1-preview3 | 71 | 6/29/2025 |
0.0.1-preview2 | 68 | 6/28/2025 |
0.0.1-preview12 | 5 | 7/19/2025 |
0.0.1-preview11 | 101 | 7/15/2025 |
0.0.1-preview10 | 104 | 7/15/2025 |
0.0.1-preview1 | 72 | 6/28/2025 |