@compilr-dev/cli 0.10.1 → 0.10.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Binary file
@@ -8,6 +8,7 @@
8
8
  * Content is stored as plain text with simple structure.
9
9
  * Styling is applied at render time by each consumer.
10
10
  */
11
+ import { imageProviderNames } from '../models/model-registry.js';
11
12
  // =============================================================================
12
13
  // Content Topics
13
14
  // =============================================================================
@@ -1296,7 +1297,7 @@ export const CONTENT_TOPICS = [
1296
1297
  'Images are resized to max 1568px to save tokens',
1297
1298
  'After a few turns, old images are replaced with text placeholders',
1298
1299
  'The agent can also view image files on disk via the view_image tool',
1299
- 'All major providers support vision: Claude, GPT-4o, Gemini',
1300
+ `Which models can see an image comes from the registry: ${imageProviderNames()}`,
1300
1301
  ],
1301
1302
  },
1302
1303
  ],
package/dist/index.js CHANGED
@@ -117,8 +117,8 @@ Other Environment Variables:
117
117
 
118
118
  Examples:
119
119
  compilr Start with auto-detected provider
120
- compilr --model claude-sonnet-4-6 Use a specific model
121
- compilr --provider gemini --model gemini-2.5-flash
120
+ compilr --model ${getDefaultModel('claude')}${' '.repeat(Math.max(1, 33 - getDefaultModel('claude').length))}Use a specific model
121
+ compilr --provider gemini --model ${getDefaultModel('gemini')}
122
122
  compilr --minimal --show-filtering Minimal tools with analysis
123
123
  compilr --update Check for updates
