### Install Cecli Source: https://context7.com/cecli-dev/cecli/llms.txt Install Cecli from PyPI or uv. Run terminal setup once for key bindings and start the agent in the current directory. ```bash # Install from PyPI pip install cecli-dev # or with uv (recommended for isolation) uv tool install --native-tls --python python3.12 cecli-dev # Run terminal setup once (configures shift+enter key binding) cecli --terminal-setup # Start the agent in the current project directory cecli ``` -------------------------------- ### Start New Project Session Source: https://github.com/cecli-dev/cecli/blob/main/cecli/website/docs/usage/sessions.md An example of initiating a new project session by adding files and potentially other commands. This is the first step before saving the session. ```bash # Start a new project session /add package.json src/main.js src/components/ ``` -------------------------------- ### Start cecli with Ollama Model Source: https://github.com/cecli-dev/cecli/blob/main/cecli/website/docs/llms/ollama.md Navigate to your project directory and start cecli, specifying the Ollama model using the `ollama_chat/` prefix for recommended usage. For example: `cecli --model ollama_chat/`. ```bash # In another terminal window, change directory into your codebase cd /to/your/project cecli --model ollama_chat/ ``` -------------------------------- ### Configure Start Hook Source: https://context7.com/cecli-dev/cecli/llms.txt Define a hook to execute a shell command when the agent session starts. This example logs the start time and coder type to a file. ```yaml hooks: start: - name: log_start command: "echo 'Session started at {timestamp} [{coder_type}]' >> .cecli/hooks.log" priority: 10 enabled: true ``` -------------------------------- ### Add Markdown Installation Section Source: https://github.com/cecli-dev/cecli/blob/main/cecli/website/docs/usage/not-code.md Insert a new section into a Markdown file detailing installation instructions using both Homebrew and PyPI. ```markdown + ## Installation + ``` + # Homebrew + brew install cool-app-10k + + # PyPI + pipx install cool-app-10k + ``` ``` -------------------------------- ### Complete TUI Configuration Example Source: https://github.com/cecli-dev/cecli/blob/main/cecli/website/docs/config/tui.md Configure TUI colors, styles, and key bindings. This example shows extensive customization options for the TUI. ```yaml tui: true tui-config: colors: primary: "#00ff5f" secondary: "#888888" accent: "#00ff87" foreground: "#ffffff" background: "#1e1e1e" success: "#00aa00" warning: "#ffd700" error: "#ff3333" surface: "transparent" panel: "transparent" input-cursor-foreground: "#00ff87" other: dark: true input-cursor-text-style: "underline" use_terminal_background: false key_bindings: newline: "shift+enter" submit: "enter" completion: "tab" stop: "escape" editor: "ctrl+o" history: "ctrl+r" cycle_forward: "tab" cycle_backward: "shift+tab" input_start: "ctrl+home" input_end: "ctrl+end" output_up: "shift+pageup" output_down: "shift+pagedown" focus: "ctrl+f" cancel: "ctrl+c" clear: "ctrl+l" quit: "ctrl+q" ``` -------------------------------- ### Install Cecli Locally from Source Source: https://github.com/cecli-dev/cecli/blob/main/cecli/website/docs/faq.md Clone the repository, navigate to the project directory, create a virtual environment, and install cecli in editable mode to run it locally from the source code. ```bash # Clone the repository git clone git@github.com:cecli-AI/cecli.git # Navigate to the project directory cd cecli # It's recommended to make a virtual environment # Install cecli in editable/development mode, # so it runs from the latest copy of these source files python -m pip install -e . # Run the local version of cecli python -m cecli ``` -------------------------------- ### Install cecli using wget one-liner (Mac/Linux) Source: https://github.com/cecli-dev/cecli/blob/main/cecli/website/docs/install.md Downloads and executes the install script for cecli using wget. Use this if curl is not available. ```bash wget -qO- https://cecli.dev/install.sh | sh ``` -------------------------------- ### Install cecli with uv Source: https://github.com/cecli-dev/cecli/blob/main/cecli/website/index.html Use uv pip to install the cecli development version. This is the recommended method for installation. ```bash uv pip install cecli-dev ``` -------------------------------- ### Install boto3 with uv tool Source: https://github.com/cecli-dev/cecli/blob/main/cecli/website/docs/llms/bedrock.md Install the boto3 package using the uv tool, commonly used with cecli. ```bash # If you installed with cecli-install or `uv tool` uv tool run --from cecli-dev pip install boto3 ``` -------------------------------- ### Install cecli as a tool using uv Source: https://github.com/cecli-dev/cecli/blob/main/README.md Install cecli as a tool using uv. This is recommended to avoid interference with your development environment. ```bash uv tool install --native-tls --python python3.12 cecli-dev ``` -------------------------------- ### Install CECLI Source: https://github.com/cecli-dev/cecli/blob/main/cecli/website/_includes/get-started.md Install CECLI using the provided include file. Ensure you have Python 3.8-3.13 installed. ```bash {% include install.md %} ``` -------------------------------- ### Set up Development Environment Source: https://github.com/cecli-dev/cecli/blob/main/CONTRIBUTING.md Clone the repository, create and activate a virtual environment, install dependencies using uv, and set up pre-commit hooks. ```bash git clone https://github.com/dwash96/cecli.git cd cecli python3 -m venv venv source venv/bin/activate pip install uv uv pip install --native-tls -e . uv pip install --native-tls pre-commit pre-commit install cecli # OR! (legacy) aider-ce ``` -------------------------------- ### Quick Start with GitHub Copilot Source: https://github.com/cecli-dev/cecli/blob/main/cecli/website/docs/llms/github.md Navigate to your project directory and run cecli, specifying a GitHub Copilot model. ```bash # change into your project cd /to/your/project # talk to Copilot cecli --model openai/gpt-4o ``` -------------------------------- ### Install boto3 with pip Source: https://github.com/cecli-dev/cecli/blob/main/cecli/website/docs/llms/bedrock.md Install or upgrade the boto3 package using pip. ```bash # Or with pip pip install -U boto3 ``` -------------------------------- ### Install google-generativeai package Source: https://github.com/cecli-dev/cecli/blob/main/cecli/website/docs/llms/gemini.md Instructions for installing the google-generativeai package depending on your cecli installation method. ```bash # If you installed with cecli-install or `uv tool` uv tool run --from cecli-dev pip install google-generativeai # Or with pipx... pipx inject cecli-dev google-generativeai # Or with pip pip install -U google-generativeai ``` -------------------------------- ### Complete Cecli Configuration Example Source: https://github.com/cecli-dev/cecli/blob/main/cecli/website/docs/config/custom-system-prompts.md This example shows a complete Cecli configuration, including model selection, custom prompt mapping, custom command paths, and other operational settings like agent activation and auto-save. ```yaml # Model configuration model: gemini/gemini-3-pro-preview weak-model: gemini/gemini-3-flash-preview # Custom prompts configuration custom: prompt_map: agent: .cecli/custom/prompts/agent.yml base: .cecli/custom/prompts/my-base.yml # Custom commands configuration custom: command-paths: [".cecli/custom/commands/"] # Other cecli options agent: true auto-commits: false auto-save: true ``` -------------------------------- ### Install cecli using curl one-liner (Mac/Linux) Source: https://github.com/cecli-dev/cecli/blob/main/cecli/website/docs/install.md Downloads and executes the install script for cecli using curl. Assumes curl is available on the system. ```bash curl -LsSf https://cecli.dev/install.sh | sh ``` -------------------------------- ### Interactive cecli session example Source: https://github.com/cecli-dev/cecli/blob/main/cecli/website/docs/usage.md An example of an interactive cecli session, showing the initial startup information, available models, git repository status, and a user prompt to generate code. ```bash $ cecli factorial.py cecli v0.37.1-dev Models: gpt-4o with diff edit format, weak model gpt-3.5-turbo Git repo: .git with 258 files Repo-map: using 1024 tokens Use /help to see in-chat commands, run with --help to see cmd line args ─────────────────────────────────────────────────────────────────────── > Make a program that asks for a number and prints its factorial ... ``` -------------------------------- ### Ask/Code Workflow Example Source: https://github.com/cecli-dev/cecli/blob/main/cecli/website/docs/usage/modes.md Demonstrates a workflow where initial discussions and planning occur in 'ask' mode, followed by code modifications in 'code' mode. ```bash > /ask What's the best thing to print if we're making a quick little demo program? It sounds like you'd like to write a "Hello, world!" program. That's a very popular phrase to use for small demo programs. > /ask Yes, that's the idea. What are some more creative options? 1. "Greetings, Earthlings!" 2. "Beep boop, I am a computer!" 3. "To code, or not to code, that is the question." 4. "I think, therefore I print." 5. "01001000 01101001!" (Binary for "Hi!") > do 4 hello.py >>>>>>> SEARCH ======= def main(): print("I think, therefore I print.") <<<<<<< REPLACE > ALL CAPS! hello.py >>>>>>> SEARCH print("I think, therefore I print.") ======= print("I THINK, THEREFORE I PRINT!") <<<<<<< REPLACE ``` -------------------------------- ### Install boto3 with pipx Source: https://github.com/cecli-dev/cecli/blob/main/cecli/website/docs/llms/bedrock.md Install the boto3 package using pipx, a tool for managing Python applications. ```bash # Or with pipx... pipx inject cecli-dev boto3 ``` -------------------------------- ### cecli Configuration File Example Source: https://github.com/cecli-dev/cecli/blob/main/README.md Example of a .cecli.conf.yml file showing various configuration options for the cecli agent, including model, agent settings, and MCP server configuration. ```yaml model: agent: true auto-commits: true auto-save: true auto-load: false cache-prompts: true check-update: true debug: false enable-context-compaction: true context-compaction-max-tokens: 0.8 env-file: .cecli.env show-model-warnings: true use-enhanced-map: true watch-files: false tui: true agent-config: large_file_token_threshold: 8192 skip_cli_confirmations: false mcp-servers: mcpServers: context7: transport: http url: https://mcp.context7.com/mcp ``` -------------------------------- ### Agent Mode Skill Configuration Example Source: https://github.com/cecli-dev/cecli/blob/main/cecli/website/docs/config/skills.md Configure skills by specifying directories to search, and optionally include or exclude specific skills. This example also shows other agent settings like file token thresholds and tool whitelists. ```yaml # Enable Agent Mode agent: true # Agent Mode configuration agent-config: | { # Skills configuration "skills_paths": ["~/my-skills", "./project-skills"], # Directories to search for skills "skills_includelist": ["python-refactoring", "react-components"], # Optional: Whitelist of skills to include "skills_excludelist": ["legacy-tools"], # Optional: Blacklist of skills to exclude # Other Agent Mode settings "large_file_token_threshold": 12500, # Token threshold for large file warnings "skip_cli_confirmations": false, # YOLO mode - be brave and let the LLM cook "tools_includelist": ["view", "makeeditable", "replacetext", "finished"], # Optional: Whitelist of tools "tools_excludelist": ["command", "commandinteractive"], # Optional: Blacklist of tools "include_context_blocks": ["todo_list", "git_status"], # Optional: Context blocks to include "exclude_context_blocks": ["symbol_outline", "directory_structure"] # Optional: Context blocks to exclude } ``` -------------------------------- ### cecli Environment File Example Source: https://github.com/cecli-dev/cecli/blob/main/README.md Example of a .cecli.env file for storing API keys as environment variables. Ensure sensitive information is kept secure. ```dotenv ANTHROPIC_API_KEY="..." GEMINI_API_KEY="..." OPENAI_API_KEY="..." OPENROUTER_API_KEY="..." DEEPSEEK_API_KEY="..." ``` -------------------------------- ### Start cecli with LM Studio Model Source: https://github.com/cecli-dev/cecli/blob/main/cecli/website/docs/llms/lm-studio.md After configuring the environment variables, you can start using cecli with your LM Studio model by specifying the model name in the command. ```bash # Change directory into your codebase cd /to/your/project cecli --model lm_studio/ ``` -------------------------------- ### Start cecli with Cohere Command-R+ Source: https://github.com/cecli-dev/cecli/blob/main/cecli/website/docs/llms/cohere.md Initiate cecli using the specified Cohere model. Ensure you are in your project's directory. ```bash # Change directory into your codebase cd /to/your/project cecli --model command-r-plus-08-2024 ``` -------------------------------- ### Pull Ollama Model and Start Server Source: https://github.com/cecli-dev/cecli/blob/main/cecli/website/docs/llms/ollama.md Pull the desired model using `ollama pull `. Then, start the Ollama server with an increased context length using `OLLAMA_CONTEXT_LENGTH=8192 ollama serve`. ```bash # Pull the model ollama pull # Start your ollama server, increasing the context window to 8k tokens OLLAMA_CONTEXT_LENGTH=8192 ollama serve ``` -------------------------------- ### Install Development Requirements Source: https://github.com/cecli-dev/cecli/blob/main/CONTRIBUTING.md Install all necessary development dependencies, including the pytest testing framework, using the provided requirements file. ```bash pip install -r requirements-dev.txt ``` -------------------------------- ### Complete Cecli Agent Mode Configuration Example Source: https://github.com/cecli-dev/cecli/blob/main/cecli/website/docs/config/agent-mode.md A comprehensive example of a YAML configuration file for Cecli Agent Mode, demonstrating settings for agent activation, tool management, context blocks, performance, and skills. ```yaml # Enable Agent Mode agent: true # Agent Mode configuration agent-config: # Tool configuration tools_includelist: ["contextmanager", "edittext", "finished"] # Optional: Whitelist of tools tools_excludelist: ["command", "commandinteractive"] # Optional: Blacklist of tools tools_paths: ["./custom-tools", "~/my-tools"] # Optional: Directories or files containing custom tools # Context blocks configuration include_context_blocks: ["todo_list", "git_status"] # Optional: Context blocks to include exclude_context_blocks: ["symbol_outline", "directory_structure"] # Optional: Context blocks to exclude # Performance and behavior settings large_file_token_threshold: 12500 # Token threshold for large file warnings skip_cli_confirmations: false # YOLO mode - be brave and let the LLM cook # Skills configuration (see Skills documentation for details) skills_paths: ["~/my-skills", "./project-skills"] # Directories to search for skills skills_includelist: ["python-refactoring", "react-components"] # Optional: Whitelist of skills to include skills_excludelist: ["legacy-tools"] # Optional: Blacklist of skills to exclude # Other Agent Mode options use-enhanced-map: true # Use enhanced repo map with import relationships ``` -------------------------------- ### Basic Command Hook Configuration Source: https://github.com/cecli-dev/cecli/blob/main/cecli/website/docs/config/hooks.md Configure a command hook to log session start information to a file. This hook runs at the start of an agent session. ```yaml hooks: start: - name: log_session_start command: "echo 'Session started at {timestamp}' >> .cecli/hooks_log.txt" priority: 10 enabled: true description: "Logs session start to file" ``` -------------------------------- ### Install cecli using uv pip Source: https://github.com/cecli-dev/cecli/blob/main/README.md Install the cecli package using the uv pip tool. This method may offer performance benefits. ```bash uv pip install --native-tls cecli-dev ``` -------------------------------- ### Example Custom Agent Prompt Source: https://github.com/cecli-dev/cecli/blob/main/cecli/website/docs/config/custom-system-prompts.md This example demonstrates a custom agent prompt that overrides specific prompts, changes the reply language to Spanish, and adds detailed directives for proactive and concise behavior. ```yaml # .cecli/custom/prompts/agent.yml # Agent prompts - inherits from base.yaml # Overrides specific prompts _inherits: [agent, base] main_system: | ## Core Directives - **Role**: Act as an expert software engineer. - **Act Proactively**: Autonomously use file discovery and context management tools (`ViewFilesAtGlob`, `ViewFilesMatching`, `Ls`, `ContextManager`) to gather information and fulfill the user's request. Chain tool calls across multiple turns to continue exploration. - **Be Decisive**: Trust that your initial findings are valid. Refrain from asking the same question or searching for the same term in multiple similar ways. - **Be Concise**: Keep all responses brief and direct (1-3 sentences). Avoid preamble, postamble, and unnecessary explanations. Do not repeat yourself. - **Be Careful**: Break updates down into smaller, more manageable chunks. Focus on one thing at a time. Always reply to the user in spanish please. ``` -------------------------------- ### Start Cecli with Voice Input Enabled Source: https://context7.com/cecli-dev/cecli/llms.txt Initiate Cecli with specific voice input settings for language and audio format. ```bash # Start cecli with voice settings cecli --voice-language en --voice-format wav ``` -------------------------------- ### Start cecli with OpenRouter Model Source: https://github.com/cecli-dev/cecli/blob/main/cecli/website/docs/llms/openrouter.md Begin using cecli with a specified OpenRouter model. Replace / with the desired model identifier. ```bash # Change directory into your codebase cd /to/your/project # Or any other open router model cecli --model openrouter// ``` -------------------------------- ### Startup QOL Improvements Source: https://github.com/cecli-dev/cecli/blob/main/HISTORY.md Startup process includes a sanity check for the git repo and pauses for confirmation after model checks. ```python Startup QOL improvements: - Sanity check the git repo and exit gracefully on problems. - Pause for confirmation after model sanity check to allow user to review warnings. ``` -------------------------------- ### Example Pip Install Conflict Message Source: https://github.com/cecli-dev/cecli/blob/main/cecli/website/docs/troubleshooting/imports.md This message indicates a version conflict between a required package for cecli and the version currently installed in your environment. ```text cecli-dev 0.97.3 requires somepackage==X.Y.Z, but you have somepackage U.W.V which is incompatible. ``` -------------------------------- ### Clone Repositories and Build Docker Container Source: https://github.com/cecli-dev/cecli/blob/main/benchmark/README.md Steps to set up the benchmarking environment by cloning the main repository, creating a scratch directory, cloning the benchmark exercises, and building the Docker container. ```bash ORG=Aider-AI REPO=aider # Clone the main repo git clone https://github.com/$ORG/$REPO.git # Create the scratch dir to hold benchmarking results inside the main repo: cd $REPO mkdir tmp.benchmarks # Clone the repo with the exercises git clone https://github.com/$ORG/polyglot-benchmark tmp.benchmarks/polyglot-benchmark # Build the docker container ./benchmark/docker_build.sh ``` -------------------------------- ### Install cecli using pip Source: https://github.com/cecli-dev/cecli/blob/main/README.md Install the cecli package using pip. This is a standard Python package installation. ```bash pip install cecli-dev ``` -------------------------------- ### Install cecli with pipx Source: https://github.com/cecli-dev/cecli/blob/main/cecli/website/docs/install.md Installs cecli using pipx. Ensure pipx is installed first. Supports Python 3.10-3.14. ```bash python -m pip install pipx # If you need to install pipx ``` ```bash pipx install cecli-dev ``` -------------------------------- ### Install cecli using PowerShell one-liner (Windows) Source: https://github.com/cecli-dev/cecli/blob/main/cecli/website/docs/install.md Installs cecli on Windows by executing a PowerShell script. Bypasses execution policy for installation. ```powershell powershell -ExecutionPolicy ByPass -c "irm https://cecli.dev/install.ps1 | iex" ``` -------------------------------- ### Install pip-tools Source: https://github.com/cecli-dev/cecli/blob/main/CONTRIBUTING.md Installs the pip-tools package, which is necessary for managing Python dependencies. ```bash pip install pip-tools ``` -------------------------------- ### Connect to GPT-5.2 Source: https://github.com/cecli-dev/cecli/blob/main/cecli/website/index.html Launch cecli and configure it to use GPT-5.2. Provide your OpenAI API key. Ensure you are in your project's directory. ```bash # GPT-5.2 cecli --model openai/gpt-5.2 --api-key openai= ``` -------------------------------- ### Install Jekyll Gems Source: https://github.com/cecli-dev/cecli/blob/main/CONTRIBUTING.md Installs the necessary Ruby gems for building the project's Jekyll documentation. ```bash bundle install ``` -------------------------------- ### Switching Between Multiple Contexts Source: https://github.com/cecli-dev/cecli/blob/main/cecli/website/docs/usage/sessions.md Illustrates how to manage multiple project contexts by saving and loading different sessions. This allows for easy switching between frontend and backend work, for example. ```bash # Work on frontend /add src/components/*.jsx src/styles/*.css /save-session frontend-work # Switch to backend /reset /add server/*.py database/*.sql /save-session backend-work # Easily switch between contexts /load-session frontend-work ``` -------------------------------- ### AI Comment Syntax Examples Source: https://github.com/cecli-dev/cecli/blob/main/cecli/website/docs/usage/watch.md Examples of AI comments in Python and JavaScript. These comments are recognized by cecli when watching files. ```python # Make a snake game. AI! # What is the purpose of this method AI? ``` ```javascript // Write a protein folding prediction engine. AI! ``` -------------------------------- ### Sample .env file for cecli configuration Source: https://github.com/cecli-dev/cecli/blob/main/cecli/website/docs/config/dotenv.md This sample .env file demonstrates how to configure API keys, select models, and set various cecli parameters. Uncomment and fill in the relevant lines for your setup. ```dotenv ########################################################## # Sample cecli .env file. # Place at the root of your git repo. # Or use `cecli --env ` to specify. ########################################################## ################# # LLM parameters: # # Include xxx_API_KEY parameters and other params needed for your LLMs. # See https://cecli.dev/docs/llms.html for details. ## OpenAI #OPENAI_API_KEY= ## Anthropic #ANTHROPIC_API_KEY= ##... ############# # Main model: ## Specify the model to use for the main chat #CECLI_MODEL= ######################## # API Keys and settings: ## Specify the OpenAI API key #CECLI_OPENAI_API_KEY= ## Specify the Anthropic API key #CECLI_ANTHROPIC_API_KEY= ## Specify the api base url #CECLI_OPENAI_API_BASE= ## (deprecated, use --set-env OPENAI_API_TYPE=) #CECLI_OPENAI_API_TYPE= ## (deprecated, use --set-env OPENAI_API_VERSION=) #CECLI_OPENAI_API_VERSION= ## (deprecated, use --set-env OPENAI_API_DEPLOYMENT_ID=) #CECLI_OPENAI_API_DEPLOYMENT_ID= ## (deprecated, use --set-env OPENAI_ORGANIZATION=) #CECLI_OPENAI_ORGANIZATION_ID= ## Set an environment variable (to control API settings, can be used multiple times) #CECLI_SET_ENV= ## Set an API key for a provider (eg: --api-key provider= sets PROVIDER_API_KEY=) #CECLI_API_KEY= ################# # Model settings: ## List known models which match the (partial) MODEL name #CECLI_LIST_MODELS= ## Specify a file with cecli model settings for unknown models #CECLI_MODEL_SETTINGS_FILE=.cecli.model.settings.yml ## Specify a file with context window and costs for unknown models #CECLI_MODEL_METADATA_FILE=.cecli.model.metadata.json ## Add a model alias (can be used multiple times) #CECLI_ALIAS= ## Set the reasoning_effort API parameter (default: not set) #CECLI_REASONING_EFFORT= ## Set the thinking token budget for models that support it. Use 0 to disable. (default: not set) #CECLI_THINKING_TOKENS= ## Verify the SSL cert when connecting to models (default: True) #CECLI_VERIFY_SSL=true ## Timeout in seconds for API calls (default: None) #CECLI_TIMEOUT= ## Specify what edit format the LLM should use (default depends on model) #CECLI_EDIT_FORMAT= ## Use architect edit format for the main chat #CECLI_ARCHITECT= ## Enable/disable automatic acceptance of architect changes (default: True) #CECLI_AUTO_ACCEPT_ARCHITECT=true ## Specify the model to use for commit messages and chat history summarization (default depends on --model) #CECLI_WEAK_MODEL= ## Specify the model to use for editor tasks (default depends on --model) #CECLI_EDITOR_MODEL= ## Specify the edit format for the editor model (default: depends on editor model) #CECLI_EDITOR_EDIT_FORMAT= ## Only work with models that have meta-data available (default: True) #CECLI_SHOW_MODEL_WARNINGS=true ## Check if model accepts settings like reasoning_effort/thinking_tokens (default: True) #CECLI_CHECK_MODEL_ACCEPTS_SETTINGS=true ## Soft limit on tokens for chat history, after which summarization begins. If unspecified, defaults to the model's max_chat_history_tokens. #CECLI_MAX_CHAT_HISTORY_TOKENS= ################# # Cache settings: ## Enable caching of prompts (default: False) #CECLI_CACHE_PROMPTS=false ## Number of times to ping at 5min intervals to keep prompt cache warm (default: 0) #CECLI_CACHE_KEEPALIVE_PINGS=false ################### # Repomap settings: ## Suggested number of tokens to use for repo map, use 0 to disable #CECLI_MAP_TOKENS= ## Control how often the repo map is refreshed. Options: auto, always, files, manual (default: auto) #CECLI_MAP_REFRESH=auto ## Multiplier for map tokens when no files are specified (default: 2) #CECLI_MAP_MULTIPLIER_NO_FILES=true ## Maximum line length for the repo map code. Prevents sending crazy long lines of minified JS files etc. (default: 100) #CECLI_MAP_MAX_LINE_LENGTH=100 ################ # History Files: ``` -------------------------------- ### Serve Jekyll Documentation Locally Source: https://github.com/cecli-dev/cecli/blob/main/CONTRIBUTING.md Builds and serves the project's documentation locally using Jekyll, allowing for live preview during development. ```bash bundle exec jekyll serve ``` -------------------------------- ### Print Quoted Pip Install Commands Source: https://github.com/cecli-dev/cecli/blob/main/HISTORY.md Aider now prints quoted pip install commands to the user for clarity, especially on Windows. ```bash Print quoted pip install commands to the user. ``` -------------------------------- ### Configure MCP Servers via Command Line (YAML) Source: https://github.com/cecli-dev/cecli/blob/main/cecli/website/docs/config/mcp.md Use the '--mcp-servers' flag with a YAML string to configure MCP servers from the command line. This example sets up 'context7' and 'deepwiki' servers. ```bash cecli --mcp-servers 'mcpServers: context7: transport: http url: https://mcp.context7.com/mcp deepwiki: transport: http url: https://mcp.deepwiki.com/mcp' ``` -------------------------------- ### Configure MCP Servers via Command Line (JSON) Source: https://github.com/cecli-dev/cecli/blob/main/cecli/website/docs/config/mcp.md Provide MCP server configurations directly on the command line using the '--mcp-servers' flag with a JSON string. This example configures the 'git' MCP server. ```bash cecli --mcp-servers '{"mcpServers":{"git":{"transport":"http","url":"http://localhost:8000"}}}' ``` -------------------------------- ### Adopt Setuptools_scm for Dev Versions Source: https://github.com/cecli-dev/cecli/blob/main/HISTORY.md Setuptools_scm is now adopted to provide development versions with git hashes. ```python Adopt setuptools_scm to provide dev versions with git hashes. ``` -------------------------------- ### Run cecli with terminal setup Source: https://github.com/cecli-dev/cecli/blob/main/README.md Run the cecli agent with the --terminal-setup flag. This is recommended for first-time runs to configure keybindings, especially 'shift+enter'. ```bash cecli --terminal-setup ``` -------------------------------- ### Configure o3-mini Model Settings Source: https://github.com/cecli-dev/cecli/blob/main/cecli/website/docs/config/reasoning.md Example configuration for the 'o3-mini' model. Note the `use_temperature: false` setting, which is often required for reasoning models. ```yaml - name: o3-mini edit_format: diff weak_model_name: gpt-4o-mini use_repo_map: true use_temperature: false # <--- editor_model_name: gpt-4o editor_edit_format: editor-diff accepts_settings: ["reasoning_effort"] ``` -------------------------------- ### Example of LLM code block with triple backticks Source: https://github.com/cecli-dev/cecli/blob/main/cecli/website/docs/faq.md This example demonstrates how an LLM typically formats code within a markdown code block using triple backticks. ```markdown Here's some code: ``` print("hello") ``` ``` -------------------------------- ### Basic Python scripting with Coder Source: https://github.com/cecli-dev/cecli/blob/main/cecli/website/docs/scripting.md Initialize a Coder object with a model and file names, then run instructions sequentially. This example demonstrates running two distinct instructions and a chat command. ```python from cecli.coders import Coder from cecli.models import Model # This is a list of files to add to the chat fnames = ["greeting.py"] model = Model("gpt-4-turbo") # Create a coder object coder = Coder.create(main_model=model, fnames=fnames) # This will execute one instruction on those files and then return coder.run("make a script that prints hello world") # Send another instruction coder.run("make it say goodbye") # You can run in-chat "/" commands too coder.run("/tokens") ``` -------------------------------- ### ctags JSON Output Example Source: https://github.com/cecli-dev/cecli/blob/main/cecli/website/docs/ctags.md Example of the JSON output from running `ctags --fields=+S --output-format=json` on a Python file. This data is used to build the repo map. ```json { "_type": "tag", "name": "main", "path": "cecli/main.py", "pattern": "/^def main(args=None, input=None, output=None):$/", "kind": "function", "signature": "(args=None, input=None, output=None)" } { "_type": "tag", "name": "status", "path": "cecli/main.py", "pattern": "/^ status = main()$/", "kind": "variable" } ``` -------------------------------- ### Project Continuation Workflow Source: https://github.com/cecli-dev/cecli/blob/main/cecli/website/docs/usage/sessions.md Demonstrates a typical workflow for saving a project session and loading it later to continue work. This involves adding files, saving the session, and then loading it to resume. ```bash # Start working on a project /add src/main.py src/utils.py # ... have a conversation ... /save-session my-project # Later, continue where you left off /load-session my-project ``` -------------------------------- ### Install Playwright Browsers Source: https://github.com/cecli-dev/cecli/blob/main/cecli/website/docs/install/optional.md Install Playwright's chromium browser and its dependencies to enable cecli to scrape all web pages effectively, especially those relying on JavaScript or blocking standard requests. ```bash playwright install --with-deps chromium ``` -------------------------------- ### Use CECLI with Different Models Source: https://github.com/cecli-dev/cecli/blob/main/cecli/website/_includes/get-started.md After installing CECLI, navigate to your project directory and use the command-line interface to interact with various language models. Remember to replace '' with your actual API key for each service. ```bash # Change directory into your codebase cd /to/your/project # DeepSeek cecli --model deepseek --api-key deepseek= # Claude 3.7 Sonnet cecli --model sonnet --api-key anthropic= # o3-mini cecli --model o3-mini --api-key openai= ``` -------------------------------- ### Common MCP Server Configuration: Context7 Source: https://github.com/cecli-dev/cecli/blob/main/cecli/website/docs/config/mcp.md Example YAML configuration for the Context7 MCP server, specifying HTTP transport and its URL. This server provides up-to-date documentation and code examples. ```yaml mcp-servers: mcpServers: context7: transport: http url: https://mcp.context7.com/mcp ``` -------------------------------- ### Whole File Edit Format Example Source: https://github.com/cecli-dev/cecli/blob/main/cecli/website/docs/benchmarks.md An example of the 'whole' edit format, where GPT returns an updated copy of the entire file within markdown triple-backtick fences, preceded by the filename. ```text Here is the updated copy of your file demo.py: demo.py ```python def main(): print("goodbye") ``` ``` -------------------------------- ### Create and Configure a Python Typing Skill Source: https://context7.com/cecli-dev/cecli/llms.txt Set up a new skill directory with reference and evaluation files. The SKILL.md file defines the skill's metadata and usage patterns. ```bash # Create a skill directory mkdir -p ~/skills/python-typing/{references,scripts,assets,evals} cat > ~/skills/python-typing/SKILL.md << 'EOF' --- name: python-typing description: Best practices for adding Python type hints license: MIT metadata: version: 1.0.0 author: dev-team tags: [python, types, mypy] --- # Python Typing Skill Add PEP 484 type hints to function signatures and variables. ## Patterns 1. Use `Optional[X]` for nullable values 2. Use `Union[X, Y]` or `X | Y` (Python 3.10+) 3. Prefer `Sequence` over `list` for read-only params ## Example ```python from typing import Optional, Sequence def process(items: Sequence[str], limit: Optional[int] = None) -> list[str]: return list(items)[:limit] ``` EOF # Reference docs cat > ~/skills/python-typing/references/mypy-cheatsheet.md << 'EOF' # Mypy Quick Reference - `mypy --strict src/` — full strict mode - `# type: ignore[attr-defined]` — suppress specific error EOF # Evaluation tests cat > ~/skills/python-typing/evals/evals.json << 'EOF' { "skill_name": "python-typing", "evals": [ { "id": 1, "prompt": "Add type hints to the parse_config function", "expected_output": "Function signature includes parameter and return type annotations", "assertions": ["Should use proper type hint syntax", "Should not break existing logic"], "files": ["src/config.py"] } ] } EOF ``` ```python from typing import Optional, Sequence def process(items: Sequence[str], limit: Optional[int] = None) -> list[str]: return list(items)[:limit] ``` -------------------------------- ### Display Aider Startup Information Source: https://github.com/cecli-dev/cecli/blob/main/cecli/website/_includes/help.md Include these announcement lines when reporting problems to provide helpful context about your cecli version and LLM model configuration. ```text Aider v0.37.1-dev Models: gpt-4o with diff edit format, weak model gpt-3.5-turbo Git repo: .git with 243 files Repo-map: using 1024 tokens ``` -------------------------------- ### Install PortAudio for Voice Coding on Linux Source: https://github.com/cecli-dev/cecli/blob/main/cecli/website/docs/install/optional.md Install the PortAudio library on Linux systems to enable cecli's voice coding feature. This is typically done using the system's package manager. ```bash sudo apt-get install libportaudio2 ``` -------------------------------- ### Configure Chrome DevTools MCP Source: https://github.com/cecli-dev/cecli/blob/main/cecli/website/docs/config/mcp.md Configure the Chrome DevTools MCP server to connect to a running Chrome instance via stdio. Ensure Chrome is started with remote debugging enabled before starting the coding agent. ```yaml mcp-servers: mcpServers: chrome-devtools: transport: stdio command: npx args: - "chrome-devtools-mcp@latest" - "--browser-url" - "http://127.0.0.1:9222" ``` -------------------------------- ### Add Executable Script to Custom Skill Source: https://github.com/cecli-dev/cecli/blob/main/cecli/website/docs/config/skills.md Create a bash script (e.g., setup.sh) in the 'scripts/' directory of your custom skill and make it executable. This script can contain commands to set up or perform tasks related to the skill. ```bash # Add a script cat > ~/skills/my-custom-skill/scripts/setup.sh << 'EOF' #!/bin/bash echo "Setting up my custom skill..." # Setup commands here EOF chmod +x ~/skills/my-custom-skill/scripts/setup.sh ``` -------------------------------- ### Run Gemini Models with cecli Source: https://github.com/cecli-dev/cecli/blob/main/cecli/website/docs/llms/gemini.md Shortcuts to run Gemini 2.5 Pro and Gemini 2.5 Pro Exp models. Also shows how to list available Gemini models. ```bash # Change directory into your codebase cd /to/your/project # You can run the Gemini 2.5 Pro model with this shortcut: cecli --model gemini # You can run the Gemini 2.5 Pro Exp for free, with usage limits: cecli --model gemini-exp # List models available from Gemini cecli --list-models gemini/ ``` -------------------------------- ### Example Token Limit Error Message Source: https://github.com/cecli-dev/cecli/blob/main/cecli/website/docs/troubleshooting/token-limits.md This is an example of an error message reported by cecli when a model exceeds its token limits. It details input, output, and total token counts, and suggests actions to reduce token usage. ```text Model gpt-3.5-turbo has hit a token limit! Input tokens: 768 of 16385 Output tokens: 4096 of 4096 -- exceeded output limit! Total tokens: 4864 of 16385 To reduce output tokens: - Ask for smaller changes in each request. - Break your code into smaller source files. - Try using a stronger model like DeepSeek V3 or Sonnet that can return diffs. For more info: https://cecli.dev/docs/token-limits.html ```