Jina 1.1.1
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 Jina --version 1.1.1
NuGet\Install-Package Jina -Version 1.1.1
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="Jina" Version="1.1.1" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Jina" Version="1.1.1" />
<PackageReference Include="Jina" />
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 Jina --version 1.1.1
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
#r "nuget: Jina, 1.1.1"
#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 Jina@1.1.1
#: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=Jina&version=1.1.1
#tool nuget:?package=Jina&version=1.1.1
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
Jina
Features 🔥
- Fully generated C# SDK based on official Jina OpenAPI specification using AutoSDK
- Same day update to support new features
- Updated and supported automatically if there are no breaking changes
- All modern .NET features - nullability, trimming, NativeAOT, etc.
- Support .Net Framework/.Net Standard 2.0
- Microsoft.Extensions.AI
IEmbeddingGeneratorsupport
Usage
using Jina;
using var api = new JinaApi(apiKey);
var response = await api.Embeddings.CreateEmbeddingAsync(new TextEmbeddingInput
{
Model = "jina-clip-v1",
Input = new List<ApiSchemasEmbeddingTextDoc>
{
new()
{
Text = "Hello, world!",
}
}
});
Console.WriteLine($"[{string.Join(", ", response.Data[0].Embedding ?? [])}]");
Microsoft.Extensions.AI
The SDK implements IEmbeddingGenerator:
using Jina;
using Microsoft.Extensions.AI;
IEmbeddingGenerator<string, Embedding<float>> generator = new JinaApi(apiKey);
var embeddings = await generator.GenerateAsync(
["Hello, world!"],
new EmbeddingGenerationOptions { ModelId = "jina-embeddings-v3" });
Console.WriteLine($"Embedding dimension: {embeddings[0].Vector.Length}");
Create Embedding
using var client = new JinaClient(apiKey);
var response = await client.SearchFoundationModels.EmbeddingsAsync(
new EmbeddingsV2Request
{
Model = EmbeddingsV2RequestModel.JinaEmbeddingsV2BaseEn,
Input = "Hello, world!",
});
var embedding = response.Data.Value1![0].Embedding.Value2;
Console.WriteLine($"[{string.Join(", ", embedding ?? [])}]");
Embedding Generator Batch Texts
using var client = new JinaClient(apiKey);
IEmbeddingGenerator<string, Embedding<float>> generator = client;
var embeddings = await generator.GenerateAsync(
["Hello", "World", "Test"],
new EmbeddingGenerationOptions
{
ModelId = "jina-embeddings-v3",
});
foreach (var embedding in embeddings)
{
}
Embedding Generator Custom Dimensions
using var client = new JinaClient(apiKey);
IEmbeddingGenerator<string, Embedding<float>> generator = client;
var embeddings = await generator.GenerateAsync(
["Hello, world!"],
new EmbeddingGenerationOptions
{
ModelId = "jina-embeddings-v3",
Dimensions = 256,
});
Embedding Generator Get Service Returns Metadata
using var client = CreateTestClient();
IEmbeddingGenerator<string, Embedding<float>> generator = client;
var metadata = generator.GetService<EmbeddingGeneratorMetadata>();
Embedding Generator Get Service Returns Null For Unknown Key
using var client = CreateTestClient();
IEmbeddingGenerator<string, Embedding<float>> generator = client;
var result = generator.GetService<EmbeddingGeneratorMetadata>(serviceKey: "unknown");
Embedding Generator Get Service Returns Self
using var client = CreateTestClient();
IEmbeddingGenerator<string, Embedding<float>> generator = client;
var self = generator.GetService<JinaClient>();
Embedding Generator Single Text
using var client = new JinaClient(apiKey);
IEmbeddingGenerator<string, Embedding<float>> generator = client;
var embeddings = await generator.GenerateAsync(
["Hello, world!"],
new EmbeddingGenerationOptions
{
ModelId = "jina-embeddings-v3",
});
Multimodal Embeddings Mixed Text And Image
using var client = new JinaClient(apiKey);
var items = new AnyOf<string, TextDoc, ImageDoc>[]
{
"A beautiful sunset over the ocean",
new ImageDoc { Image = "https://i.ibb.co/nQNGqL0/beach1.jpg" },
};
var embeddings = await client.GenerateMixedEmbeddingsAsync(
items,
new EmbeddingGenerationOptions
{
Dimensions = 256,
});
foreach (var embedding in embeddings)
{
}
Multimodal Embeddings Single Image
using var client = new JinaClient(apiKey);
var embeddings = await client.GenerateImageEmbeddingsAsync(
["https://i.ibb.co/nQNGqL0/beach1.jpg"],
new EmbeddingGenerationOptions
{
Dimensions = 256,
});
Rerank
using var client = new JinaClient(apiKey);
RerankingResponse output = await client.SearchFoundationModels.RerankAsync(
new TextRerankerRequest
{
Model = TextRerankerRequestModel.JinaRerankerV2BaseMultilingual,
Query = "Organic skincare products for sensitive skin",
TopN = 3,
Documents =
[
"Organic skincare for sensitive skin with aloe vera and chamomile.",
"New makeup trends focus on bold colors and innovative techniques.",
"Bio-Hautpflege für empfindliche Haut mit Aloe Vera und Kamille.",
"Neue Make-up-Trends setzen auf kräftige Farben und innovative Techniken.",
"Cuidado de la piel orgánico para piel sensible con aloe vera y manzanilla.",
"Las nuevas tendencias de maquillaje se centran en colores vivos y técnicas innovadoras.",
],
});
foreach (RerankingResult result in output.Results)
{
Console.WriteLine($@"
Index: {result.Index}
Document: {result.Document?.Value1 ?? result.Document?.Value2?.Text}
RelevanceScore: {result.RelevanceScore}");
}
Support
Priority place for bugs: https://github.com/tryAGI/Jina/issues
Priority place for ideas and general questions: https://github.com/tryAGI/Jina/discussions
Discord: https://discord.gg/Ca2xhfBf3v
Acknowledgments
This project is supported by JetBrains through the Open Source Support Program.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net10.0 is compatible. 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.
-
net10.0
- Microsoft.Extensions.AI.Abstractions (>= 10.5.0)
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 |
|---|---|---|
| 1.1.2-dev.2 | 25 | 5/21/2026 |
| 1.1.1 | 95 | 4/30/2026 |
| 1.1.1-dev.619 | 63 | 4/1/2026 |
| 1.1.1-dev.608 | 66 | 3/29/2026 |
| 1.1.1-dev.607 | 64 | 3/29/2026 |
| 1.1.1-dev.597 | 160 | 3/28/2026 |
| 1.1.1-dev.594 | 68 | 3/28/2026 |
| 1.1.1-dev.592 | 67 | 3/28/2026 |
| 1.1.1-dev.591 | 61 | 3/28/2026 |
| 1.1.1-dev.589 | 67 | 3/27/2026 |
| 1.1.1-dev.556 | 58 | 3/20/2026 |
| 1.1.1-dev.551 | 64 | 3/20/2026 |
| 1.1.1-dev.550 | 59 | 3/19/2026 |
| 1.1.1-dev.547 | 65 | 3/19/2026 |
| 1.1.1-dev.546 | 62 | 3/19/2026 |
| 1.1.1-dev.544 | 62 | 3/19/2026 |
| 1.1.1-dev.543 | 58 | 3/19/2026 |
| 1.1.1-dev.542 | 60 | 3/19/2026 |
| 1.1.1-dev.539 | 58 | 3/19/2026 |
| 1.1.1-dev.538 | 61 | 3/19/2026 |
Loading failed