124
124
  `);
@@ -36,3 +36,9 @@ export declare function getDefaultModelsForProvider(provider: ProviderType): Mod
36
36
  * Get all models for a provider (including non-defaults), formatted for UI overlays.
37
37
  */
38
38
  export declare function getAllModelsForProviderUI(provider: ProviderType): ModelOptionForUI[];
39
+ /** "Haiku 4.5, GPT-6 Luna, Gemini 3.5 Flash Lite" — the current line-up for one tier. */
40
+ export declare function tierModelExamples(tier: ModelTier, providers?: readonly string[]): string;
41
+ /** The current default model's display name for a tier and provider: "Sonnet 5.5". */
42
+ export declare function tierModelName(provider: string, tier: ModelTier): string;
43
+ /** "Claude, OpenAI, Gemini" — the providers whose current models accept images. */
44
+ export declare function imageProviderNames(): string;
@@ -68,3 +68,37 @@ export function getAllModelsForProviderUI(provider) {
68
68
  tier: m.defaultTier,
69
69
  }));
70
70
  }
71
+ // =============================================================================
72
+ // Tutorial / help text helpers
73
+ // =============================================================================
74
+ /*
75
+ ⚠️ MODEL NAMES IN TUTORIAL TEXT ARE DERIVED, NEVER TYPED IN.
76
+
77
+ The tutorials used to name models in prose and in their screen mock-ups — "Haiku, GPT-4o-mini",
78
+ "Sonnet, GPT-4o", "Opus, o1", "Model: gemini-2.5-flash". All retired, and the tutorials are
79
+ what a new user follows on their first day: a stale model there sends them looking for a model
80
+ that no longer exists and reads as the tool being broken.
81
+
82
+ A current tier model is one with a `defaultTier` — the registry keeps older ids addressable but
83
+ untiered, which is exactly the line to draw for a "here is what to pick" tutorial.
84
+ */
85
+ /** "Haiku 4.5, GPT-6 Luna, Gemini 3.5 Flash Lite" — the current line-up for one tier. */
86
+ export function tierModelExamples(tier, providers = ['claude', 'openai', 'gemini']) {
87
+ const names = providers.flatMap((p) => MODEL_REGISTRY.filter((m) => m.provider === p && m.defaultTier === tier).map((m) => m.displayName));
88
+ return names.join(', ');
89
+ }
90
+ /** The current default model's display name for a tier and provider: "Sonnet 5.5". */
91
+ export function tierModelName(provider, tier) {
92
+ return (MODEL_REGISTRY.find((m) => m.provider === provider && m.defaultTier === tier)?.displayName ?? '');
93
+ }
94
+ /** "Claude, OpenAI, Gemini" — the providers whose current models accept images. */
95
+ export function imageProviderNames() {
96
+ const seen = [];
97
+ for (const m of MODEL_REGISTRY) {
98
+ if (m.supportsImages && m.defaultTier !== undefined && !seen.includes(m.provider)) {
99
+ seen.push(m.provider);
100
+ }
101
+ }
102
+ const label = { claude: 'Claude', openai: 'OpenAI', gemini: 'Gemini' };
103
+ return seen.map((p) => label[p] ?? p).join(', ');
104
+ }
@@ -10,7 +10,7 @@ export { getActiveProject, setActiveProject } from './project-db.js';
10
10
  /**
11
11
  * All database tools combined (32 tools from SDK)
12
12
  */
13
- export declare const allDbTools: import("@compilr-dev/agents").Tool<never>[];
13
+ export declare const allDbTools: import("@compilr-dev/sdk").Tool<never>[];
14
14
  /**
15
15
  * All factory tools (5 tools from @compilr-dev/factory)
16
16
  */
@@ -3,6 +3,7 @@
3
3
  *
4
4
  * How to interact with the AI in REPL mode.
5
5
  */
6
+ import { getDefaultModelForTier } from '../../../../../models/model-registry.js';
6
7
  export const firstConversationTutorial = (s) => ({
7
8
  id: 'first-conversation',
8
9
  title: 'Your First Conversation',
@@ -41,7 +42,7 @@ export const firstConversationTutorial = (s) => ({
41
42
  '',
42
43
  ` ${s.muted('✓ Agent connected')}`,
43
44
  '',
44
- ` ${s.muted('Model: gemini-2.5-flash')}`,
45
+ ` ${s.muted(`Model: ${getDefaultModelForTier('gemini', 'balanced')?.id ?? ''}`)}`,
45
46
  ` ${s.muted('Provider: gemini')}`,
46
47
  ` ${s.muted('[^_^] Switched to project: My First Project')}`,
47
48
  '',
@@ -4,6 +4,7 @@
4
4
  * How to share images (screenshots, mockups, diagrams) with the agent
5
5
  * for visual analysis.
6
6
  */
7
+ import { imageProviderNames } from '../../../../../models/model-registry.js';
7
8
  export const imageSupportTutorial = (s) => ({
8
9
  id: 'image-support',
9
10
  title: 'Image Support',
@@ -28,7 +29,7 @@ export const imageSupportTutorial = (s) => ({
28
29
  '',
29
30
  ` ${s.primaryBold('PNG')} · ${s.primaryBold('JPEG')} · ${s.primaryBold('GIF')} · ${s.primaryBold('WebP')}`,
30
31
  '',
31
- ` ${s.secondary('Supported by:')} Claude, GPT-4o, Gemini (all major vision models)`,
32
+ ` ${s.secondary('Supported by:')} ${imageProviderNames()} (from the model registry)`,
32
33
  '',
33
34
  ],
34
35
  },
@@ -3,6 +3,7 @@
3
3
  *
4
4
  * Covers the /model overlay: provider tabs, tiers, API keys, model cycling.
5
5
  */
6
+ import { tierModelExamples, tierModelName } from '../../../../../models/model-registry.js';
6
7
  export const modelSelectionTutorial = (s) => ({
7
8
  id: 'model-selection',
8
9
  title: 'Model Selection',
@@ -44,9 +45,9 @@ export const modelSelectionTutorial = (s) => ({
44
45
  '',
45
46
  ` ${s.success('●')} API Key: Set`,
46
47
  '',
47
- ` ${s.primary('>')} ${s.success('●')} Fast Haiku 4.5 (active)`,
48
- ` ${s.success('●')} Balanced Sonnet 4.5`,
49
- ` ${s.success('●')} Powerful Opus 4.5`,
48
+ ` ${s.primary('>')} ${s.success('●')} Fast ${tierModelName('claude', 'fast')}${' '.repeat(Math.max(1, 23 - tierModelName('claude', 'fast').length))}(active)`,
49
+ ` ${s.success('●')} Balanced ${tierModelName('claude', 'balanced')}`,
50
+ ` ${s.success('●')} Powerful ${tierModelName('claude', 'powerful')}`,
50
51
  '',
51
52
  ` ${s.muted('Status indicators:')}`,
52
53
  ` ${s.success('●')} API key set / Ollama installed`,
@@ -139,13 +140,13 @@ export const modelSelectionTutorial = (s) => ({
139
140
  '',
140
141
  ` ${s.warning('TIP:')} Match the model to the task:`,
141
142
  '',
142
- ` ${s.primary('Fast')} tier ${s.muted('(Haiku, GPT-4o-mini)')}`,
143
+ ` ${s.primary('Fast')} tier ${s.muted(`(${tierModelExamples('fast')})`)}`,
143
144
  ` Simple questions, quick edits, file reads`,
144
145
  '',
145
- ` ${s.primary('Balanced')} tier ${s.muted('(Sonnet, GPT-4o)')}`,
146
+ ` ${s.primary('Balanced')} tier ${s.muted(`(${tierModelExamples('balanced')})`)}`,
146
147
  ` Feature implementation, debugging, code review`,
147
148
  '',
148
- ` ${s.primary('Powerful')} tier ${s.muted('(Opus, o1)')}`,
149
+ ` ${s.primary('Powerful')} tier ${s.muted(`(${tierModelExamples('powerful')})`)}`,
149
150
  ` Architecture decisions, complex refactoring`,
150
151
  '',
151
152
  ` ${s.warning('TIP:')} Team agents can use different tiers.`,
@@ -3,6 +3,7 @@
3
3
  *
4
4
  * Covers $ prefix switching, autocomplete, custom agents, and tool profiles.
5
5
  */
6
+ import { tierModelExamples } from '../../../../../models/model-registry.js';
6
7
  export const workingWithAgentsTutorial = (s) => ({
7
8
  id: 'working-with-agents',
8
9
  title: 'Working with Agents',
@@ -95,10 +96,10 @@ export const workingWithAgentsTutorial = (s) => ({
95
96
  ` Each agent has a ${s.primaryBold('model tier')} setting:`,
96
97
  '',
97
98
  ` ${s.primaryBold('Fast')} Quick responses, low cost`,
98
- ` ${s.muted(' Claude Haiku, GPT-4o Mini, Gemini Flash')}`,
99
+ ` ${s.muted(` ${tierModelExamples('fast')}`)}`,
99
100
  '',
100
101
  ` ${s.primaryBold('Balanced')} Good quality/speed balance (default)`,
101
- ` ${s.muted(' Claude Sonnet, GPT-4o, Gemini Pro')}`,
102
+ ` ${s.muted(` ${tierModelExamples('balanced')}`)}`,
102
103
  '',
103
104
  ` ${s.primaryBold('Powerful')} Maximum capability`,
104
105
  ` ${s.muted(' Claude Opus, GPT-4, Gemini Ultra')}`,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@compilr-dev/cli",
3
- "version": "0.10.1",
3
+ "version": "0.10.2",
4
4
  "description": "AI-powered coding assistant CLI using @compilr-dev/agents",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",
@@ -55,12 +55,12 @@
55
55
  },
56
56
  "dependencies": {
57
57
  "@anthropic-ai/sdk": "^0.74.0",
58
- "@compilr-dev/agents": "^0.6.8",
58
+ "@compilr-dev/agents": "^0.8.0",
59
59
  "@compilr-dev/agents-coding": "^1.0.4",
60
60
  "@compilr-dev/editor-core": "^0.0.3",
61
61
  "@compilr-dev/factory": "^0.1.35",
62
62
  "@compilr-dev/logger": "^0.1.0",
63
- "@compilr-dev/sdk": "^0.33.0",
63
+ "@compilr-dev/sdk": "^0.35.0",
64
64
  "@compilr-dev/ui-core": "^0.0.1",
65
65
  "@modelcontextprotocol/sdk": "^1.23.0",
66
66
  "ansi-escapes": "^7.3.0",