archondev 2.6.0 → 2.7.0

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.
@@ -2,8 +2,8 @@ import {
2
2
  login,
3
3
  logout,
4
4
  status
5
- } from "./chunk-SGGLAY6G.js";
6
- import "./chunk-DHGQPKIV.js";
5
+ } from "./chunk-IA3ENLBQ.js";
6
+ import "./chunk-UG5MAS4X.js";
7
7
  import "./chunk-Y7DQ5XTU.js";
8
8
  import "./chunk-M4LGRTLC.js";
9
9
  import "./chunk-QGM4M3NI.js";
@@ -2,7 +2,7 @@ import {
2
2
  handleTierSetup,
3
3
  promptTierSelection,
4
4
  updateUserTier
5
- } from "./chunk-DHGQPKIV.js";
5
+ } from "./chunk-UG5MAS4X.js";
6
6
  import {
7
7
  clearConfig,
8
8
  loadConfig,
@@ -70,7 +70,7 @@ async function promptTierSelection() {
70
70
  case "s":
71
71
  case "skip":
72
72
  case "":
73
- console.log(chalk.dim("\nDefaulting to Free tier. You can change this anytime with `archon pricing`"));
73
+ console.log(chalk.dim("\nDefaulting to Free tier. You can upgrade anytime with `archon upgrade`"));
74
74
  return { tier: "FREE", skipped: true };
75
75
  default:
76
76
  console.log(chalk.yellow("Invalid choice. Defaulting to Free tier."));
@@ -141,54 +141,89 @@ async function createCheckoutSession(amountCents) {
141
141
  return null;
142
142
  }
143
143
  }
144
- async function showTierSwitchMenu() {
144
+ async function showUpgradeMenu() {
145
145
  const config = await loadConfig();
146
146
  const currentTier = config.tier || "FREE";
147
147
  console.log();
148
- console.log(chalk.bold("Pricing & Billing"));
148
+ console.log(chalk.bold("ARCHONDEV UPGRADE OPTIONS"));
149
149
  console.log();
150
- console.log(`Current tier: ${formatTierDisplay(currentTier)}`);
150
+ console.log(chalk.dim("\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501"));
151
+ console.log(`CURRENT TIER: ${formatTierDisplay(currentTier)}`);
151
152
  console.log();
152
- console.log(chalk.dim("Choose a pricing model:\n"));
153
- const tiers = [
154
- { key: "1", tier: "FREE", info: TIER_INFO.FREE },
155
- { key: "2", tier: "BYOK", info: TIER_INFO.BYOK },
156
- { key: "3", tier: "CREDITS", info: TIER_INFO.CREDITS }
157
- ];
158
- for (const { key, tier, info } of tiers) {
159
- const isCurrent = tier === currentTier;
160
- const marker = isCurrent ? chalk.green("\u25CF ") : "\u25CB ";
161
- console.log(` ${chalk.cyan(key)}) ${marker}${chalk.bold(info.name)}`);
162
- console.log(chalk.dim(` ${info.description}`));
163
- if (tier !== "FREE") {
164
- console.log(chalk.green(` \u2713 ${info.models}`));
165
- }
153
+ if (currentTier !== "FREE") {
154
+ console.log(chalk.green("\u2713 You have unlimited access!"));
155
+ console.log();
156
+ console.log(chalk.dim("Switch tiers:"));
157
+ } else {
158
+ console.log(chalk.bold("UPGRADE TO UNLOCK UNLIMITED ACCESS:"));
159
+ }
160
+ console.log();
161
+ const byokCurrent = currentTier === "BYOK";
162
+ const byokMarker = byokCurrent ? chalk.green("\u25CF ") : "\u25CB ";
163
+ console.log(` ${chalk.cyan("1")}) ${byokMarker}${chalk.bold("\u{1F511} BRING YOUR OWN KEY (BYOK)")} ${chalk.green("- FREE")}`);
164
+ console.log(chalk.dim(" \u2022 Pay only your actual API provider costs (OpenAI, Anthropic, etc.)"));
165
+ console.log(chalk.dim(" \u2022 No ArchonDev fees"));
166
+ console.log(chalk.dim(" \u2022 Full control over your API keys"));
167
+ console.log(chalk.green(" \u2713 Unlimited usage"));
168
+ console.log();
169
+ const creditsCurrent = currentTier === "CREDITS";
170
+ const creditsMarker = creditsCurrent ? chalk.green("\u25CF ") : "\u25CB ";
171
+ console.log(` ${chalk.cyan("2")}) ${creditsMarker}${chalk.bold("\u{1F4B3} MANAGED PLAN")}`);
172
+ console.log(chalk.dim(" \u2022 Just 10% service fee above actual AI costs"));
173
+ console.log(chalk.dim(" \u2022 No API key setup required"));
174
+ console.log(chalk.dim(" \u2022 We handle all provider billing"));
175
+ console.log(chalk.green(" \u2713 Unlimited usage"));
176
+ console.log();
177
+ if (currentTier !== "FREE") {
178
+ const freeMarker = currentTier === "FREE" ? chalk.green("\u25CF ") : "\u25CB ";
179
+ console.log(` ${chalk.cyan("3")}) ${freeMarker}${chalk.dim("Free (Limited)")}`);
180
+ console.log(chalk.dim(" \u2022 Basic models, limited usage"));
166
181
  console.log();
167
182
  }
168
- console.log(` ${chalk.dim("b")}) Back`);
183
+ console.log(chalk.dim("\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501"));
169
184
  console.log();
170
- const choice = await prompt("Enter choice");
185
+ console.log(` ${chalk.dim("b")}) Back / Cancel`);
186
+ console.log();
187
+ const choice = await prompt("Enter choice (1-2 or b)");
171
188
  if (choice.toLowerCase() === "b" || choice === "") {
172
189
  return;
173
190
  }
174
- const selected = tiers.find((t) => t.key === choice);
175
- if (!selected) {
191
+ let selectedTier = null;
192
+ let selectedName = "";
193
+ switch (choice) {
194
+ case "1":
195
+ selectedTier = "BYOK";
196
+ selectedName = "BYOK (Bring Your Own Key)";
197
+ break;
198
+ case "2":
199
+ selectedTier = "CREDITS";
200
+ selectedName = "Managed Plan";
201
+ break;
202
+ case "3":
203
+ if (currentTier !== "FREE") {
204
+ selectedTier = "FREE";
205
+ selectedName = "Free";
206
+ }
207
+ break;
208
+ }
209
+ if (!selectedTier) {
176
210
  console.log(chalk.yellow("Invalid choice."));
177
211
  return;
178
212
  }
179
- if (selected.tier === currentTier) {
180
- console.log(chalk.dim("Already using this pricing model."));
213
+ if (selectedTier === currentTier) {
214
+ console.log(chalk.dim("Already using this tier."));
181
215
  return;
182
216
  }
183
- const spinner = ora(`Switching to ${selected.info.name}...`).start();
184
- const result = await updateUserTier(selected.tier);
217
+ const spinner = ora(`Switching to ${selectedName}...`).start();
218
+ const result = await updateUserTier(selectedTier);
185
219
  if (result.success) {
186
- spinner.succeed(chalk.green(`Switched to ${selected.info.name}`));
187
- await handleTierSetup(selected.tier);
220
+ spinner.succeed(chalk.green(`\u2713 Switched to ${selectedName}`));
221
+ await handleTierSetup(selectedTier);
188
222
  } else {
189
223
  spinner.fail(chalk.red(result.error || "Failed to update tier"));
190
224
  }
191
225
  }
226
+ var showTierSwitchMenu = showUpgradeMenu;
192
227
  async function updateUserTier(tier) {
193
228
  try {
194
229
  const config = await loadConfig();
@@ -260,6 +295,7 @@ function promptYesNo(question, defaultValue) {
260
295
  export {
261
296
  promptTierSelection,
262
297
  handleTierSetup,
298
+ showUpgradeMenu,
263
299
  showTierSwitchMenu,
264
300
  updateUserTier
265
301
  };
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  login
3
- } from "./chunk-SGGLAY6G.js";
3
+ } from "./chunk-IA3ENLBQ.js";
4
4
  import {
5
5
  getApiUrl,
6
6
  getAuthToken,
package/dist/index.js CHANGED
@@ -18,7 +18,7 @@ import {
18
18
  setPreference,
19
19
  showExecutionPreferences,
20
20
  showPreferences
21
- } from "./chunk-ZP75P65T.js";
21
+ } from "./chunk-ZCWCSRCQ.js";
22
22
  import {
23
23
  parallelClean,
24
24
  parallelMerge,
@@ -62,12 +62,12 @@ import {
62
62
  login,
63
63
  logout,
64
64
  status
65
- } from "./chunk-SGGLAY6G.js";
65
+ } from "./chunk-IA3ENLBQ.js";
66
66
  import {
67
67
  handleTierSetup,
68
68
  promptTierSelection,
69
69
  updateUserTier
70
- } from "./chunk-DHGQPKIV.js";
70
+ } from "./chunk-UG5MAS4X.js";
71
71
  import {
72
72
  getAuthToken,
73
73
  loadConfig,
@@ -2614,7 +2614,7 @@ async function start(options = {}) {
2614
2614
  } else {
2615
2615
  config.tierConfirmed = true;
2616
2616
  await saveConfig(config);
2617
- console.log(chalk5.dim("Using Free tier. You can change this anytime with `archon pricing`\n"));
2617
+ console.log(chalk5.dim("Using Free tier. You can upgrade anytime with `archon upgrade`\n"));
2618
2618
  }
2619
2619
  }
2620
2620
  }
@@ -2623,8 +2623,14 @@ async function start(options = {}) {
2623
2623
  }
2624
2624
  const currentTier = config.tier || "FREE";
2625
2625
  const tierDisplay = formatTierName(currentTier);
2626
- const upgradeHint = currentTier === "FREE" ? chalk5.dim(" \u2014 Run `archon pricing` to upgrade") : "";
2627
- console.log(chalk5.dim(`Tier: `) + tierDisplay + upgradeHint);
2626
+ console.log(chalk5.dim(`Tier: `) + tierDisplay);
2627
+ if (currentTier === "FREE") {
2628
+ console.log();
2629
+ console.log(chalk5.yellow("\u26A0\uFE0F FREE TIER: Limited usage. Upgrade options:"));
2630
+ console.log(chalk5.dim(" \u2022 ") + chalk5.bold("BYOK (FREE)") + chalk5.dim(" - Unlimited usage with your own API keys"));
2631
+ console.log(chalk5.dim(" \u2022 ") + chalk5.bold("Managed Plan") + chalk5.dim(" - Just 10% fee on AI costs, zero setup"));
2632
+ console.log(chalk5.cyan("\u2192 Run ") + chalk5.bold("'archon upgrade'") + chalk5.cyan(" to unlock unlimited access"));
2633
+ }
2628
2634
  console.log();
2629
2635
  const updateResult = await updateCheckPromise;
2630
2636
  if (updateResult?.hasUpdate) {
@@ -3283,7 +3289,7 @@ async function listAtoms() {
3283
3289
  async function executeNext() {
3284
3290
  const { listLocalAtoms: listLocalAtoms2 } = await import("./plan-67BMJFES.js");
3285
3291
  const { analyzeProject, getComplexityDescription, getModeDescription } = await import("./orchestration-X6LHSHBJ.js");
3286
- const { loadExecutionPreferences } = await import("./preferences-DRR4A76D.js");
3292
+ const { loadExecutionPreferences } = await import("./preferences-6J2UVWLQ.js");
3287
3293
  const cwd = process.cwd();
3288
3294
  const atoms = await listLocalAtoms2();
3289
3295
  const pendingAtoms = atoms.filter((a) => a.status === "READY" || a.status === "IN_PROGRESS");
@@ -3330,11 +3336,11 @@ async function reportBug() {
3330
3336
  }
3331
3337
  }
3332
3338
  async function viewStatus() {
3333
- const { status: status2 } = await import("./auth-5BOORBOL.js");
3339
+ const { status: status2 } = await import("./auth-ZWXKMI3Q.js");
3334
3340
  await status2();
3335
3341
  }
3336
3342
  async function settingsMenu() {
3337
- const { interactiveSettings } = await import("./preferences-DRR4A76D.js");
3343
+ const { interactiveSettings } = await import("./preferences-6J2UVWLQ.js");
3338
3344
  await interactiveSettings();
3339
3345
  await showMainMenu();
3340
3346
  }
@@ -7466,9 +7472,13 @@ program.command("logout").description("Clear stored authentication").action(asyn
7466
7472
  program.command("status").description("Show current user and project status").action(async () => {
7467
7473
  await status();
7468
7474
  });
7469
- program.command("pricing").description("View and switch pricing tiers (Free, BYOK, Credits)").action(async () => {
7470
- const { showTierSwitchMenu } = await import("./tier-selection-YPES45QY.js");
7471
- await showTierSwitchMenu();
7475
+ program.command("upgrade").description("Upgrade your tier (BYOK for free unlimited, or Managed plan)").action(async () => {
7476
+ const { showUpgradeMenu } = await import("./tier-selection-LQ7ZOBEK.js");
7477
+ await showUpgradeMenu();
7478
+ });
7479
+ program.command("pricing", { hidden: true }).action(async () => {
7480
+ const { showUpgradeMenu } = await import("./tier-selection-LQ7ZOBEK.js");
7481
+ await showUpgradeMenu();
7472
7482
  });
7473
7483
  program.command("init").description("Initialize ArchonDev in current project").option("--analyze", "Run enhanced analysis of codebase").option("--no-git", "Skip git initialization").action(async (options) => {
7474
7484
  await init(options);
@@ -7,10 +7,10 @@ import {
7
7
  setPreference,
8
8
  showExecutionPreferences,
9
9
  showPreferences
10
- } from "./chunk-ZP75P65T.js";
10
+ } from "./chunk-ZCWCSRCQ.js";
11
11
  import "./chunk-QN65APWL.js";
12
- import "./chunk-SGGLAY6G.js";
13
- import "./chunk-DHGQPKIV.js";
12
+ import "./chunk-IA3ENLBQ.js";
13
+ import "./chunk-UG5MAS4X.js";
14
14
  import "./chunk-Y7DQ5XTU.js";
15
15
  import "./chunk-M4LGRTLC.js";
16
16
  import "./chunk-WH6IKTYF.js";
@@ -2,8 +2,9 @@ import {
2
2
  handleTierSetup,
3
3
  promptTierSelection,
4
4
  showTierSwitchMenu,
5
+ showUpgradeMenu,
5
6
  updateUserTier
6
- } from "./chunk-DHGQPKIV.js";
7
+ } from "./chunk-UG5MAS4X.js";
7
8
  import "./chunk-Y7DQ5XTU.js";
8
9
  import "./chunk-M4LGRTLC.js";
9
10
  import "./chunk-QGM4M3NI.js";
@@ -11,5 +12,6 @@ export {
11
12
  handleTierSetup,
12
13
  promptTierSelection,
13
14
  showTierSwitchMenu,
15
+ showUpgradeMenu,
14
16
  updateUserTier
15
17
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "archondev",
3
- "version": "2.6.0",
3
+ "version": "2.7.0",
4
4
  "description": "Local-first AI-powered development governance system",
5
5
  "main": "dist/index.js",
6
6
  "bin": {