< Summary

Information
Class: Orchestrator.Commands.Observability.ExportExperimentItem.ExportExperimentItemSettings
Assembly: Orchestrator
File(s): /home/runner/work/KicktippAi/KicktippAi/src/Orchestrator/Commands/Observability/ExportExperimentItem/ExportExperimentItemSettings.cs
Line coverage
0%
Covered lines: 0
Uncovered lines: 24
Coverable lines: 24
Total lines: 83
Line coverage: 0%
Branch coverage
0%
Covered branches: 0
Total branches: 12
Branch coverage: 0%
Method coverage

Feature is only available for sponsors

Upgrade to PRO version

Metrics

MethodBranch coverage Crap Score Cyclomatic complexity Line coverage
get_Model()100%210%
set_Model(...)100%210%
.ctor()100%210%
get_CommunityContext()100%210%
set_CommunityContext(...)100%210%
get_HomeTeam()100%210%
set_HomeTeam(...)100%210%
get_AwayTeam()100%210%
set_AwayTeam(...)100%210%
get_Matchday()100%210%
set_Matchday(...)100%210%
get_WithJustification()100%210%
set_WithJustification(...)100%210%
get_EvaluationTime()100%210%
set_EvaluationTime(...)100%210%
get_OutputPath()100%210%
set_OutputPath(...)100%210%
Validate()0%156120%

File(s)

/home/runner/work/KicktippAi/KicktippAi/src/Orchestrator/Commands/Observability/ExportExperimentItem/ExportExperimentItemSettings.cs

#LineLine coverage
 1using System.ComponentModel;
 2using Spectre.Console;
 3using Spectre.Console.Cli;
 4
 5namespace Orchestrator.Commands.Observability.ExportExperimentItem;
 6
 7public sealed class ExportExperimentItemSettings : CommandSettings
 8{
 9    [CommandArgument(0, "<MODEL>")]
 10    [Description("The model used for the stored prediction that anchors prompt reconstruction")]
 011    public string Model { get; set; } = string.Empty;
 12
 13    [CommandOption("--community-context")]
 14    [Description("Community context used for the stored prediction")]
 015    public string CommunityContext { get; set; } = string.Empty;
 16
 17    [CommandOption("--home")]
 18    [Description("Home team name")]
 019    public string HomeTeam { get; set; } = string.Empty;
 20
 21    [CommandOption("--away")]
 22    [Description("Away team name")]
 023    public string AwayTeam { get; set; } = string.Empty;
 24
 25    [CommandOption("--matchday")]
 26    [Description("Matchday number for the selected match")]
 027    public int? Matchday { get; set; }
 28
 29    [CommandOption("--with-justification")]
 30    [Description("Reconstruct the justification prompt variant")]
 31    [DefaultValue(false)]
 032    public bool WithJustification { get; set; }
 33
 34    [CommandOption("--evaluation-time")]
 35    [Description("Optional explicit evaluation time in NodaTime invariant ZonedDateTime 'G' format, for example '2026-03
 036    public string? EvaluationTime { get; set; }
 37
 38    [CommandOption("--output")]
 39    [Description("Path to the JSON file to write. Defaults to artifacts/langfuse-runner-spike/<match>.json")]
 040    public string? OutputPath { get; set; }
 41
 42    public override ValidationResult Validate()
 43    {
 044        if (string.IsNullOrWhiteSpace(Model))
 45        {
 046            return ValidationResult.Error("Model is required");
 47        }
 48
 049        if (string.IsNullOrWhiteSpace(CommunityContext))
 50        {
 051            return ValidationResult.Error("--community-context is required");
 52        }
 53
 054        if (string.IsNullOrWhiteSpace(HomeTeam))
 55        {
 056            return ValidationResult.Error("--home must be provided");
 57        }
 58
 059        if (string.IsNullOrWhiteSpace(AwayTeam))
 60        {
 061            return ValidationResult.Error("--away must be provided");
 62        }
 63
 064        if (!Matchday.HasValue)
 65        {
 066            return ValidationResult.Error("--matchday must be provided");
 67        }
 68
 069        if (!string.IsNullOrWhiteSpace(EvaluationTime))
 70        {
 71            try
 72            {
 073                _ = Commands.Observability.EvaluationTimeParser.Parse(EvaluationTime);
 074            }
 75            catch (ArgumentException ex)
 76            {
 077                return ValidationResult.Error(ex.Message);
 78            }
 79        }
 80
 081        return ValidationResult.Success();
 082    }
 83}