{"_id":"@alenisaw/routis","_rev":"5-adea384c100fdcf66595e368eb9c5d83","name":"@alenisaw/routis","dist-tags":{"latest":"0.3.0"},"versions":{"0.1.1":{"name":"@alenisaw/routis","version":"0.1.1","keywords":["codex","cli","routing","execution-policy","typescript"],"license":"Apache-2.0","_id":"@alenisaw/routis@0.1.1","maintainers":[{"name":"alenisaw","email":"alenkz20001@gmail.com"}],"homepage":"https://github.com/alenisaw/routis#readme","bugs":{"url":"https://github.com/alenisaw/routis/issues"},"bin":{"routis":"bin/routis.js"},"dist":{"shasum":"8d3c225cf06a98facc0d46dec49dff6ad9d0e25b","tarball":"https://registry.npmjs.org/@alenisaw/routis/-/routis-0.1.1.tgz","fileCount":33,"integrity":"sha512-yGsaI4RlmNiSC1n0y5MDrWLvNeKNfE60klOx4LE+zJCCsum7tKZJkf/wu8/uOp7onu2FpeGcOI0MXpEQZZ2dKA==","signatures":[{"sig":"MEUCIQCT19ciL+hKyT5ySJhlXhSOx6WxhMhKrSH9E/CcCyzK+QIgNqn7w6GH9IT65gv6gvez4ZKoPkXyaPDOUovndWtqVr8=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":77411},"type":"module","engines":{"node":">=20"},"gitHead":"7abd9f4fba6d06c5af7073e3c81338663a38290c","scripts":{"cli":"tsx apps/cli/src/index.ts","test":"tsx tests/router-foundation.test.ts","build":"tsc -p tsconfig.json","prepack":"npm run build","prepare":"npm run build","install:local":"npm run build && npm link && node scripts/finalize-linked-cli.mjs","prepublishOnly":"npm run verify:release","verify:release":"npm run build && npm test","uninstall:local":"npm unlink --global routis"},"_npmUser":{"name":"alenisaw","email":"alenkz20001@gmail.com"},"repository":{"url":"git+https://github.com/alenisaw/routis.git","type":"git"},"_npmVersion":"10.5.2","description":"CLI-first adaptive execution router foundation for Codex","directories":{},"_nodeVersion":"20.13.1","dependencies":{"yaml":"^2.8.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"tsx":"^4.19.0","typescript":"^5.8.0","@types/node":"^24.0.0"},"_npmOperationalInternal":{"tmp":"tmp/routis_0.1.1_1776777028452_0.5585663034654866","host":"s3://npm-registry-packages-npm-production"},"deprecated":"Package no longer supported. Contact Support at https://www.npmjs.com/support for more info."},"0.2.0":{"name":"@alenisaw/routis","version":"0.2.0","keywords":["codex","cli","routing","execution-policy","typescript"],"license":"Apache-2.0","_id":"@alenisaw/routis@0.2.0","maintainers":[{"name":"alenisaw","email":"alenkz20001@gmail.com"}],"homepage":"https://github.com/alenisaw/routis#readme","bugs":{"url":"https://github.com/alenisaw/routis/issues"},"bin":{"routis":"bin/routis.js"},"dist":{"shasum":"673828c932091b14edd471a7d2b5854089fda614","tarball":"https://registry.npmjs.org/@alenisaw/routis/-/routis-0.2.0.tgz","fileCount":34,"integrity":"sha512-wS7smkXEYyi3mo+Q4bVH5Nzn4UEm93OphksU2vVBdSBDZyJCRrLrrt+QUggOSuWIUfIFjxfs11WrGCe9V4eVzg==","signatures":[{"sig":"MEUCICl0NGuuu+9AUUCTAa/pTWerbuDQSISkg7jrhI0VUaUNAiEAjeL30+pajesx+sHFVTp/dn6WTg81BkzEPe4Bw5Scwn4=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":88256},"type":"module","engines":{"node":">=20"},"gitHead":"22ce4a90d12e9afdf1e0595403982049205b6fbf","scripts":{"cli":"tsx apps/cli/src/index.ts","test":"tsx tests/router-foundation.test.ts","build":"tsc -p tsconfig.json","prepack":"npm run build","prepare":"npm run build","install:local":"npm run build && npm link && node scripts/finalize-linked-cli.mjs","prepublishOnly":"npm run verify:release","verify:release":"npm run build && npm test","uninstall:local":"npm unlink --global routis"},"_npmUser":{"name":"alenisaw","email":"alenkz20001@gmail.com"},"repository":{"url":"git+https://github.com/alenisaw/routis.git","type":"git"},"_npmVersion":"10.5.2","description":"CLI-first adaptive execution router foundation for Codex","directories":{},"_nodeVersion":"20.13.1","dependencies":{"yaml":"^2.8.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"tsx":"^4.19.0","typescript":"^5.8.0","@types/node":"^24.0.0"},"_npmOperationalInternal":{"tmp":"tmp/routis_0.2.0_1776825617997_0.4970656230377284","host":"s3://npm-registry-packages-npm-production"},"deprecated":"Package no longer supported. Contact Support at https://www.npmjs.com/support for more info."},"0.2.1":{"name":"@alenisaw/routis","version":"0.2.1","keywords":["codex","cli","routing","execution-policy","typescript"],"license":"Apache-2.0","_id":"@alenisaw/routis@0.2.1","maintainers":[{"name":"alenisaw","email":"alenkz20001@gmail.com"}],"homepage":"https://github.com/alenisaw/routis#readme","bugs":{"url":"https://github.com/alenisaw/routis/issues"},"bin":{"routis":"bin/routis.js"},"dist":{"shasum":"0e540d9466ef34cada8e3a9755e46fe0c0c02de3","tarball":"https://registry.npmjs.org/@alenisaw/routis/-/routis-0.2.1.tgz","fileCount":34,"integrity":"sha512-MdwPOtfakC1OcwfZL6nQGbHc2aK5ckJwaECPnDIyxAD0G2z30tK2r3W+oMZ6SDMrmtkUwyF3Rh106Q86ZFoCoA==","signatures":[{"sig":"MEUCIFgog6eUWvcN+QenJwr392gmaZaLUT9UeYsYKdq7DUFiAiEA4GN9GEqwFgC96x0pSfGDVw3iu54cjYSKrsHsHkDg+hw=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":92001},"type":"module","engines":{"node":">=20"},"gitHead":"9bbf73222b1cb7ab4e1a47e06595130435e7a831","scripts":{"cli":"tsx apps/cli/src/index.ts","test":"tsx tests/router-foundation.test.ts","build":"tsc -p tsconfig.json","prepack":"npm run build","prepare":"npm run build","install:local":"npm run build && npm link && node scripts/finalize-linked-cli.mjs","prepublishOnly":"npm run verify:release","verify:release":"npm run build && npm test","uninstall:local":"npm unlink --global routis"},"_npmUser":{"name":"alenisaw","email":"alenkz20001@gmail.com"},"repository":{"url":"git+https://github.com/alenisaw/routis.git","type":"git"},"_npmVersion":"10.5.2","description":"CLI-first adaptive execution router foundation for Codex","directories":{},"_nodeVersion":"20.13.1","dependencies":{"yaml":"^2.8.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"tsx":"^4.19.0","typescript":"^5.8.0","@types/node":"^24.0.0"},"_npmOperationalInternal":{"tmp":"tmp/routis_0.2.1_1776837241227_0.9927848339180625","host":"s3://npm-registry-packages-npm-production"},"deprecated":"Package no longer supported. Contact Support at https://www.npmjs.com/support for more info."},"0.3.0":{"name":"@alenisaw/routis","version":"0.3.0","keywords":["codex","cli","routing","execution-policy","typescript"],"license":"Apache-2.0","_id":"@alenisaw/routis@0.3.0","maintainers":[{"name":"alenisaw","email":"alenkz20001@gmail.com"}],"homepage":"https://github.com/alenisaw/routis#readme","bugs":{"url":"https://github.com/alenisaw/routis/issues"},"bin":{"routis":"bin/routis.js"},"dist":{"shasum":"32968f98a57d13a15947a1acb55e43366c681bcc","tarball":"https://registry.npmjs.org/@alenisaw/routis/-/routis-0.3.0.tgz","fileCount":46,"integrity":"sha512-uiIHV5rzFxW01Z/UqIKYJNoiRBkEH+sKGagRGrgidMFCmRZocF9dGVeYif7jBFBaBGKXB1KHofrOq6tHk24FIw==","signatures":[{"sig":"MEQCIBn9YpYKICdt7HSF7HE9i9S14zFSl2WgOEpP99cz59NkAiB8yBbdyVdhjomNoyMv9ZcdXrAEc29+Ikve6wp2OgkJAA==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":153017},"type":"module","engines":{"node":">=20"},"gitHead":"70c1030f1eee0be51eded33456e910bf73943305","scripts":{"cli":"tsx apps/cli/src/index.ts","test":"tsx tests/router-foundation.test.ts","build":"tsc -p tsconfig.json","prepack":"npm run build","prepare":"npm run build","install:local":"npm run build && npm link && node scripts/finalize-linked-cli.mjs","prepublishOnly":"npm run verify:release","verify:release":"npm run build && npm test","uninstall:local":"npm unlink --global routis"},"_npmUser":{"name":"alenisaw","email":"alenkz20001@gmail.com"},"repository":{"url":"git+https://github.com/alenisaw/routis.git","type":"git"},"_npmVersion":"10.5.2","description":"CLI-first adaptive execution router and interactive shell for Codex","directories":{},"_nodeVersion":"20.13.1","dependencies":{"yaml":"^2.8.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"tsx":"^4.19.0","typescript":"^5.8.0","@types/node":"^24.0.0"},"_npmOperationalInternal":{"tmp":"tmp/routis_0.3.0_1776842273907_0.7945105728258008","host":"s3://npm-registry-packages-npm-production"},"deprecated":"Package no longer supported. Contact Support at https://www.npmjs.com/support for more info."}},"time":{"created":"2026-04-21T13:10:28.338Z","modified":"2026-04-27T15:39:29.126Z","0.1.1":"2026-04-21T13:10:28.588Z","0.2.0":"2026-04-22T02:40:18.144Z","0.2.1":"2026-04-22T05:54:01.382Z","0.3.0":"2026-04-22T07:17:54.052Z"},"bugs":{"url":"https://github.com/alenisaw/routis/issues"},"license":"Apache-2.0","homepage":"https://github.com/alenisaw/routis#readme","keywords":["codex","cli","routing","execution-policy","typescript"],"repository":{"url":"git+https://github.com/alenisaw/routis.git","type":"git"},"description":"CLI-first adaptive execution router and interactive shell for Codex","maintainers":[{"name":"alenisaw","email":"alenkz20001@gmail.com"}],"readme":"<p align=\"center\">\r\n  <img src=\"https://em-content.zobj.net/source/apple/391/compass_1f9ed.png\" width=\"120\" />\r\n</p>\r\n\r\n<h1 align=\"center\">Routis</h1>\r\n\r\n<p align=\"center\">\r\n  <strong>adaptive client and execution policy layer for Codex</strong>\r\n</p>\r\n\r\n<p align=\"center\">\r\n  <a href=\"https://github.com/alenisaw/routis/stargazers\"><img src=\"https://img.shields.io/github/stars/alenisaw/routis?style=flat&color=yellow\" alt=\"Stars\"></a>\r\n  <a href=\"https://github.com/alenisaw/routis/commits/main\"><img src=\"https://img.shields.io/github/last-commit/alenisaw/routis?style=flat\" alt=\"Last Commit\"></a>\r\n  <a href=\"LICENSE\"><img src=\"https://img.shields.io/github/license/alenisaw/routis?style=flat\" alt=\"License\"></a>\r\n</p>\r\n\r\n<p align=\"center\">\r\n  <a href=\"#quickstart\">Quickstart</a> &bull;\r\n  <a href=\"#install\">Install</a> &bull;\r\n  <a href=\"#run\">Run</a> &bull;\r\n  <a href=\"#verify\">Verify</a> &bull;\r\n  <a href=\"#profiles\">Profiles</a> &bull;\r\n  <a href=\"#routing\">Routing</a>\r\n</p>\r\n\r\n---\r\n\r\nRoutis is an adaptive client and execution policy layer for Codex. It routes tasks into the right execution depth, reduces unnecessary token burn, keeps responses lean, and stays explainable.\r\n\r\nRight now it is intentionally narrow:\n\n- CLI-first\n- policy-driven\n- rule-based\n- repo-aware\n- interactive\n- explainable\n- dry-run first\n- thin Codex adapter\n\r\n## Quickstart\r\n\r\n```bash\nnpm install -g @alenisaw/routis\nroutis\n```\n\r\nExample output:\n\n```text\nRequested policy: default\nEffective profile: extradeep\nModel: gpt-5.4\nReasoning: xhigh\nSelected route: ExtraDeep\nWhy: Matched extradeep signal: \"redesign routing\".\n[optional] Mismatch warning: Requested profile \"cheap\" is lighter than inferred profile \"deep\".\nExecution mode: dry-run\nCodex command: $env:CODEX_HOME = '...'; & 'codex.cmd' 'exec' '-m' 'gpt-5.4' ...\n```\n\r\n## What It Does\r\n\r\n- accepts a task from the CLI\n- supports explicit task input through `--task <text>`\n- supports `--policy default|cheap|balanced|deep|extradeep`\n- supports custom policy loading through `--policy-file <path>`\n- supports `--dry-run` and `--execute`\n- supports `--explain` for expanded routing detail\n- supports `--help` and `--version`\n- starts an interactive shell when launched without a task\n- loads policy presets from YAML\n- uses a rule-based classifier to recommend an effective profile\n- inspects lightweight repository context when available\n- auto-selects an effective profile when `default` is requested\n- shows mismatch warnings when an explicit profile conflicts with the classifier recommendation\n- shows when repository context pushed the route higher\n- provides shell commands for session-level control over policy, mode, explain, and repo status\n- persists shell history across sessions\n- completes shell commands, policy values, and mode values\n- prepares a Codex execution plan from the selected effective profile\n- generates the Codex CLI command Routis would run\n- can optionally execute Codex CLI through a thin adapter\n\r\n## Install\r\n\r\nRequirements:\r\n\r\n- Node.js 20+\r\n- npm\r\n\r\nInstall from npm:\r\n\r\n```bash\r\nnpm install -g @alenisaw/routis\r\n```\r\n\r\nCheck the installation:\n\n```bash\nroutis\nroutis --version\nroutis --help\n```\n\r\nFor local development from the repository:\r\n\r\n```bash\r\nnpm install\r\nnpm run install:local\r\n```\r\n\r\nThat builds the project and runs `npm link`, so `routis` is available in your shell.\r\n\r\nOn Windows, the install step also removes the blocked `routis.ps1` shim so PowerShell resolves bare `routis` directly to the linked command launcher.\r\n\r\nIf you prefer to keep the generated PowerShell shim enabled for the current session instead, run:\r\n\r\n```powershell\r\nSet-ExecutionPolicy -Scope Process -ExecutionPolicy Bypass\r\n```\r\n\r\nRemove the local development link later with:\r\n\r\n```bash\r\nnpm run uninstall:local\r\n```\r\n\r\n## Run\n\nInteractive shell:\n\n```bash\nroutis\n```\n\nExplicit interactive shell entrypoint:\n\n```bash\nroutis shell\n```\n\nBasic run:\n\n```bash\nroutis \"fix typo in readme\"\n```\n\nExplicit task flag:\n\n```bash\nroutis --task \"fix typo in readme\"\n```\n\nExplicit profile:\n\n```bash\nroutis --policy deep \"debug tricky edge case in validation flow\"\n```\n\r\nDynamic default:\r\n\r\n```bash\r\nroutis --policy default \"redesign routing architecture across files\"\n```\n\nExpanded routing detail:\n\n```bash\nroutis --policy default --explain \"review and update the CLI config loading flow\"\n```\n\nRepo-aware routing in a dirty working tree:\n\n```bash\nroutis --policy default --explain \"look around\"\n```\n\nCustom policy file:\n\n```bash\nroutis --policy-file ./configs/policies/default.yaml --task \"implement CLI flag to load config\"\n```\n\nExecute mode:\n\n```bash\nroutis --policy balanced --execute \"implement CLI flag to load config\"\n```\n\r\nHelp:\n\n```bash\nroutis shell --policy deep --explain\nroutis --help\nroutis --version\n```\n\r\nUnknown profile handling:\n\r\n```bash\r\nroutis --policy unknown \"fix typo\"\n```\n\nUnknown option handling:\n\n```bash\nroutis --polciy deep \"fix typo\"\n```\n\nConflicting task input:\n\n```bash\nroutis --task \"fix typo\" extra words\n```\n\nThat fails clearly because Routis accepts either positional task input or `--task`, not both.\n\nIf the task itself starts with dashes, separate it with `--`:\n\n```bash\nroutis -- --review current route selection\n```\n\nIf you prefer not to link it globally, you can still run the development entrypoint:\n\n```bash\nnpm run cli -- --task \"review the current task summary\" --explain\n```\n\n## Shell\n\nWhen `routis` starts without a task, it opens an interactive shell.\n\nThe shell loads the current working directory, requested policy, execution mode, explain setting, and lightweight repo context before you start entering tasks.\n\nAvailable shell commands:\n\n- `/help`\n- `/status`\n- `/summary`\n- `/policy <preset>`\n- `/policy-file <path>`\n- `/mode <dry-run|execute>`\n- `/explain <on|off>`\n- `/context`\n- `/reload`\n- `/clear`\n- `/exit`\n\nNormal text input is treated as a task. Shell command completion is available for slash commands plus policy and mode values, and readline history is preserved across sessions.\n\r\n## Verify\r\n\r\nSmoke test:\r\n\r\n```bash\r\nnpm test\r\n```\r\n\r\nBuild:\r\n\r\n```bash\r\nnpm run build\r\n```\r\n\r\nRelease candidate check:\r\n\r\n```bash\r\nnpm run verify:release\r\n```\r\n\r\n## Profiles\n\n| Profile | Model | Reasoning | Notes |\n|--------|-------|-----------|-------|\n| `cheap` | `gpt-5.4-mini` | `none` | For quick, low-risk work |\n| `balanced` | `gpt-5.4` | `medium` | Default level for normal implementation work |\n| `deep` | `gpt-5.4` | `high` | For debugging, investigation, and riskier changes |\n| `extradeep` | `gpt-5.4` | `xhigh` | For redesigns and deeply uncertain work |\n| `default` | `dynamic` | `dynamic` | Auto-selects the effective profile from the classifier result |\n\r\n## Routing\r\n\r\nThe classifier is rule-based and meant to stay readable.\n\nIt looks at:\n\n- cheap signals like `typo`, `rename`, `format`, `small edit`\n- balanced signals like `implement`, `update`, `review`, `load config`\n- deep signals like `debug`, `architecture`, `migration`, `security`\n- extradeep signals like `redesign routing`, `major architecture change`, `large refactor across layers`\n- upgrade and downgrade cues that can move the result one level up or down\n- lightweight repository context such as changed file count, file type spread, and risk-zone paths like config, package, auth, schema, or workflow files\n\nIt is not trying to be clever. It is trying to be easy to inspect and easy to tune.\n\nWhen you run `--explain`, Routis now shows both prompt-derived routing and repo-derived routing context.\n\r\n## Repository Layout\r\n\r\n```text\r\nroutis/\r\n  apps/cli/                CLI entrypoint\r\n  bin/                     linked CLI wrapper\r\n  configs/policies/        YAML policy presets and shared routing rules\r\n  packages/codex-adapter/  thin Codex command planning and execution\r\n  packages/core/           classification and route selection\r\n  packages/policy/         policy types and loading\r\n  tests/                   smoke-test script\r\n```\r\n\r\n## Contributing\r\n\r\nSee [CONTRIBUTING.md](CONTRIBUTING.md).\r\n\r\n## License\r\n\r\nApache License 2.0. See [LICENSE](LICENSE).\r\n","readmeFilename":"README.md"}