stellar-agent 0.2.0 → 0.3.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.
@@ -0,0 +1,234 @@
1
+ ---
2
+ name: stellar-submission-prep
3
+ description: 'Final pre-submission checklist for Stellar/Soroban hackathons — repo polish, README, demo video, deployed testnet, contract IDs, Devpost/SCF/SDF form. Use when the user is in the last 2 hours before deadline, ready to hit submit, or verifying the submission is complete.'
4
+ ---
5
+
6
+ # Submission Prep
7
+
8
+ ## Purpose
9
+
10
+ Run the final checklist in the last 2 hours before submission. Catch the 5-minute fixes that cost the team a track win — missing testnet contract ID in README, demo video not uploaded, repo still private, team members not invited to Devpost.
11
+
12
+ ## On Activation
13
+
14
+ Load:
15
+ - `{planning_artifacts}/hackathon-brief.md`
16
+ - `{implementation_artifacts}/demo-storyboard.md`
17
+ - `{implementation_artifacts}/deployed-contracts.md` (if it exists)
18
+
19
+ Check the submission deadline. Surface hours remaining at the top of the response.
20
+
21
+ ## Workflow
22
+
23
+ ### Step 1: Surface Hours Remaining
24
+
25
+ ```
26
+ ⏳ Hours remaining: <X>
27
+
28
+ Recommended order for last 2h:
29
+ T-2:00 → Repository polish
30
+ T-1:30 → README final pass
31
+ T-1:00 → Demo video uploaded
32
+ T-0:30 → Submission form
33
+ T-0:15 → Buffer for re-submission
34
+ ```
35
+
36
+ If hours remaining < 0.5, skip non-critical items. Get the submission in first; polish after if time allows.
37
+
38
+ ### Step 2: Repository Checklist
39
+
40
+ ```markdown
41
+ ## Repository
42
+
43
+ - [ ] Public GitHub repo (not private — judges can't see private repos)
44
+ - [ ] Default branch is `main` and reflects the submitted code
45
+ - [ ] Repo URL has been tested in an incognito window
46
+ - [ ] `LICENSE` file present (MIT or Apache-2.0 is the safe default)
47
+ - [ ] `.gitignore` excludes: `target/`, `node_modules/`, `.env`, `*.wasm`, keypair files
48
+ - [ ] No secrets committed — grep for: `PRIVATE_KEY`, `S...` (raw secrets), `password`, `api_key`
49
+ - [ ] All team members are repo collaborators (or visibly active in commits)
50
+ - [ ] Last commit is from a hackathon-time window (judges check timestamps)
51
+ ```
52
+
53
+ If the repo is currently private, **make it public now**. Some hackathons disqualify private submissions outright.
54
+
55
+ ### Step 3: README Checklist
56
+
57
+ The README is the front door. A judge who can't run the project in 5 minutes moves on.
58
+
59
+ ```markdown
60
+ ## README must include
61
+
62
+ - [ ] One-line pitch at the top (`# <Project name>` + tagline)
63
+ - [ ] One screenshot or GIF in the first scroll height
64
+ - [ ] Demo video link (unlisted YouTube or hosted MP4)
65
+ - [ ] Live demo URL (if web-accessible) OR a "try it" section
66
+ - [ ] Install + run instructions a judge can copy-paste
67
+ - [ ] Testnet contract ID(s) with `stellar.expert` link
68
+ - [ ] At least one successful tx hash linked from `stellar.expert`
69
+ - [ ] Built-with stack (Soroban, Stellar SDK, Next.js, etc.)
70
+ - [ ] Team section with handles
71
+ - [ ] License
72
+ ```
73
+
74
+ #### README template skeleton
75
+
76
+ ```markdown
77
+ # <Project name>
78
+
79
+ > <One-sentence tagline>
80
+
81
+ ![<Screenshot>](docs/screenshot.png)
82
+
83
+ **Demo video:** <youtube link>
84
+ **Live demo:** <url>
85
+ **Testnet contract:** [`<CONTRACT_ID>`](https://stellar.expert/explorer/testnet/contract/<CONTRACT_ID>)
86
+ **Example tx:** [`<TX_HASH>`](https://stellar.expert/explorer/testnet/tx/<TX_HASH>)
87
+
88
+ ## Problem
89
+
90
+ <2–3 sentences>
91
+
92
+ ## Solution
93
+
94
+ <2–3 sentences>
95
+
96
+ ## How it works
97
+
98
+ <3 bullets describing the on-chain flow>
99
+
100
+ ## Install
101
+
102
+ \`\`\`bash
103
+ git clone <repo>
104
+ cd <repo>
105
+ npm install # or: cargo build --target wasm32-unknown-unknown --release
106
+ cp .env.example .env
107
+ npm run dev
108
+ \`\`\`
109
+
110
+ ## Stack
111
+
112
+ - Soroban smart contracts (Rust)
113
+ - @stellar/stellar-sdk (TypeScript)
114
+ - Next.js App Router
115
+ - Freighter wallet
116
+
117
+ ## Team
118
+
119
+ - <Name> (@handle) — <what they built>
120
+
121
+ ## License
122
+
123
+ MIT
124
+ ```
125
+
126
+ ### Step 4: On-Chain Verification
127
+
128
+ ```markdown
129
+ ## On-chain checklist
130
+
131
+ - [ ] Contract deployed to testnet — record contract ID in README
132
+ - [ ] Contract initialized (`initialize` or equivalent) — verify with `stellar contract invoke ... -- get_*`
133
+ - [ ] At least one successful tx hash linked from README
134
+ - [ ] If using a custom asset: issuing account + trustline tx hash documented
135
+ - [ ] If using SEP-10: auth endpoint live and returning valid JWTs
136
+ ```
137
+
138
+ Quick verification commands:
139
+ ```bash
140
+ # Confirm contract is alive
141
+ stellar contract invoke \
142
+ --id <CONTRACT_ID> \
143
+ --network testnet \
144
+ -- <view_function>
145
+
146
+ # Confirm a tx
147
+ curl -s "https://horizon-testnet.stellar.org/transactions/<TX_HASH>" | jq '.successful'
148
+ ```
149
+
150
+ ### Step 5: Demo Video Checklist
151
+
152
+ ```markdown
153
+ ## Demo video
154
+
155
+ - [ ] Recorded at 1080p+ (1920×1080 minimum)
156
+ - [ ] Length: 60–180s (check hackathon spec)
157
+ - [ ] Audio narration audible (no static, no clipping)
158
+ - [ ] Uploaded to YouTube as **unlisted** (NOT private — judges can't see private)
159
+ - [ ] OR hosted on Vimeo / direct MP4 — link works in incognito
160
+ - [ ] Linked from README
161
+ - [ ] Linked from submission form
162
+ - [ ] Thumbnail is a meaningful frame (not black, not the OS desktop)
163
+ ```
164
+
165
+ ### Step 6: Submission Form Checklist
166
+
167
+ The exact form depends on the platform (Devpost, SCF, SDF, Discord). Common fields:
168
+
169
+ ```markdown
170
+ ## Submission form
171
+
172
+ - [ ] Project title (matches repo name)
173
+ - [ ] Tagline (one sentence)
174
+ - [ ] Description (2–3 paragraphs — pull from README)
175
+ - [ ] Built-with tags include: `stellar`, `soroban`, language stack, frameworks
176
+ - [ ] Track selection confirmed (from `TR` recommendation)
177
+ - [ ] GitHub URL
178
+ - [ ] Demo video URL
179
+ - [ ] Live demo URL (if applicable)
180
+ - [ ] Testnet contract ID in the body
181
+ - [ ] Team members invited and they have **accepted** the invite (Devpost especially — unaccepted invites disqualify)
182
+ - [ ] Selected for the right hackathon (verify the URL on the submission page)
183
+ - [ ] Submission saved as draft once, then submitted (in case of platform error)
184
+ ```
185
+
186
+ ### Step 7: Final Sanity Checks
187
+
188
+ Before hitting "Submit":
189
+
190
+ - [ ] Open the GitHub repo in an incognito window — it loads, README renders
191
+ - [ ] Click the demo video link in incognito — it plays
192
+ - [ ] Click the testnet contract link in incognito — stellar.expert shows the contract
193
+ - [ ] Submission form preview matches what's in your README
194
+
195
+ ### Step 8: Submit and Confirm
196
+
197
+ After submission:
198
+ - [ ] Screenshot the "Submission received" page
199
+ - [ ] Confirmation email received (check spam)
200
+ - [ ] Submission visible on the public hackathon submission page (some platforms have a delay)
201
+
202
+ If anything fails, you have the buffer window in Step 1 to fix and resubmit.
203
+
204
+ ### Step 9: Sign-off
205
+
206
+ Pera signs off when the checklist is green:
207
+
208
+ > "Submitted. Hands off the keyboard. Get sleep."
209
+
210
+ Add a `## Submission` section to `{planning_artifacts}/hackathon-brief.md` capturing:
211
+ - Final submission timestamp
212
+ - Submission URL
213
+ - Track submitted
214
+ - Confirmation screenshot path
215
+
216
+ ## Anti-patterns to flag
217
+
218
+ - **Submitting at T-0 minutes.** Always submit at T-30 minimum. Platforms get flaky under deadline load.
219
+ - **Private repos / private videos.** Disqualifies the submission silently.
220
+ - **Unaccepted team invites.** Some platforms (Devpost) only credit accepted team members.
221
+ - **Submitting and then pushing more commits.** The submission snapshot is what's judged. Don't introduce regressions after submitting.
222
+ - **Skipping the incognito test.** Cookies hide private/draft state. Always verify in incognito.
223
+
224
+ ## Output
225
+
226
+ - Final state of `{planning_artifacts}/hackathon-brief.md` with `## Submission` section
227
+ - All checklist items confirmed before final submit
228
+
229
+ ## Next Steps
230
+
231
+ After submission:
232
+ - Get sleep.
233
+ - Prepare for live judging Q&A — review `{planning_artifacts}/judge-qa.md` if a live round is scheduled.
234
+ - Plan a mainnet follow-up only after the team has rested.
@@ -0,0 +1,97 @@
1
+ ---
2
+ name: stellar-track-recommendation
3
+ description: 'Match a hackathon idea to the right Stellar/Soroban track and surface the judging rubric for that track. Use when the user is undecided between tracks, wants to know which track fits their idea best, or needs to read the rubric before building.'
4
+ ---
5
+
6
+ # Track Recommendation
7
+
8
+ ## Purpose
9
+
10
+ Pick the right hackathon track for the idea. The wrong track punishes the team twice — judges score against criteria the build wasn't optimized for, and the team misses the rubric that would've shaped a better build.
11
+
12
+ ## On Activation
13
+
14
+ Load `{planning_artifacts}/hackathon-brief.md` if it exists. If not, recommend running `IS` (Idea Scoping) first.
15
+
16
+ If a hackathon URL was provided to Pera on greeting, fetch it now and read the official track list and rubrics. Treat the live page as source of truth — overrides anything below.
17
+
18
+ ## Workflow
19
+
20
+ ### Step 1: Identify Candidate Tracks
21
+
22
+ Match the idea against the Stellar hackathon track families:
23
+
24
+ | Track | Best fits | Stellar/Soroban primitive | Judging weight |
25
+ |---|---|---|---|
26
+ | **DeFi** | Lending, AMM, yield, perp/swap, stablecoin mech | Soroban contracts, AMM pools, trustlines | Technical depth · Composability · TVL potential |
27
+ | **Payments** | Cross-border, remittance, micropayments, payroll | Classic Stellar payments, anchors, path payments | UX · Cost per tx · Anchor / SEP integration |
28
+ | **Identity / SEP-10** | KYC, attestation, reputation, gated access | SEP-10 auth, Soroban storage for attestations | Privacy · SEP compliance · Real-world fit |
29
+ | **Gaming / NFT** | On-chain assets, in-game economy, collectibles | Custom assets, Soroban inventory contracts | Player retention · Creative use of Soroban |
30
+ | **RWA / Tokenization** | Real estate, invoices, commodities, carbon | Custom assets + Soroban escrow + oracles | Legal viability · Oracle design · Trust model |
31
+ | **Infra / DevTools** | SDKs, dashboards, oracles, indexers | Anything that helps other devs ship on Stellar | Developer adoption · Reusability |
32
+ | **Open / Other** | Idea doesn't fit above | Anything | Innovation · Demo · Business potential |
33
+
34
+ ### Step 2: Score the Idea Against Each Candidate
35
+
36
+ For each candidate track, produce a 3-line block:
37
+
38
+ ```
39
+ <Track>
40
+ Fit: <high | medium | low> — <one-line reason>
41
+ Win condition: <what would the judges score highly>
42
+ Risk: <what the judges will challenge>
43
+ ```
44
+
45
+ If two tracks score `high`, prefer the one with:
46
+ - Smaller judging field (less competition)
47
+ - Rubric the build naturally aligns to without rework
48
+
49
+ ### Step 3: Recommend
50
+
51
+ Output:
52
+
53
+ ```markdown
54
+ ## Track recommendation
55
+
56
+ **Primary:** <track>
57
+ **Why:** <one sentence — the strongest rubric alignment>
58
+ **Risk to mitigate:** <what to harden before submission>
59
+
60
+ **Secondary (if primary doesn't fit at submission):** <track>
61
+ ```
62
+
63
+ ### Step 4: Pull the Rubric
64
+
65
+ If the hackathon URL is known, extract the official rubric from the page. Otherwise use the generic Stellar judging rubric:
66
+
67
+ | Criterion | Default weight | Notes |
68
+ |---|---|---|
69
+ | Innovation | 25% | "Have we seen this before on Stellar?" |
70
+ | Technical implementation | 25% | Soroban depth, code quality, test coverage |
71
+ | Business / impact | 25% | Who pays, how big, distribution path |
72
+ | Demo quality | 25% | Recording, narration, on-chain proof |
73
+
74
+ Append to `{planning_artifacts}/hackathon-brief.md` as a `## Track + rubric` section.
75
+
76
+ ### Step 5: Confirm
77
+
78
+ Ask the user: *"Locking in `<track>` — proceed?"*
79
+
80
+ If yes, suggest `MV` next.
81
+ If no, present the secondary or ask what's missing.
82
+
83
+ ## Common mistakes
84
+
85
+ - **Picking DeFi by default.** DeFi is the most crowded track at most Stellar hackathons. A "DeFi-lite" idea in Payments or Identity often wins more easily.
86
+ - **Picking a track because the team likes it.** Track choice is about rubric fit, not preference.
87
+ - **Ignoring the official rubric.** Always pull the actual hackathon's rubric over generic priors. Hackathons weight criteria differently.
88
+ - **Multi-track submissions.** Most Stellar hackathons only allow one track. Picking two splits attention.
89
+
90
+ ## Output
91
+
92
+ Updates `{planning_artifacts}/hackathon-brief.md` with the chosen track and the rubric the build must align to.
93
+
94
+ ## Next Steps
95
+
96
+ - `stellar-mvp-definition` (MV) — cut the feature list against the chosen rubric
97
+ - `stellar-judging-criteria` (JC) — when the MVP is locked, map it to the rubric line-by-line
@@ -3,11 +3,13 @@ Stellar,_meta,,,,,,,,,false,https://github.com/tolgazorlu/stellar-agent#readme,
3
3
  Stellar,stellar-analytics,Analytics Setup,AN,Set up dbt blockchain analytics for Stellar network data and tokenomics reporting.,,,1-analysis,,,false,{project_knowledge},dbt models
4
4
  Stellar,stellar-market-research,Market Research,MR,DeFi landscape competitive analysis and Stellar ecosystem research.,,,1-analysis,,,false,{planning_artifacts},research document
5
5
  Stellar,stellar-domain-research,Domain Research,DR,Stellar protocol deep dive — tokenomics regulatory landscape and use case research.,,,1-analysis,,,false,{planning_artifacts},research document
6
+ Stellar,stellar-known-assets,Known Assets Registry,KA,Look up canonical Stellar asset issuer addresses (USDC EURC AQUA yXLM) with provenance and verification commands. Prevents issuer hallucination.,,,1-analysis,,,false,,
6
7
  Stellar,stellar-project-brief,Project Brief,PB,Define the dApp concept goals and target users in a concise brief.,,,2-planning,,,false,{planning_artifacts},project-brief
7
8
  Stellar,stellar-prd,Stellar dApp PRD,PR,Create or update Product Requirements Document for a Stellar application.,,,2-planning,stellar-project-brief,,true,{planning_artifacts},prd
8
9
  Stellar,stellar-epics-stories,Epics and Stories,ES,Break PRD into development epics and user stories with Stellar-specific acceptance criteria.,,,2-planning,stellar-prd,,true,{planning_artifacts},epics-stories
9
10
  Stellar,stellar-architecture-doc,Architecture Document,AD,Create technical architecture document covering on-chain vs off-chain Soroban contract design and Horizon integration.,,,3-architecture,stellar-prd,,true,{planning_artifacts},architecture
10
11
  Stellar,stellar-setup-environment,Setup Environment,SE,Set up local Stellar development environment with Docker quickstart Stellar CLI and SDK.,,,4-implementation,,,true,{project_knowledge},environment-guide
12
+ Stellar,stellar-doctor,Stellar Doctor,SD,Diagnose toolchain network reachability wallet state contract state and project context. Run before any deployment.,,,4-implementation,,,false,,
11
13
  Stellar,stellar-init-contract,Init Contract,IC,Initialize a new Soroban smart contract project with Rust workspace and scaffold.,,,4-implementation,stellar-setup-environment,,false,{implementation_artifacts},contract scaffold
12
14
  Stellar,stellar-write-contract,Write Contract,WC,Implement Soroban contract logic including storage types host functions and error handling.,,,4-implementation,stellar-init-contract,,false,{implementation_artifacts},contract code
13
15
  Stellar,stellar-test-contract,Test Contract,TC,Write and run comprehensive Soroban contract tests using the Rust test harness.,,,4-implementation,stellar-write-contract,,true,{implementation_artifacts},test suite
@@ -22,3 +24,10 @@ Stellar,stellar-nextjs-wallet,Next.js Wallet,NW,Integrate Freighter wallet into
22
24
  Stellar,stellar-nextjs-soroban,Next.js Soroban,NS,Call Soroban contracts from Next.js using Server Components API routes and client-side signing.,,,4-implementation,stellar-nextjs-wallet,,false,{implementation_artifacts},soroban-integration
23
25
  Stellar,stellar-freighter-integration,Freighter Integration,FI,Deep Freighter wallet integration — full API reference connection lifecycle and blob signing.,,,4-implementation,stellar-setup-environment,,false,{implementation_artifacts},freighter-integration
24
26
  Stellar,stellar-sep10-auth,SEP-10 Auth,S10,Implement SEP-10 Web Authentication with JWT for Next.js API routes and protected endpoints.,,,4-implementation,stellar-nextjs-setup,,false,{implementation_artifacts},sep10-auth
27
+ Stellar,stellar-idea-scoping,Idea Scoping,IS,Pressure-test the hackathon idea against the build window and produce a one-page brief with cut list.,,,5-mentorship,,,false,{planning_artifacts},hackathon-brief
28
+ Stellar,stellar-track-recommendation,Track Recommendation,TR,Match the idea to the right Stellar/Soroban hackathon track and pull the judging rubric.,,,5-mentorship,stellar-idea-scoping,,false,{planning_artifacts},track-decision
29
+ Stellar,stellar-mvp-definition,MVP Definition,MV,Split features into must-have / nice-to-have / skip with hour estimates and a 25% buffer rule.,,,5-mentorship,stellar-idea-scoping,,false,{planning_artifacts},mvp-cut
30
+ Stellar,stellar-judging-criteria,Judging Criteria,JC,Reverse-map the build to the judging rubric and identify gaps before they cost points.,,,5-mentorship,stellar-mvp-definition,,false,{planning_artifacts},rubric-alignment
31
+ Stellar,stellar-demo-prep,Demo Prep,DM,Build the hackathon demo storyboard 2-3 min script and recording checklist with common failure modes.,,,5-mentorship,stellar-mvp-definition,,false,{implementation_artifacts},demo-storyboard
32
+ Stellar,stellar-pitch-coaching,Pitch Coaching,PC,Build the hackathon pitch 3-minute deck outline elevator pitch and judge Q&A drill.,,,5-mentorship,stellar-demo-prep,,false,{planning_artifacts},pitch-script
33
+ Stellar,stellar-submission-prep,Submission Prep,SP,Final pre-submission checklist repo polish README demo video deployed testnet contract IDs and submission form.,,,5-mentorship,stellar-pitch-coaching,,false,{planning_artifacts},submission-confirmation
@@ -54,6 +54,7 @@ async function installStellarAgent(targetDir, config) {
54
54
  planning_artifacts: `${OUTPUT_DIR}/planning-artifacts`,
55
55
  implementation_artifacts: `${OUTPUT_DIR}/implementation-artifacts`,
56
56
  project_knowledge: 'docs',
57
+ skills_version: config.skills_version,
57
58
  };
58
59
  await fsp.writeFile(
59
60
  path.join(stellarDir, 'stellar', 'config.yaml'),
@@ -64,6 +65,7 @@ async function installStellarAgent(targetDir, config) {
64
65
  // Write manifest
65
66
  const manifest = {
66
67
  version: require('../../../package.json').version,
68
+ skills_version: config.skills_version,
67
69
  installed_at: new Date().toISOString(),
68
70
  project_name: config.project_name,
69
71
  };
@@ -226,8 +228,23 @@ description = "Hackathon mentor — scopes ideas to the timebox, picks the track
226
228
  }
227
229
 
228
230
  async function action(options) {
231
+ const pkgVersion = require('../../../package.json').version;
232
+ const requestedVersion = options?.skills || pkgVersion;
233
+
234
+ // Pinning warning — we don't ship multi-version download support yet
235
+ if (requestedVersion !== pkgVersion) {
236
+ console.error(
237
+ `⚠️ Skills version mismatch.\n` +
238
+ ` You requested: ${requestedVersion}\n` +
239
+ ` This package: ${pkgVersion}\n\n` +
240
+ ` To pin to a different version, run:\n` +
241
+ ` npx stellar-agent@${requestedVersion} init\n\n` +
242
+ ` Continuing with ${pkgVersion}...\n`
243
+ );
244
+ }
245
+
229
246
  await CLIUtils.displayLogo();
230
- await prompts.intro('Stellar Agent — AI agent team for Stellar blockchain development');
247
+ await prompts.intro(`Stellar Agent v${pkgVersion} — AI agent team for Stellar blockchain development`);
231
248
 
232
249
  // Directory selection
233
250
  const rawDir = await prompts.text({
@@ -307,6 +324,7 @@ async function action(options) {
307
324
  network_preference: networkPreference,
308
325
  primary_language: primaryLanguage,
309
326
  communication_language: communicationLanguage,
327
+ skills_version: pkgVersion,
310
328
  };
311
329
 
312
330
  // Install
@@ -339,6 +357,8 @@ async function action(options) {
339
357
  module.exports = {
340
358
  command: 'init',
341
359
  description: 'Initialize Stellar Agent in your project',
342
- options: [],
360
+ options: [
361
+ ['--skills <version>', 'Pin to a specific skills version (defaults to the installed package version)'],
362
+ ],
343
363
  action,
344
364
  };
@@ -0,0 +1,38 @@
1
+ /**
2
+ * `stellar-agent mcp` — start the MCP server over stdio.
3
+ *
4
+ * Invoked by MCP-aware clients (Claude Desktop, Cline, Continue, Zed)
5
+ * via their server config:
6
+ *
7
+ * {
8
+ * "mcpServers": {
9
+ * "stellar-agent": {
10
+ * "command": "npx",
11
+ * "args": ["stellar-agent", "mcp"]
12
+ * }
13
+ * }
14
+ * }
15
+ */
16
+
17
+ const path = require('node:path');
18
+ const { spawn } = require('node:child_process');
19
+
20
+ async function action() {
21
+ const serverPath = path.join(__dirname, '..', '..', 'mcp-server', 'server.js');
22
+ const child = spawn(process.execPath, [serverPath], {
23
+ stdio: 'inherit',
24
+ });
25
+
26
+ child.on('exit', (code) => process.exit(code ?? 0));
27
+ child.on('error', (err) => {
28
+ console.error('Failed to start MCP server:', err);
29
+ process.exit(1);
30
+ });
31
+ }
32
+
33
+ module.exports = {
34
+ command: 'mcp',
35
+ description: 'Run the Stellar Agent MCP server (stdio). Used by Claude Desktop, Cline, Continue, Zed.',
36
+ options: [],
37
+ action,
38
+ };
@@ -0,0 +1,42 @@
1
+ /**
2
+ * `stellar-agent version` — print CLI version + installed skills version (if any).
3
+ *
4
+ * Outputs both:
5
+ * - the version of this CLI / npm package
6
+ * - the skills version recorded at `_stellar/_config/manifest.yaml`
7
+ * if the current directory has stellar-agent installed
8
+ */
9
+
10
+ const fs = require('node:fs');
11
+ const path = require('node:path');
12
+ const yaml = require('yaml');
13
+
14
+ async function action() {
15
+ const pkg = require('../../../package.json');
16
+ console.log(`stellar-agent v${pkg.version}`);
17
+
18
+ const manifestPath = path.join(process.cwd(), '_stellar', '_config', 'manifest.yaml');
19
+ if (fs.existsSync(manifestPath)) {
20
+ try {
21
+ const manifest = yaml.parse(fs.readFileSync(manifestPath, 'utf8'));
22
+ console.log(` installed: ${manifest.installed_at}`);
23
+ console.log(` skills version: ${manifest.skills_version || manifest.version || '(unknown)'}`);
24
+ console.log(` project: ${manifest.project_name || '(unset)'}`);
25
+ if (manifest.skills_version && manifest.skills_version !== pkg.version) {
26
+ console.log('');
27
+ console.log(` ⚠️ CLI (${pkg.version}) differs from installed skills (${manifest.skills_version}).`);
28
+ console.log(` Run \`npx stellar-agent init\` (choose Update) to refresh, or`);
29
+ console.log(` run \`npx stellar-agent@${manifest.skills_version} <command>\` to stay pinned.`);
30
+ }
31
+ } catch (err) {
32
+ console.error(` (could not parse manifest: ${err.message})`);
33
+ }
34
+ }
35
+ }
36
+
37
+ module.exports = {
38
+ command: 'version',
39
+ description: 'Print the CLI version and the installed skills version (if any)',
40
+ options: [],
41
+ action,
42
+ };
@@ -55,7 +55,7 @@ if (process.stdin.isTTY) {
55
55
  }
56
56
 
57
57
  const commandsPath = path.join(__dirname, 'commands');
58
- const ALLOWED_COMMANDS = ['init'];
58
+ const ALLOWED_COMMANDS = ['init', 'mcp', 'version'];
59
59
 
60
60
  const commands = {};
61
61
  for (const name of ALLOWED_COMMANDS) {