mirror of
https://github.com/MindWorkAI/AI-Studio.git
synced 2026-09-27 03:33:37 +00:00
Resolve the remaining unused-symbol warnings
This commit is contained in:
parent
fb8e37aaf3
commit
2c212f75f6
@ -679,7 +679,7 @@ public sealed partial class DataSourceEmbeddingService
|
||||
if (matches.Count == 0)
|
||||
return [text];
|
||||
|
||||
return matches.Cast<Match>().Select(match => match.Value).ToList();
|
||||
return matches.Select(match => match.Value).ToList();
|
||||
}
|
||||
|
||||
private static List<(int Start, int End, string Text)> ReadLines(string text)
|
||||
|
||||
@ -23,6 +23,13 @@ public sealed class DataSourceLocalRetrievalService(
|
||||
BM25,
|
||||
}
|
||||
|
||||
//
|
||||
// A hit keeps the complete shape both retrieval channels deliver, even where nothing reads a
|
||||
// value yet. Merging is deterministic on purpose for now, so Channel, Score and Rank have no
|
||||
// consumer until reranking arrives. Naming them still beats handing an unlabelled tuple of
|
||||
// strings and numbers through the service.
|
||||
//
|
||||
// ReSharper disable NotAccessedPositionalProperty.Local
|
||||
private sealed record LocalRetrievalHit(
|
||||
RetrievalChannel Channel,
|
||||
string ChunkId,
|
||||
@ -41,6 +48,7 @@ public sealed class DataSourceLocalRetrievalService(
|
||||
int Rank,
|
||||
string ConfidenceLevel,
|
||||
int ConfidenceLevelRank);
|
||||
// ReSharper restore NotAccessedPositionalProperty.Local
|
||||
|
||||
public Task<IReadOnlyList<IRetrievalContext>> RetrieveDataAsync(DataSourceLocalFile dataSource, IContent lastUserPrompt, ChatThread thread, CancellationToken token = default) =>
|
||||
this.RetrieveDataAsync(dataSource, lastUserPrompt, token);
|
||||
|
||||
@ -9,6 +9,13 @@ namespace AIStudio.Tools.Services;
|
||||
|
||||
public sealed class DataSourceService
|
||||
{
|
||||
//
|
||||
// Trust is recorded for every participating provider, while only the chat provider's trust
|
||||
// decides about external data sources below. The agent which validates retrieval contexts
|
||||
// checks its own provider before it runs, so nothing slips through today. Keeping the value
|
||||
// named here is what makes that asymmetry visible.
|
||||
//
|
||||
// ReSharper disable once NotAccessedPositionalProperty.Local
|
||||
private readonly record struct ParticipatingProvider(string Role, bool IsTrusted, ConfidenceLevel ConfidenceLevel);
|
||||
|
||||
private readonly RustService rustService;
|
||||
|
||||
Loading…
Reference in New Issue
Block a user