![]() |
VOOZH | about |
dotnet add package Hazina.Core.Plugins.Lua --version 1.0.2
NuGet\Install-Package Hazina.Core.Plugins.Lua -Version 1.0.2
<PackageReference Include="Hazina.Core.Plugins.Lua" Version="1.0.2" />
<PackageVersion Include="Hazina.Core.Plugins.Lua" Version="1.0.2" />Directory.Packages.props
<PackageReference Include="Hazina.Core.Plugins.Lua" />Project file
paket add Hazina.Core.Plugins.Lua --version 1.0.2
#r "nuget: Hazina.Core.Plugins.Lua, 1.0.2"
#:package Hazina.Core.Plugins.Lua@1.0.2
#addin nuget:?package=Hazina.Core.Plugins.Lua&version=1.0.2Install as a Cake Addin
#tool nuget:?package=Hazina.Core.Plugins.Lua&version=1.0.2Install as a Cake Tool
π .NET 9.0
π Build Status
π NuGet
π Packages
π Deploy Docs
Production-ready AI infrastructure for .NET that scales from prototype to production without rewriting your code.
If upgrading from v1.x, please note these important changes:
using Hazina.LLMs.OpenAI; for OpenAI-specific classesGenerateTextAsync β GenerateAsync with updated parametersSee the full for details and migration paths.
| Hazina | LangChain | Semantic Kernel | Roll Your Own | |
|---|---|---|---|---|
| Language | C# native | Python-first | C# | C# |
| Setup time | 4 lines | 50+ lines | 30+ lines | 200+ lines |
| Multi-provider failover | Built-in | Manual | Plugin required | Build yourself |
| Hallucination detection | Built-in | External tools | Not included | Build yourself |
| Cost tracking | Automatic | Manual | Manual | Build yourself |
| Production monitoring | Included | External | External | Build yourself |
| Local + Cloud | Unified API | Separate configs | Separate configs | Multiple implementations |
Build a production-ready RAG AI that answers questions from your documents:
dotnet new console -n MyRAGApp
cd MyRAGApp
dotnet add package Hazina.AI.FluentAPI
dotnet add package Hazina.AI.RAG
using Hazina.AI.FluentAPI.Configuration;
using Hazina.AI.RAG.Core;
// 1. Setup (one line)
var ai = QuickSetup.SetupOpenAI(Environment.GetEnvironmentVariable("OPENAI_API_KEY")!);
// 2. Create RAG engine
var vectorStore = new InMemoryVectorStore();
var rag = new RAGEngine(ai, vectorStore);
// 3. Index your documents
await rag.IndexDocumentsAsync(new List<Document>
{
new() { Content = "Hazina is a .NET AI framework for production applications." },
new() { Content = "RAG combines retrieval with generation for accurate answers." }
});
// 4. Query with context
var response = await rag.QueryAsync("What is Hazina?");
Console.WriteLine(response.Answer);
This scales from demo β production without rewriting.
See the full for:
99 production-ready packages now available on NuGet.org!
All Hazina packages are published at version 1.0.1 and ready for use in your production applications.
π Browse all packages: https://www.nuget.org/packages?q=owner:martiendejong+Hazina
# Core orchestration
dotnet add package Hazina.AI.Orchestration --version 1.0.1
dotnet add package Hazina.AI.FluentAPI --version 1.0.1
# LLM providers
dotnet add package Hazina.LLMs.OpenAI --version 1.0.1
dotnet add package Hazina.LLMs.Anthropic --version 1.0.1
dotnet add package Hazina.LLMs.Ollama --version 1.0.1
# RAG & agents
dotnet add package Hazina.AI.RAG --version 1.0.1
dotnet add package Hazina.AI.Agents --version 1.0.1
# Tools & services
dotnet add package Hazina.Tools.Services.Database --version 1.0.1
dotnet add package Hazina.Storage.Embeddings --version 1.0.1
# Core package (minimal)
dotnet add package Hazina.AI.FluentAPI
# Add RAG capabilities
dotnet add package Hazina.AI.RAG
# Add agentic workflows
dotnet add package Hazina.AI.Agents
# Add production monitoring
dotnet add package Hazina.Production.Monitoring
# LangChain - 15+ lines, Python only
from langchain.llms import OpenAI
from langchain.chains import RetrievalQA
from langchain.vectorstores import Chroma
from langchain.embeddings import OpenAIEmbeddings
embeddings = OpenAIEmbeddings()
vectorstore = Chroma.from_documents(docs, embeddings)
llm = OpenAI()
chain = RetrievalQA.from_chain_type(llm, retriever=vectorstore.as_retriever())
# No built-in failover, cost tracking, or hallucination detection
// Hazina - 4 lines, native C#
var ai = QuickSetup.SetupWithFailover(openAiKey, anthropicKey); // Auto-failover
var rag = new RAGEngine(ai, vectorStore);
await rag.IndexDocumentsAsync(docs);
var answer = await rag.QueryAsync("question"); // Cost tracked automatically
// Semantic Kernel - requires plugins, manual setup
var kernel = Kernel.CreateBuilder()
.AddOpenAIChatCompletion("gpt-4", apiKey)
.Build();
// Failover? Add another plugin. Cost tracking? Write it yourself.
// Hazina - batteries included
var ai = QuickSetup.SetupWithFailover(openAiKey, anthropicKey);
ai.EnableCostTracking(budgetLimit: 10.00m);
ai.EnableHealthMonitoring();
// Failover, cost tracking, health checks β all built-in
| Feature | DIY Effort | Hazina |
|---|---|---|
| Multi-provider abstraction | 2-4 weeks | β Included |
| Circuit breaker + failover | 1-2 weeks | β Included |
| Hallucination detection | 2-4 weeks | β Included |
| Cost tracking + budgets | 1 week | β Included |
| RAG with chunking | 2-3 weeks | β Included |
| Agent workflows | 3-4 weeks | β Included |
| Production monitoring | 1-2 weeks | β Included |
Total: 12-19 weeks of work β 0 with Hazina
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β Your Application β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β
βΌ
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β Hazina.AI.FluentAPI β
β Hazina.AI() β .WithProvider() β .WithFaultDetection() β Ask() β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β β β β
βΌ βΌ βΌ βΌ
ββββββββββββββββ ββββββββββββββββ ββββββββββββββββ ββββββββββββββββ
β Providers β β RAG β β Agents β β Neurochain β
β OpenAI β β Indexing β β Tools β β Multi-layer β
β Anthropic β β Retrieval β β Workflows β β Reasoning β
β Local LLMs β β Generation β β Coordinationβ β Validation β
ββββββββββββββββ ββββββββββββββββ ββββββββββββββββ ββββββββββββββββ
β β β β
ββββββββββββββββ΄βββββββββββββββ΄βββββββββββββββ
β
βΌ
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β Production Monitoring β
β Metrics β’ Cost Tracking β’ Health Checks β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
var ai = QuickSetup.SetupWithFailover(openAiKey, anthropicKey);
// Automatic failover when primary fails
var response = await ai.GetResponse(messages); // Uses OpenAI, fails over to Claude
// Or select by strategy
ai.SetDefaultStrategy(SelectionStrategy.LeastCost); // Cheapest provider
ai.SetDefaultStrategy(SelectionStrategy.FastestResponse); // Fastest provider
var result = await Hazina.AI()
.WithFaultDetection(minConfidence: 0.9)
.Ask("What is the capital of France?")
.ExecuteAsync();
// Automatically validates responses
// Detects hallucinations
// Retries with refined prompts if needed
var rag = new RAGEngine(ai, vectorStore);
// Index documents with smart chunking
await rag.IndexDocumentsAsync(documents);
// Query with automatic context retrieval
var response = await rag.QueryAsync("Explain the authentication flow", new RAGQueryOptions
{
TopK = 5,
MinSimilarity = 0.7,
RequireCitation = true
});
var coordinator = new MultiAgentCoordinator();
coordinator.AddAgent(new Agent("researcher", researchPrompt, ai));
coordinator.AddAgent(new Agent("writer", writerPrompt, ai));
coordinator.AddAgent(new Agent("reviewer", reviewerPrompt, ai));
var result = await coordinator.ExecuteAsync("Write a blog post about AI",
CoordinationStrategy.Sequential);
var neurochain = new NeuroChainOrchestrator();
neurochain.AddLayer(new FastReasoningLayer(ai)); // Quick analysis
neurochain.AddLayer(new DeepReasoningLayer(ai)); // Thorough analysis
neurochain.AddLayer(new VerificationLayer(ai)); // Cross-validation
var result = await neurochain.ReasonAsync("Complex question requiring high confidence");
// Returns 95-99% confidence through independent validation
π β Complete API reference and guides (open locally after cloning)
For private repositories: Documentation is committed to the repository at docs/apidoc/ - no external hosting required.
.\generate-docs.ps1 -Serve to preview at http://localhost:8080# Clone repository
git clone https://github.com/hazina-ai/hazina.git
cd hazina
# Choose your solution file (see SOLUTIONS.md for guidance)
# New to Hazina? Start with QuickStart.sln
dotnet restore Hazina.QuickStart.sln
dotnet build Hazina.QuickStart.sln
# Working on a specific area?
# dotnet build Hazina.AI.sln # AI features
# dotnet build Hazina.Core.sln # Infrastructure
# dotnet build Hazina.Tools.sln # Tools & services
# dotnet build Hazina.Apps.sln # Applications
# Full build (all 62 projects)
# dotnet build Hazina.sln
# Run demos
dotnet run --project apps/Demos/Hazina.Demo.Supabase
All contributions to Hazina must meet the complete Definition of Done before being merged.
See: C:\scripts\_machine\DEFINITION_OF_DONE.md for the comprehensive checklist (Brand2Boost/client-manager project context).
Key Hazina-Specific DoD Requirements:
develop (or main)Key Principle: A contribution is NOT done until it's merged, deployed (if applicable), and documented.
Complete Package & Service Listings:
Quick Find:
# Find a package
grep -i "keyword" PACKAGES_REGISTRY.md
# Find a service
grep -i "IMyService" SERVICES_REGISTRY.md
# List all packages in a category
grep "## AI Core" PACKAGES_REGISTRY.md -A 50
Hazina provides comprehensive documentation to help you get started and master the framework.
Documentation is auto-generated and committed to the repository at docs/apidoc/:
docs/apidoc/index.html in your browser for the full documentationdocs/apidoc/api/index.htmlBenefits for private repos: No external hosting needed - documentation is version-controlled alongside code.
# Generate API documentation from source code
.\generate-docs.ps1
# Generate and preview in browser (http://localhost:8080)
.\generate-docs.ps1 -Serve
# Clean previous build and regenerate
.\generate-docs.ps1 -Clean
Documentation is automatically regenerated by GitHub Actions on every push to develop/main.
All public APIs must include XML documentation comments. See for details.
Before creating a PR:
.\generate-docs.ps1We welcome contributions! See for guidelines.
Before contributing:
develop (or main)MIT License - see for details.
Built for .NET developers who ship production AI.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net10.0 net10.0 is compatible. net10.0-android net10.0-android was computed. net10.0-browser net10.0-browser was computed. net10.0-ios net10.0-ios was computed. net10.0-maccatalyst net10.0-maccatalyst was computed. net10.0-macos net10.0-macos was computed. net10.0-tvos net10.0-tvos was computed. net10.0-windows net10.0-windows was computed. |
This package is not used by any NuGet packages.
This package is not used by any popular GitHub repositories.