Coding Context CLI

A command-line interface for dynamically assembling context for AI coding agents.

This tool collects context from predefined rule files and task-specific prompts, substitutes parameters, and outputs a combined context to standard output. Use it to provide rich, relevant information to AI models like Claude, Gemini, or GPT.

Quick Example

# Install
sudo curl -fsL -o /usr/local/bin/coding-context \
  https://github.com/kitproj/coding-context-cli/releases/download/v0.0.23/coding-context_v0.0.23_linux_amd64
sudo chmod +x /usr/local/bin/coding-context

# Use with an AI agent
coding-context -p issue_key=BUG-123 -s languages=go /fix-bug | llm -m claude-3-5-sonnet-20241022

Documentation Structure

This documentation follows the Diataxis framework, organized by your needs:

📚 Tutorials - Learning-oriented

Step-by-step guides to get you started:

Best for: Learning the basics, first-time users, hands-on practice

🛠️ How-to Guides - Problem-oriented

Practical guides to solve specific problems:

Best for: Solving specific problems, achieving specific goals, practical tasks

📖 Reference - Information-oriented

Technical specifications and API details:

Best for: Looking up specific details, understanding options, technical specifications

💡 Explanation - Understanding-oriented

Conceptual guides to deepen your understanding:

Best for: Understanding concepts, learning why things work the way they do, big picture

Key Features

  • Dynamic Context Assembly: Merges context from various source files
  • Remote Directories: Load rules from Git, HTTP, S3, and other sources
  • Task-Specific Prompts: Different prompts for different tasks
  • Rule-Based Context: Reusable context snippets
  • Frontmatter Filtering: Select rules based on metadata
  • Bootstrap Scripts: Fetch or generate context dynamically
  • Parameter Substitution: Inject runtime values
  • Token Estimation: Monitor context size

Supported AI Agent Formats

Automatically discovers rules from configuration files for:

  • Anthropic Claude, Cursor, GitHub Copilot
  • Google Gemini, OpenCode.ai, Windsurf
  • Augment, Codex, and generic .agents/ directories

See Search Paths Reference for complete list.

Need Help?