@avcodes/mi
Advanced tools
+1
-1
@@ -26,3 +26,3 @@ #!/usr/bin/env node | ||
| } | ||
| const SYSTEM = process.env.SYSTEM_PROMPT || 'You are an autonomous coding agent with bash, read, and write tools. Explore first (bash/read to understand codebase), plan, make one change at a time, then verify (test/lint/run). If it fails, diagnose and fix—don\'t retry blindly. Be concise—show work via tool calls. Always read before editing. Write complete files. Prefer simple correct solutions. Summarize changes when done.'; | ||
| const SYSTEM = (process.env.SYSTEM_PROMPT || 'You are an autonomous coding agent with bash, read, and write tools.\nExplore first (bash/read to understand codebase), plan, make one change at a time, then verify (test/lint/run). If it fails, diagnose and fix—don\'t retry blindly.\nBe concise—show work via tool calls. Always read before editing. Write complete files. Prefer simple correct solutions. Summarize changes when done.') + `\nCWD: ${process.cwd()}\nDate: ${new Date().toISOString()}`; | ||
| const hist = [{role:'system',content:SYSTEM}]; const pIdx = process.argv.indexOf('-p'); | ||
@@ -29,0 +29,0 @@ if (pIdx !== -1 && process.argv[pIdx+1]) { hist.push({role:'user',content:process.argv[pIdx+1]}); console.log(await run(hist)); process.exit(0); |
+1
-1
| { | ||
| "name": "@avcodes/mi", | ||
| "version": "1.0.0", | ||
| "version": "1.0.1", | ||
| "description": "agentic coding in 30 loc. a loop, three tools, and an llm.", | ||
@@ -5,0 +5,0 @@ "type": "module", |
+14
-3
@@ -11,2 +11,13 @@  | ||
| ## install | ||
| ```sh | ||
| # run directly | ||
| npx @avcodes/mi | ||
| # or install globally | ||
| npm i -g @avcodes/mi | ||
| mi | ||
| ``` | ||
| ## usage | ||
@@ -16,9 +27,9 @@ | ||
| # interactive repl | ||
| OPENAI_API_KEY=sk-... node index.mjs | ||
| OPENAI_API_KEY=sk-... mi | ||
| # one-shot (run once, exit) | ||
| node index.mjs -p 'refactor auth.js to use bcrypt' | ||
| mi -p 'refactor auth.js to use bcrypt' | ||
| # local models via any openai-compatible api | ||
| MODEL=qwen3.5:4b OPENAI_BASE_URL=http://localhost:33821 node index.mjs | ||
| MODEL=qwen3.5:4b OPENAI_BASE_URL=http://localhost:33821 mi | ||
| ``` | ||
@@ -25,0 +36,0 @@ |
Network access
Supply chain riskThis module accesses the network.
Found 1 instance in 1 package
Shell access
Supply chain riskThis module accesses the system shell. Accessing the system shell increases the risk of executing arbitrary code.
Found 1 instance in 1 package
Environment variable access
Supply chain riskPackage accesses environment variables, which may be a sign of credential stuffing or data theft.
Found 4 instances in 1 package
Filesystem access
Supply chain riskAccesses the file system, and could potentially read sensitive data.
Found 1 instance in 1 package
Network access
Supply chain riskThis module accesses the network.
Found 1 instance in 1 package
Shell access
Supply chain riskThis module accesses the system shell. Accessing the system shell increases the risk of executing arbitrary code.
Found 1 instance in 1 package
Environment variable access
Supply chain riskPackage accesses environment variables, which may be a sign of credential stuffing or data theft.
Found 4 instances in 1 package
Filesystem access
Supply chain riskAccesses the file system, and could potentially read sensitive data.
Found 1 instance in 1 package
4033
3.38%43
34.38%