From d12a75bcfb625a1fc91fe5c4ec6071f5d009bbf7 Mon Sep 17 00:00:00 2001 From: Tomi Eckert Date: Wed, 4 Mar 2026 12:04:50 +0100 Subject: [PATCH] feat: update default model to qwen/qwen3.5-397b-a17b --- AnchorConfig.cs | 2 +- SetupTui.cs | 34 +++++++++++++++++++++++++++++----- 2 files changed, 30 insertions(+), 6 deletions(-) diff --git a/AnchorConfig.cs b/AnchorConfig.cs index da15967..148783f 100644 --- a/AnchorConfig.cs +++ b/AnchorConfig.cs @@ -6,7 +6,7 @@ namespace AnchorCli; internal sealed class AnchorConfig { public string ApiKey { get; set; } = ""; - public string Model { get; set; } = "qwen/qwen3.5-27b"; + public string Model { get; set; } = "qwen/qwen3.5-397b-a17b"; // ── Persistence ────────────────────────────────────────────────────── diff --git a/SetupTui.cs b/SetupTui.cs index a5e3ccf..b0c82bf 100644 --- a/SetupTui.cs +++ b/SetupTui.cs @@ -29,12 +29,36 @@ internal static class SetupTui // ── Model ───────────────────────────────────────────────────── AnsiConsole.MarkupLine($" Current model: [cyan]{Markup.Escape(config.Model)}[/]"); - string newModel = AnsiConsole.Prompt( - new TextPrompt(" New model [dim](Enter to keep)[/]:") - .AllowEmpty()); - if (!string.IsNullOrWhiteSpace(newModel)) - config.Model = newModel.Trim(); + var models = new List<(string Value, string Description)> + { + ("qwen/qwen3.5-397b-a17b", "smart, expensive"), + ("qwen/qwen3.5-35b-a3b", "cheapest"), + ("qwen/qwen3.5-27b", "fast"), + ("qwen/qwen3.5-122b-a10b", "smart"), + ("Custom...", "") + }; + + string selectedModel = AnsiConsole.Prompt( + new SelectionPrompt<(string Value, string Description)>() + .Title(" Select a model:") + .UseConverter(m => m.Value + (string.IsNullOrEmpty(m.Description) ? "" : $" [dim]({m.Description})[/]")) + .AddChoices(models)) + .Value; + + if (selectedModel == "Custom...") + { + string customModel = AnsiConsole.Prompt( + new TextPrompt(" Enter custom model name:") + .AllowEmpty()); + + if (!string.IsNullOrWhiteSpace(customModel)) + config.Model = customModel.Trim(); + } + else + { + config.Model = selectedModel; + } // ── Save ────────────────────────────────────────────────────── AnsiConsole.WriteLine();