using AIStudio.AIOperations; using AIStudio.AIOperations.DataSourceChoice; using AIStudio.AIOperations.PluginAudit; using AIStudio.AIOperations.RetrievalContextValidation; using AIStudio.Assistants.BeyondFactsLab; using AIStudio.Assistants.Builder; using AIStudio.Assistants.ERI; using AIStudio.Assistants.ModelComparison; using AIStudio.Assistants.PromptOptimizer; using AIStudio.Assistants.SWOTAnalysis; using AIStudio.Tools.DocumentSegments; using AIStudio.Tools.PowerPoint; using AIStudio.Tools.Services; namespace AIStudio.Tests.Serialization; public static partial class JsonTestRoots { /// /// The JSON which models write for the AI operations and assistants of AI Studio, apart from the Visual Briefing /// assistant. /// public static IEnumerable ModelAnswers() { TestHost.PrepareStaticState(); // The AI operations, which select data sources, check retrieved passages, and audit assistant plugins: yield return Case(new(typeof(List), AIOperationsJson.OPTIONS)); yield return Case(new(typeof(RetrievalContextValidationAnswer), AIOperationsJson.OPTIONS)); yield return Case(new(typeof(PluginAuditResult), AIOperationsJson.OPTIONS)); // The Assistant Builder, for assistant plugins and for direct chat launchers: yield return Case(new(typeof(LuaResponse), LuaResponse.JSON_OPTIONS)); yield return Case(new(typeof(LauncherTextsResponse), LauncherTextsResponse.JSON_OPTIONS)); yield return Case(new(typeof(ModelComparisonJudgeAnswer), ModelComparisonJudgeVerdict.JSON_OPTIONS)); yield return Case(new(typeof(PromptOptimizationResult), AssistantPromptOptimizer.JSON_OPTIONS)); yield return Case(new(typeof(SwotCategoryAnalysisResult), SwotModelAnswer.JSON_OPTIONS)); yield return Case(new(typeof(SwotModerationResult), SwotModelAnswer.JSON_OPTIONS)); yield return Case(new(typeof(ERIServerFileList), ERIServerFileList.JSON_OPTIONS)); yield return Case(new(typeof(BflParticipantSelectionAnswer), BflModelAnswerJson.OPTIONS)); yield return Case(new(typeof(SlideDeckSpec.DeckDto), SlideDeckSpec.JSON_OPTIONS)); // The segments of a document, e.g., translated by the Translation assistant: yield return Case(new(typeof(SegmentBatch), SegmentJson.ANSWER_OPTIONS)); } /// /// The JSON which the Assistant Builder, the moderation of a SWOT analysis, and the work on the segments of a /// document put into their prompts. /// public static IEnumerable ModelPrompts() { TestHost.PrepareStaticState(); var untrusted = AssistantPluginGenerationService.UNTRUSTED_PROMPT_JSON_OPTIONS; yield return Case(new(typeof(AssistantBuilderDraftPromptData), untrusted)); yield return Case(new(typeof(AssistantBuilderGenerationPromptData), untrusted)); yield return Case(new(typeof(AssistantBuilderLauncherPromptData), untrusted)); yield return Case(new(typeof(AssistantBuilderRevisionPromptData), untrusted)); yield return Case(new(typeof(Dictionary), SwotAnalysisModeration.JSON_OPTIONS)); // The segments of a document, which a model works on: yield return Case(new(typeof(SegmentBatch), SegmentJson.PROMPT_OPTIONS)); } }