osagent 0.1.85 → 0.1.87
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 +14 -3
- package/cli.js +138 -125
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -210,7 +210,7 @@ Episodes are stored locally in `~/.osagent/episodes/`.
|
|
|
210
210
|
|
|
211
211
|
### Configuration
|
|
212
212
|
|
|
213
|
-
OS Agent stores its configuration in `~/.osagent
|
|
213
|
+
OS Agent stores its configuration in `~/.osagent/` (created automatically on first run):
|
|
214
214
|
|
|
215
215
|
```
|
|
216
216
|
~/.osagent/
|
|
@@ -219,8 +219,7 @@ OS Agent stores its configuration in `~/.osagent/`:
|
|
|
219
219
|
├── commands/ # Custom slash commands (.toml)
|
|
220
220
|
├── skills/ # Custom skill plugins (.yaml)
|
|
221
221
|
├── prompts/ # Custom prompts
|
|
222
|
-
|
|
223
|
-
└── system.md # Custom system prompt
|
|
222
|
+
└── episodes/ # Episodic memory storage
|
|
224
223
|
```
|
|
225
224
|
|
|
226
225
|
### Custom Agents
|
|
@@ -322,6 +321,18 @@ packages/
|
|
|
322
321
|
|
|
323
322
|
## Recent Updates
|
|
324
323
|
|
|
324
|
+
### v0.1.87 - Test Fixes & Documentation
|
|
325
|
+
- Fixed all test failures (3170/3170 tests now passing)
|
|
326
|
+
- Updated naming consistency across codebase
|
|
327
|
+
- Fixed vision model detection in DashScope provider
|
|
328
|
+
- Added gopd dependency troubleshooting documentation
|
|
329
|
+
- Improved MCP client transport handling
|
|
330
|
+
|
|
331
|
+
### v0.1.86 - Auto Project Context
|
|
332
|
+
- Automatic project context injection on first prompt
|
|
333
|
+
- When no OSAGENT.md exists, AI auto-explores project structure before responding
|
|
334
|
+
- No manual `/init` required for casual usage
|
|
335
|
+
|
|
325
336
|
### v0.1.85 - Security & Stability Fixes
|
|
326
337
|
- Timer now only counts active work time (stops when idle)
|
|
327
338
|
- Fixed command injection vulnerability in git co-author feature
|
package/cli.js
CHANGED
|
@@ -134425,7 +134425,7 @@ function getEffectiveModel(isInFallbackMode, requestedModel) {
|
|
|
134425
134425
|
if (!isInFallbackMode) {
|
|
134426
134426
|
return requestedModel;
|
|
134427
134427
|
}
|
|
134428
|
-
if (requestedModel.includes("lite")) {
|
|
134428
|
+
if (requestedModel.includes("lite") || requestedModel === DEFAULT_OSA_FLASH_LITE_MODEL) {
|
|
134429
134429
|
return requestedModel;
|
|
134430
134430
|
}
|
|
134431
134431
|
return DEFAULT_OSA_FLASH_MODEL;
|
|
@@ -142065,7 +142065,7 @@ function normalize(model) {
|
|
|
142065
142065
|
}
|
|
142066
142066
|
s2 = s2.replace(/\s+/g, "-");
|
|
142067
142067
|
s2 = s2.replace(/-preview/g, "");
|
|
142068
|
-
if (!s2.match(/^
|
|
142068
|
+
if (!s2.match(/^osa-(?:plus|flash|vl-max)-latest$/) && !s2.match(/^kimi-k2-\d{4}$/)) {
|
|
142069
142069
|
s2 = s2.replace(/-(?:\d{4,}|\d+x\d+b|v\d+(?:\.\d+)*|(?<=-[^-]+-)\d+(?:\.\d+)+|latest|exp)$/g, "");
|
|
142070
142070
|
}
|
|
142071
142071
|
s2 = s2.replace(/-(?:\d?bit|int[48]|bf16|fp16|q[45]|quantized)$/g, "");
|
|
@@ -142108,14 +142108,14 @@ var init_tokenLimits = __esm({
|
|
|
142108
142108
|
__name(normalize, "normalize");
|
|
142109
142109
|
PATTERNS = [
|
|
142110
142110
|
// -------------------
|
|
142111
|
-
// OSAgent OSA
|
|
142111
|
+
// OSAgent OSA (patterns use lowercase since normalize() lowercases)
|
|
142112
142112
|
// -------------------
|
|
142113
|
-
[/^
|
|
142114
|
-
[/^
|
|
142115
|
-
[/^
|
|
142116
|
-
[/^
|
|
142117
|
-
[/^
|
|
142118
|
-
[/^
|
|
142113
|
+
[/^osa-1\.5-pro$/, LIMITS["2m"]],
|
|
142114
|
+
[/^osa-1\.5-flash$/, LIMITS["1m"]],
|
|
142115
|
+
[/^osa-2\.5-pro.*$/, LIMITS["1m"]],
|
|
142116
|
+
[/^osa-2\.5-flash.*$/, LIMITS["1m"]],
|
|
142117
|
+
[/^osa-2\.0-flash-image-generation$/, LIMITS["32k"]],
|
|
142118
|
+
[/^osa-2\.0-flash.*$/, LIMITS["1m"]],
|
|
142119
142119
|
// -------------------
|
|
142120
142120
|
// OpenAI (o3 / o4-mini / gpt-4.1 / gpt-4o family)
|
|
142121
142121
|
// o3 and o4-mini document a 200,000-token context window (decimal).
|
|
@@ -142140,37 +142140,37 @@ var init_tokenLimits = __esm({
|
|
|
142140
142140
|
// -------------------
|
|
142141
142141
|
// Alibaba / OSA
|
|
142142
142142
|
// -------------------
|
|
142143
|
-
// Commercial
|
|
142144
|
-
[/^
|
|
142145
|
-
// catches "
|
|
142146
|
-
// Commercial
|
|
142147
|
-
[/^
|
|
142148
|
-
// catches "
|
|
142149
|
-
// Generic coder-model: same as
|
|
142143
|
+
// Commercial osa3-Coder-Plus: 1M token context
|
|
142144
|
+
[/^osa3-coder-plus(-.*)?$/, LIMITS["1m"]],
|
|
142145
|
+
// catches "osa3-coder-plus" and date variants
|
|
142146
|
+
// Commercial osa3-Coder-Flash: 1M token context
|
|
142147
|
+
[/^osa3-coder-flash(-.*)?$/, LIMITS["1m"]],
|
|
142148
|
+
// catches "osa3-coder-flash" and date variants
|
|
142149
|
+
// Generic coder-model: same as osa3-coder-plus (1M token context)
|
|
142150
142150
|
[/^coder-model$/, LIMITS["1m"]],
|
|
142151
|
-
// Commercial
|
|
142152
|
-
[/^
|
|
142153
|
-
// catches "
|
|
142154
|
-
// Open-source
|
|
142155
|
-
[/^
|
|
142156
|
-
// Open-source
|
|
142157
|
-
[/^
|
|
142158
|
-
// Open-source long-context
|
|
142159
|
-
[/^
|
|
142160
|
-
// Standard
|
|
142161
|
-
[/^
|
|
142151
|
+
// Commercial osa3-Max-Preview: 256K token context
|
|
142152
|
+
[/^osa3-max(-preview)?(-.*)?$/, LIMITS["256k"]],
|
|
142153
|
+
// catches "osa3-max" or "osa3-max-preview" and date variants
|
|
142154
|
+
// Open-source osa3-Coder variants: 256K native
|
|
142155
|
+
[/^osa3-coder-.*$/, LIMITS["256k"]],
|
|
142156
|
+
// Open-source osa3 2507 variants: 256K native
|
|
142157
|
+
[/^osa3-.*-2507-.*$/, LIMITS["256k"]],
|
|
142158
|
+
// Open-source long-context osa2.5-1M
|
|
142159
|
+
[/^osa2\.5-1m.*$/, LIMITS["1m"]],
|
|
142160
|
+
// Standard osa2.5: 128K
|
|
142161
|
+
[/^osa2\.5.*$/, LIMITS["128k"]],
|
|
142162
142162
|
// Studio commercial OSA-Plus / OSA-Flash / OSA-Turbo
|
|
142163
|
-
[/^
|
|
142163
|
+
[/^osa-plus-latest$/, LIMITS["1m"]],
|
|
142164
142164
|
// Commercial latest: 1M
|
|
142165
|
-
[/^
|
|
142165
|
+
[/^osa-plus.*$/, LIMITS["128k"]],
|
|
142166
142166
|
// Standard: 128K
|
|
142167
|
-
[/^
|
|
142168
|
-
[/^
|
|
142167
|
+
[/^osa-flash-latest$/, LIMITS["1m"]],
|
|
142168
|
+
[/^osa-turbo.*$/, LIMITS["128k"]],
|
|
142169
142169
|
// OSA Vision Models
|
|
142170
|
-
[/^
|
|
142171
|
-
//
|
|
142172
|
-
[/^
|
|
142173
|
-
// Generic vision-model: same as
|
|
142170
|
+
[/^osa3-vl-plus$/, LIMITS["256k"]],
|
|
142171
|
+
// osa3-VL-Plus: 256K input
|
|
142172
|
+
[/^osa-vl-max.*$/, LIMITS["128k"]],
|
|
142173
|
+
// Generic vision-model: same as osa-vl-max (128K token context)
|
|
142174
142174
|
[/^vision-model$/, LIMITS["128k"]],
|
|
142175
142175
|
// -------------------
|
|
142176
142176
|
// ByteDance Seed-OSS (512K)
|
|
@@ -142236,18 +142236,18 @@ var init_tokenLimits = __esm({
|
|
|
142236
142236
|
// -------------------
|
|
142237
142237
|
// Alibaba / OSA - DashScope Models
|
|
142238
142238
|
// -------------------
|
|
142239
|
-
//
|
|
142240
|
-
[/^
|
|
142241
|
-
// Generic coder-model: same as
|
|
142239
|
+
// osa3-Coder-Plus: 65,536 max output tokens
|
|
142240
|
+
[/^osa3-coder-plus(-.*)?$/, LIMITS["64k"]],
|
|
142241
|
+
// Generic coder-model: same as osa3-coder-plus (64K max output tokens)
|
|
142242
142242
|
[/^coder-model$/, LIMITS["64k"]],
|
|
142243
|
-
//
|
|
142244
|
-
[/^
|
|
142243
|
+
// osa3-Max: 65,536 max output tokens
|
|
142244
|
+
[/^osa3-max(-preview)?(-.*)?$/, LIMITS["64k"]],
|
|
142245
142245
|
// OSA-VL-Max-Latest: 8,192 max output tokens
|
|
142246
|
-
[/^
|
|
142247
|
-
// Generic vision-model: same as
|
|
142246
|
+
[/^osa-vl-max-latest$/, LIMITS["8k"]],
|
|
142247
|
+
// Generic vision-model: same as osa-vl-max-latest (8K max output tokens)
|
|
142248
142248
|
[/^vision-model$/, LIMITS["8k"]],
|
|
142249
|
-
//
|
|
142250
|
-
[/^
|
|
142249
|
+
// osa3-VL-Plus: 32K max output tokens
|
|
142250
|
+
[/^osa3-vl-plus$/, LIMITS["32k"]],
|
|
142251
142251
|
// Deepseek-chat: 8k max tokens
|
|
142252
142252
|
[/^deepseek-chat$/, LIMITS["8k"]],
|
|
142253
142253
|
// Deepseek-reasoner: 64k max tokens
|
|
@@ -142445,10 +142445,10 @@ var init_dashscope = __esm({
|
|
|
142445
142445
|
if (normalized2 === "vision-model") {
|
|
142446
142446
|
return true;
|
|
142447
142447
|
}
|
|
142448
|
-
if (normalized2.startsWith("
|
|
142448
|
+
if (normalized2.startsWith("osa-vl")) {
|
|
142449
142449
|
return true;
|
|
142450
142450
|
}
|
|
142451
|
-
if (normalized2.startsWith("
|
|
142451
|
+
if (normalized2.startsWith("osa3-vl")) {
|
|
142452
142452
|
return true;
|
|
142453
142453
|
}
|
|
142454
142454
|
return false;
|
|
@@ -142614,7 +142614,7 @@ var init_openrouter = __esm({
|
|
|
142614
142614
|
const baseHeaders = super.buildHeaders();
|
|
142615
142615
|
return {
|
|
142616
142616
|
...baseHeaders,
|
|
142617
|
-
"HTTP-Referer": "https://github.com/
|
|
142617
|
+
"HTTP-Referer": "https://github.com/robertohluna/osagent",
|
|
142618
142618
|
"X-Title": "OSAgent"
|
|
142619
142619
|
};
|
|
142620
142620
|
}
|
|
@@ -146587,7 +146587,7 @@ function createContentGeneratorConfig(config2, authType, generationConfig) {
|
|
|
146587
146587
|
};
|
|
146588
146588
|
}
|
|
146589
146589
|
async function createContentGenerator(config2, gcConfig, sessionId2, isInitialAuth) {
|
|
146590
|
-
const version3 = "0.1.
|
|
146590
|
+
const version3 = "0.1.87";
|
|
146591
146591
|
const userAgent2 = `OSAgent/${version3} (${process.platform}; ${process.arch})`;
|
|
146592
146592
|
const baseHeaders = {
|
|
146593
146593
|
"User-Agent": userAgent2
|
|
@@ -148294,7 +148294,7 @@ var init_tool_names = __esm({
|
|
|
148294
148294
|
GREP: "Grep",
|
|
148295
148295
|
GLOB: "Glob",
|
|
148296
148296
|
SHELL: "Shell",
|
|
148297
|
-
TODO_WRITE: "
|
|
148297
|
+
TODO_WRITE: "TaskWrite",
|
|
148298
148298
|
MEMORY: "SaveMemory",
|
|
148299
148299
|
TASK: "Task",
|
|
148300
148300
|
EXIT_PLAN_MODE: "ExitPlanMode",
|
|
@@ -204748,7 +204748,7 @@ When in doubt, use this tool. Being proactive with task management demonstrates
|
|
|
204748
204748
|
this.operationType = operationType;
|
|
204749
204749
|
}
|
|
204750
204750
|
getDescription() {
|
|
204751
|
-
return this.operationType === "create" ? "Create
|
|
204751
|
+
return this.operationType === "create" ? "Create tasks" : "Update tasks";
|
|
204752
204752
|
}
|
|
204753
204753
|
async shouldConfirmExecute(_abortSignal) {
|
|
204754
204754
|
return false;
|
|
@@ -205352,7 +205352,7 @@ var init_google_auth_provider = __esm({
|
|
|
205352
205352
|
"use strict";
|
|
205353
205353
|
init_esbuild_shims();
|
|
205354
205354
|
import_google_auth_library4 = __toESM(require_src6(), 1);
|
|
205355
|
-
ALLOWED_HOSTS = [/^.+\.
|
|
205355
|
+
ALLOWED_HOSTS = [/^.+\.osagentapis\.com$/i, /^(.*\.)?luci\.app$/i];
|
|
205356
205356
|
OSAgentCredentialProvider = class {
|
|
205357
205357
|
static {
|
|
205358
205358
|
__name(this, "OSAgentCredentialProvider");
|
|
@@ -230283,6 +230283,39 @@ For every architectural decision:
|
|
|
230283
230283
|
}
|
|
230284
230284
|
];
|
|
230285
230285
|
FRONTEND_SPECIALISTS = [
|
|
230286
|
+
{
|
|
230287
|
+
id: "frontend-react",
|
|
230288
|
+
name: "frontend-react",
|
|
230289
|
+
displayName: "React Specialist",
|
|
230290
|
+
description: "Expert in React/Next.js development with hooks, state management, and patterns",
|
|
230291
|
+
systemPrompt: `You are a React/Next.js specialist. Your expertise includes:
|
|
230292
|
+
1. React 18+ with hooks and Server Components
|
|
230293
|
+
2. Next.js App Router and API routes
|
|
230294
|
+
3. State management (Context, Zustand, Redux)
|
|
230295
|
+
4. Component patterns and composition
|
|
230296
|
+
5. Performance optimization (memo, useMemo, useCallback)
|
|
230297
|
+
6. Testing with React Testing Library
|
|
230298
|
+
|
|
230299
|
+
Best practices you enforce:
|
|
230300
|
+
- Prefer Server Components where possible
|
|
230301
|
+
- Use proper data fetching patterns
|
|
230302
|
+
- Implement proper error boundaries
|
|
230303
|
+
- Follow component composition patterns
|
|
230304
|
+
- Optimize re-renders appropriately
|
|
230305
|
+
- Write accessible components`,
|
|
230306
|
+
capabilities: [
|
|
230307
|
+
{ name: "react", keywords: ["react", "jsx", "tsx", "hooks", "useState", "useEffect"], confidence: 0.95, filePatterns: ["*.tsx", "*.jsx"] },
|
|
230308
|
+
{ name: "nextjs", keywords: ["nextjs", "next.js", "next", "app router", "server component", "vercel"], confidence: 0.9 },
|
|
230309
|
+
// Generic frontend keywords have lower confidence - only triggers when no specific tech mentioned
|
|
230310
|
+
{ name: "frontend", keywords: ["frontend", "component", "ui", "interface", "web app", "web application"], confidence: 0.5 }
|
|
230311
|
+
],
|
|
230312
|
+
// React has slightly higher priority as the default frontend choice when no specific tech is mentioned
|
|
230313
|
+
priority: 86,
|
|
230314
|
+
tier: "specialist",
|
|
230315
|
+
model: "sonnet",
|
|
230316
|
+
enabled: true,
|
|
230317
|
+
isBuiltin: true
|
|
230318
|
+
},
|
|
230286
230319
|
{
|
|
230287
230320
|
id: "frontend-svelte",
|
|
230288
230321
|
name: "frontend-svelte",
|
|
@@ -230307,7 +230340,8 @@ Best practices you enforce:
|
|
|
230307
230340
|
File patterns: *.svelte, +page.ts, +page.server.ts, +layout.ts`,
|
|
230308
230341
|
capabilities: [
|
|
230309
230342
|
{ name: "svelte", keywords: ["svelte", "sveltekit", "runes", "$state", "$derived"], confidence: 0.95, filePatterns: ["*.svelte", "+*.ts"] },
|
|
230310
|
-
|
|
230343
|
+
// Generic frontend keywords have lower confidence - Svelte only selected when explicitly mentioned
|
|
230344
|
+
{ name: "frontend", keywords: ["frontend", "component", "ui", "interface"], confidence: 0.4 },
|
|
230311
230345
|
{ name: "stores", keywords: ["store", "state", "writable", "readable"], confidence: 0.9 },
|
|
230312
230346
|
{ name: "ssr", keywords: ["ssr", "server-side", "hydration", "load function"], confidence: 0.85 }
|
|
230313
230347
|
],
|
|
@@ -230317,37 +230351,6 @@ File patterns: *.svelte, +page.ts, +page.server.ts, +layout.ts`,
|
|
|
230317
230351
|
enabled: true,
|
|
230318
230352
|
isBuiltin: true
|
|
230319
230353
|
},
|
|
230320
|
-
{
|
|
230321
|
-
id: "frontend-react",
|
|
230322
|
-
name: "frontend-react",
|
|
230323
|
-
displayName: "React Specialist",
|
|
230324
|
-
description: "Expert in React/Next.js development with hooks, state management, and patterns",
|
|
230325
|
-
systemPrompt: `You are a React/Next.js specialist. Your expertise includes:
|
|
230326
|
-
1. React 18+ with hooks and Server Components
|
|
230327
|
-
2. Next.js App Router and API routes
|
|
230328
|
-
3. State management (Context, Zustand, Redux)
|
|
230329
|
-
4. Component patterns and composition
|
|
230330
|
-
5. Performance optimization (memo, useMemo, useCallback)
|
|
230331
|
-
6. Testing with React Testing Library
|
|
230332
|
-
|
|
230333
|
-
Best practices you enforce:
|
|
230334
|
-
- Prefer Server Components where possible
|
|
230335
|
-
- Use proper data fetching patterns
|
|
230336
|
-
- Implement proper error boundaries
|
|
230337
|
-
- Follow component composition patterns
|
|
230338
|
-
- Optimize re-renders appropriately
|
|
230339
|
-
- Write accessible components`,
|
|
230340
|
-
capabilities: [
|
|
230341
|
-
{ name: "react", keywords: ["react", "jsx", "tsx", "hooks", "useState", "useEffect"], confidence: 0.95, filePatterns: ["*.tsx", "*.jsx"] },
|
|
230342
|
-
{ name: "nextjs", keywords: ["nextjs", "next.js", "app router", "server component"], confidence: 0.9 },
|
|
230343
|
-
{ name: "frontend", keywords: ["frontend", "component", "ui", "interface"], confidence: 0.85 }
|
|
230344
|
-
],
|
|
230345
|
-
priority: 85,
|
|
230346
|
-
tier: "specialist",
|
|
230347
|
-
model: "sonnet",
|
|
230348
|
-
enabled: true,
|
|
230349
|
-
isBuiltin: true
|
|
230350
|
-
},
|
|
230351
230354
|
{
|
|
230352
230355
|
id: "tailwind-expert",
|
|
230353
230356
|
name: "tailwind-expert",
|
|
@@ -231053,7 +231056,13 @@ var init_agent_registry = __esm({
|
|
|
231053
231056
|
});
|
|
231054
231057
|
}
|
|
231055
231058
|
}
|
|
231056
|
-
return results.sort((a, b) =>
|
|
231059
|
+
return results.sort((a, b) => {
|
|
231060
|
+
if (b.score !== a.score)
|
|
231061
|
+
return b.score - a.score;
|
|
231062
|
+
if (b.agent.priority !== a.agent.priority)
|
|
231063
|
+
return b.agent.priority - a.agent.priority;
|
|
231064
|
+
return a.agent.name.localeCompare(b.agent.name);
|
|
231065
|
+
});
|
|
231057
231066
|
}
|
|
231058
231067
|
/**
|
|
231059
231068
|
* Get tier multiplier for scoring
|
|
@@ -320747,7 +320756,7 @@ import * as path61 from "node:path";
|
|
|
320747
320756
|
import { homedir as homedir11 } from "node:os";
|
|
320748
320757
|
var import_strip_json_comments = __toESM(require_strip_json_comments(), 1);
|
|
320749
320758
|
var TRUSTED_FOLDERS_FILENAME = "trustedFolders.json";
|
|
320750
|
-
var SETTINGS_DIRECTORY_NAME = ".
|
|
320759
|
+
var SETTINGS_DIRECTORY_NAME = ".osagent";
|
|
320751
320760
|
var USER_SETTINGS_DIR = path61.join(homedir11(), SETTINGS_DIRECTORY_NAME);
|
|
320752
320761
|
function getTrustedFoldersPath() {
|
|
320753
320762
|
if (process.env["OSA_CLI_TRUSTED_FOLDERS_PATH"]) {
|
|
@@ -329023,7 +329032,7 @@ function getMergeStrategyForPath(path119) {
|
|
|
329023
329032
|
return current?.mergeStrategy;
|
|
329024
329033
|
}
|
|
329025
329034
|
__name(getMergeStrategyForPath, "getMergeStrategyForPath");
|
|
329026
|
-
var SETTINGS_DIRECTORY_NAME2 = ".
|
|
329035
|
+
var SETTINGS_DIRECTORY_NAME2 = ".osagent";
|
|
329027
329036
|
var USER_SETTINGS_PATH = Storage.getGlobalSettingsPath();
|
|
329028
329037
|
var USER_SETTINGS_DIR2 = path72.dirname(USER_SETTINGS_PATH);
|
|
329029
329038
|
var DEFAULT_EXCLUDED_ENV_VARS = ["DEBUG", "DEBUG_MODE"];
|
|
@@ -335564,7 +335573,7 @@ __name(getPackageJson, "getPackageJson");
|
|
|
335564
335573
|
// packages/cli/src/utils/version.ts
|
|
335565
335574
|
async function getCliVersion() {
|
|
335566
335575
|
const pkgJson = await getPackageJson();
|
|
335567
|
-
return "0.1.
|
|
335576
|
+
return "0.1.87";
|
|
335568
335577
|
}
|
|
335569
335578
|
__name(getCliVersion, "getCliVersion");
|
|
335570
335579
|
|
|
@@ -339766,8 +339775,8 @@ var formatDuration = /* @__PURE__ */ __name((milliseconds) => {
|
|
|
339766
339775
|
|
|
339767
339776
|
// packages/cli/src/generated/git-commit.ts
|
|
339768
339777
|
init_esbuild_shims();
|
|
339769
|
-
var GIT_COMMIT_INFO2 = "
|
|
339770
|
-
var CLI_VERSION2 = "0.1.
|
|
339778
|
+
var GIT_COMMIT_INFO2 = "f3fb13a";
|
|
339779
|
+
var CLI_VERSION2 = "0.1.87";
|
|
339771
339780
|
|
|
339772
339781
|
// packages/cli/src/utils/systemInfo.ts
|
|
339773
339782
|
async function getNpmVersion() {
|
|
@@ -382727,40 +382736,33 @@ var TaskMasterPanel = /* @__PURE__ */ __name(({
|
|
|
382727
382736
|
"%"
|
|
382728
382737
|
] })
|
|
382729
382738
|
] }),
|
|
382730
|
-
todos.length > 0 && /* @__PURE__ */ (0, import_jsx_runtime112.
|
|
382731
|
-
|
|
382732
|
-
|
|
382733
|
-
|
|
382734
|
-
|
|
382735
|
-
|
|
382736
|
-
|
|
382737
|
-
|
|
382738
|
-
|
|
382739
|
-
|
|
382740
|
-
|
|
382741
|
-
|
|
382742
|
-
|
|
382743
|
-
|
|
382744
|
-
|
|
382745
|
-
|
|
382746
|
-
|
|
382747
|
-
|
|
382748
|
-
|
|
382749
|
-
|
|
382750
|
-
|
|
382751
|
-
|
|
382752
|
-
|
|
382753
|
-
|
|
382754
|
-
|
|
382755
|
-
|
|
382756
|
-
|
|
382757
|
-
}),
|
|
382758
|
-
todos.length > (compact ? 5 : 10) && /* @__PURE__ */ (0, import_jsx_runtime112.jsxs)(Text3, { color: theme.text.secondary, children: [
|
|
382759
|
-
"\u2514 ... and ",
|
|
382760
|
-
todos.length - (compact ? 5 : 10),
|
|
382761
|
-
" more"
|
|
382762
|
-
] })
|
|
382763
|
-
] })
|
|
382739
|
+
todos.length > 0 && /* @__PURE__ */ (0, import_jsx_runtime112.jsx)(Box_default, { flexDirection: "column", marginTop: 1, paddingLeft: 1, children: todos.map((todo, idx) => {
|
|
382740
|
+
const isCompleted = todo.status === "completed";
|
|
382741
|
+
const isInProgress = todo.status === "in_progress";
|
|
382742
|
+
const isLast = idx === todos.length - 1;
|
|
382743
|
+
const iconColor = isInProgress ? Colors.AccentYellow : isCompleted ? theme.text.secondary : theme.text.primary;
|
|
382744
|
+
const textColor = isInProgress ? Colors.AccentYellow : isCompleted ? theme.text.secondary : theme.text.primary;
|
|
382745
|
+
return /* @__PURE__ */ (0, import_jsx_runtime112.jsxs)(Box_default, { children: [
|
|
382746
|
+
/* @__PURE__ */ (0, import_jsx_runtime112.jsxs)(Text3, { color: theme.text.secondary, children: [
|
|
382747
|
+
isLast ? "\u2514" : "\u251C",
|
|
382748
|
+
" "
|
|
382749
|
+
] }),
|
|
382750
|
+
/* @__PURE__ */ (0, import_jsx_runtime112.jsxs)(Text3, { color: iconColor, children: [
|
|
382751
|
+
STATUS_ICONS2[todo.status],
|
|
382752
|
+
" "
|
|
382753
|
+
] }),
|
|
382754
|
+
/* @__PURE__ */ (0, import_jsx_runtime112.jsx)(
|
|
382755
|
+
Text3,
|
|
382756
|
+
{
|
|
382757
|
+
color: textColor,
|
|
382758
|
+
dimColor: isCompleted,
|
|
382759
|
+
strikethrough: isCompleted,
|
|
382760
|
+
bold: isInProgress,
|
|
382761
|
+
children: isInProgress && todo.activeForm ? todo.activeForm : todo.content
|
|
382762
|
+
}
|
|
382763
|
+
)
|
|
382764
|
+
] }, todo.id);
|
|
382765
|
+
}) })
|
|
382764
382766
|
]
|
|
382765
382767
|
}
|
|
382766
382768
|
),
|
|
@@ -391874,13 +391876,24 @@ var AppContainer = /* @__PURE__ */ __name((props) => {
|
|
|
391874
391876
|
currentPrompt,
|
|
391875
391877
|
tokenUsage
|
|
391876
391878
|
});
|
|
391879
|
+
const hasAutoContextInjected = (0, import_react154.useRef)(false);
|
|
391877
391880
|
const handleFinalSubmit = (0, import_react154.useCallback)(
|
|
391878
391881
|
(submittedValue) => {
|
|
391879
391882
|
setCurrentPrompt(submittedValue);
|
|
391880
391883
|
setPromptCount((prev) => prev + 1);
|
|
391881
|
-
|
|
391884
|
+
const isSlashCommand2 = submittedValue.trim().startsWith("/");
|
|
391885
|
+
const needsAutoContext = !isSlashCommand2 && !hasAutoContextInjected.current && OSAMdFileCount === 0 && submittedValue.trim().length > 0;
|
|
391886
|
+
if (needsAutoContext) {
|
|
391887
|
+
hasAutoContextInjected.current = true;
|
|
391888
|
+
const enhancedPrompt = `Before responding to my request, please quickly explore this project to understand its structure (check package.json, README, main source directories). This will help you give better answers.
|
|
391889
|
+
|
|
391890
|
+
My request: ${submittedValue}`;
|
|
391891
|
+
addMessage(enhancedPrompt);
|
|
391892
|
+
} else {
|
|
391893
|
+
addMessage(submittedValue);
|
|
391894
|
+
}
|
|
391882
391895
|
},
|
|
391883
|
-
[addMessage]
|
|
391896
|
+
[addMessage, OSAMdFileCount]
|
|
391884
391897
|
);
|
|
391885
391898
|
const {
|
|
391886
391899
|
welcomeBackInfo,
|