create-snipara 1.3.56 → 2.0.1

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.
Files changed (3) hide show
  1. package/README.md +27 -4
  2. package/dist/index.js +68 -4
  3. package/package.json +3 -1
package/README.md CHANGED
@@ -15,12 +15,17 @@ creates or reuses auth, writes Hosted MCP config, and prepares the local project
15
15
  so an LLM client can use Snipara context and reviewed memory. Install once with
16
16
  `create-snipara`; continue every session with `snipara-companion`.
17
17
 
18
+ Use it when the goal is outcome-first agent work: the user asks for judgment,
19
+ implementation, release, or verification, and the agent handles Snipara context,
20
+ workflow state, package checks, Git operations, deployment, and smoke checks
21
+ behind the scenes.
22
+
18
23
  Use it for:
19
24
 
20
- - Hosted MCP onboarding for Claude Code, Cursor, Windsurf, Codex, Gemini, Mistral, VS Code/Copilot, Continue, ChatGPT Desktop, and similar clients
25
+ - Hosted MCP onboarding for Claude Code, Cursor, Windsurf, Codex, Gemini, Mistral, VS Code/Copilot, Continue, ChatGPT Desktop, Orca-style MCP clients, LM Studio-backed local stacks, and similar clients
21
26
  - free account signup with reviewed Context + Memory
22
27
  - local project wiring, `doctor`, `repair`, and `upgrade`
23
- - GitHub repository sync and PR Answer Packs approval when the current folder is a GitHub repo
28
+ - local source activation without GitHub, plus optional GitHub repository sync and PR Answer Packs approval when the current folder is a GitHub repo
24
29
 
25
30
  ## Why It Exists
26
31
 
@@ -34,7 +39,7 @@ flowchart LR
34
39
  CLI --> Auth["Snipara auth and project key"]
35
40
  CLI --> MCP["Hosted MCP config"]
36
41
  CLI --> Templates["AGENTS.md, CLAUDE.md, Cursor, Codex, MCP references"]
37
- MCP --> Agents["Claude Code, Cursor, Codex, Gemini, Mistral, VS Code, ChatGPT"]
42
+ MCP --> Agents["Claude Code, Cursor, Codex, Gemini, Mistral, VS Code, ChatGPT, Orca, LM Studio stacks"]
38
43
  Templates --> Agents
39
44
  Agents --> Context["Snipara context and memory"]
40
45
  ```
@@ -77,7 +82,7 @@ Free onboarding is now **Context + Memory**, not Context-only:
77
82
 
78
83
  - Context Free: three projects and 1,000 context queries/month
79
84
  - Memory Free: reviewed hosted memories for continuity across sessions
80
- - Hosted MCP: direct connection for Claude Code, Cursor, Windsurf, Codex, Gemini, Mistral, VS Code/Copilot, Continue, ChatGPT Desktop, and other MCP clients
85
+ - Hosted MCP: direct connection for Claude Code, Cursor, Windsurf, Codex, Gemini, Mistral, VS Code/Copilot, Continue, ChatGPT Desktop, Orca-style MCP clients, LM Studio-backed local stacks, and other MCP clients
81
86
 
82
87
  The CLI opens a browser device-flow login when the user does not already have a key, auto-provisions the free Context + Memory account when needed, then writes the returned API key into the local MCP config.
83
88
 
@@ -102,6 +107,7 @@ That distinction matters:
102
107
  - opens the browser device-flow free Context + Memory account flow when needed
103
108
  - writes Hosted MCP configuration
104
109
  - detects a GitHub remote and can open the Snipara GitHub App automation path
110
+ - activates the current folder locally through `snipara-companion source init` so docs and code overlay context are available before GitHub approval
105
111
  - explains the GitHub PR Answer Packs path for AI-assisted pull request workflows
106
112
  - installs `snipara-companion` by default for local status, briefs, timelines,
107
113
  phase commits, handoffs, resume, and managed workflows
@@ -129,6 +135,7 @@ That distinction matters:
129
135
  Keep the package roles simple:
130
136
 
131
137
  - `create-snipara` = connect the user to Hosted MCP Context + Memory
138
+ - `snipara-companion source init` = automatic local source snapshot, document dry-run, and local code overlay without GitHub
132
139
  - `create-snipara --github` = connect the current GitHub repository through the browser approval flow for repository sync and PR Answer Packs
133
140
  - `snipara-openclaw-install` = OpenClaw-only wrapper for Hosted MCP config plus OpenClaw env and hook setup
134
141
  - `snipara-business` = prepare business context from local or mounted folders
@@ -190,6 +197,8 @@ the human-facing contract.
190
197
 
191
198
  ```bash
