Skip to content
clink-standalone logo

Clink Standalone

clink-standalone

Standalone CLI bridge - launch external AI CLIs (gemini, codex, claude) directly without MCP server. Use when you need to delegate tasks to specialized CLI tools with their own context windows. Supports role-based prompts and file references.

SKILL.md

Full skill instructions

Clink Standalone - CLI Bridge Skill (No MCP Required)

Overview

This skill provides a standalone interface to launch external AI CLI tools (gemini, codex, claude) without requiring an MCP server. It runs as a local Python script that directly executes CLI commands.

Key Benefits:

  • No MCP Server Needed: Runs standalone as a Python script
  • Isolated Context: Fresh context window for each CLI
  • Full CLI Capabilities: Web search, file tools, native features
  • Role-based Prompts: Pre-configured personas (default, planner, codereviewer)

Prerequisites

Before using this skill, install the CLIs you want to use:

# Gemini CLI (Google)
npm install -g @google/​gemini-cli
gemini auth login

# Codex CLI (Sourcegraph)
# Visit https://docs.sourcegraph.com/​codex

# Claude Code (Anthropic)
# Visit https://www.anthropic.com/​claude-code

Installation

  1. Copy the skill to your Claude skills directory:
cp -r vc/​clink-standalone ~/​.claude/​skills/​clink-standalone
  1. Install Python dependencies:
pip install pydantic

Usage

Basic Usage

# Run from the skill directory
cd ~/​.claude/​skills/​clink-standalone
python bin/​clink.py <cli_name> "<prompt>"

Examples

# Ask Gemini a question
python bin/​clink.py gemini "Explain async/​await in Python"

# Use Codex for code review
python bin/​clink.py codex "Review this code" --files src/​auth.py

# Use planner role
python bin/​clink.py gemini "Plan a microservices migration" --role planner

# Output as JSON
python bin/​clink.py gemini "What is Rust?" --json

# List available CLIs
python bin/​clink.py --list-clients

# List roles for a CLI
python bin/​clink.py --list-roles gemini

In Claude Code

When using this skill in Claude Code, Claude will execute the clink script:

User: "Use gemini to explain Rust ownership"

Claude will run:
python bin/​clink.py gemini "Explain Rust ownership system"

Available CLIs and Roles

CLIInstallStrengthsRoles
gemininpm install -g @google/​gemini-cli1M context, web searchdefault, planner, codereviewer
codexSourcegraph CodexCode analysis, reviewdefault, planner, codereviewer
claudeClaude CodeGeneral purposedefault, planner, codereviewer

Role Definitions

RolePurposeBest For
defaultGeneral tasksQuestions, summaries, quick answers
plannerStrategic planningMulti-phase plans, architecture, migrations
codereviewerCode analysisSecurity review, quality checks, bug hunting

Command Reference

python bin/​clink.py <cli_name> <prompt> [OPTIONS]

Options:
  --role, -r       Role to use (default: default)
  --files, -f      File paths to reference
  --images, -i     Image paths to include
  --config-dir     Custom config directory
  --json           Output as JSON
  --list-clients   List available CLIs
  --list-roles     List roles for a CLI

Directory Structure

clink-standalone/
├── bin/
│   └── clink.py           # Main CLI script
├── clink_core/
│   ├── __init__.py
│   ├── models.py          # Pydantic models
│   ├── registry.py        # Config loader
│   └── runner.py          # CLI execution
├── config/
│   ├── gemini.json        # Gemini CLI config
│   ├── codex.json         # Codex CLI config
│   └── claude.json        # Claude CLI config
├── systemprompts/
│   ├── gemini/
│   ├── codex/
│   └── claude/
└── SKILL.md               # This file

Configuration

CLI configurations are in config/​*.json:

{
  "name": "gemini",
  "command": "gemini",
  "additional_args": ["--telemetry", "false", "--yolo", "-o", "json"],
  "timeout_seconds": 300,
  "roles": {
    "default": {"prompt_path": "systemprompts/​gemini/​default.txt"},
    "planner": {"prompt_path": "systemprompts/​gemini/​planner.txt"},
    "codereviewer": {"prompt_path": "systemprompts/​gemini/​codereviewer.txt"}
  }
}

Customize by editing these files.

System Prompts

Role-specific prompts are in systemprompts/<cli>/<role>.txt. Edit these to customize behavior.

Error Handling

CLI Not Found

Error: Executable 'gemini' not found in PATH

Solution: Install the CLI first (see Prerequisites)

Timeout

Error: CLI 'gemini' timed out after 300 seconds

Solution: Increase timeout_seconds in config or break into smaller tasks

Invalid Output

Output was 75000 characters, exceeding limit

Solution: Narrow your prompt or request a summary

Best Practices

  1. Choose the Right CLI

    • Large context → gemini
    • Code tasks → codex
    • General tasks → claude
  2. Use Appropriate Roles

    • Strategic work → planner
    • Code review → codereviewer
    • Everything else → default
  3. File References

    • Pass file paths via --files, CLI reads what it needs
    • More efficient than embedding full content
  4. Break Down Large Tasks

    • If timeout occurs, split into smaller subtasks

