diff --git a/HISTORY.md b/HISTORY.md index 1c459553f..998bdbff5 100644 --- a/HISTORY.md +++ b/HISTORY.md @@ -1,3 +1,6 @@ +--- +nav_order: 999 +--- # Release history diff --git a/README.md b/README.md index 32e5ec7f0..5872388d6 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,9 @@ +--- +title: Home +nav_order: 10 +--- -# aider is AI pair programming in your terminal +# Aider is AI pair programming in your terminal Aider is a command line tool that lets you pair program with LLMs, to edit code stored in your local git repository. @@ -21,22 +25,6 @@ and supports [connecting to almost any LLM](https://aider.chat/docs/llms.html).

-- [Getting started](#getting-started) -- [Features](#features) -- [Usage](#usage) -- [Tutorial videos](https://aider.chat/docs/install.html#tutorial-videos) -- [In-chat commands](#in-chat-commands) -- [Tips](#tips) -- [Installation](https://aider.chat/docs/install.html) -- [Connecting to LLMs](https://aider.chat/docs/llms.html) -- [LLM Leaderboards](https://aider.chat/docs/leaderboards/) -- [Voice-to-code](https://aider.chat/docs/voice.html) -- [Example chat transcripts](https://aider.chat/examples/) -- [FAQ](https://aider.chat/docs/faq.html) -- [Discord](https://discord.gg/Tv2uQnR88V) -- [Blog](https://aider.chat/blog/) - - ## Getting started See the @@ -60,85 +48,29 @@ $ aider --opus ## Features * Chat with aider about your code by running `aider ...` from the command line with set of source files to discuss and edit together. Aider lets the LLM see and edit the content of those files. -* Aider can write and edit code in most popular languages: python, javascript, typescript, php, html, css, etc. +* Aider can write and edit code in most every popular languages: python, javascript, typescript, php, html, css, and more... * Aider works well with GPT-4o, Claude 3 Opus, GPT-3.5 and supports [connecting to almost any LLM](https://aider.chat/docs/llms.html). * Request new features, changes, improvements, or bug fixes to your code. Ask for new test cases, updated documentation or code refactors. * Aider will apply the edits suggested by the LLM directly to your source files. * Aider will [automatically commit each changeset to your local git repo](https://aider.chat/docs/faq.html#how-does-aider-use-git) with a descriptive commit message. These frequent, automatic commits provide a safety net. It's easy to undo changes or use standard git workflows to manage longer sequences of changes. * You can use aider with multiple source files at once, so aider can make coordinated code changes across all of them in a single changeset/commit. -* Aider can [give the LLM a map of your entire git repo](https://aider.chat/docs/repomap.html), which helps it understand and modify large codebases. +* Aider [gives the LLM a map of your entire git repo](https://aider.chat/docs/repomap.html), which helps it understand and modify large codebases. * You can also edit files by hand using your editor while chatting with aider. Aider will notice these out-of-band edits and keep up to date with the latest versions of your files. This lets you bounce back and forth between the aider chat and your editor, to collaboratively code with an LLM. * You can add images files to your chat if you are working with a vision capable OpenAI model (GPT-4o, GPT-4 Turbo, etc). +* You can add URLs to the chat and aider will scrape their content and share it with the LLM. -## Usage +## Documentation -Run `aider` with the source code files you want to edit. -These files will be "added to the chat session", so that the LLM can see their -contents and edit them according to your instructions. +- [Installation](https://aider.chat/docs/install.html) +- [Usage](https://aider.chat/docs/usage.html) +- [Tutorial videos](https://aider.chat/docs/tutorials.html) +- [Connecting to LLMs](https://aider.chat/docs/llms.html) +- [LLM Leaderboards](https://aider.chat/docs/leaderboards/) +- [FAQ](https://aider.chat/docs/faq.html) +- [Discord](https://discord.gg/Tv2uQnR88V) +- [Blog](https://aider.chat/blog/) -``` -aider ... -``` - -Be selective, and just add the files that the LLM will need to edit. -If you add a bunch of unrelated files, the LLM can get overwhelmed -and confused (and it costs more tokens). -Aider will automatically -share snippets from other, related files with the LLM so it can -[understand the rest of your code base](https://aider.chat/docs/repomap.html). - -You can also just launch aider anywhere in a git repo without naming -files on the command line. It will discover all the files in the -repo. You can then add and remove individual files in the chat -session with the `/add` and `/drop` chat commands described below. -If you or the LLM mention any of the repo's filenames in the conversation, -aider will ask if you'd like to add them to the chat. - -Aider also has many other options which can be set with -command line switches, environment variables or via a configuration file. -See `aider --help` for details. - - -## In-chat commands - -Aider supports commands from within the chat, which all start with `/`. Here are some of the most useful in-chat commands: - -* `/add `: Add matching files to the chat session, including image files. -* `/drop `: Remove matching files from the chat session. -* `/undo`: Undo the last git commit if it was done by aider. -* `/diff`: Display the diff of the last aider commit. -* `/run `: Run a shell command and optionally add the output to the chat. -* `/voice`: Speak to aider to [request code changes with your voice](https://aider.chat/docs/voice.html). -* `/help`: Show help about all commands. - -See the [full command docs](https://aider.chat/docs/commands.html) for more information. - - -## Tips - -* Think about which files need to be edited to make your change and add them to the chat. -Aider can help the LLM figure out which files to edit all by itself, but the most efficient approach is to add the needed files to the chat yourself. -* Large changes are best performed as a sequence of thoughtful bite sized steps, where you plan out the approach and overall design. Walk the LLM through changes like you might with a junior dev. Ask for a refactor to prepare, then ask for the actual change. Spend the time to ask for code quality/structure improvements. -* Use Control-C to safely interrupt the LLM if it isn't providing a useful response. The partial response remains in the conversation, so you can refer to it when you reply to the LLM with more information or direction. -* Use the `/run` command to run tests, linters, etc and show the output to the LLM so it can fix any issues. -* Use Meta-ENTER (Esc+ENTER in some environments) to enter multiline chat messages. Or enter `{` alone on the first line to start a multiline message and `}` alone on the last line to end it. -* If your code is throwing an error, share the error output with the LLM using `/run` or by pasting it into the chat. Let the LLM figure out and fix the bug. -* LLMs know about a lot of standard tools and libraries, but may get some of the fine details wrong about APIs and function arguments. You can paste doc snippets into the chat to resolve these issues. -* The LLM can only see the content of the files you specifically "add to the chat". Aider also sends a [map of your entire git repo](https://aider.chat/docs/repomap.html). So the LLM may ask to see additional files if it feels that's needed for your requests. - -## Example chat transcripts - -[The example transcripts page](https://aider.chat/examples/) shows how you can chat with aider to write -and edit code. - -## Installation - -See the [installation instructions](https://aider.chat/docs/install.html). - -## FAQ - -For more information, see the [FAQ](https://aider.chat/docs/faq.html). ## Kind words from users diff --git a/_config.yml b/_config.yml index b85b844ee..aa9dc38af 100644 --- a/_config.yml +++ b/_config.yml @@ -35,4 +35,11 @@ aux_links: - "https://github.com/paul-gauthier/aider" "Discord": - "https://discord.gg/Tv2uQnR88V" - \ No newline at end of file + "Blog": + - "/blog" + +nav_external_links: + - title: "GitHub" + url: "https://github.com/paul-gauthier/aider" + - title: "Discord" + url: "https://discord.gg/Tv2uQnR88V" diff --git a/_posts/2024-03-08-claude-3.md b/_posts/2024-03-08-claude-3.md index 8d71cec99..1254dcc91 100644 --- a/_posts/2024-03-08-claude-3.md +++ b/_posts/2024-03-08-claude-3.md @@ -2,6 +2,7 @@ title: Claude 3 beats GPT-4 on Aider's code editing benchmark excerpt: Claude 3 Opus outperforms all of OpenAI's models on Aider's code editing benchmark, making it the best available model for pair programming with AI. highlight_image: /assets/2024-03-07-claude-3.jpg +nav_exclude: true --- # Claude 3 beats GPT-4 on Aider's code editing benchmark diff --git a/_posts/2024-04-09-gpt-4-turbo.md b/_posts/2024-04-09-gpt-4-turbo.md index 5394ab6a7..eb4d07afe 100644 --- a/_posts/2024-04-09-gpt-4-turbo.md +++ b/_posts/2024-04-09-gpt-4-turbo.md @@ -2,6 +2,7 @@ title: GPT-4 Turbo with Vision is a step backwards for coding excerpt: OpenAI's GPT-4 Turbo with Vision model scores worse on aider's code editing benchmarks than all the previous GPT-4 models. In particular, it seems much more prone to "lazy coding" than the existing GPT-4 Turbo "preview" models. highlight_image: /assets/2024-04-09-gpt-4-turbo-laziness.jpg +nav_exclude: true --- # GPT-4 Turbo with Vision is a step backwards for coding diff --git a/_posts/2024-05-02-browser.md b/_posts/2024-05-02-browser.md index 64a81616d..4111d66e6 100644 --- a/_posts/2024-05-02-browser.md +++ b/_posts/2024-05-02-browser.md @@ -2,6 +2,7 @@ title: Aider in your browser excerpt: Aider has an experimental browser UI, allowing you to collaborate with LLMs on code in your local git repo. highlight_image: /assets/browser.jpg +nav_order: 800 --- # Aider in your browser diff --git a/_posts/2024-05-13-models-over-time.md b/_posts/2024-05-13-models-over-time.md index e3fa8ef01..d9397fa41 100644 --- a/_posts/2024-05-13-models-over-time.md +++ b/_posts/2024-05-13-models-over-time.md @@ -2,6 +2,7 @@ title: Drawing graphs with aider, GPT-4o and matplotlib excerpt: Use GPT-4o to draw graphs with matplotlib, including adjusting styles and making visual changes. You get the graph, but you also get the code in your repo. highlight_image: /assets/models-over-time.png +nav_exclude: true --- ![LLM coding skill over time](/assets/models-over-time.svg) diff --git a/_posts/2024-05-22-draft.md b/_posts/2024-05-22-draft.md index 0531bf677..22b74579c 100644 --- a/_posts/2024-05-22-draft.md +++ b/_posts/2024-05-22-draft.md @@ -3,6 +3,7 @@ title: A draft post. excerpt: With a draft summary. highlight_image: /assets/linting.jpg draft: true +nav_exclude: true --- # A draft post diff --git a/_posts/2024-05-22-linting.md b/_posts/2024-05-22-linting.md index a23f1b249..e6640ec2e 100644 --- a/_posts/2024-05-22-linting.md +++ b/_posts/2024-05-22-linting.md @@ -2,6 +2,7 @@ title: Linting code for LLMs with tree-sitter excerpt: Aider now lints code after every LLM edit and automatically fixes errors, using tree-sitter and AST-aware code context. highlight_image: /assets/linting.jpg +nav_exclude: true --- [![Linting code](/assets/linting.jpg)](https://aider.chat/assets/linting.jpg) diff --git a/_posts/2024-05-22-swe-bench-lite.md b/_posts/2024-05-22-swe-bench-lite.md index 17d3953ae..92e9ef67f 100644 --- a/_posts/2024-05-22-swe-bench-lite.md +++ b/_posts/2024-05-22-swe-bench-lite.md @@ -2,6 +2,7 @@ title: How aider scored SOTA 26.3% on SWE Bench Lite excerpt: Aider achieved this result mainly through its existing features that focus on static code analysis, reliable LLM code editing, and pragmatic UX for AI pair programming. highlight_image: /assets/swe_bench_lite.jpg +nav_exclude: true --- # How aider scored SOTA 26.3% on SWE Bench Lite diff --git a/_posts/2024-05-24-self-assembly.md b/_posts/2024-05-24-self-assembly.md index 1c9ca4aad..a79c1e59c 100644 --- a/_posts/2024-05-24-self-assembly.md +++ b/_posts/2024-05-24-self-assembly.md @@ -2,6 +2,7 @@ title: Aider has written 7% of its own code excerpt: Aider has written 7% of its own code, via 600+ commits that inserted 4.8K and deleted 1.5K lines of code. highlight_image: /assets/self-assembly.jpg +nav_exclude: true --- # Aider has written 7% of its own code diff --git a/_posts/2024-06-02-main-swe-bench.md b/_posts/2024-06-02-main-swe-bench.md index ad0b751c8..d70830354 100644 --- a/_posts/2024-06-02-main-swe-bench.md +++ b/_posts/2024-06-02-main-swe-bench.md @@ -2,6 +2,7 @@ title: Aider is SOTA for both SWE Bench and SWE Bench Lite excerpt: Aider sets SOTA for the main SWE Bench, after recently setting SOTA for the Lite version. highlight_image: /assets/swe_bench.jpg +nav_exclude: true --- # Aider is SOTA for both SWE Bench and SWE Bench Lite diff --git a/blog/index.html b/blog/index.html index 0bdf5e80f..df534b68f 100644 --- a/blog/index.html +++ b/blog/index.html @@ -1,5 +1,7 @@ --- layout: default +title: Blog +nav_order: 1000 ---
diff --git a/docs/benchmarks-0125.md b/docs/benchmarks-0125.md index 691558e24..256d85d8d 100644 --- a/docs/benchmarks-0125.md +++ b/docs/benchmarks-0125.md @@ -2,6 +2,7 @@ title: The January GPT-4 Turbo is lazier than the last version excerpt: The new `gpt-4-0125-preview` model is quantiatively lazier at coding than previous GPT-4 versions, according to a new "laziness" benchmark. highlight_image: /assets/benchmarks-0125.jpg +nav_exclude: true --- # The January GPT-4 Turbo is lazier than the last version diff --git a/docs/benchmarks-1106.md b/docs/benchmarks-1106.md index f6e364b58..8d2a2220e 100644 --- a/docs/benchmarks-1106.md +++ b/docs/benchmarks-1106.md @@ -2,6 +2,7 @@ title: Code editing benchmarks for OpenAI's "1106" models excerpt: A quantitative comparison of the code editing capabilities of the new GPT-3.5 and GPT-4 versions that were released in Nov 2023. highlight_image: /assets/benchmarks-1106.jpg +nav_exclude: true --- # Code editing benchmarks for OpenAI's "1106" models diff --git a/docs/benchmarks-speed-1106.md b/docs/benchmarks-speed-1106.md index b91316652..6d7d7cde9 100644 --- a/docs/benchmarks-speed-1106.md +++ b/docs/benchmarks-speed-1106.md @@ -3,6 +3,7 @@ title: Speed benchmarks of GPT-4 Turbo and gpt-3.5-turbo-1106 excerpt: This report provides a detailed comparison of the speed of GPT-4 Turbo and gpt-3.5-turbo-1106 models based on the aider benchmarking suite. canonical_url: https://aider.chat/2023/11/06/benchmarks-speed-1106.html highlight_image: /assets/benchmarks-speed-1106.jpg +nav_exclude: true --- # Speed benchmarks of GPT-4 Turbo and gpt-3.5-turbo-1106 diff --git a/docs/benchmarks.md b/docs/benchmarks.md index 41742f274..f21f5557c 100644 --- a/docs/benchmarks.md +++ b/docs/benchmarks.md @@ -2,6 +2,7 @@ title: GPT code editing benchmarks excerpt: Benchmarking GPT-3.5 and GPT-4 code editing skill using a new code editing benchmark suite based on the Exercism python exercises. highlight_image: /assets/benchmarks.jpg +nav_exclude: true --- # GPT code editing benchmarks diff --git a/docs/browser.md b/docs/browser.md new file mode 120000 index 000000000..cbd60a972 --- /dev/null +++ b/docs/browser.md @@ -0,0 +1 @@ +../_posts/2024-05-02-browser.md \ No newline at end of file diff --git a/docs/commands.md b/docs/commands.md index 9f28d03c9..cb2bca30a 100644 --- a/docs/commands.md +++ b/docs/commands.md @@ -1,9 +1,19 @@ -# Commands +--- +nav_order: 50 +--- +# In-chat commands + + +## In-chat commands + +Aider supports commands from within the chat, which all start with `/`. +Here are some of the most useful in-chat commands: - `/help`: Show help about all commands - `/exit`: Exit the application -## context management +## Context management + - `/add `: Add matching files to the chat session using glob patterns - `/drop `: Remove matching files from the chat session - `/web `: Add the contents of a webpage to the chat @@ -11,18 +21,20 @@ - `/ls`: List all known files and those included in the chat session - `/tokens`: Report on the number of tokens used by the current chat context -## git +## Git + - `/undo`: Undo the last git commit if it was done by aider - `/diff`: Display the diff of the last aider commit - `/commit `: Commit edits to the repo made outside the chat (commit message optional) - `/git `: Run a git command -## other +## Other + - `/run `: Run a shell command and optionally add the output to the chat, or use `!`. - `/test `: Like run, but automatically adds the output to the chat on non-zero exit codes. - `/voice`: Speak to aider to [request code changes with your voice](https://aider.chat/docs/voice.html). -# Prompt Toolkit defaults +# Keybindings The interactive prompt is built with [prompt-toolkit](https://github.com/prompt-toolkit/python-prompt-toolkit) which provides a lot of Emacs and Vi-style keyboard. Some emacs bindings you may find useful are diff --git a/docs/conventions.md b/docs/conventions.md index 2bef2da03..c7db95c90 100644 --- a/docs/conventions.md +++ b/docs/conventions.md @@ -1,3 +1,6 @@ +--- +nav_order: 100 +--- # Specifying coding conventions Sometimes you want GPT to be aware of certain coding guidelines, diff --git a/docs/ctags.md b/docs/ctags.md index 678135ef9..80ec1ad0c 100644 --- a/docs/ctags.md +++ b/docs/ctags.md @@ -2,6 +2,7 @@ title: Improving GPT-4's codebase understanding with ctags excerpt: Using ctags to build a "repository map" to increase GPT-4's ability to understand a large code base. highlight_image: /assets/robot-flowchart.png +nav_exclude: true --- # Improving GPT-4's codebase understanding with ctags diff --git a/docs/docker.md b/docs/docker.md index a06f1b773..2d98bcd00 100644 --- a/docs/docker.md +++ b/docs/docker.md @@ -1,5 +1,8 @@ +--- +nav_order: 100 +--- -# Run aider with docker (experimental) +# Run aider with docker You can run aider via docker without doing any local installation, like this: diff --git a/docs/faq.md b/docs/faq.md index 3af21f50d..98aa48da6 100644 --- a/docs/faq.md +++ b/docs/faq.md @@ -1,17 +1,12 @@ +--- +nav_order: 60 +--- # Frequently asked questions +{: .no_toc } -- [How does aider use git?](#how-does-aider-use-git) -- [Can I use aider with other LLMs, local LLMs, etc?](https://aider.chat/docs/llms.html) -- [Can I run aider in Google Colab?](#can-i-run-aider-in-google-colab) -- [How can I run aider locally from source code?](#how-can-i-run-aider-locally-from-source-code) -- [Can I script aider?](#can-i-script-aider) -- [What code languages does aider support?](#what-code-languages-does-aider-support) -- [How to use pipx to avoid python package conflicts?](#how-to-use-pipx-to-avoid-python-package-conflicts) -- [Aider isn't editing my files?](#aider-isnt-editing-my-files) -- [How can I add ALL the files to the chat?](#how-can-i-add-all-the-files-to-the-chat) -- [Can I specify guidelines or conventions?](#can-i-specify-guidelines-or-conventions) -- [Can I change the system prompts that aider uses?](#can-i-change-the-system-prompts-that-aider-uses) +- TOC +{:toc} ## How does aider use git? @@ -63,7 +58,7 @@ pip install -r requirements.txt python -m aider.main ``` -# Can I script aider? +## Can I script aider? You can script aider via the command line or python. diff --git a/docs/install.md b/docs/install.md index 73ece46c9..96842a8be 100644 --- a/docs/install.md +++ b/docs/install.md @@ -1,12 +1,29 @@ +--- +title: Installation +nav_order: 20 +--- # Installing aider +{: .no_toc } -- [Install git](#install-git) -- [Get your API key](#get-your-api-key) -- [Windows install](#windows-install) -- [Mac/Linux install](#maclinux-install) -- [Working with other LLMs](https://aider.chat/docs/llms.html) -- [Tutorial videos](#tutorial-videos) +- TOC +{:toc} + +## Quick start + +``` +$ pip install aider-chat + +# To work with GPT-4o +$ export OPENAI_API_KEY=your-key-goes-here +$ aider + +# To work with Claude 3 Opus: +$ export ANTHROPIC_API_KEY=your-key-goes-here +$ aider --opus +``` + +Or read on for more detailed installation instructions. ## Install git @@ -53,17 +70,9 @@ $ aider --anthropic-api-key sk-xxx... --opus Aider works well with GPT-4o, Claude 3 Opus, GPT-3.5 and supports [connecting to almost any LLM](https://aider.chat/docs/llms.html). -## Tutorial videos - -Here are a few tutorial videos: - -- [Aider : the production ready AI coding assistant you've been waiting for](https://www.youtube.com/watch?v=zddJofosJuM) -- Learn Code With JV -- [Holy Grail: FREE Coding Assistant That Can Build From EXISTING CODE BASE](https://www.youtube.com/watch?v=df8afeb1FY8) -- Matthew Berman -- [Aider: This AI Coder Can Create AND Update Git Codebases](https://www.youtube.com/watch?v=EqLyFT78Sig) -- Ian Wootten - ## You are done! -See the [usage instructions](/#usage) to start coding with aider. +See the [usage instructions](https://aider.chat/docs/usage.html) to start coding with aider. --- @@ -78,6 +87,7 @@ The steps below are completely optional. - [Install development versions of aider](#install-development-versions-of-aider-optional) ## Store your api key (optional) +{: .no_toc } You can place your api key in an environment variable: @@ -92,6 +102,7 @@ openai-api-key: sk-... ``` ## Enable Playwright (optional) +{: .no_toc } Aider supports adding web pages to the chat with the `/web ` command. When you add a url to the chat, aider fetches the page and scrapes its @@ -116,6 +127,7 @@ for additional information. ## Enable voice coding (optional) +{: .no_toc } Aider supports [coding with your voice](https://aider.chat/docs/voice.html) using the in-chat `/voice` command. @@ -128,6 +140,7 @@ Installing PortAudio is completely optional, but can usually be accomplished lik - For Linux, do `sudo apt-get install libportaudio2` ## Add aider to your editor (optional) +{: .no_toc } Other projects have integrated aider into some IDE/editors. It's not clear if they are tracking the latest @@ -136,12 +149,14 @@ so it may be best to just run the latest aider in a terminal alongside your editor. ### NeoVim +{: .no_toc } [joshuavial](https://github.com/joshuavial) provided a NeoVim plugin for aider: [https://github.com/joshuavial/aider.nvim](https://github.com/joshuavial/aider.nvim) ### VS Code +{: .no_toc } joshuavial also confirmed that aider works inside a VS Code terminal window. Aider detects if it is running inside VSCode and turns off pretty/color output, @@ -152,6 +167,7 @@ since the VSCode terminal doesn't seem to support it well. [https://marketplace.visualstudio.com/items?itemName=MattFlower.aider](https://marketplace.visualstudio.com/items?itemName=MattFlower.aider) ### Other editors +{: .no_toc } If you are interested in creating an aider plugin for your favorite editor, please let me know by opening a @@ -159,6 +175,7 @@ please let me know by opening a ## Install development versions of aider (optional) +{: .no_toc } If you want to install the very latest development version of aider: diff --git a/docs/leaderboards/index.md b/docs/leaderboards/index.md index 7fb8cf290..7eb12809f 100644 --- a/docs/leaderboards/index.md +++ b/docs/leaderboards/index.md @@ -1,5 +1,6 @@ --- highlight_image: /assets/leaderboard.jpg +nav_order: 900 --- # Aider LLM Leaderboards diff --git a/docs/llms.md b/docs/llms.md index 6ae9fb721..db4a98139 100644 --- a/docs/llms.md +++ b/docs/llms.md @@ -1,3 +1,7 @@ +--- +title: Connecting to LLMs +nav_order: 70 +--- # Aider can connect to most LLMs diff --git a/docs/repomap.md b/docs/repomap.md index 374455f17..ecadc6d6d 100644 --- a/docs/repomap.md +++ b/docs/repomap.md @@ -2,6 +2,7 @@ title: Building a better repository map with tree sitter excerpt: Tree-sitter allows aider to build a repo map that better summarizes large code bases. highlight_image: /assets/robot-ast.png +nav_exclude: true --- # Building a better repository map with tree sitter diff --git a/docs/tips.md b/docs/tips.md new file mode 100644 index 000000000..e25cdb7bb --- /dev/null +++ b/docs/tips.md @@ -0,0 +1,18 @@ +--- +nav_order: 50 +--- + +## Tips + +* Think about which files need to be edited to make your change and add them to the chat. +Aider can help the LLM figure out which files to edit all by itself, but the most efficient approach is to add the needed files to the chat yourself. +* Don't add *everything* to the chat, just the files you think need to be edited. +Aider also sends the LLM a [map of your entire git repo](https://aider.chat/docs/repomap.html). +So the LLM can see all the other relevant parts of your code base. +* Large changes are best performed as a sequence of thoughtful bite sized steps, where you plan out the approach and overall design. Walk the LLM through changes like you might with a junior dev. Ask for a refactor to prepare, then ask for the actual change. Spend the time to ask for code quality/structure improvements. +* Use Control-C to safely interrupt the LLM if it isn't providing a useful response. The partial response remains in the conversation, so you can refer to it when you reply to the LLM with more information or direction. +* Use the `/run` and `/test` commands to run the code or tests and show the output to the LLM so it can fix any issues. +* Use Meta-ENTER (Esc+ENTER in some environments) to enter multiline chat messages. Or enter `{` alone on the first line to start a multiline message and `}` alone on the last line to end it. +* If your code is throwing an error, share the error output with the LLM using `/run` or by pasting it into the chat. Let the LLM figure out and fix the bug. +* LLMs know about a lot of standard tools and libraries, but may get some of the fine details wrong about APIs and function arguments. You can paste doc snippets into the chat to resolve these issues. + diff --git a/docs/tutorials.md b/docs/tutorials.md new file mode 100644 index 000000000..38c262773 --- /dev/null +++ b/docs/tutorials.md @@ -0,0 +1,13 @@ +--- +nav_order: 25 +--- + +## Tutorial videos + +Here are a few tutorial videos made by aider users: + +- [Aider : the production ready AI coding assistant you've been waiting for](https://www.youtube.com/watch?v=zddJofosJuM) -- Learn Code With JV +- [Holy Grail: FREE Coding Assistant That Can Build From EXISTING CODE BASE](https://www.youtube.com/watch?v=df8afeb1FY8) -- Matthew Berman +- [Aider: This AI Coder Can Create AND Update Git Codebases](https://www.youtube.com/watch?v=EqLyFT78Sig) -- Ian Wootten + + diff --git a/docs/unified-diffs.md b/docs/unified-diffs.md index d1c65b30b..bc6001182 100644 --- a/docs/unified-diffs.md +++ b/docs/unified-diffs.md @@ -2,6 +2,7 @@ title: Unified diffs make GPT-4 Turbo 3X less lazy excerpt: GPT-4 Turbo has a problem with lazy coding, which can be signiciantly improved by asking for code changes formatted as unified diffs. highlight_image: /assets/benchmarks-udiff.jpg +nav_exclude: true --- # Unified diffs make GPT-4 Turbo 3X less lazy diff --git a/docs/usage.md b/docs/usage.md new file mode 100644 index 000000000..271c133b3 --- /dev/null +++ b/docs/usage.md @@ -0,0 +1,31 @@ +--- +nav_order: 30 +--- + +## Usage + +Run `aider` with the source code files you want to edit. +These files will be "added to the chat session", so that the LLM can see their +contents and edit them according to your instructions. + +``` +aider ... +``` + +Be selective, and just add the files that the LLM will need to edit. +If you add a bunch of unrelated files, the LLM can get overwhelmed +and confused (and it costs more tokens). +Aider will automatically +share snippets from other, related files with the LLM so it can +[understand the rest of your code base](https://aider.chat/docs/repomap.html). + +You can also just launch aider anywhere in a git repo without naming +files on the command line. It will discover all the files in the +repo. You can then add and remove individual files in the chat +session with the `/add` and `/drop` chat commands described below. +If you or the LLM mention any of the repo's filenames in the conversation, +aider will ask if you'd like to add them to the chat. + +Aider also has many other options which can be set with +command line switches, environment variables or via a configuration file. +See `aider --help` for details. diff --git a/docs/voice.md b/docs/voice.md index 2c994c727..5b5cb7d0f 100644 --- a/docs/voice.md +++ b/docs/voice.md @@ -1,3 +1,6 @@ +--- +nav_order: 100 +--- # Voice-to-code with aider diff --git a/examples/README.md b/examples/README.md index 77c28e189..37e7031ae 100644 --- a/examples/README.md +++ b/examples/README.md @@ -1,6 +1,8 @@ --- title: Example chat transcripts has_children: true +nav_order: 80 +has_toc: false --- # Example chat transcripts diff --git a/share/index.md b/share/index.md index 9ef901fbc..f4a5d7248 100644 --- a/share/index.md +++ b/share/index.md @@ -1,3 +1,6 @@ +--- +nav_exclude: true +--- # Shared aider chat transcript