{"slug": "lmcli-v0-7-0-tui-harness-with-smooth-performance-up-to-1m-context", "title": "lmcli v0.7.0 – TUI harness with smooth performance up to 1M context", "summary": "Lmcli v0.7.0, a general-purpose LLM harness written in Go, has been released with smooth performance at 1M+ token context and features including composable agents, custom tools, sandboxed execution, and branching conversations. The tool supports OpenAI-compatible and Anthropic-compatible APIs, consumes under 50MB of RAM per instance, and is available via Go install.", "body_md": "- Go 100%\n\n|\n|\n\n[screenshots](/mlow/lmcli/src/branch/main/screenshots)[.gitignore](/mlow/lmcli/src/branch/main/.gitignore)[CHANGELOG.md](/mlow/lmcli/src/branch/main/CHANGELOG.md)[config.sample.yaml](/mlow/lmcli/src/branch/main/config.sample.yaml)[go.mod](/mlow/lmcli/src/branch/main/go.mod)[go.sum](/mlow/lmcli/src/branch/main/go.sum)[LICENSE](/mlow/lmcli/src/branch/main/LICENSE)[main.go](/mlow/lmcli/src/branch/main/main.go)[README.md](/mlow/lmcli/src/branch/main/README.md)# lmcli - Large Model CLI\n\n`lmcli`\n\nis a general-purpose LLM harness. Use it to code, chat, or build custom\nagentic workflows!\n\nWe have [screenshots](/mlow/lmcli/src/branch/main/screenshots).\n\n## Features\n\n- Buttery smooth at 1M+ tokens (sliding-window rendering)\n- Composable, nesting\n[Agents](#user-content-agents) - Custom\n[tools](#user-content-tools)(exec-only, MCP coming soon) [Sandbox](#user-content-sandbox)tool execution- OpenAI-compatible and Anthropic-compatible API clients (talk to any local or remote API)\n- Branching, persisted conversations (thanks, SQLite <3)\n`vi`\n\n-like keybindings- Export conversations to JSON or HTML\n- Image support\n- < 50MB of RAM per instance\n\n## Installation\n\n```\ngo install codeberg.org/mlow/lmcli@latest\n```\n\n### Dependencies\n\n`lmcli`\n\nworks best when the following tools are available:\n\n- ripgrep - Grep tool\n- libchafa - image rendering\n- uv - Python tool\n`--with`\n\ndependencies - bubblewrap - Sandbox tools with\n`bwrap`\n\n## Configuration\n\nSee [ config.sample.yaml](/mlow/lmcli/src/branch/main/config.sample.yaml) for the full example configuration.\n\n### Defaults\n\nDefaults which apply to new `lmcli chat`\n\nand `lmcli new`\n\nsessions.\n\n```\n# ~/.config/lmcli/config.yaml\ndefaults:\n  model: deepseek-v4-flash\n  agent: default # default `lmcli chat` agent\n  codeAgent: coder # default `lmcli code` agent - just an alias\n  temperature: 1.0\n  maxTokens: 64000\n  effort: xhigh\n```\n\n### Agents\n\nAn Agent is a system prompt and a set of available tools.\n\nEach `lmcli`\n\nsession starts with a root agent, which the user interacts with\ndirectly. This agent may then delegate tasks using the `SubAgent`\n\ntool\n(provided it has been given access), and those sub-agents may delegate\nfurther.\n\nOnly synchronous sub-agents are supported at the moment; background/persisted sub-agents are planned for a future release.\n\nThe contents of `AGENT.md`\n\n, `AGENTS.md`\n\n, and `CLAUDE.md`\n\nwill automatically be\ninjected into the system prompt if any of them exist, and the agent has the\n`Read`\n\ntool.\n\n```\n# ~/.config/lmcli/config.yaml\nagents:\n  - name: default\n    systemPrompt: You are a helpful assistant.\n\n  - name: coding\n    tools:\n      - Bash\n      - Glob\n      - Grep\n      - Read\n      - Write\n      - Edit\n      - Python\n    systemPrompt: |-\n      You are an expert software engineer...\n      (see config.sample.yaml for an effective prompt)\n\n  - name: web_summarizer\n    tools:\n      - WebReader\n    systemPrompt:\n      Your task is to summarize the web page.\n```\n\n### Tools\n\nThe following tools are built-in:\n\n`Glob`\n\n- List files based on glob patterns`Grep`\n\n-`ripgrep`\n\n-powered code search`Read`\n\n- Read contents of a file`Write`\n\n- Write contents of a file`Edit`\n\n- Search and replace contents of a file`Bash`\n\n- Execute shell commands`Python`\n\n-`uv run --with=<deps>`\n\n-powered python execution`SubAgent`\n\n- Spawn a sub-agent - see[Agents](#user-content-agents)`WebReader`\n\n- Fetch web content using a Firecrawl endpoint.\n\nMost tools execute out-of-process via the `lmcli tool`\n\nsub-command, which may\nbe wrapped in the [Sandbox](#user-content-sandbox).\n\nTools usage is gated a very simple 'read-write-execute' permissions model.\nPress `ctrl-p`\n\nin the TUI to cycle through read-only, read-write, and read-write-execute\nunattended permissions, or use `lmcli chat|reply|new -p [rwx]`\n\n.\n\n**Custom tools** exec-based tools are supported.\n\nFor example, given the `GetWeather`\n\nexample below, the model's call to\n`GetWeather(location=\"Tokyo, Japan\", units=\"celsius\")`\n\nwould be piped the tool\nas:\n\n```\n{\"location\": \"Tokyo, Japan\", \"units\": \"celsius\"}\n```\n\nThe executable's stdout is used as the tool result, which is returned to the model as-is.\n\nEnvironment variables defined on custom tools get passed set on the environment during execution, hidden from the model.\n\n*MCP support is planned.*\n\n```\n# ~/.config/lmcli/config.yaml\ntools:\n  # Override a built-in tool\n  - name: WebReader\n    config:\n      backend: https://firecrawl.example.com/v1\n      apiKey: fc-...\n\n  # Custom external tool\n  - name: GetWeather\n    description: Get the current weather.\n    path: fetch-weather.sh\n    permission: read\n    parameters:\n      - name: location\n        type: string\n        required: true\n\n  - name: Read\n  - name: Write\n  - name: Edit\n  - name: Glob\n  - name: Grep\n```\n\n### Providers\n\n`lmcli`\n\nsupports local and remote OpenAI-compatible and Anthropic-compatible providers.\n\n```\n# ~/.config/lmcli/config.yaml\nproviders:\n  - name: deepseek\n    display: DeepSeek\n    kind: openai\n    baseUrl: https://api.deepseek.com/\n    models:\n      - deepseek-v4-pro\n\n  - name: anthropic\n    kind: anthropic\n    apiKey: ...\n    models:\n      - name: claude-sonnet-4-6\n```\n\n### Sandbox\n\nWhen enabled, `lmcli`\n\nsandboxes local tool invocations with\n[ bubblewrap](https://github.com/containers/bubblewrap).\n\nThe sandbox is configured to prevent filesystem access outside of the CWD (with\nconfigured exceptions), and to prevent leaking of `lmcli`\n\n's environment (API\nkeys, etc). Access to the host network stack remains a vector for escape.\n\nSandboxing is currently opt-in: `sandbox.enabled`\n\nmust be true.\n\n```\n# ~/.config/lmcli/config.yaml\nsandbox:\n  # Whether to use the sandbox, default false\n  enabled: true\n  # Whether to remap the working directory to /workspace in the sandbox\n  remapWorkspace: true\n  # Paths to map from the host into the sandbox\n  bindDirs:\n    - /home/user/.config:/home/user/.config:ro\n    - /home/user/.cache:/home/user/.cache:ro\n  # Paths to persist across lmcli instances and tool invocations\n  # Stored in ~/.local/share/lmcli/sandbox/<path>\n  persistDirs:\n    - /tmp\n```\n\n### Misc\n\nVarious settings that affect `lmcli`\n\n's behavior.\n\n```\n# ~/.config/lmcli/config.yaml\n\n# Conversation title generation\nconversations:\n  titleGeneration:\n    # Defaults to defaults.model\n    model: optional\n    # set to agent with custom prompt for title generation.\n    # Agent must respond with {\"title\": \"<title>\"} JSON\n    # Defaults to built-in agent, see pkg/lmcli/tasks/title.go\n    # agent: title-generator\n    effort: none\n    maxTokens: 1024\n\n# Syntax highlighting by Chroma: https://github.com/alecthomas/chroma\nchroma:\n  # Refer to: https://github.com/alecthomas/chroma/tree/master/styles\n  style: onedark\n  # - `terminal` - 8 colors\n  # - `terminal16` - 16 colors\n  # - `terminal256` - 256 colors\n  # - `terminal16m` - true color (default)\n  formatter: terminal16m\n\ntui:\n  hideHelpHint: false\n```\n\n## Usage\n\n``` bash\n$ lmcli help\nlmcli - Large Language Model CLI\n\nUsage:\n  lmcli <command> [flags]\n  lmcli [command]\n\nAvailable Commands:\n  chat        Open the chat interface\n  clone       Clone conversations\n  code        Open the chat interface with a code agent\n  completion  Generate the autocompletion script for the specified shell\n  edit        Edit the last user reply in a conversation\n  export      Export a conversation\n  help        Help about any command\n  list        List conversations\n  new         Start a new conversation\n  prompt      Do a one-shot prompt\n  rename      Rename a conversation\n  reply       Reply to a conversation\n  retry       Retry the last user reply in a conversation\n  rm          Remove conversations\n  view        View messages in a conversation\n\nFlags:\n  -h, --help   help for lmcli\n\nUse \"lmcli [command] --help\" for more information about a command.\n```\n\nNote: Use `ctrl+h`\n\nin the TUI view for keybindings.\n\n### Examples\n\nStart a new chat with the `code`\n\nagent wired up to perform file editing.\n\n``` bash\n$ lmcli code\n```\n\nStart a new conversation, imperative style (no tui):\n\n``` bash\n$ lmcli new \"Help me plan meals for the next week\"\n```\n\nSend a one-shot prompt (no persistence):\n\n``` bash\n$ lmcli prompt \"What is the answer to life, the universe, and everything?\"\n```\n\n#### tmux\n\nDo you run `lmcli`\n\nwith `tmux`\n\n? To get scroll-wheel scrolling working, you'll want the following in your `~/.tmux.conf`\n\n:\n\n```\n# Emulate scrolling by sending up and down keys if these commands are running in the pane\ntmux_commands_with_legacy_scroll=\"lmcli\"\nbind-key -T root WheelUpPane \\\n    if-shell -Ft= '#{?mouse_any_flag,1,#{pane_in_mode}}' \\\n        'send -Mt=' \\\n        'if-shell -t= \"#{?alternate_on,true,false} || echo \\\"#{tmux_commands_with_legacy_scroll}\\\" | grep -q \\\"#{pane_current_command}\\\"\" \\\n            \"send -t= Up\" \"copy-mode -et=\"'\n\nbind-key -T root WheelDownPane \\\n    if-shell -Ft = '#{?pane_in_mode,1,#{mouse_any_flag}}' \\\n        'send -Mt=' \\\n        'if-shell -t= \"#{?alternate_on,true,false} || echo \\\"#{tmux_commands_with_legacy_scroll}\\\" | grep -q \\\"#{pane_current_command}\\\"\" \\\n            \"send -t= Down\" \"send -Mt=\"'\n```\n\nThis example will be removed when `bubbletea`\n\nis able to handle scrolling in tmux on its own.\n\n## Roadmap\n\nI aim to keep `lmcli`\n\na light-weight and easy to understand shim between users\nand models. A driving philosophy is that models will grow capable of\naccomplishing increasingly complex tasks with access to the same set of simple\ntools.\n\nIn rough order of priority:\n\n- MCP (local custom tools already supported)\n- Skills\n- Image output\n- Built-in web search tool\n- RAG-driven prior conversation search\n- Computer use (connect to Wayland and/or X, pass display output to model, feed back mouse/KB inputs)\n- Semantic conversation search\n- Conversation categorization/tagging\n- Token accounting\n- Fleshed-out permissions model (beyond current read-write-execute model)\n\n## License\n\nMIT\n\n## Acknowledgements\n\n`lmcli`\n\nis a hobby project. Special thanks to the Go community and the creators\nof the libraries used in this project.", "url": "https://wpnews.pro/news/lmcli-v0-7-0-tui-harness-with-smooth-performance-up-to-1m-context", "canonical_source": "https://codeberg.org/mlow/lmcli", "published_at": "2026-06-13 06:19:33+00:00", "updated_at": "2026-06-13 06:54:07.930686+00:00", "lang": "en", "topics": ["large-language-models", "ai-tools", "developer-tools", "ai-agents"], "entities": ["lmcli", "OpenAI", "Anthropic", "SQLite", "Firecrawl", "ripgrep", "libchafa", "bubblewrap"], "alternates": {"html": "https://wpnews.pro/news/lmcli-v0-7-0-tui-harness-with-smooth-performance-up-to-1m-context", "markdown": "https://wpnews.pro/news/lmcli-v0-7-0-tui-harness-with-smooth-performance-up-to-1m-context.md", "text": "https://wpnews.pro/news/lmcli-v0-7-0-tui-harness-with-smooth-performance-up-to-1m-context.txt", "jsonld": "https://wpnews.pro/news/lmcli-v0-7-0-tui-harness-with-smooth-performance-up-to-1m-context.jsonld"}}