Property Guidance
- Namespace
- LMKit.Extraction
- Assembly
- LM-Kit.NET.dll
Guidance
Gets or sets semantic guidance for the extraction process.
public string Guidance { get; set; }
Property Value
- string
A string providing contextual guidance to improve the accuracy of the extraction. Defaults to an empty string.
Examples
var te = new TextExtraction(LM.LoadFromModelID("lmkit-tasks:4b-preview"));
te.Guidance = "The text is a shipping label. Prioritize 'TrackingNumber' and 'ShipTo' fields.";
te.Elements = new List<TextExtractionElement>
{
new TextExtractionElement("TrackingNumber", ElementType.String),
new TextExtractionElement("ShipTo", new [] {
new TextExtractionElement("Name", ElementType.String),
new TextExtractionElement("City", ElementType.String)
}, isArray: false)
};
te.SetContent("Ship to: Bob, Paris. Tracking: 1Z999AA10123456784");
var r = te.Parse();
Console.WriteLine(r.Json);
Remarks
Guidance can be used to provide additional context or instructions to the language model, helping it better understand the structure and meaning of the content.