This commit is contained in:
15
docs/snippets/csharp/utils/token_reduction.md
Normal file
15
docs/snippets/csharp/utils/token_reduction.md
Normal file
@@ -0,0 +1,15 @@
|
||||
```csharp title="C#"
|
||||
using Kreuzberg;
|
||||
|
||||
var config = new ExtractionConfig
|
||||
{
|
||||
TokenReduction = new TokenReductionOptions
|
||||
{
|
||||
Mode = "moderate",
|
||||
PreserveImportantWords = true,
|
||||
},
|
||||
};
|
||||
|
||||
var result = await KreuzbergLib.ExtractFile("document.pdf", null, config);
|
||||
Console.WriteLine($"Content length: {result.Content.Length}");
|
||||
```
|
||||
Reference in New Issue
Block a user