192
199
  snipara-companion status
200
+ snipara-companion source init .
201
+ snipara-companion source sync --json
193
202
  snipara-companion brief --task "ship auth hardening" --changed-files src/auth.ts
194
203
  snipara-companion workflow start --goal "ship auth hardening" --plan-file ./plan.json
195
204
  snipara-companion workflow phase-start context
@@ -206,6 +215,20 @@ snipara-companion workflow run --mode full --include-session-context --query "im
206
215
  snipara-companion final-commit --summary "Shipped auth hardening and tests" --files src/auth.ts tests/auth.test.ts
207
216
  ```
208
217
 
218
+ ### Local source first
219
+
220
+ For free users, the first useful source step does not need GitHub approval:
221
+
222
+ ```bash
223
+ snipara-companion source init .
224
+ snipara-companion source status --json
225
+ ```
226
+
227
+ That creates `.snipara/source/latest.json`, previews supported document sync,
228
+ and refreshes `.snipara/code-overlay/latest.json` from local files. GitHub
229
+ automation is still the canonical hosted repository path for teams, PR Answer
230
+ Packs, and shared CODE indexing after the user approves the provider.
231
+
209
232
  ## Main Commands
210
233
 
211
234
  ### Install or initialize
package/dist/index.js CHANGED
@@ -13,7 +13,7 @@ import { homedir } from "os";
13
13
  // package.json
14
14
  var package_default = {
15
15
  name: "create-snipara",
16
- version: "1.3.56",
16
+ version: "2.0.1",
17
17
  description: "Onboard Snipara Hosted MCP Context + Memory with auth, companion workflows, and optional Snipara Sandbox",
18
18
  main: "dist/index.js",
19
19
  type: "module",
@@ -48,6 +48,8 @@ var package_default = {
48
48
  "windsurf",
49
49
  "gemini",
50
50
  "mistral",
51
+ "orca",
52
+ "lm-studio",
51
53
  "vscode",
52
54
  "continue",
53
55
  "claude-desktop"
@@ -90,7 +92,7 @@ var API_URL = "https://api.snipara.com";
90
92
  var COMPANION_PACKAGE_NAME = "snipara-companion";
91
93
  var COMPANION_COMMAND_NAME = "snipara-companion";
92
94
  var COMPANION_NPX_COMMAND = "npx -y snipara-companion@latest";
93
- var MIN_COMPANION_VERSION = "1.3.0";
95
+ var MIN_COMPANION_VERSION = "3.0.0";
94
96
  var GITHUB_ANSWER_PACKS_LABEL = "GitHub PR Answer Packs";
95
97
  var MCP_PACKAGE_NAME = "snipara-mcp";
96
98
  var SANDBOX_PACKAGE_NAME = "snipara-sandbox[all]";
@@ -101,6 +103,17 @@ var SANDBOX_COMMAND_NAME = "snipara-sandbox";
101
103
  var LEGACY_SANDBOX_COMMAND_NAME = "rlm";
102
104
  var ORCHESTRATOR_COMMAND_NAME = "snipara-orchestrator";
103
105
  var DEVICE_CLIENT_ID = "create-snipara";
106
+ var EXPERIENCE_GOAL_SECTION = `## Experience Goal
107
+
108
+ The target experience is outcome-first agent work across supported clients:
109
+ Codex, Claude Code, Cursor, Orca, LM Studio-backed local stacks, or another
110
+ MCP-capable environment. The user should be able to state an outcome, ask for
111
+ engineering judgment, or request a release while the agent handles Snipara
112
+ context retrieval, workflow state, verification, package checks, Git operations,
113
+ deployment, and production smoke checks behind the scenes. Surface important
114
+ decisions, blockers, and evidence, but do not make the user manually orchestrate
115
+ routine Snipara or release mechanics.`;
116
+ var UNIVERSAL_CLIENT_GUIDANCE = "The target experience is outcome-first: the user can ask for engineering judgment or a release, and the agent should use Snipara context, workflow state, verification, package checks, Git, deploy, and smoke checks without making the user orchestrate routine mechanics.";
104
117
  var DeviceAuthorizationAborted = class extends Error {
105
118
  };
106
119
  var AI_CLIENT_CHOICES = [
@@ -529,6 +542,7 @@ function printBanner() {
529
542
  \u2551 \u2551
530
543
  \u2551 \u2022 Hosted MCP for LLM agents \u2551
531
544
  \u2551 \u2022 Free account path with hosted context and reviewed memory \u2551
545
+ \u2551 \u2022 Local source activation before GitHub approval \u2551
532
546
  \u2551 \u2022 API / SDK for product integrations \u2551
533
547
  \u2551 \u2022 Optional local companion and Snipara Sandbox helpers \u2551
534
548
  \u2551 \u2022 One CLI for auth, config, doctor, repair, and upgrade \u2551
@@ -1413,6 +1427,8 @@ This project uses Snipara Hosted MCP for project context and reviewed memory.
1413
1427
  \`snipara-companion task-commit\` as the reliable local fallback, then restart
1414
1428
  or reload Codex after MCP config changes.
1415
1429
 
1430
+ ${EXPERIENCE_GOAL_SECTION}
1431
+
1416
1432
  Agent task lifecycle:
1417
1433
 
1418
1434
  1. Start every new thread by validating hosted MCP availability, then use
@@ -1478,6 +1494,9 @@ Use Snipara Hosted MCP before answering project-specific questions.
1478
1494
 
1479
1495
  - Endpoint: \`${buildHostedMcpEndpoint(answers)}\`
1480
1496
  - If a session exposes only a subset of expected Snipara tools, call \`snipara_help(list_all=true)\` before concluding a tool is unavailable.
1497
+
1498
+ ${EXPERIENCE_GOAL_SECTION}
1499
+
1481
1500
  - Start substantial work with \`snipara_recall\` and a targeted \`snipara_context_query\`.
1482
1501
  - Use \`snipara_context_query\` for source truth and \`snipara_get_chunk\` for exact cited sections.
1483
1502
  - When \`snipara_context_query\` returns \`answer_pack\`, use its facts, caveats, source map, and verification checklist before drafting claims.
@@ -1509,6 +1528,9 @@ This workspace uses Snipara Hosted MCP for current project context, business/cli
1509
1528
  - Check the configured Snipara MCP server before answering project-specific questions.
1510
1529
  - If a session exposes only a subset of expected Snipara tools, call \`snipara_help(list_all=true)\` before concluding a tool is unavailable.
1511
1530
  - Endpoint: \`${buildHostedMcpEndpoint(answers)}\`
1531
+
1532
+ ${EXPERIENCE_GOAL_SECTION}
1533
+
1512
1534
  - Use \`snipara_recall\` for durable decisions, preferences, and validated learnings.
1513
1535
  - Use \`snipara_context_query\` for docs, business context, current client/project truth, and narrative source material.
1514
1536
  - When \`snipara_context_query\` returns \`answer_pack\`, use its facts, caveats, source map, and verification checklist before drafting claims.
@@ -2228,6 +2250,24 @@ function getClientGuidance(client) {
2228
2250
  function getCompanionCommands(answers) {
2229
2251
  const projectFlag = answers.projectSlug ? ` --project ${answers.projectSlug}` : "";
2230
2252
  const clientFlag = getCompanionInitClientFlag(answers.aiClient);
2253
+ const localSourceCommands = answers.installCompanion ? [
2254
+ {
2255
+ title: "Activate this folder locally",
2256
+ command: `${COMPANION_NPX_COMMAND} source init .`,
2257
+ purpose: "Create a local source snapshot, preview supported document sync, and build a local code overlay without GitHub."
2258
+ },
2259
+ {
2260
+ title: "Refresh local source context",
2261
+ command: `${COMPANION_NPX_COMMAND} source sync --json`,
2262
+ purpose: "Refresh the local snapshot, document dry-run, and code overlay cache after files change."
2263
+ }
2264
+ ] : [
2265
+ {
2266
+ title: "Enable local source activation",
2267
+ command: "npx create-snipara repair --with-companion",
2268
+ purpose: `Install ${COMPANION_PACKAGE_NAME} so this project can run ${COMPANION_NPX_COMMAND} source init without GitHub.`
2269
+ }
2270
+ ];
2231
2271
  const businessOnboardingCommands = answers.installCompanion ? [
2232
2272
  {
2233
2273
  title: "Preview a business folder import",
@@ -2271,6 +2311,7 @@ function getCompanionCommands(answers) {
2271
2311
  command: "create-snipara repair",
2272
2312
  purpose: "Rebuild config files, hooks, and the companion pack."
2273
2313
  },
2314
+ ...localSourceCommands,
2274
2315
  {
2275
2316
  title: "Run a focused hosted query",
2276
2317
  command: `${COMPANION_NPX_COMMAND} query --query "how does auth middleware work?" --max-tokens 4000`,
@@ -2477,7 +2518,7 @@ async function createCompanionPack(answers) {
2477
2518
  console.log(chalk.bold("\n\u{1F5C2}\uFE0F Generating Companion Pack\n"));
2478
2519
  const packDir = path.join(process.cwd(), ".snipara", "companion");
2479
2520
  const commands = getCompanionCommands(answers);
2480
- const guidance = getClientGuidance(answers.aiClient);
2521
+ const guidance = [UNIVERSAL_CLIENT_GUIDANCE, ...getClientGuidance(answers.aiClient)];
2481
2522
  const detection = detectEnvironment();
2482
2523
  const clientPackFilename = getClientPackFilename(answers.aiClient);
2483
2524
  fs.mkdirSync(packDir, { recursive: true });
@@ -2527,7 +2568,29 @@ Apply only after reviewing the manifest:
2527
2568
 
2528
2569
  \`npx create-snipara repair --with-companion\``}
