{"_id":"@0x5278/copium","name":"@0x5278/copium","dist-tags":{"latest":"1.0.0"},"versions":{"1.0.0":{"name":"@0x5278/copium","version":"1.0.0","description":"100% free, no-account, no-subscription coding agent for the terminal","type":"module","module":"src/index.ts","main":"src/index.ts","bin":{"copium":"src/index.ts"},"scripts":{"start":"bun run src/index.ts","dev":"bun --watch run src/index.ts","typecheck":"bunx tsc --noEmit","lint":"bunx eslint src test --ext .ts","format":"bunx prettier --write src test","test":"bun test","prepublishOnly":"bun run typecheck && bun test"},"dependencies":{"@opentui/core":"^0.5.2"},"devDependencies":{"@types/bun":"^1.1.0","@types/node":"^22.0.0","typescript":"^5.5.0"},"engines":{"bun":">=1.1.0"},"keywords":["ai","coding agent","cli","tui","openrouter","ollama","local","free"],"license":"MIT","repository":{"type":"git","url":"git+https://github.com/JoeyKoch1/Copium.git"},"bugs":{"url":"https://github.com/JoeyKoch1/Copium/issues"},"homepage":"https://github.com/JoeyKoch1/Copium#readme","_id":"@0x5278/copium@1.0.0","gitHead":"c0c516b991cbcca3e070402596d39f35b128d09d","_nodeVersion":"22.23.2","_npmVersion":"10.9.8","dist":{"integrity":"sha512-9agkPARXQmuoBtixP3Fx3DD7ECtnBHNpvfB74f399NOytsSkMSoWCe7x2bfPc2C62k7mtJn76HFao6nZOQyjMg==","shasum":"e77ffebdda68a40b0b8a0b625a7a8830d4d8ce63","tarball":"https://registry.npmjs.org/@0x5278/copium/-/copium-1.0.0.tgz","fileCount":34,"unpackedSize":197044,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEUCIQCiXitp1NDliYYlflxzB/mfxEdu8xIK1qv2o8Zp/McTPgIgH4EVuI4xOkA4TDE2WaSlLi97n32hRY6KlFK3aKleOVU="}]},"_npmUser":{"name":"0x5278","email":"joeykoch2010@gmail.com"},"directories":{},"maintainers":[{"name":"0x5278","email":"joeykoch2010@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/copium_1.0.0_1787661812068_0.5148879262564803"},"_hasShrinkwrap":false}},"time":{"created":"2026-08-25T12:43:31.873Z","1.0.0":"2026-08-25T12:43:32.224Z","modified":"2026-08-25T12:43:32.436Z"},"maintainers":[{"name":"0x5278","email":"joeykoch2010@gmail.com"}],"description":"100% free, no-account, no-subscription coding agent for the terminal","homepage":"https://github.com/JoeyKoch1/Copium#readme","keywords":["ai","coding agent","cli","tui","openrouter","ollama","local","free"],"repository":{"type":"git","url":"git+https://github.com/JoeyKoch1/Copium.git"},"bugs":{"url":"https://github.com/JoeyKoch1/Copium/issues"},"license":"MIT","readme":"# Copium\n\n![banner](Assets/logo.webp)\n\n100% free, no-account, no-subscription coding agent for the terminal.\n\n## Why Copium\n\nWhy cope with expensive AI coding tools when Copium is free. Copium is a terminal-based coding agent (TUI) that gives you a fully functional coding agent without gating features behind payment, waitlists, or required accounts.\n\n## Features\n\n- **Multi-provider support** - OpenRouter, BYOK OpenAI-compatible endpoints, and Ollama local models\n- **Free by default** - Defaults to OpenRouter free auto-routed models. No credit card required\n- **Swarm agents** - Run a coordinated explorer → coder → reviewer pipeline with shared memory\n- **Agent tools** - Read/write files, run commands, search code, check git status/diff\n- **Persistent memory** - Every request and response is logged in compressed JSON so the agent always has context\n- **Permission tiers** - Choose read-only, propose-edits, or auto-execute modes\n- **Streaming responses** - Real-time token streaming from models\n\n## Requirements\n\n- [Bun](https://bun.sh) >= 1.1\n\n## Quick Start\n\n```bash\nbun install\nbun start\n```\n\nThis starts the interactive chat UI. Type a prompt and press Enter to send (Shift+Enter for a newline).\n\n| Key | Action |\n|-----|--------|\n| Enter | Send message |\n| Shift+Enter | Newline |\n| ? | Show help overlay |\n| Ctrl+L | Clear the transcript |\n\n### Slash commands\n\nType these in the input box:\n\n| Command | Action |\n|---------|--------|\n| `/model` | Pick a model from the provider (interactive picker) |\n| `/permission` | Switch permission level: read-only / propose-edits / auto-execute |\n| `/permission <lvl>` | Set permission level directly |\n| `/swarm <task>` | Run a swarm of agents on a task |\n| `/tools` | List the tools the agent can use |\n| `/config` | Show current provider/model/permission/swarm config |\n| `/stats` | Session stats: turns, tool calls, tokens, context % |\n| `/sessions` | Resume a previous saved session |\n| `/export [id] [dest]` | Export a session as a shareable folder |\n| `/import <folder>` | Import an exported session folder |\n| `/skill [name]` | List skills, or arm one for your next message |\n| `/plugins` | List discovered plugins and their commands |\n| `/theme` | Pick a color theme (built-in or custom) |\n| `/bypassperms` | Toggle never-ask permission mode (`/yolo`) |\n| `/clear` | Clear the transcript |\n| `/help` | Show help overlay |\n| `/version` | Print version |\n\n## Skills\n\nSkills are markdown files that inject instructions into the agent's system prompt. Place them in `~/.config/copium/skills/` (all projects) or `.copium/skills/` (this project only):\n\n```markdown\n---\nname: commit-style\ndescription: Conventional Commits for this repo\ntrigger: auto          # auto = keyword-matched, manual = via /skill <name>\nkeywords: commit, git commit\n---\nWhen creating git commits, use Conventional Commits format...\n```\n\nAuto-triggered skills activate when your message matches their keywords. Manual skills are armed with `/skill <name>` and apply to the next message.\n\n## Plugins\n\nPlugins are folders with a `plugin.json` and an entry module. Drop them in `~/.config/copium/plugins/` (user) or `.copium/plugins/` (project):\n\n```\nmy-plugin/\n  plugin.json     # { \"name\": \"my-plugin\", \"version\": \"1.0.0\" }\n  main.ts         # default export: (ctx: PluginContext) => void\n```\n\n```ts\n// my-plugin/main.ts\nimport type { PluginContext } from 'copium/src/plugins/loader';\n\nexport default function main(ctx: PluginContext) {\n  ctx.registerCommand('hello', 'say hi', (arg) => console.error(`hi ${arg}`));\n  ctx.registerTool(new MyCustomTool());\n  ctx.registerTheme({ name: 'my-theme', accent: '#ff5500' });\n  ctx.on('turn-end', () => console.error('turn finished'));\n}\n```\n\nPlugins can register tools (available to the model), slash commands, themes, and subscribe to lifecycle events (`turn-start`, `turn-end`, `tool-call`). Disable a plugin with `\"plugins\": { \"my-plugin\": false }` in config. See `examples/plugins/wordcount/` for a working example.\n\n⚠️ Plugins run with full runtime access — only install plugins you trust.\n\n## Custom Themes\n\nDrop a JSON file in `~/.config/copium/themes/my-theme.json`. Partial palettes merge over defaults:\n\n```json\n{ \"name\": \"my-theme\", \"accent\": \"#ff5500\", \"bg\": \"#0d0d0d\" }\n```\n\nPick it with `/theme` (custom themes are marked `(custom)`).\n\nIn one-shot mode you can pass `/model <id>` as the prompt to just switch the model:\n\n```bash\nbun run src/index.ts \"/model meta-llama/llama-3.3-70b\"\n```\n\n### One-shot mode\n\nPass a prompt as an argument to run non-interactively (no confirmations; denied unless `--permission auto-execute`):\n\n```bash\nbun run src/index.ts \"explain the diff in my last commit\"\n```\n\n### Swarm Mode\n\nEnable swarm mode with `--swarm`, then use `/swarm` in chat to run a task through a pipeline of agents:\n\n```bash\nbun run src/index.ts --swarm\n# then:  /swarm implement user authentication with JWT tokens\n```\n\nBy default, three agents run **in sequence**, each handing its output to the next: an Explorer scans the codebase and gathers context, a Coder implements the change, and a Reviewer checks it for correctness. They run one after another (not concurrently) so each stage can build on the last, and they share context and memory through compressed JSON logs stored in `.swarm/` next to your workspace.\n\n## Supported Providers\n\n| Provider | Default Model | Notes |\n|----------|--------------|-------|\n| OpenRouter | cohere/north-mini-code:free | Free model, no API key needed |\n| BYOK | deepseek-chat | Bring your own OpenAI-compatible endpoint |\n| Ollama | (first available) | Local models, fully offline |\n\n## Configuration\n\nConfiguration lives in `~/.config/copium/config.json` (override the path with `--config` or the `COPIUM_CONFIG_FILE` environment variable).\n\n```json\n{\n  \"provider\": \"openrouter\",\n  \"openrouter\": { \"apiKey\": \"\", \"model\": \"cohere/north-mini-code:free\" },\n  \"byok\": { \"endpoint\": \"https://api.deepseek.com/v1\", \"apiKey\": \"\", \"model\": \"deepseek-chat\" },\n  \"ollama\": { \"endpoint\": \"http://localhost:11434\", \"model\": \"\" },\n  \"permissionLevel\": \"propose-edits\",\n  \"swarm\": { \"enabled\": false, \"maxAgents\": 3 }\n}\n```\n\n### Environment variables\n\n| Variable | Description |\n|----------|-------------|\n| `OPENROUTER_API_KEY` / `COPIUM_OPENROUTER_API_KEY` | OpenRouter API key |\n| `COPIUM_OPENROUTER_MODEL` | OpenRouter model ID |\n| `COPIUM_BYOK_ENDPOINT` / `COPIUM_BYOK_API_KEY` / `COPIUM_BYOK_MODEL` | BYOK endpoint, key, model |\n| `COPIUM_OLLAMA_ENDPOINT` / `COPIUM_OLLAMA_MODEL` | Ollama endpoint, model |\n| `COPIUM_PROVIDER` | `ollama` \\| `openrouter` \\| `byok` |\n| `COPIUM_PERMISSION_LEVEL` | `read-only` \\| `propose-edits` \\| `auto-execute` |\n| `COPIUM_SWARM_ENABLED` | Enable swarm mode |\n| `COPIUM_SWARM_MAX_AGENTS` | Max agents in the swarm pipeline |\n\n### CLI options\n\n```\ncopium                        Start the interactive chat UI\ncopium \"<prompt>\"             Run a one-shot prompt (non-interactive)\ncopium /swarm \"<task>\"        Run a swarm of agents on a task\n\n--provider <p>       ollama | openrouter | byok\n--model <m>          Model name (provider-specific)\n--permission <lvl>   read-only | propose-edits | auto-execute\n--swarm              Enable swarm mode\n--max-agents <n>     Max swarm agents (default 3)\n--config <path>      Path to config file\n--list-models        List available models for the configured provider\n--version, -v        Print version\n--help, -h           Show this help\n```\n\n## Memory System\n\nEvery interaction is logged to `.swarm/memory/` in your workspace as compressed JSON. The agent reads this memory on every request to maintain full context across sessions.\n\n## Development\n\n```bash\nbun install\nbunx tsc --noEmit   # typecheck\nbun test            # tests\nbun start           # run the TUI\n```\n\n## License\n\nMIT\n\n","readmeFilename":"README.md","_rev":"1-f38f7bacabffc23f39b34e8d41f520e7"}