Guide

Mastering CLI-Anything: Turn Any Desktop App into a Claude Skill

Build command-line harnesses for desktop software and wire them into Claude Code as token-efficient skills.

~7 min read

If you want to use NotebookLM or desktop creative tools to research, analyze, and build content seamlessly, connecting local software directly into your Claude Code workflow is a massive productivity booster. But running a stack of local Model Context Protocol (MCP) servers comes with real friction: background daemon processes, memory overhead, and context-window bloat from verbose JSON tool definitions on every turn.

CLI-Anything solves this by generating minimal, standalone command-line interfaces for any app or repository, even when no official MCP server or connector exists. By wrapping those CLI commands in a standard SKILL.md, your agent gets deterministic desktop automation with a fraction of the token cost.

What CLI-Anything is and why it matters

CLI-Anything is an open-source tool developed by HKUDS that automatically builds command-line harnesses for software. You point it at an application binary or codebase, and the tool analyzes the interface, drafts execution commands, and installs the required runtime automatically.

  • Works without official MCPs: controls desktop applications and local utilities that have no native AI connectors.
  • Token-optimized execution: MCP servers inject full JSON schemas into your prompt context on every message. CLI tools run on-demand via standard shell tools, keeping context clean.
  • Deterministic piping: CLI harnesses return standard stdout and exit codes, making them easy to test, script, and chain inside an agent loop.
Comment: 5 MCP servers active: tool schemas loaded on EVERY turn
Note: System prompt overhead: ~4,200 tokens before you type your request
Comment: CLI-Anything skill: 1 lightweight description line in skills catalog
Note: System prompt overhead: ~45 tokens. Full instructions load only on match.
CLI harnesses load into context only when triggered, saving thousands of tokens per session.

Step 1: Install the CLI-Anything hub

The ecosystem runs through a centralized package hub. Install the core hub using pip in your terminal:

Command: pip install cli-anything-hub
Output: Successfully installed cli-anything-hub-0.4.2
Install the hub package from PyPI.

Step 2: Download or generate an app harness

Once the hub is installed, you can browse and download community-built harnesses for specific applications. For example, to control NotebookLM research workflows:

Command: cli-hub install notebooklm
Output: Installed harness: notebooklm (v1.2.0) to ~/.local/bin/notebooklm
Comment: Or point CLI-Anything at any local app or repo to generate a new harness:
Command: cli-anything build --target ~/apps/my-custom-tool
Output: Analyzing codebase... 14 CLI commands generated successfully.
Pull a pre-built app harness or build a custom one from a local repository.

The harness translates desktop actions into predictable commands you can invoke right from the shell.

Step 3: Connect CLI commands into Claude Code as a skill

Claude Code does not require custom Python glue to execute these tools. You register the tool by creating a standard SKILL.md in your personal skills directory (~/.claude/skills/) or your project root (.claude/skills/).

---
name: notebooklm-research
description: Use when researching topics, ingesting source documents, or generating study notes via NotebookLM CLI.
---

# NotebookLM Research Skill

When asked to research a topic or process documents with NotebookLM:

1. Ingest sources into the active notebook:
   notebooklm add --file ./research/source-doc.pdf

2. Query the notebook for key synthesis:
   notebooklm query "Extract the core technical architecture and key takeaways"

3. Export notes to local Markdown:
   notebooklm export --out ./content/research-notes.md

4. Review the generated notes and cite key sources.

The skill in action: Watching Claude run the workflow

Once the skill is in place, ask Claude to research a topic. Claude matches your intent, announces the skill, runs the CLI harness, and reports the results:

You type: research the new Agent Skills specification using NotebookLM
Claude announces: Using notebooklm-research to ingest sources and extract key concepts
Command: notebooklm add --file ./docs/agentskills-spec.pdf
Output: Source added: 18 pages ingested into notebook "Agent Skills"
Command: notebooklm query "Summarize the 5 core frontmatter requirements"
Output: Generated summary from 1 source with 4 grounded citations
Command: notebooklm export --out ./notes/spec-summary.md
Output: Wrote structured Markdown summary to ./notes/spec-summary.md
Note: The entire research round-trip completed in one prompt without manual browser clicks.
Claude invokes the skill, ingests the document, and exports structured notes.

Productivity flows: Automating NotebookLM and desktop tools

Bridging Claude Code with local desktop applications unlocks continuous autonomous pipelines across tools like NotebookLM, Blender, Premiere Pro, and Zoom:

  1. Automated document research: Claude loads raw documentation into NotebookLM, triggers deep-dive analysis, and writes structured summary files to disk.
  2. Continuous evaluation loops: In unattended or background loops, Claude queries the notebook, evaluates new information against your style guide, and compiles draft articles.
  3. Multi-app publishing chains: An agent can pull research from NotebookLM, format media assets with desktop creative tools, and stage finished pages for review.

Production safety and operational rules

Desktop CLI tools give your agent real execution power on your workstation. Protect your environment with three practical habits:

  • Scope credentials carefully: store API tokens and application secrets in your environment vault, never in the SKILL.md itself.
  • Use dry-runs for destructive steps: write harnesses with explicit --dry-run or preview flags before applying state changes.
  • Test triggering boundaries: verify your skill description is scoped to specific requests so it does not intercept unrelated terminal commands.
Stay updated

Get new guides in your inbox

One task, one guide, done fast. Practical Claude Code skills, zero noise.