181 Commits

Author SHA1 Message Date
yetone
d1286e7bfb
feat: enable token counting (#1157) 2025-02-02 01:27:12 +08:00
Christopher Brewin
0a273c2f5d
feat(sidebar): move quit and close key mappings into config values. (#979) 2025-02-01 09:48:11 -05:00
yetone
2ead26f809 feat: thinking 🤯 2025-01-27 22:54:24 +08:00
Yunlong
e849fc2c15
fix: prevent nil result_container error on buffer detach (#1123)
Co-authored-by: yetone <yetoneful@gmail.com>
2025-01-24 11:29:11 +08:00
yetone
c3dd0630f1
feat: not focusing on the last line when the cursor moves (#1110) 2025-01-21 00:32:04 +08:00
yetone
76f60794c3
fix: release the cursor when generating (#1109) 2025-01-21 00:04:48 +08:00
Seong Yong-ju
12beaebb2a
chore(sidebar): set different filetype for the selected files buffer (#1097)
Set different filetypes so that [edgy.nvim](https://github.com/folke/edgy.nvim)
can easily identify the result buffer and the selected files buffer.
2025-01-17 00:47:01 +08:00
yetone
81abbdb796
fix: add missing field ask for caculate_tokens (#1088) 2025-01-15 20:10:23 +08:00
Christopher Brewin
f401983737
feat(sidebar): support files outside of the current working directory. (#1065) 2025-01-11 23:15:13 +08:00
Alban Kurti
225e6f9572
feat: auto focus sidebar (#982) 2025-01-09 01:40:19 +08:00
Yang Jun
794c643033
fix: cannot apply changes if model is gemini-2.0-flash-thinking-exp-1219 (#1052) 2025-01-09 00:14:14 +08:00
yetone
a3ac0b84be
fix: seleted file is nil (#1049) 2025-01-07 14:36:31 +08:00
Yang Jun
c8ba3d36cc
feat: focus to input after /clear or /reset be execuated (#1044) 2025-01-06 16:51:35 +08:00
yetone
48fc35f978
fix: hide internal properties of config (#1036) 2025-01-05 18:27:23 +08:00
f7b51730df
fix(switch_windows): add nowait to avoid pre-<Tab> keymap (#1028) 2025-01-05 13:24:03 +08:00
yetone
81e5f1937f
fix: Claude sometimes gets lazy and doesnt return the filepath (#1025) 2025-01-02 21:34:39 +08:00
Rohith Ravi
be92be6124
feat(context): mention @quickfix to add files in qf to context (#988)
Neovim allows quickfix list to be populated in a variety of ways: grep,
lsp symbol references etc. Being able to add files in the quickfix
window to the LLM chat context allows for interesting workflows. For
example, one could search for a symbol using the LSP integration,
populate the quickfix with that list and then pass those along as
context in Avante using @quickfix mention in the sidebar.

If there are no files in the quickfix list or the items do not have a
file, nothing is added to the context.
2024-12-24 22:48:37 +08:00
Christopher Brewin
429bdd6b61
fix (sidebar) rendering and applying snippets for new files and files outside of the sidebar selected file context. (#991) 2024-12-24 22:44:02 +08:00
yetone
dde035831a
fix(ci): lua lint (#960) 2024-12-17 20:47:52 +08:00
Michael Gendy
e98fa46bec
feat(tokens): add token count display to sidebar (#956)
* feat (tokens) add token count display to sidebar

* refactor: calculate the real tokens and reuse input hints to avoid occlusion

---------

Co-authored-by: yetone <yetoneful@gmail.com>
2024-12-17 20:43:25 +08:00
Maddison Hellstrom
b102f673c4
feat(AvanteClear): accept args to clear history, memory or cache (#930)
* chore: extract sidebar clear history/memory functions

* feat(AvanteClear): accept args to clear history, memory or cache

Usage:
```
:AvanteClear [history|memory|cache]
```

- changed default behavior from clearing the cache to clearing history.
- added args to clear history, memory or cache.
- added confirm dialog before clearing cache.
2024-12-13 22:59:09 +08:00
Fernando Freire
5c20cc1779
feat(context): add current buffer to selected file ctx (#941) 2024-12-13 22:57:42 +08:00
Christopher Brewin
4d6f8e65fb
feat (sidebar) nvim-web-devicons support files with multiple dots and use default for unknown file types. (#943) 2024-12-13 22:54:16 +08:00
Christopher Brewin
78dd9b0a6d
feat(context): add a ui for selecting and adding files to the sidebar as context (#912)
* feat(sidebar): supports select files

chore (context) update add type annotations to context functions

chore (sidebar) remove unused notify function call

refactor (sidebar) remove setting search file to file path

chore (sidebar) remove nvim_notify debugging api call

* feat (files) allow selecting a file by string via cmp suggestion menu

* chore (context) refactor to allow context using @file with a context view

* refactor (context) refactor seletected file types as an array of path and content

* refactor (config) remove unused configuration options

* refactor (sidebar) remove unused unbild key

* refactor (context) remove unused imports

* refactor (mentions) update mentions to support items with callback functions and removal of the underlying selection.

* fix (sidebar) add file context as a window that is visitable via the tab key

* refactor (file_content) remove file content as an input to llm

* feat (sidebar) support suggesting and applying code in all languages that are in the context

* feat (sidebar) configurable mapping for removing a file from the context.

* feat (context_view) configure hints for the context view for adding and deleting a file.

* feat (context) add hints for the context view.

* fix (sidebar) type when scrolling the results buffer.

* refactor (selected files) refactor llm stream to accept an array of selected file metadata

* refactor: context => selected_files

---------

Co-authored-by: yetone <yetoneful@gmail.com>
2024-12-12 01:29:10 +08:00
yetone
5e6d3368f7
fix: diff insert (#893) 2024-11-24 05:10:09 +08:00
yetone
67e946ef13
fix: diagnostics lnum starts with 1 (#892) 2024-11-23 23:08:10 +08:00
yetone
9042f5f202
feat: enable diagnostics (#891) 2024-11-23 21:49:33 +08:00
Christopher Brewin
d14b2290d1
fix(sidebar): apply windows.wrap setting to code split and input split (#789) 2024-11-23 20:27:00 +08:00
yetone
9d0e1cd4af
fix: align lua oop (#889) 2024-11-23 20:23:05 +08:00
Christopher Brewin
da41105fc8
fix (sidebar) only display apply ext marks for codeblocks that can be applied (#883) 2024-11-23 12:48:21 +08:00
Will Lynas
341ecd2073
feat: minimal diff (#583)
* Add minimize_diff option and add dummy function

* fix: minimize snippets

---------

Co-authored-by: yetone <yetoneful@gmail.com>
2024-11-21 16:16:32 +08:00
yetone
5dd42548d4
fix: use relative path (#875) 2024-11-19 23:52:53 +08:00
yetone
c551bbe5b6
fix: cmp slash commands disappeared (#869) 2024-11-19 06:01:50 +08:00
yetone
3b390040f5
refactor: chat history based on project (#867) 2024-11-18 18:07:33 +08:00
yetone
0b1cd5509e
fix: incorrect filepath (#865) 2024-11-18 02:55:44 +08:00
yetone
7bab283616
fix: auto_apply_diff_after_generation (#849) 2024-11-16 01:02:38 +08:00
Christopher Brewin
af33f3a602
fix (sidebar) lock avante input and avante buffers to the sidebar window (#846) 2024-11-15 00:33:27 +08:00
yetone
9fbe0256f2
feat: keep the history content in the resp buffer (#807) 2024-11-05 21:02:38 +08:00
yetone
5db2a0f92f
fix: filter out empty history (#794) 2024-11-04 16:39:50 +08:00
yetone
1e8abbf798
feat: memory 🧠 (#793) 2024-11-04 16:20:28 +08:00
JIAJUN
58e0165098
feat: add configurable input window height for vertical layout (#773)
Co-authored-by: amojury <wujiajun880@gmail.com>
2024-11-03 16:48:37 +08:00
Maddison Hellstrom
8e8f2c15ab
feat: add windows.ask.focus_on_apply config option (#779) 2024-11-02 18:33:08 +08:00
Maddison Hellstrom
1aa8b03f00
feat: consider config.windows.ask.start_insert for non-floating ask window (#780) 2024-11-02 18:32:36 +08:00
João Mendonça
134cf40096
feat: toggle sidebar_header (#737) 2024-10-21 03:42:07 +08:00
yetone
a0d3845bf3
fix: failed to rename buffer (#730) 2024-10-16 23:57:40 +08:00
yetone
595ea56fc1
fix: compatible with backquoted returns (#728) 2024-10-16 16:23:02 +08:00
yetone
7c83558b37
feat: smart position (#725) 2024-10-15 17:12:10 +08:00
yetone
8c28e285ea
perf(sidebar): update the buffer more efficiently (#724) 2024-10-15 12:30:20 +08:00
Maddison Hellstrom
964715be64
feat: floating input (#721)
* feat: add floating input to ask method

Open a floating input similar to the "edit" input for the "ask" input.
Enabled in config via `Config.windows.ask.floating` or by passing
`{ floating = true }` to the `api.ask` method.

Includes logic to ensure the sidebar uses the correct buffer and selection
if an existing sidebar is open for another code buffer.

Also refactored the `selection` module to extract the floating input
logic into a new `PromptInput` class.

* docs: update config options

* feat: more accurate annotations to prevent user misunderstandings

---------

Co-authored-by: yetone <yetoneful@gmail.com>
2024-10-15 11:22:34 +08:00
yetone
b19573cb2a
feat: write to multiple files (#720) 2024-10-14 20:15:11 +08:00