@avcodes/mi
Advanced tools
+1
-1
@@ -9,3 +9,3 @@ #!/usr/bin/env node | ||
| // DIR = package root (for tool/skill discovery); MI_DIR/MI_PATH = env vars so tools can locate project assets. | ||
| Object.assign(global, { spawn, readFileSync, existsSync, readdirSync, homedir }); const DIR = new URL('.', import.meta.url).pathname; Object.assign(process.env, { MI_DIR: DIR, MI_PATH: new URL(import.meta.url).pathname }); if (!process.env.OPENAI_API_KEY && !process.argv.includes('-h')) { console.error('OPENAI_API_KEY required'); process.exit(1); } | ||
| Object.assign(global, { spawn, readFileSync, existsSync, readdirSync, homedir }); const DIR = new URL('.', import.meta.url).pathname; Object.assign(process.env, { MI_DIR: DIR, MI_PATH: new URL(import.meta.url).pathname }); const rc = `${homedir()}/.mirc`; if (existsSync(rc)) Object.entries(JSON.parse(readFileSync(rc, 'utf8'))).forEach(([k, v]) => process.env[k] ||= v); if (!process.env.OPENAI_API_KEY && !process.argv.includes('-h')) { console.error('OPENAI_API_KEY required'); process.exit(1); } | ||
@@ -12,0 +12,0 @@ // ── Tool discovery ─────────────────────────────────────────────────── |
+1
-1
| { | ||
| "name": "@avcodes/mi", | ||
| "version": "1.6.3", | ||
| "version": "1.7.0", | ||
| "description": "agentic coding in 30 loc. a loop, two tools, and an llm.", | ||
@@ -5,0 +5,0 @@ "type": "module", |
+15
-0
@@ -21,2 +21,3 @@ [](https://www.youtube.com/watch?v=JdMBn7FXilg) | ||
| - graceful `SIGINT` handling for bash child processes | ||
| - optional `~/.mirc` JSON config file (env vars always override) | ||
@@ -53,2 +54,16 @@ ## install | ||
| ## config | ||
| `~/.mirc` is an optional JSON config file. keys become env var defaults — your shell env always wins. | ||
| ```json | ||
| { | ||
| "MODEL": "o3", | ||
| "OPENAI_BASE_URL": "http://localhost:11434", | ||
| "REASONING_EFFORT": "high" | ||
| } | ||
| ``` | ||
| any env var that mi reads can be set here: `OPENAI_API_KEY`, `MODEL`, `OPENAI_BASE_URL`, `REASONING_EFFORT`, `SYSTEM_PROMPT`. | ||
| ## env | ||
@@ -55,0 +70,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 8 instances in 1 package
Filesystem access
Supply chain riskAccesses the file system, and could potentially read sensitive data.
Found 1 instance in 1 package
Long strings
Supply chain riskContains long string literals, which may be a sign of obfuscated or packed code.
Found 1 instance in 1 package
URL strings
Supply chain riskPackage contains fragments of external URLs or IP addresses, which the package may be accessing at runtime.
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 8 instances in 1 package
Filesystem access
Supply chain riskAccesses the file system, and could potentially read sensitive data.
Found 1 instance in 1 package
Long strings
Supply chain riskContains long string literals, which may be a sign of obfuscated or packed code.
Found 1 instance in 1 package
URL strings
Supply chain riskPackage contains fragments of external URLs or IP addresses, which the package may be accessing at runtime.
Found 1 instance in 1 package
63107
0.91%204
7.94%14
7.69%