Python API

You can also use clink as a Python module:

from clink_core import get_registry, run_cli

# Get registry
registry = get_registry()

# Get CLI and role
client = registry.get_client("gemini")
role = client.get_role("default")

# Run
result = run_cli(
    client=client,
    role=role,
    prompt="Explain async/​await in Python",
    files=["/​path/​to/​file.py"],
)

print(result.content)
print(result.metadata)

License

This is a standalone extraction of the clink functionality from zen-mcp-server.

More skills from diegosouzapw

accessibility logo
diegosouzapw/awesome-omni-skill

accessibility

Accessibility guidelines for VS Code features — covers accessibility help dialogs, accessible views, verbosity settings, accessibility signals, ARIA alerts/status announcements, keyboard navigation, and ARIA labels/roles. Applies to both new interactive UI surfaces and updates to existing feature...

62 1
View
mermaid-diagrams logo
diegosouzapw/awesome-omni-skill

mermaid-diagrams

Mermaid diagram creation for flowcharts, sequences, ERDs, and more. Generate diagrams from text in markdown files. Use for documentation, architecture diagrams, and visual representations. Triggers on mermaid, flowchart, sequence diagram, ERD, entity relationship, gantt chart, pie chart, class di...

62 1
View
tauri2-react-rust logo
diegosouzapw/awesome-omni-skill

tauri2-react-rust

Guides development of cross-platform desktop apps with Tauri 2, TypeScript, React, and Rust. Use when building Tauri apps, implementing IPC, designing Rust backend or TypeScript/React frontend, when researching or cloning a website (open site, snapshot elements), when verifying local dev or built...

62 1
View
fp-ts-errors logo
diegosouzapw/awesome-omni-skill

fp-ts-errors

Handle errors as values using fp-ts Either and TaskEither for cleaner, more predictable TypeScript code. Use when implementing error handling patterns with fp-ts.

62 0
View
ring:pre-dev-research logo
diegosouzapw/awesome-omni-skill

ring:pre-dev-research

Gate 0 research phase for pre-dev workflow. Dispatches 3 parallel research agents to gather codebase patterns, external best practices, and framework documentation BEFORE creating PRD/TRD. Outputs research.md with file:line references.

62 0
View
create-assistant logo
diegosouzapw/awesome-omni-skill

create-assistant

Create and configure Vapi voice AI assistants with models, voices, transcribers, tools, hooks, and advanced settings. Use when building voice agents, phone bots, customer support assistants, or any conversational AI that handles phone or web calls.

62 0
View
codex-headless logo
diegosouzapw/awesome-omni-skill

codex-headless

Delegiere Aufgaben an OpenAI Codex CLI im Headless-Mode. Nutzt ChatGPT Subscription (KEIN API Key). Nur Workspace-Zugriff, KEIN System-Zugriff. Auto-Accept mit --full-auto. Web-Recherche mit --search.

62 0
View
social-media-scheduler logo
diegosouzapw/awesome-omni-skill

social-media-scheduler

Generate a full week of social media content for any topic. Outputs platform-optimized posts for Twitter/X, LinkedIn, and Instagram with hashtags and posting times.

62 0
View
Data Privacy Compliance logo
diegosouzapw/awesome-omni-skill

Data Privacy Compliance

Data privacy and regulatory compliance specialist for GDPR, CCPA, HIPAA, and international data protection laws. Use when implementing privacy controls, conducting data protection impact assessments, ensuring regulatory compliance, or managing data subject rights. Expert in consent management, da...

62 0
View
triple-review logo
diegosouzapw/awesome-omni-skill

triple-review

Reviews a task using the TRIPLE protocol, as the review agent.

62 0
View
Tech Stack & Architecture Decision logo
diegosouzapw/awesome-omni-skill

Tech Stack & Architecture Decision

Define and document the technology stack and architecture decisions for a project. Use when the user needs to choose a tech stack, make architecture decisions, define infrastructure choices, or document technology selections. Triggers on requests like "define the tech stack", "choose technologies...

62 0
View

Popular AI tools

Kaiber logo
Video

Kaiber

Generate, edit, and beat-sync AI video with leading models in one workspace.

Paid
View
Vimcal logo
Productivity

Vimcal

The world's fastest calendar for remote work

Free
View

Transform Your Design with AI Designer by ImgCreator.ai

Freemium
View
Akool AI logo
Content & writing

Akool AI

Revolutionizing Video Production with AI-Powered Creativity

Paid
View

Extend an image past the frame and let AI fill the new aspect ratio.

Freemium
View
StarByFace logo
Security

StarByFace

Discover your celebrity doppelgänger with StarByFace!

Free
View
C

ChainClarity explains 700+ crypto whitepapers in plain English, with layered summaries, comparisons, research tools, alerts, and a $4.99 Pro plan.

Freemium
View
Opus Clip logo
Coding & apps

Opus Clip

Opus.ai: Revolutionize Your Web Experience

Free
View