2529
2570
 
2530
- For source-code repositories, use the GitHub OAuth/code onboarding path instead of \`onboard-folder\`.
2571
+ ## Local Source Activation
2572
+
2573
+ Use this first when the user has not connected GitHub yet, or when the folder has no Git metadata.
2574
+ It creates a local source snapshot, previews supported document sync, and refreshes the local code
2575
+ overlay cache that agents can query immediately.
2576
+
2577
+ ${answers.installCompanion ? `Activate the current folder:
2578
+
2579
+ \`${COMPANION_NPX_COMMAND} source init .\`
2580
+
2581
+ Refresh after file changes:
2582
+
2583
+ \`${COMPANION_NPX_COMMAND} source sync --json\`
2584
+
2585
+ Inspect local drift:
2586
+
2587
+ \`${COMPANION_NPX_COMMAND} source status --json\`` : `This setup did not install snipara-companion. Enable it before local source activation:
2588
+
2589
+ \`npx create-snipara repair --with-companion\``}
2590
+
2591
+ GitHub automation remains useful after first value: it gives Snipara a canonical hosted repository
2592
+ sync and PR Answer Packs. Local source activation is the fallback, not a replacement for explicit
2593
+ provider approval when a team wants shared hosted code context.
2531
2594
 
2532
2595
  ## GitHub PR Answer Packs
2533
2596
 
@@ -3320,6 +3383,7 @@ function printSuccess(answers, report) {
3320
3383
  printNextStep(
3321
3384
  `${COMPANION_COMMAND_NAME} ${MIN_COMPANION_VERSION}+ is installed for low-latency local hooks.`
3322
3385
  );
3386
+ printNextStep(`Activate local source context now with: ${COMPANION_NPX_COMMAND} source init .`);
3323
3387
  printNextStep(
3324
3388
  `Use ${COMPANION_NPX_COMMAND} recall / query / plan / upload / task-commit for explicit local workflows and as a fallback when an AI client exposes only a partial MCP surface.`
3325
3389
  );
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "create-snipara",
3
- "version": "1.3.56",
3
+ "version": "2.0.1",
4
4
  "description": "Onboard Snipara Hosted MCP Context + Memory with auth, companion workflows, and optional Snipara Sandbox",
5
5
  "main": "dist/index.js",
6
6
  "type": "module",
@@ -35,6 +35,8 @@
35
35
  "windsurf",
36
36
  "gemini",
37
37
  "mistral",
38
+ "orca",
39
+ "lm-studio",
38
40
  "vscode",
39
41
  "continue",
40
42
  "claude-desktop"