vigthoria-cli 1.6.9 → 1.6.13
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.
- package/README.md +1 -1
- package/dist/commands/chat.d.ts +32 -2
- package/dist/commands/chat.js +666 -49
- package/dist/index.js +21 -9
- package/dist/utils/api.d.ts +12 -1
- package/dist/utils/api.js +966 -62
- package/dist/utils/config.d.ts +1 -0
- package/dist/utils/config.js +7 -1
- package/dist/utils/tools.js +33 -6
- package/package.json +3 -2
package/dist/index.js
CHANGED
|
@@ -98,7 +98,7 @@ function getVersion() {
|
|
|
98
98
|
catch (e) {
|
|
99
99
|
// Fallback to hardcoded version
|
|
100
100
|
}
|
|
101
|
-
return '1.6.
|
|
101
|
+
return '1.6.12';
|
|
102
102
|
}
|
|
103
103
|
const VERSION = getVersion();
|
|
104
104
|
/**
|
|
@@ -194,8 +194,9 @@ async function main() {
|
|
|
194
194
|
.command('chat')
|
|
195
195
|
.alias('c')
|
|
196
196
|
.description('Start interactive chat with Vigthoria AI')
|
|
197
|
-
.option('-m, --model <model>', 'Select AI model (fast, balanced, code, creative, cloud, ultra)'
|
|
198
|
-
.option('-p, --project <path>', 'Set project context path'
|
|
197
|
+
.option('-m, --model <model>', 'Select AI model (fast, balanced, code, creative, cloud, ultra)')
|
|
198
|
+
.option('-p, --project <path>', 'Set project context path')
|
|
199
|
+
.option('--new-project [name]', 'Create or use a managed local workspace folder when no --project path is given')
|
|
199
200
|
.option('-a, --agent', 'Enable agentic mode (default: true for best quality)', true)
|
|
200
201
|
.option('--no-agent', 'Disable agentic mode (simple chat only)')
|
|
201
202
|
.option('-r, --resume', 'Resume last session for this project', false)
|
|
@@ -208,6 +209,8 @@ async function main() {
|
|
|
208
209
|
await chat.run({
|
|
209
210
|
model: options.model,
|
|
210
211
|
project: options.project,
|
|
212
|
+
projectProvided: typeof options.project === 'string' && options.project.trim().length > 0,
|
|
213
|
+
newProject: options.newProject,
|
|
211
214
|
agent: options.agent,
|
|
212
215
|
workflow: options.workflow,
|
|
213
216
|
json: options.json,
|
|
@@ -219,8 +222,9 @@ async function main() {
|
|
|
219
222
|
program
|
|
220
223
|
.command('chat-resume')
|
|
221
224
|
.description('Resume the latest chat session for the current or specified project')
|
|
222
|
-
.option('-m, --model <model>', 'Select AI model (fast, balanced, code, creative, cloud, ultra)'
|
|
223
|
-
.option('-p, --project <path>', 'Set project context path'
|
|
225
|
+
.option('-m, --model <model>', 'Select AI model (fast, balanced, code, creative, cloud, ultra)')
|
|
226
|
+
.option('-p, --project <path>', 'Set project context path')
|
|
227
|
+
.option('--new-project [name]', 'Create or use a managed local workspace folder when no --project path is given')
|
|
224
228
|
.option('-a, --agent', 'Enable agentic mode (default: true for best quality)', true)
|
|
225
229
|
.option('--no-agent', 'Disable agentic mode (simple chat only)')
|
|
226
230
|
.option('--prompt <text>', 'Run a single prompt directly and exit after resuming context')
|
|
@@ -232,6 +236,8 @@ async function main() {
|
|
|
232
236
|
await chat.run({
|
|
233
237
|
model: options.model,
|
|
234
238
|
project: options.project,
|
|
239
|
+
projectProvided: typeof options.project === 'string' && options.project.trim().length > 0,
|
|
240
|
+
newProject: options.newProject,
|
|
235
241
|
agent: options.agent,
|
|
236
242
|
workflow: options.workflow,
|
|
237
243
|
json: options.json,
|
|
@@ -246,8 +252,9 @@ async function main() {
|
|
|
246
252
|
.command('agent')
|
|
247
253
|
.alias('a')
|
|
248
254
|
.description('Start agentic mode - AI can read/write files, run commands')
|
|
249
|
-
.option('-m, --model <model>', 'Select AI model (agent, code, cloud, ultra)'
|
|
250
|
-
.option('-p, --project <path>', 'Set project context path'
|
|
255
|
+
.option('-m, --model <model>', 'Select AI model (agent, code, cloud, ultra)')
|
|
256
|
+
.option('-p, --project <path>', 'Set project context path')
|
|
257
|
+
.option('--new-project [name]', 'Create or use a managed local workspace folder when no --project path is given')
|
|
251
258
|
.option('--prompt <text>', 'Run a single agent prompt directly and exit')
|
|
252
259
|
.option('-w, --workflow <selector>', 'Run the prompt through a named or explicit VigFlow workflow target')
|
|
253
260
|
.option('--json', 'Emit machine-readable JSON output for direct prompt runs', false)
|
|
@@ -257,6 +264,8 @@ async function main() {
|
|
|
257
264
|
await chat.run({
|
|
258
265
|
model: options.model,
|
|
259
266
|
project: options.project,
|
|
267
|
+
projectProvided: typeof options.project === 'string' && options.project.trim().length > 0,
|
|
268
|
+
newProject: options.newProject,
|
|
260
269
|
agent: true,
|
|
261
270
|
operator: false,
|
|
262
271
|
workflow: options.workflow,
|
|
@@ -269,8 +278,9 @@ async function main() {
|
|
|
269
278
|
.command('operator')
|
|
270
279
|
.alias('op')
|
|
271
280
|
.description('Start BMAD operator mode for infrastructure and system workflows')
|
|
272
|
-
.option('-m, --model <model>', 'Select operator model (code-8b, code, agent)'
|
|
273
|
-
.option('-p, --project <path>', 'Set project context path'
|
|
281
|
+
.option('-m, --model <model>', 'Select operator model (code-8b, code, agent)')
|
|
282
|
+
.option('-p, --project <path>', 'Set project context path')
|
|
283
|
+
.option('--new-project [name]', 'Create or use a managed local workspace folder when no --project path is given')
|
|
274
284
|
.option('--prompt <text>', 'Run a single operator prompt directly and exit')
|
|
275
285
|
.option('-w, --workflow <selector>', 'Run the prompt through a named or explicit VigFlow workflow target')
|
|
276
286
|
.option('--save-plan', 'Save the completed BMAD plan into VigFlow for rerun and audit', false)
|
|
@@ -280,6 +290,8 @@ async function main() {
|
|
|
280
290
|
await chat.run({
|
|
281
291
|
model: options.model,
|
|
282
292
|
project: options.project,
|
|
293
|
+
projectProvided: typeof options.project === 'string' && options.project.trim().length > 0,
|
|
294
|
+
newProject: options.newProject,
|
|
283
295
|
agent: false,
|
|
284
296
|
operator: true,
|
|
285
297
|
workflow: options.workflow,
|
package/dist/utils/api.d.ts
CHANGED
|
@@ -186,7 +186,7 @@ export declare class APIClient {
|
|
|
186
186
|
private refreshToken;
|
|
187
187
|
getSubscriptionStatus(): Promise<void>;
|
|
188
188
|
private getAccessToken;
|
|
189
|
-
getV3AgentBaseUrls(): string[];
|
|
189
|
+
getV3AgentBaseUrls(preferLocal?: boolean): string[];
|
|
190
190
|
getV3AgentRunUrl(baseUrl: string): string;
|
|
191
191
|
getOperatorBaseUrls(): string[];
|
|
192
192
|
getOperatorStreamUrl(baseUrl: string): string;
|
|
@@ -227,9 +227,15 @@ export declare class APIClient {
|
|
|
227
227
|
}): Promise<VigFlowExecutionResult>;
|
|
228
228
|
getVigFlowExecutionStatus(executionId: string): Promise<VigFlowExecutionStatus>;
|
|
229
229
|
buildV3AgentContext(context?: Record<string, any>): string;
|
|
230
|
+
buildMinimalV3AgentContext(context?: Record<string, any>): string;
|
|
231
|
+
private extractEmergencyAppName;
|
|
232
|
+
private materializeEmergencySaaSWorkspace;
|
|
230
233
|
private ensureExecutionContext;
|
|
231
234
|
bindExecutionContext(context?: Record<string, any>): Promise<Record<string, any>>;
|
|
232
235
|
private resolveAgentTargetPath;
|
|
236
|
+
private isLikelyWindowsPath;
|
|
237
|
+
private resolveServerBindableWorkspacePath;
|
|
238
|
+
private buildLocalWorkspaceSummary;
|
|
233
239
|
hasAgentWorkspaceOutput(context?: Record<string, any>): boolean;
|
|
234
240
|
getAgentWorkspaceSnapshot(rootPath: string): {
|
|
235
241
|
fileCount: number;
|
|
@@ -240,9 +246,14 @@ export declare class APIClient {
|
|
|
240
246
|
extractExpectedWorkspaceFiles(message?: string, context?: Record<string, any>): string[];
|
|
241
247
|
captureV3AgentStreamMutation(event: any, streamedFiles: Record<string, string>): void;
|
|
242
248
|
recoverAgentWorkspaceFiles(context?: Record<string, any>, streamedFiles?: Record<string, string>, expectedFiles?: string[]): void;
|
|
249
|
+
normalizeAgentWorkspaceRelativePath(rawPath: string, rootPath?: string): string;
|
|
243
250
|
ensureAgentFrontendPolish(message?: string, context?: Record<string, any>): Promise<void>;
|
|
244
251
|
private injectSectionBeforeFooter;
|
|
245
252
|
private injectNavLink;
|
|
253
|
+
private ensureReferencedFrontendAssets;
|
|
254
|
+
private buildFallbackFrontendCss;
|
|
255
|
+
private buildFallbackFrontendJs;
|
|
256
|
+
private replaceMissingLocalAssetReferences;
|
|
246
257
|
formatV3AgentResponse(data: any): string;
|
|
247
258
|
collectV3AgentStream(response: Response, context?: Record<string, any>): Promise<any>;
|
|
248
259
|
runV3AgentWorkflow(message: string, context?: Record<string, any>): Promise<V3AgentWorkflowResponse>;
|