[nongnu] elpa/haskell-mode be2639592f 2/2: Merge pull request #1873 from haskell/dependabot/github_actions/cachix/install-nix-action-31

2025-03-24 Thread ELPA Syncer
branch: elpa/haskell-mode
commit be2639592f0fd3c779bcdcec54e2124277baa03f
Merge: 2ada981f24 0c9454a59a
Author: Steve Purcell 
Commit: GitHub 

Merge pull request #1873 from 
haskell/dependabot/github_actions/cachix/install-nix-action-31

chore(deps): bump cachix/install-nix-action from 30 to 31
---
 .github/workflows/test.yml | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml
index 6a76eec55a..7517b4ad9f 100644
--- a/.github/workflows/test.yml
+++ b/.github/workflows/test.yml
@@ -29,7 +29,7 @@ jobs:
   - emacs_version: 29.4
 target: deploy-manual
 steps:
-- uses: cachix/install-nix-action@v30
+- uses: cachix/install-nix-action@v31
   with:
 nix_path: nixpkgs=channel:nixos-unstable
 - uses: purcell/setup-emacs@master



[elpa] externals/org ac9bd59994: Ensure that gnus-other-frame-object is alive before selecting

2025-03-24 Thread ELPA Syncer
branch: externals/org
commit ac9bd59994aca656961dd81a4499885b8a52dc80
Author: Björn Bidar 
Commit: Ihor Radchenko 

Ensure that gnus-other-frame-object is alive before selecting

* lisp/ol-gnus.el (org-gnus-follow-link): Ensure that
`gnus-other-frame-object' is active before selecting it.
Error out in case frame-object is dead, i.e. wasn't activated
by `org-link-frame-setup-function'.
(org-gnus-no-new-news): Take `gnus-other-frame-object' into account.
Call `gnus-other-frame' with chosen action.
Ensures that previous behavior of `org-gnus-follow-link' is kept.
(org-gnus-no-new-news-other-frame): New function for users who choose
to call `gnus-other-frame' regardless if previous used or not.
* lisp/ol.el (org-link-frame-setup): Include new
`org-gnus-no-news-other-frame` function.

Link: https://list.orgmode.org/orgmode/874j1tvzpk.fsf@/

TINYCHANGE
---
 etc/ORG-NEWS|  6 ++
 lisp/ol-gnus.el | 30 --
 lisp/ol.el  |  5 -
 3 files changed, 34 insertions(+), 7 deletions(-)

diff --git a/etc/ORG-NEWS b/etc/ORG-NEWS
index 332586f4f3..05280f3de5 100644
--- a/etc/ORG-NEWS
+++ b/etc/ORG-NEWS
@@ -324,6 +324,12 @@ properties.
 
 # This also includes changes in function behavior from Elisp perspective.
 
+*** New function ~org-gnus-no-new-news-other-frame~ (to be used in 
~org-link-frame-setup~)
+
+The new function is like ~org-gnus-no-new-news~, but always opens the
+link in other frame.
+
+
 *** New command ~org-link-preview~ to preview Org links
 
 This command replaces ~org-toggle-inline-images~, which is now
diff --git a/lisp/ol-gnus.el b/lisp/ol-gnus.el
index 5cddc3790a..65d77ea886 100644
--- a/lisp/ol-gnus.el
+++ b/lisp/ol-gnus.el
@@ -228,7 +228,12 @@ If `org-store-link' was called with a prefix arg the 
meaning of
   "Follow a Gnus link to GROUP and ARTICLE."
   (require 'gnus)
   (funcall (org-link-frame-setup-function 'gnus))
-  (when gnus-other-frame-object (select-frame gnus-other-frame-object))
+  (when gnus-other-frame-object
+(if (not (frame-live-p gnus-other-frame-object))
+;; Error out in case org-link-frame-setup did not take care of setting 
up
+;; the gnus frame if was activate previously.
+(error "Couldn't select \'gnus-other-frame-object\', make sure it is 
active"))
+(select-frame gnus-other-frame-object))
   (let ((group (org-no-properties group))
(article (org-no-properties article)))
 (cond
@@ -260,11 +265,24 @@ If `org-store-link' was called with a prefix arg the 
meaning of
 (message "Couldn't follow Gnus link.  The linked group is empty."
  (group (gnus-group-jump-to-group group)
 
-(defun org-gnus-no-new-news ()
-  "Like `\\[gnus]' but doesn't check for new news."
-  (cond ((gnus-alive-p) nil)
-   (org-gnus-no-server (gnus-no-server))
-   (t (gnus
+(defun org-gnus-no-new-news (&optional other-frame)
+  "Like `\\[gnus]' but doesn't check for new news.
+In case of OTHER-FRAME or `gnus-other-frame-object' call `gnus-other-frame'.
+
+Ensures that `gnus-other-frame' is activated correctly if dead."
+  (let ((action (cond  (org-gnus-no-server #'gnus-no-server)
+  (t #'gnus
+(cond ((or other-frame gnus-other-frame-object)
+   (let ((gnus-other-frame-function action)
+ (gnus-other-frame-resume-function action))
+ (gnus-other-frame)))
+  (t (if (not (gnus-alive-p))
+ (funcall action))
+
+(defun org-gnus-no-new-news-other-frame ()
+  "Like `org-gnus-no-new-news' but always in another frame."
+(org-gnus-no-new-news t))
+
 
 (provide 'ol-gnus)
 
diff --git a/lisp/ol.el b/lisp/ol.el
index e5b574e479..9e46b43a5c 100644
--- a/lisp/ol.el
+++ b/lisp/ol.el
@@ -348,6 +348,7 @@ For Gnus, use any of
 `gnus'
 `gnus-other-frame'
 `org-gnus-no-new-news'
+`org-gnus-no-new-news-other-frame'
 For FILE, use any of
 `find-file'
 `find-file-other-window'
@@ -359,6 +360,7 @@ For the calendar, use the variable `calendar-setup'.
 For BBDB, it is currently only possible to display the matches in
 another window."
   :group 'org-link-follow
+  :package-version  '(Org . "9.8")
   :type '(list
  (cons (const vm)
(choice
@@ -374,7 +376,8 @@ another window."
(choice
 (const gnus)
 (const gnus-other-frame)
-(const org-gnus-no-new-news)))
+(const org-gnus-no-new-news)
+ (const org-gnus-no-new-news-other-frame)))
  (cons (const file)
(choice
 (const find-file)



[nongnu] elpa/aidermacs c9de3b24e9 1/2: Recommend add-to-list to aidermacs-extra-args

2025-03-24 Thread ELPA Syncer
branch: elpa/aidermacs
commit c9de3b24e97fa5e694c56b8df5012d7fc794823b
Author: Mingde (Matthew) Zeng 
Commit: Mingde (Matthew) Zeng 

Recommend add-to-list to aidermacs-extra-args

Signed-off-by: Mingde (Matthew) Zeng 
---
 README.md | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/README.md b/README.md
index ee5fd79197..9fe51e4d8c 100644
--- a/README.md
+++ b/README.md
@@ -375,7 +375,7 @@ See the [Aider configuration 
documentation](https://aider.chat/docs/config/optio
 
 ```emacs-lisp
 ;; Set the verbosity:
-(setq aidermacs-extra-args '("--verbose"))
+(add-to-list 'aidermacs-extra-args "--verbose")
 ```
 
 These arguments will be appended to the Aider command when it is run. Note 
that the `--model` argument is automatically handled by 
`aidermacs-default-model` and should not be included in `aidermacs-extra-args`.



[nongnu] elpa/aidermacs f4fc53e4ce 2/2: Revert "Use shell-quote-argument"

2025-03-24 Thread ELPA Syncer
branch: elpa/aidermacs
commit f4fc53e4ceef699ad2404d0970ff70bce4ce56b4
Author: Mingde (Matthew) Zeng 
Commit: Mingde (Matthew) Zeng 

Revert "Use shell-quote-argument"

This reverts commit 462c2dc6613bcf4fe4ce039a3eae7b01387000fe.

Addresses #88 as it reintroduces the bug again.

Signed-off-by: Mingde (Matthew) Zeng 
---
 aidermacs.el | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/aidermacs.el b/aidermacs.el
index 08f4168320..6b2fb98a2e 100644
--- a/aidermacs.el
+++ b/aidermacs.el
@@ -678,7 +678,7 @@ Otherwise, return FILE unchanged."
   "Prepare FILES for use with COMMAND in aider.
 Handles TRAMP paths by extracting local parts and formats the command string."
   (let* ((localized-files (mapcar #'aidermacs--localize-tramp-path (delq nil 
files)))
- (quoted-files (mapcar #'shell-quote-argument localized-files)))
+ (quoted-files (mapcar (lambda (path) (format "\"%s\"" path)) 
localized-files)))
 (if quoted-files
 (format "%s %s" command
 (mapconcat #'identity quoted-files " "))



[nongnu] elpa/aidermacs updated (9c8806258e -> f4fc53e4ce)

2025-03-24 Thread ELPA Syncer
elpasync pushed a change to branch elpa/aidermacs.

  from  9c8806258e Fix linting
   new  c9de3b24e9 Recommend add-to-list to aidermacs-extra-args
   new  f4fc53e4ce Revert "Use shell-quote-argument"


Summary of changes:
 README.md| 2 +-
 aidermacs.el | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)



[nongnu] elpa/package-lint 12c8dab578 3/5: Adjust test that covers the HEAD emacs version

2025-03-24 Thread ELPA Syncer
branch: elpa/package-lint
commit 12c8dab5789fb753e411a92e6a2de18cddf1b474
Author: Steve Purcell 
Commit: GitHub 

Adjust test that covers the HEAD emacs version
---
 package-lint-test.el | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/package-lint-test.el b/package-lint-test.el
index dff9cc1eef..8bbb557b28 100644
--- a/package-lint-test.el
+++ b/package-lint-test.el
@@ -270,7 +270,7 @@ headers and provide form."
   (should
(equal
 '((6 23 warning "This makes the package uninstallable in all released 
Emacs versions."))
-(package-lint-test--run ";; Package-Requires: ((emacs \"30\"))"
+(package-lint-test--run ";; Package-Requires: ((emacs \"31\"))"
 
 (ert-deftest package-lint-test-accept-emacs-24+-dep ()
   (should (equal '() (package-lint-test--run ";; Package-Requires: ((emacs 
\"24\"))")))



[nongnu] elpa/reformatter 9a44f0df18 1/2: chore(deps): bump cachix/install-nix-action from 30 to 31

2025-03-24 Thread ELPA Syncer
branch: elpa/reformatter
commit 9a44f0df180e36b826e59a75f57fd428ec5beea7
Author: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Commit: GitHub 

chore(deps): bump cachix/install-nix-action from 30 to 31

Bumps 
[cachix/install-nix-action](https://github.com/cachix/install-nix-action) from 
30 to 31.
- [Release notes](https://github.com/cachix/install-nix-action/releases)
- [Commits](https://github.com/cachix/install-nix-action/compare/v30...v31)

---
updated-dependencies:
- dependency-name: cachix/install-nix-action
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] 
---
 .github/workflows/test.yml | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml
index 5bfb67a016..ca04d13bb4 100644
--- a/.github/workflows/test.yml
+++ b/.github/workflows/test.yml
@@ -35,7 +35,7 @@ jobs:
   - 29.1
   - snapshot
 steps:
-- uses: cachix/install-nix-action@v30
+- uses: cachix/install-nix-action@v31
   with:
 nix_path: nixpkgs=channel:nixos-unstable
 - uses: purcell/setup-emacs@master



[nongnu] elpa/reformatter 6ac08cebaf 2/2: Merge pull request #62 from purcell/dependabot/github_actions/cachix/install-nix-action-31

2025-03-24 Thread ELPA Syncer
branch: elpa/reformatter
commit 6ac08cebafb9e04b825ed22d82269ff69cc5f87f
Merge: f2cb59466b 9a44f0df18
Author: Steve Purcell 
Commit: GitHub 

Merge pull request #62 from 
purcell/dependabot/github_actions/cachix/install-nix-action-31

chore(deps): bump cachix/install-nix-action from 30 to 31
---
 .github/workflows/test.yml | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml
index 5bfb67a016..ca04d13bb4 100644
--- a/.github/workflows/test.yml
+++ b/.github/workflows/test.yml
@@ -35,7 +35,7 @@ jobs:
   - 29.1
   - snapshot
 steps:
-- uses: cachix/install-nix-action@v30
+- uses: cachix/install-nix-action@v31
   with:
 nix_path: nixpkgs=channel:nixos-unstable
 - uses: purcell/setup-emacs@master



[nongnu] elpa/racket-mode 6b9a51828a 1/2: Refresh racket-mode.texi; overlooked in commit f5098c6

2025-03-24 Thread ELPA Syncer
branch: elpa/racket-mode
commit 6b9a51828a5d08ac9ee4d96a21f6cff95f0e6a17
Author: Greg Hendershott 
Commit: Greg Hendershott 

Refresh racket-mode.texi; overlooked in commit f5098c6
---
 doc/racket-mode.texi | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/doc/racket-mode.texi b/doc/racket-mode.texi
index edad5f83a3..108515c7d8 100644
--- a/doc/racket-mode.texi
+++ b/doc/racket-mode.texi
@@ -465,7 +465,7 @@ NOTE: If you get an error message about ``contacting a 
host'' or ``downloading a
 @node Minimal Racket
 @section Minimal Racket
 
-If you have installed the minimal Racket distribution (for example by using 
the 
@uref{https://github.com/Homebrew/homebrew-core/blob/ebd95ad1db5c23b5b76a4a660b1e0b58655e/Formula/m/minimal-racket.rb,
 homebrew formula}) Racket Mode needs some additional Racket packages. A simple 
way to get all these packages is to install the @code{drracket} Racket package. 
In a command shell:
+If you have installed the minimal Racket distribution (for example by using 
the 
@uref{https://github.com/Homebrew/homebrew-core/blob/master/Formula/m/minimal-racket.rb,
 homebrew formula}) Racket Mode needs some additional Racket packages. A simple 
way to get all these packages is to install the @code{drracket} Racket package. 
In a command shell:
 
 @example
 raco pkg install --auto drracket



[nongnu] elpa/racket-mode 88d82e249e 2/2: Fix typo in doc string

2025-03-24 Thread ELPA Syncer
branch: elpa/racket-mode
commit 88d82e249e20c3ea8565297ba7ddb2eafcf0dd76
Author: Greg Hendershott 
Commit: Greg Hendershott 

Fix typo in doc string
---
 test/racket-tests.el | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/test/racket-tests.el b/test/racket-tests.el
index 4007de1dc9..d5bc1fe247 100644
--- a/test/racket-tests.el
+++ b/test/racket-tests.el
@@ -44,7 +44,7 @@ set this, as well as perhaps setting their own env var.")
 (t  10))
   "Because some of these integration tests await the result of
 asynchronous command responses from the back end, it is possible
-they might wait indefinitely. So wee impose a timeout, used
+they might wait indefinitely. So we impose a timeout, used
 primarily in `racket-tests/call-until-true'. By default, when
 running tests locally, we prefer a shorter timeout. We use a
 longer timeout in CI environments, which are likely to be slower.")



[nongnu] elpa/package-lint 2c1b0b8e5c 1/5: Bump the emacs-head-version

2025-03-24 Thread ELPA Syncer
branch: elpa/package-lint
commit 2c1b0b8e5cde5b776c95698e4d8eec256ee2c2fd
Author: Bozhidar Batsov 
Commit: GitHub 

Bump the emacs-head-version

Emacs 30 was release last month, so now the head version is 31.
---
 package-lint.el | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/package-lint.el b/package-lint.el
index 980a9e7e0b..7c8062fc7c 100644
--- a/package-lint.el
+++ b/package-lint.el
@@ -86,7 +86,7 @@ The path can be absolute or relative to that of the linted 
file.")
   "List of errors and warnings for the current buffer.
 This is bound dynamically while the checks run.")
 
-(defconst package-lint-emacs-head-version '(30)
+(defconst package-lint-emacs-head-version '(31)
   "Version of Emacs HEAD.")
 
 (defconst package-lint-backport-libraries



[elpa] externals/minuet 4ed8a466d5 29/97: README: Small indentation fix to match removal of `general-use-key`

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit 4ed8a466d5b19fc1902bb5e5dee33218ced87c1e
Author: Mike Olson 
Commit: Mike Olson 

README: Small indentation fix to match removal of `general-use-key`
---
 README.md | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/README.md b/README.md
index 54bbe9ec5b..8332798902 100644
--- a/README.md
+++ b/README.md
@@ -76,9 +76,9 @@ Currently you need to install from github via `package-vc` or
("M-e" . #'minuet-dismiss-suggestion))
 
 :init
- ;; if you want to enable auto suggestion.
- ;; Note that you can manually invoke completions without enable 
minuet-auto-suggestion-mode
- (add-hook 'prog-mode-hook #'minuet-auto-suggestion-mode)
+;; if you want to enable auto suggestion.
+;; Note that you can manually invoke completions without enable 
minuet-auto-suggestion-mode
+(add-hook 'prog-mode-hook #'minuet-auto-suggestion-mode)
 
 :config
 (setq minuet-provider 'openai-fim-compatible)



[nongnu] elpa/dracula-theme 370ebc75f5 1/2: fix dracula-height-title documentation

2025-03-24 Thread ELPA Syncer
branch: elpa/dracula-theme
commit 370ebc75f5c6c5bda1468206195ab2caa932507f
Author: Grzegorz Kwacz 
Commit: Grzegorz Kwacz 

fix dracula-height-title documentation
---
 dracula-theme.el | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/dracula-theme.el b/dracula-theme.el
index fdc64b9d96..78b9033cbd 100644
--- a/dracula-theme.el
+++ b/dracula-theme.el
@@ -126,7 +126,7 @@ The theme has to be reloaded after changing anything in 
this group."
   :group 'dracula)
 
 (defcustom dracula-height-title-1 1.3
-  "Font size 100%."
+  "Font size 130%."
   :type 'number
   :group 'dracula)
 
@@ -136,7 +136,7 @@ The theme has to be reloaded after changing anything in 
this group."
   :group 'dracula)
 
 (defcustom dracula-height-title-3 1.0
-  "Font size 130%."
+  "Font size 100%."
   :type 'number
   :group 'dracula)
 



[nongnu] elpa/haskell-mode 0c9454a59a 1/2: chore(deps): bump cachix/install-nix-action from 30 to 31

2025-03-24 Thread ELPA Syncer
branch: elpa/haskell-mode
commit 0c9454a59aa80ba11d842760404eefbf55a7cc2d
Author: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Commit: GitHub 

chore(deps): bump cachix/install-nix-action from 30 to 31

Bumps 
[cachix/install-nix-action](https://github.com/cachix/install-nix-action) from 
30 to 31.
- [Release notes](https://github.com/cachix/install-nix-action/releases)
- [Commits](https://github.com/cachix/install-nix-action/compare/v30...v31)

---
updated-dependencies:
- dependency-name: cachix/install-nix-action
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] 
---
 .github/workflows/test.yml | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml
index 6a76eec55a..7517b4ad9f 100644
--- a/.github/workflows/test.yml
+++ b/.github/workflows/test.yml
@@ -29,7 +29,7 @@ jobs:
   - emacs_version: 29.4
 target: deploy-manual
 steps:
-- uses: cachix/install-nix-action@v30
+- uses: cachix/install-nix-action@v31
   with:
 nix_path: nixpkgs=channel:nixos-unstable
 - uses: purcell/setup-emacs@master



[elpa] externals/minuet 7943be7458 88/97: doc: note that emacs requires native json support.

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit 7943be74589c7404de4b16c84d7e1c3f61235b3a
Author: Milan Glacier 
Commit: Milan Glacier 

doc: note that emacs requires native json support.
---
 README.md | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/README.md b/README.md
index d349d97cba..8b1299261d 100644
--- a/README.md
+++ b/README.md
@@ -49,7 +49,7 @@ Just as dancers move during a minuet.
 
 # Requirements
 
-- emacs 29+
+- emacs 29+ compiled with native JSON support (verify with `json-available-p`).
 - plz 0.9+
 - dash
 - An API key for at least one of the supported AI providers



[nongnu] elpa/dirvish updated (1d8de07f4e -> 573d90a34f)

2025-03-24 Thread ELPA Syncer
elpasync pushed a change to branch elpa/dirvish.

  from  1d8de07f4e fix(core): subdir navigation (#323)
   new  91f6df1131 fix: regression introduced in 4c78097
   new  573d90a34f refactor: add throttle/debounce system


Summary of changes:
 dirvish-extras.el|  4 +--
 dirvish-widgets.el   |  2 +-
 dirvish.el   | 78 +++-
 docs/CUSTOMIZING.org |  2 +-
 extensions/dirvish-fd.el | 61 ++
 extensions/dirvish-narrow.el | 26 ---
 extensions/dirvish-peek.el   | 11 +++
 extensions/dirvish-side.el   |  9 +++--
 8 files changed, 91 insertions(+), 102 deletions(-)



[nongnu] elpa/dirvish 573d90a34f 2/2: refactor: add throttle/debounce system

2025-03-24 Thread ELPA Syncer
branch: elpa/dirvish
commit 573d90a34f3b779c0fa6b460a3bfb77f7993a31f
Author: Alex Lu 
Commit: Alex Lu 

refactor: add throttle/debounce system

Dirvish employed a basic but functional "run with delay" mechanism, 
suitable for
many common tasks. However, its reliance on `run-with-idle-timer` has led to
occasional issues over time. Furthermore, the auto-caching feature demands a
more advanced throttling and debouncing system.

Ref: #216
Ref: #218 
(https://github.com/alexluigit/dirvish/issues/218#issuecomment-2692829019)
---
 dirvish-extras.el|  4 +--
 dirvish-widgets.el   |  2 +-
 dirvish.el   | 77 +++-
 docs/CUSTOMIZING.org |  2 +-
 extensions/dirvish-fd.el | 61 ++-
 extensions/dirvish-narrow.el | 26 ---
 extensions/dirvish-peek.el   | 11 +++
 extensions/dirvish-side.el   |  9 +++---
 8 files changed, 90 insertions(+), 102 deletions(-)

diff --git a/dirvish-extras.el b/dirvish-extras.el
index d92af1b7cc..4a8bcad303 100644
--- a/dirvish-extras.el
+++ b/dirvish-extras.el
@@ -131,8 +131,8 @@ predicate for that infix."
  ["Switch layouts:"
   :if (lambda () (dv-curr-layout (dirvish-curr))) ,@layouts]
  ["Actions:"
-  ("M-t" "Toggle fullscreen" dirvish-layout-toggle)
-  ("RET" "Apply current settings to future sessions"
+  ("f" "Toggle fullscreen" dirvish-layout-toggle)
+  ("a" "Apply current settings to future sessions"
(lambda () (interactive)
  (let* ((dv (dirvish-curr)) (tp (dv-type dv)) (dft (eq tp 
'default))
 (attr-sym (or (and dft 'dirvish-attributes)
diff --git a/dirvish-widgets.el b/dirvish-widgets.el
index 6b5e80d26e..1e112f107f 100644
--- a/dirvish-widgets.el
+++ b/dirvish-widgets.el
@@ -269,7 +269,7 @@ EXT is a suffix such as \".jpg\" that is attached to FILE's 
md5 hash."
   (when-let* ((dv (dirvish-curr))
   (path (dirvish-prop :index)))
 (and (equal path (process-get proc 'path))
- (dirvish-debounce nil (dirvish--preview-update dv path)
+ (dirvish--preview-update dv path
 
 (defun dirvish-media--group-heading (group-titles)
   "Format media group heading in Dirvish preview buffer.
diff --git a/dirvish.el b/dirvish.el
index d850f62cd3..9bdee60bd4 100644
--- a/dirvish.el
+++ b/dirvish.el
@@ -230,11 +230,22 @@ The valid values are:
  (const :tag "only keep index after open a 
file" open)
  (const :tag "never keep any index buffer" 
nil)))
 
-(defcustom dirvish-redisplay-debounce 0.02
-  "Input debounce for dirvish UI redisplay.
-The UI of dirvish is refreshed only when there has not been new
-input for `dirvish-redisplay-debounce' seconds."
-  :group 'dirvish :type 'float)
+(defcustom dirvish-input-throttle 0.25
+  "Input THROTTLE for commands run repeatedly within a short period of time.
+The preview window and any associated asynchronous processes for the
+file under the cursor are updated and started only every THROTTLE
+seconds.  This also applies root window's refreshing for synchronous
+filtering commands like ``dirvish-narrow'`."
+  :group 'dirvish :type '(float :tag "Delay in seconds"))
+
+(define-obsolete-variable-alias 'dirvish-redisplay-debounce 
'dirvish-input-debounce "Mar 25, 2025")
+(defcustom dirvish-input-debounce 0.02
+  "Input DEBOUNCE for commands run repeatedly within a short period of time.
+The preview window and any associated asynchronous processes for the
+file under the cursor are updated and started only when there has not
+been new input for DEBOUNCE seconds.  This also applies to root window's
+refreshing for synchronous filtering commands like `dirvish-narrow'."
+  :group 'dirvish :type '(float :tag "Delay in seconds"))
 
 (cl-defgeneric dirvish-clean-cache () "Clean cache for selected files." nil)
 (cl-defgeneric dirvish-build-cache () "Build cache for current directory." nil)
@@ -302,7 +313,7 @@ opening and customized handling of specific file types."
 (dirvish-collapse collapse)
 (dirvish-subtree  subtree-state)
 (dirvish-yank yank)))
-(defvar dirvish-redisplay-debounce-timer nil)
+(defvar dirvish--delay-timer `(,(timer-create) ,(float-time) nil))
 (defvar dirvish--history nil)
 (defvar dirvish--reset-keywords '(:free-space :content-begin))
 (defvar dirvish--selected-window nil)
@@ -324,18 +335,25 @@ Set the PROP with BODY if given."
 (push (cons ,prop val) dirvish--props)))
 `val)))
 
-(defmacro dirvish-debounce (label &rest body)
-  "Debouncing the execution of BODY under LABEL.
-The BODY runs only when there has not been new input for DEBOUNCE
-seconds.  DEBOUNCE defaults to `dirvish-redisplay-debounce'."
+(defun dirvish-run-with-delay (action fun &optional debounce throttle record)
+  "DV ACTION FUN DEBOUNCE THROTTLE RECORD."
   (declare (indent def

[nongnu] elpa/dirvish 91f6df1131 1/2: fix: regression introduced in 4c78097

2025-03-24 Thread ELPA Syncer
branch: elpa/dirvish
commit 91f6df113191fa7ae2c647ba11c16a5b58fe0bf7
Author: Alex Lu 
Commit: Alex Lu 

fix: regression introduced in 4c78097

Use dedicated window for mode-line/header-line.
---
 dirvish.el | 1 +
 1 file changed, 1 insertion(+)

diff --git a/dirvish.el b/dirvish.el
index ba5fb2a075..d850f62cd3 100644
--- a/dirvish.el
+++ b/dirvish.el
@@ -1380,6 +1380,7 @@ Dirvish sets `revert-buffer-function' to this function."
   ('preview (setf (dv-preview-window dv) win))
   ('header (when (and gui? (> hh lh)) (fit-window-to-buffer win 2 1)))
   ('footer (when (and gui? (> mh lh)) (fit-window-to-buffer win 2 1
+(unless (eq pane 'preview) (set-window-dedicated-p win t))
 (set-window-buffer win buf)))
 (dirvish--create-parent-windows dv)
 (unless (dirvish-prop :cached)



[nongnu] elpa/helm ffa0778ca4 2/6: Remove unused keymap

2025-03-24 Thread ELPA Syncer
branch: elpa/helm
commit ffa0778ca44b3849ee4f0772727457344350fb50
Author: Thierry Volpiatto 
Commit: Thierry Volpiatto 

Remove unused keymap
---
 helm-files.el | 18 --
 1 file changed, 18 deletions(-)

diff --git a/helm-files.el b/helm-files.el
index 25bc7ee9c3..99a0d28b36 100644
--- a/helm-files.el
+++ b/helm-files.el
@@ -266,24 +266,6 @@ Should not be used among other sources.")
 map)
   "Keymap for `helm-find-files'.")
 
-(defvar helm-find-files-dummy-map
-  (let ((map (make-sparse-keymap)))
-(set-keymap-parent map helm-map)
-(define-key map (kbd "M-T")   'helm-ff-run-touch-files)
-(define-key map (kbd "C-c r") 'helm-ff-run-find-file-as-root)
-(define-key map (kbd "C-l")   'helm-find-files-up-one-level)
-(define-key map (kbd "C-_")   'helm-ff-undo)
-(define-key map (kbd "C-r")   'helm-find-files-down-last-level)
-(define-key map (kbd "C-") 'helm-ff-run-toggle-auto-update)
-(define-key map (kbd "C-c ") 'helm-ff-run-toggle-auto-update)
-(helm-define-key-with-subkeys map (kbd "DEL") ?\d 
'helm-ff-delete-char-backward
-  '((C-backspace . 
helm-ff-run-toggle-auto-update)
-([C-c DEL] . 
helm-ff-run-toggle-auto-update))
-  nil 'helm-ff-delete-char-backward--exit-fn)
-map)
-  "The map used for `helm-find-files-dummy-source'.
-It is the source handling new file or directory in `helm-find-files'.")
-
 (defvar helm-read-file-map
   (let ((map (make-sparse-keymap)))
 (set-keymap-parent map helm-map)



[elpa] externals/ellama 5f77d4bb43 3/9: Remove redundant group parameter from definitions

2025-03-24 Thread ELPA Syncer
branch: externals/ellama
commit 5f77d4bb434f6c5b29ace25b37ad89e1af5960f1
Author: Sergey Kostyaev 
Commit: Sergey Kostyaev 

Remove redundant group parameter from definitions

Removed redundant group parameter from all defcustom definitions in 
ellama.el
---
 ellama.el | 81 +++
 1 file changed, 8 insertions(+), 73 deletions(-)

diff --git a/ellama.el b/ellama.el
index a4ab6b6def..2699d7bc04 100644
--- a/ellama.el
+++ b/ellama.el
@@ -47,74 +47,60 @@
 
 (defcustom ellama-user-nick "User"
   "User nick in logs."
-  :group 'ellama
   :type 'string)
 
 (defcustom ellama-assistant-nick "Ellama"
   "Assistant nick in logs."
-  :group 'ellama
   :type 'string)
 
 (defcustom ellama-nick-prefix-depth 2
   "Prefix depth."
-  :group 'ellama
   :type 'integer)
 
 (defcustom ellama-language "English"
   "Language for ellama translation."
-  :group 'ellama
   :type 'string)
 
 (defcustom ellama-provider nil
   "Backend LLM provider."
-  :group 'ellama
   :type '(sexp :validate llm-standard-provider-p))
 
 (defcustom ellama-session-remove-reasoning t
   "Remove internal reasoning from the session after ellama provide an answer.
 This can improve long-term communication with reasoning models."
-  :group 'ellama
   :type 'boolean)
 
 (defcustom ellama-output-remove-reasoning t
   "Remove internal reasoning from ellama output.
 Make reasoning models more useful for many cases."
-  :group 'ellama
   :type 'boolean)
 
 (defcustom ellama-session-hide-org-quotes t
   "Hide org quotes in ellama session buffer."
-  :group 'ellama
   :type 'boolean)
 
 (defcustom ellama-chat-translation-enabled nil
   "Enable chat translations."
-  :group 'ellama
   :type 'boolean)
 
 (defcustom ellama-translation-provider nil
   "LLM provider for chat translation."
-  :group 'ellama
   :type '(sexp :validate llm-standard-provider-p))
 
 (defcustom ellama-summarization-provider nil
   "LLM provider for summarization."
-  :group 'ellama
   :type '(sexp :validate llm-standard-provider-p))
 
 (defcustom ellama-coding-provider nil
   "LLM provider for coding tasks."
-  :group 'ellama
   :type '(sexp :validate llm-standard-provider-p))
 
 (defcustom ellama-completion-provider nil
   "LLM provider for completions."
-  :group 'ellama
   :type '(sexp :validate llm-standard-provider-p))
 
 (defcustom ellama-providers nil
   "LLM provider list for fast switching."
-  :group 'ellama
   :type '(alist :key-type string
:value-type (sexp :validate llm-standard-provider-p)))
 
@@ -122,7 +108,6 @@ Make reasoning models more useful for many cases."
 
 (defcustom ellama-spinner-type 'progress-bar
   "Spinner type for ellama."
-  :group 'ellama
   :type `(choice ,@(if (boundp 'spinner-types)
   (mapcar
(lambda (type)
@@ -132,7 +117,6 @@ Make reasoning models more useful for many cases."
 
 (defcustom ellama-spinner-enabled nil
   "Enable spinner during text generation."
-  :group 'ellama
   :type 'boolean)
 
 (defcustom ellama-command-map
@@ -188,7 +172,6 @@ Make reasoning models more useful for many cases."
 (define-key map (kbd "p s") 'ellama-provider-select)
 map)
   "Keymap for ellama commands."
-  :group 'ellama
   :type 'keymap)
 
 (defun ellama-setup-keymap ()
@@ -207,22 +190,18 @@ Make reasoning models more useful for many cases."
   :set (lambda (symbol value)
 (custom-set-default symbol value)
 (when value
-  (ellama-setup-keymap)))
-  :group 'ellama)
+  (ellama-setup-keymap
 
 (defcustom ellama-ollama-binary "ollama"
   "Path to ollama binary."
-  :type 'string
-  :group 'ellama)
+  :type 'string)
 
 (defcustom ellama-auto-scroll nil
   "If enabled ellama buffer will scroll automatically during generation."
-  :type 'boolean
-  :group 'ellama)
+  :type 'boolean)
 
 (defcustom ellama-fill-paragraphs '(text-mode)
   "When to wrap paragraphs."
-  :group 'ellama
   :type `(choice
   (const :tag "Never fill paragraphs" nil)
   (const :tag "Always fill paragraphs" t)
@@ -231,7 +210,6 @@ Make reasoning models more useful for many cases."
 
 (defcustom ellama-name-prompt-words-count 5
   "Count of words in prompt to generate name."
-  :group 'ellama
   :type 'integer)
 
 (defcustom ellama-naming-scheme 'ellama-generate-name-by-words
@@ -244,7 +222,6 @@ PROVIDER is an llm provider.
 ACTION is a symbol, current command.
 
 PROMPT is a prompt string."
-  :group 'ellama
   :type `(choice
   (const :tag "By first N words of prompt" 
ellama-generate-name-by-words)
   (const :tag "By current time" ellama-generate-name-by-time)
@@ -254,7 +231,6 @@ PROMPT is a prompt string."
 
 (defcustom ellama-define-word-prompt-template "Define %s"
   "Prompt template for `ellama-define-word'."
-  :group 'ellama
   :type 'string)
 
 (defcustom ellama-summarize-prompt-template "# GOAL
@@ -275,17 +251,14 @@ says. Focus on clarity and maintain a straightforward 
presentation.
 3. NO NEW

[elpa] externals/ellama eb8584e610 6/9: Bump version

2025-03-24 Thread ELPA Syncer
branch: externals/ellama
commit eb8584e610c520697063355941cd1f22a5814263
Author: Sergey Kostyaev 
Commit: Sergey Kostyaev 

Bump version
---
 NEWS.org  | 12 
 ellama.el |  2 +-
 2 files changed, 13 insertions(+), 1 deletion(-)

diff --git a/NEWS.org b/NEWS.org
index c6ba6cd5ce..7974f28d1c 100644
--- a/NEWS.org
+++ b/NEWS.org
@@ -1,3 +1,15 @@
+* Version 1.6.2
+- Fix marker handling in block processing to correctly handle block boundaries
+  during text processing and updated tests to include inline code translation
+  from Markdown to Org.
+- Improve text processing in ~ellama.el~ by adding markers for beginning and 
end
+  of the text range to handle text transformation more accurately. Updated
+  paragraph filling logic to avoid unwanted behavior in ~org-mode~.
+- Remove redundant group parameter from all defcustom definitions in ellama.el.
+- Refactor session line update functions by removing redundant show and hide
+  functions for header and mode lines, simplifying the update functions using a
+  let-bound element variable.
+- Removed hooks from ellama minor modes.
 * Version 1.6.1
 - Added functionality to display the current Ellama session ID in both the
   header line and the mode line.
diff --git a/ellama.el b/ellama.el
index c58834e3ed..10ecda5aa0 100644
--- a/ellama.el
+++ b/ellama.el
@@ -6,7 +6,7 @@
 ;; URL: http://github.com/s-kostyaev/ellama
 ;; Keywords: help local tools
 ;; Package-Requires: ((emacs "28.1") (llm "0.24.0") (plz "0.8") (transient 
"0.7") (compat "29.1"))
-;; Version: 1.6.1
+;; Version: 1.6.2
 ;; SPDX-License-Identifier: GPL-3.0-or-later
 ;; Created: 8th Oct 2023
 



[elpa] externals/ellama b8e7468f1c 4/9: Refactor session line update functions

2025-03-24 Thread ELPA Syncer
branch: externals/ellama
commit b8e7468f1cdd7d8fbdf31729f6cf239a77ed8fa6
Author: Sergey Kostyaev 
Commit: Sergey Kostyaev 

Refactor session line update functions

Refactored ellama.el to remove redundant show and hide functions for header 
and
mode lines. Simplified the update functions by using a let-bound element
variable and conditionally adding or removing it from the respective line 
format
lists.
---
 ellama.el | 34 ++
 1 file changed, 10 insertions(+), 24 deletions(-)

diff --git a/ellama.el b/ellama.el
index 2699d7bc04..9b50ed8c22 100644
--- a/ellama.el
+++ b/ellama.el
@@ -671,20 +671,13 @@ This filter contains only subset of markdown syntax to be 
good enough."
ellama--current-session-id))
  'face 'ellama-face))
 
-(defun ellama-session-show-header-line ()
-  "Display session id in the header line."
-  (when (listp header-line-format)
-(add-to-list 'header-line-format '(:eval (ellama-session-line)) t)))
-
-(defun ellama-session-hide-header-line ()
-  "Hide session id from header line."
-  (setq header-line-format (delete '(:eval (ellama-session-line)) 
header-line-format)))
-
 (defun ellama-session-update-header-line ()
   "Update header line for ellama session header line mode."
-  (if ellama-session-header-line-mode
-  (ellama-session-show-header-line)
-(ellama-session-hide-header-line)))
+  (when (listp header-line-format)
+(let ((element '(:eval (ellama-session-line
+  (if ellama-session-header-line-mode
+  (add-to-list 'header-line-format element t)
+   (setq header-line-format (delete element header-line-format))
 
 ;;;###autoload
 (define-minor-mode ellama-session-header-line-mode
@@ -697,20 +690,13 @@ This filter contains only subset of markdown syntax to be 
good enough."
   ellama-session-header-line-mode
   ellama-session-header-line-mode)
 
-(defun ellama-session-show-mode-line ()
-  "Display session id in the mode line."
-  (when (listp mode-line-format)
-(add-to-list 'mode-line-format '(:eval (ellama-session-line)) t)))
-
-(defun ellama-session-hide-mode-line ()
-  "Hide session id from mode line."
-  (setq mode-line-format (delete '(:eval (ellama-session-line)) 
mode-line-format)))
-
 (defun ellama-session-update-mode-line ()
   "Update mode line for ellama session mode line mode."
-  (if ellama-session-mode-line-mode
-  (ellama-session-show-mode-line)
-(ellama-session-hide-mode-line)))
+  (when (listp mode-line-format)
+(let ((element '(:eval (ellama-session-line
+  (if ellama-session-mode-line-mode
+ (add-to-list 'mode-line-format element t)
+   (setq mode-line-format (delete element mode-line-format))
 
 ;;;###autoload
 (define-minor-mode ellama-session-mode-line-mode



[elpa] externals/ellama 6c1fe02ff5 5/9: Remove hooks from ellama minor modes

2025-03-24 Thread ELPA Syncer
branch: externals/ellama
commit 6c1fe02ff51c88f2ffc9e41a4881f5b109118523
Author: Sergey Kostyaev 
Commit: Sergey Kostyaev 

Remove hooks from ellama minor modes

Removed the window-state-change-hook from both 
ellama-session-header-line-mode
and ellama-session-mode-line-mode. Changed their :lighter attribute to an 
empty
string.
---
 ellama.el | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/ellama.el b/ellama.el
index 9b50ed8c22..c58834e3ed 100644
--- a/ellama.el
+++ b/ellama.el
@@ -682,7 +682,7 @@ This filter contains only subset of markdown syntax to be 
good enough."
 ;;;###autoload
 (define-minor-mode ellama-session-header-line-mode
   "Toggle Ellama Session header line mode."
-  (add-hook 'window-state-change-hook #'ellama-session-update-header-line)
+  :lighter ""
   (ellama-session-update-header-line))
 
 ;;;###autoload
@@ -701,7 +701,7 @@ This filter contains only subset of markdown syntax to be 
good enough."
 ;;;###autoload
 (define-minor-mode ellama-session-mode-line-mode
   "Toggle Ellama Session mode line mode."
-  (add-hook 'window-state-change-hook #'ellama-session-update-mode-line)
+  :lighter ""
   (ellama-session-update-mode-line))
 
 ;;;###autoload



[nongnu] elpa/gptel e6cd2374c5 1/2: gptel-gemini: Check for Curl before streaming

2025-03-24 Thread ELPA Syncer
branch: elpa/gptel
commit e6cd2374c5c15c28506ab3c6c9f0b3198571e690
Author: Karthik Chikmagalur 
Commit: Karthik Chikmagalur 

gptel-gemini: Check for Curl before streaming

* gptel-gemini.el (gptel-make-gemini): Only request streaming
responses in the HTTP request header when all three conditions are
met: the backend specifies :stream, and both `gptel-stream' and
`gptel-use-curl' are non-nil. (#729)
---
 gptel-gemini.el | 8 
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/gptel-gemini.el b/gptel-gemini.el
index aa75c82f37..0d34ff0427 100644
--- a/gptel-gemini.el
+++ b/gptel-gemini.el
@@ -501,10 +501,10 @@ for."
   :request-params request-params
   :key key
   :url (lambda ()
- (let ((method (if (and stream
-gptel-stream)
-   "streamGenerateContent"
- "generateContent")))
+ (let ((method
+(if (and stream gptel-use-curl gptel-stream)
+"streamGenerateContent"
+  "generateContent")))
(format "%s://%s%s/%s:%s?key=%s"
protocol
host



[elpa] externals/denote d931f37ff8 1/2: Respect encryption-file-extensions in get-path-by-id

2025-03-24 Thread ELPA Syncer
branch: externals/denote
commit d931f37ff8c789ad2df20322311de03da3c25d21
Author: eum3l 
Commit: eum3l 

Respect encryption-file-extensions in get-path-by-id
---
 denote.el | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/denote.el b/denote.el
index 6cf052d23a..ca4a1b8e7b 100644
--- a/denote.el
+++ b/denote.el
@@ -1395,7 +1395,7 @@ something like .org even if the actual file extension is
 (car files)
   (seq-find
(lambda (file)
- (let ((file-extension (denote-get-file-extension file)))
+ (let ((file-extension (denote-get-file-extension-sans-encryption 
file)))
(and (denote-file-has-supported-extension-p file)
 (or (string= (denote--file-extension denote-file-type)
  file-extension)



[elpa] externals/denote 24b95a62d2 2/2: Merge pull request #562 from eum3l/fix-link-collisions

2025-03-24 Thread ELPA Syncer
branch: externals/denote
commit 24b95a62d290a2558bf084bfe5f0a1fe8484a549
Merge: e41fd8ebc7 d931f37ff8
Author: Protesilaos Stavrou 
Commit: GitHub 

Merge pull request #562 from eum3l/fix-link-collisions

Respect encryption-file-extensions in get-path-by-id
---
 denote.el | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/denote.el b/denote.el
index 6cf052d23a..ca4a1b8e7b 100644
--- a/denote.el
+++ b/denote.el
@@ -1395,7 +1395,7 @@ something like .org even if the actual file extension is
 (car files)
   (seq-find
(lambda (file)
- (let ((file-extension (denote-get-file-extension file)))
+ (let ((file-extension (denote-get-file-extension-sans-encryption 
file)))
(and (denote-file-has-supported-extension-p file)
 (or (string= (denote--file-extension denote-file-type)
  file-extension)



[nongnu] elpa/dracula-theme 793591c3d6 2/2: Merge pull request #110 from greg19/numbers

2025-03-24 Thread ELPA Syncer
branch: elpa/dracula-theme
commit 793591c3d6749ff5f254aabd9b49a8e32fdd5943
Merge: a3508f702f 370ebc75f5
Author: Étienne Pflieger 
Commit: GitHub 

Merge pull request #110 from greg19/numbers

Fix dracula-height-title documentation
---
 dracula-theme.el | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/dracula-theme.el b/dracula-theme.el
index fdc64b9d96..78b9033cbd 100644
--- a/dracula-theme.el
+++ b/dracula-theme.el
@@ -126,7 +126,7 @@ The theme has to be reloaded after changing anything in 
this group."
   :group 'dracula)
 
 (defcustom dracula-height-title-1 1.3
-  "Font size 100%."
+  "Font size 130%."
   :type 'number
   :group 'dracula)
 
@@ -136,7 +136,7 @@ The theme has to be reloaded after changing anything in 
this group."
   :group 'dracula)
 
 (defcustom dracula-height-title-3 1.0
-  "Font size 130%."
+  "Font size 100%."
   :type 'number
   :group 'dracula)
 



[nongnu] elpa/helm 8b9639d29a 1/6: Add :action-transformer to helm-find-files-dummy-source

2025-03-24 Thread ELPA Syncer
branch: elpa/helm
commit 8b9639d29a1af0b3211df8f497c63af3e2be7b51
Author: Thierry Volpiatto 
Commit: Thierry Volpiatto 

Add :action-transformer to helm-find-files-dummy-source
---
 helm-files.el | 22 +-
 1 file changed, 21 insertions(+), 1 deletion(-)

diff --git a/helm-files.el b/helm-files.el
index 86ad78c75a..25bc7ee9c3 100644
--- a/helm-files.el
+++ b/helm-files.el
@@ -5594,7 +5594,27 @@ Use it for non-interactive calls of `helm-find-files'."
 (list (helm-ff-filter-candidate-one-by-one helm-pattern nil t
 :all-marked t
 :keymap 'helm-find-files-map
-:action 'helm-find-files-actions))
+:action 'helm-find-files-actions
+:action-transformer 'helm-find-files-dummy-action-transformer))
+
+(defun helm-find-files-dummy-action-transformer (actions candidate)
+  "Action transformer for `helm-find-files-dummy-source'."
+  (let (cand-no-linum linum)
+(cond ((and helm--url-regexp
+(not (string-match-p helm--url-regexp candidate))
+(string-match "\\(:[[:digit:]]+:?\\)\\'" candidate)
+(file-exists-p
+ (setq cand-no-linum (replace-match "" t t candidate 1
+   (setq linum (replace-regexp-in-string
+":" "" (match-string 1 candidate)))
+   (helm-append-at-nth
+actions
+`(("Find file to line number"
+   . (lambda (_candidate)
+   (find-file ,cand-no-linum)
+   (helm-goto-line (string-to-number ,linum) t
+1))
+  (t actions
 
 (defun helm-ff--update-resume-after-hook (sources &optional nohook)
   "Meant to be used in `helm-resume-after-hook'.



[nongnu] elpa/magit 18d649cf50 1/5: magit-status-show-untracked-files: Fix custom type

2025-03-24 Thread Jonas Bernoulli via
branch: elpa/magit
commit 18d649cf5041809f24352dcae9b75efae5d44d9c
Author: Jonas Bernoulli 
Commit: Jonas Bernoulli 

magit-status-show-untracked-files: Fix custom type
---
 lisp/magit-status.el | 6 --
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/lisp/magit-status.el b/lisp/magit-status.el
index 984e907d6e..f827de948d 100644
--- a/lisp/magit-status.el
+++ b/lisp/magit-status.el
@@ -174,8 +174,10 @@ of the work Git is responsible for.  Turning that list 
into sections is
 also not free, so Magit only lists `magit-status-file-list-limit' files."
   :package-version '(magit . "4.3.0")
   :group 'magit-status
-  :type 'boolean
-  :safe 'booleanp)
+  :type '(choice (const :tag "Do not list untracked files" nil)
+ (const :tag "List mixture of files and directories" t)
+ (const :tag "List individual files (slow)" all))
+  :safe (##memq % '(nil t all)))
 
 (defcustom magit-status-file-list-limit 100
   "How many files to list in file list sections in the status buffer.



[nongnu] elpa/racket-mode c4c77d98ee: Use longer timeout for Debian buildd

2025-03-24 Thread ELPA Syncer
branch: elpa/racket-mode
commit c4c77d98eec27b729798462f1e83e612348eca4d
Author: Xiyue Deng 
Commit: GitHub 

Use longer timeout for Debian buildd

It turns out 900 seconds is still not long enough for some of the
slower architectures supported in Debian and some of the operations
may timeout.  Using 1800 seconds seems to be more reliable.
---
 test/racket-tests.el | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/test/racket-tests.el b/test/racket-tests.el
index 42b488ff73..4007de1dc9 100644
--- a/test/racket-tests.el
+++ b/test/racket-tests.el
@@ -39,9 +39,9 @@ By convention, most CI systems like Travis CI or GitHub 
Actions
 set this, as well as perhaps setting their own env var.")
 
 (defconst racket-tests/timeout
-  (cond (buildd-env-p 900)
-(ci-env-p  60)
-(t 10))
+  (cond (buildd-env-p 1800)
+(ci-env-p   60)
+(t  10))
   "Because some of these integration tests await the result of
 asynchronous command responses from the back end, it is possible
 they might wait indefinitely. So wee impose a timeout, used



[nongnu] elpa/helm updated (3084975808 -> 5359372ac2)

2025-03-24 Thread ELPA Syncer
elpasync pushed a change to branch elpa/helm.

  from  3084975808 Simpler version of package--dependencies broken in 
emacs-30
   new  8b9639d29a Add :action-transformer to helm-find-files-dummy-source
   new  ffa0778ca4 Remove unused keymap
   new  f32ac746d5 Add restore backup files action to hff
   new  dc649ffbb0 Add change wall paper action to HFF
   new  bfde27990d Add encrypt file action to HFF
   new  5359372ac2 Add byte compile file async action to HFF


Summary of changes:
 helm-files.el | 146 +-
 1 file changed, 124 insertions(+), 22 deletions(-)



[nongnu] elpa/helm bfde27990d 5/6: Add encrypt file action to HFF

2025-03-24 Thread ELPA Syncer
branch: elpa/helm
commit bfde27990db8deed6bc42ef21b47758da2599101
Author: Thierry Volpiatto 
Commit: Thierry Volpiatto 

Add encrypt file action to HFF
---
 helm-files.el | 25 +
 1 file changed, 25 insertions(+)

diff --git a/helm-files.el b/helm-files.el
index 8581d8dcdc..961a3043db 100644
--- a/helm-files.el
+++ b/helm-files.el
@@ -92,6 +92,9 @@
 (declare-function wfnames-setup-buffer "ext:wfnames.el")
 (declare-function svg-lib-progress-bar "ext:svg-lib")
 (declare-function svg-lib-tag "ext:svg-lib")
+(declare-function helm-epa-success-message"helm-epa")
+(declare-function helm-epa-collect-id-from-candidates "helm-epa")
+(declare-function helm-epa-collect-keys-from-candidates "helm-epa")
 
 (defvar term-char-mode-point-at-process-mark)
 (defvar term-char-mode-buffer-read-only)
@@ -839,6 +842,7 @@ want to use it, helm is still providing
   " async" "")))
'helm-ff-delete-files
"Touch File(s) `M-T'" 'helm-ff-touch-files
+   "Encrypt file(s)" 'helm-ff-encrypt-files
"Copy file(s) `M-C, C-u to follow'" 'helm-find-files-copy
(lambda ()
  (and (executable-find "rsync")
@@ -2126,6 +2130,27 @@ prefix arg shell buffer doesn't exists, create it and 
switch to it."
(length failures)
(mapconcat (lambda (f) (format "- %s\n" f)) failures "")
 
+(defun helm-ff-encrypt-files (_candidate)
+  "Encrypt marked files."
+  (require 'epg) (require 'epa) (require 'helm-epa)
+  (let* ((mkds (helm-marked-candidates :with-wildcard t))
+ (recipients (helm :sources (helm-build-sync-source
+"Select recipient for encryption: "
+  :persistent-action 'ignore
+  :candidates 'helm-epa-get-key-list
+  :action (lambda (_candidate)
+(helm-marked-candidates))
+  :must-match t)
+   :buffer "*helm-ff epg keys*"))
+ (keys (and recipients (helm-epa-collect-keys-from-candidates 
recipients)))
+ (ids  (and recipients (helm-epa-collect-id-from-candidates 
recipients
+(when recipients ; may be aborted by quit.
+  (cl-loop for f in mkds
+   do (epa-encrypt-file f recipients))
+  (helm-epa-success-message (concat (format "%s File(s) encrypted" (length 
mkds))
+" with key(s):\n %s")
+keys ids
+
 (helm-make-command-from-action helm-ff-run-touch-files
   "Used to interactively run touch file action from keyboard."
   'helm-ff-touch-files)



[nongnu] elpa/helm dc649ffbb0 4/6: Add change wall paper action to HFF

2025-03-24 Thread ELPA Syncer
branch: elpa/helm
commit dc649ffbb0afbd0b56f685bd8b65dd981a37024e
Author: Thierry Volpiatto 
Commit: Thierry Volpiatto 

Add change wall paper action to HFF
---
 helm-files.el | 12 +---
 1 file changed, 9 insertions(+), 3 deletions(-)

diff --git a/helm-files.el b/helm-files.el
index 89825d6db6..8581d8dcdc 100644
--- a/helm-files.el
+++ b/helm-files.el
@@ -4534,9 +4534,15 @@ Arg FILE is the real part of candidate, a filename with 
no props."
   ((string-match (image-file-name-regexp) candidate)
(helm-append-at-nth
 actions
-'(("Rotate image right `M-r'" . helm-ff-rotate-image-right)
-  ("Rotate image left `M-l'" . helm-ff-rotate-image-left)
-  ("Start slideshow with marked" . 
helm-ff-start-slideshow-on-marked))
+(helm-make-actions
+ "Rotate image right `M-r'" 'helm-ff-rotate-image-right
+  "Rotate image left `M-l'" 'helm-ff-rotate-image-left
+  "Start slideshow with marked" 'helm-ff-start-slideshow-on-marked
+  (lambda ()
+(and (fboundp 'image-dired-wallpaper-set)
+ (display-graphic-p)
+ "Change wall paper"))
+  'image-dired-wallpaper-set)
 3))
   ((string-match "\\.el\\'" candidate)
(helm-append-at-nth



[elpa] externals/ellama 87d7b067c5 2/9: Improve text processing in `ellama.el`

2025-03-24 Thread ELPA Syncer
branch: externals/ellama
commit 87d7b067c549d0f835ccc29b9109f1e0e50f4a1d
Author: Sergey Kostyaev 
Commit: Sergey Kostyaev 

Improve text processing in `ellama.el`

Added markers for beginning and end of the text range to handle text
transformation more accurately. Updated paragraph filling logic to avoid
unwanted behavior in `org-mode` by checking if the current position is 
within a
code block before filling paragraphs.

Fix #271
---
 ellama.el | 14 +++---
 1 file changed, 11 insertions(+), 3 deletions(-)

diff --git a/ellama.el b/ellama.el
index c850f1a212..a4ab6b6def 100644
--- a/ellama.el
+++ b/ellama.el
@@ -1283,11 +1283,14 @@ If POINT is nil, current point will be used.
 FILTER is a function for text transformation."
   (with-current-buffer
   buffer
-(let* ((end-marker (make-marker))
+(let* ((beg-marker (make-marker))
+  (end-marker (make-marker))
   (previous-filtered-text "")
   (safe-common-prefix ""))
   (set-marker end-marker (or point (point)))
+  (set-marker beg-marker end-marker)
   (set-marker-insertion-type end-marker t)
+  (set-marker-insertion-type beg-marker nil)
   (lambda
(text)
(with-current-buffer buffer
@@ -1310,14 +1313,19 @@ FILTER is a function for text transformation."
  (delete-char (- wrong-chars-cnt))
  (insert delta)
  (when (and
-(not (eq major-mode 'org-mode))
 ellama-fill-paragraphs
 (pcase ellama-fill-paragraphs
   ((cl-type function) (funcall ellama-fill-paragraphs))
   ((cl-type boolean) ellama-fill-paragraphs)
   ((cl-type list) (and (apply #'derived-mode-p
   ellama-fill-paragraphs)
-   (fill-paragraph))
+   (if (not (eq major-mode 'org-mode))
+   (fill-paragraph)
+ (when (not (save-excursion
+  (re-search-backward
+   "#\\+BEGIN_SRC"
+   beg-marker t)))
+   (org-fill-paragraph
  (set-marker end-marker (point))
  (when (and ellama-auto-scroll (not ellama--stop-scroll))
(ellama--scroll buffer end-marker))



[elpa] externals/ellama c5a5532fb3 1/9: Fix marker handling in block processing

2025-03-24 Thread ELPA Syncer
branch: externals/ellama
commit c5a5532fb34c4e024cf4ab85ac655048dfe26287
Author: Sergey Kostyaev 
Commit: Sergey Kostyaev 

Fix marker handling in block processing

Addressed issues with marker initialization and insertion types to correctly
handle block boundaries during text processing. Updated tests to include 
inline
code translation from Markdown to Org.
---
 ellama.el| 36 +++-
 tests/test-ellama.el | 14 ++
 2 files changed, 33 insertions(+), 17 deletions(-)

diff --git a/ellama.el b/ellama.el
index 8d98ea8132..c850f1a212 100644
--- a/ellama.el
+++ b/ellama.el
@@ -628,12 +628,14 @@ Skip code blocks and math environments."
   (with-temp-buffer
 (insert (propertize text 'hard t))
 (goto-char (point-min))
-(let (block-start
- block-end
+(let ((block-start (make-marker))
+ (block-end (make-marker))
  (prev-point (point-min)))
+  (set-marker-insertion-type block-start t)
+  (set-marker-insertion-type block-end t)
   ;; Process regions outside of blocks
   (while (re-search-forward "\\(#\\+BEGIN_SRC\\|\\$\\$\\|\\$\\|`\\)" nil t)
-(setq block-start (match-beginning 0))
+(set-marker block-start (match-beginning 0))
(goto-char block-start)
 (let ((block-type (cond ((looking-at "#\\+BEGIN_SRC") 'src)
 ((looking-at "\\$\\$") 'math-display)
@@ -643,20 +645,20 @@ Skip code blocks and math environments."
   (ellama--apply-transformations prev-point block-start)
   ;; Skip over the block content
   (goto-char block-start)
-  (setq block-end
-   (cond
-((eq block-type 'src)
-  (if (re-search-forward "#\\+END_SRC" nil t) (point) 
(point-max)))
-((eq block-type 'math-display)
-  (if (re-search-forward "\\$\\$.+?\\$\\$" nil t) (point) 
(point-max)))
-((eq block-type 'math-inline)
-  (if (re-search-forward "\\$.+?\\$" nil t) (point) 
(point-max)))
-((eq block-type 'code-inline)
- (if (re-search-forward "`\\(.+?\\)`" nil t)
- (progn
-   (replace-match "~\\1~")
-   (point))
-   (point-max)
+  (set-marker block-end
+ (cond
+  ((eq block-type 'src)
+   (if (re-search-forward "#\\+END_SRC" nil t) (point) 
(point-max)))
+  ((eq block-type 'math-display)
+   (if (re-search-forward "\\$\\$.+?\\$\\$" nil t) (point) 
(point-max)))
+  ((eq block-type 'math-inline)
+   (if (re-search-forward "\\$.+?\\$" nil t) (point) 
(point-max)))
+  ((eq block-type 'code-inline)
+   (if (re-search-forward "`\\([^`]+\\)`" nil t)
+   (progn
+ (replace-match "~\\1~")
+ (point))
+ (point-max)
   (when block-end
(goto-char block-end))
  (setq prev-point (point
diff --git a/tests/test-ellama.el b/tests/test-ellama.el
index ddb1a04555..29ef24ff02 100644
--- a/tests/test-ellama.el
+++ b/tests/test-ellama.el
@@ -437,6 +437,20 @@ _more italic_")))
 $P_\\theta$
 /more italic/"
 
+(ert-deftest test-ellama-md-to-org-inline-code ()
+  (let ((result (ellama--translate-markdown-to-org-filter "```go
+package main
+```
+### Explanation:
+1. **Initialization**: We create a boolean slice `prime` of size `n+1`, where 
each
+index represents whether the number is prime (`true`) or not (`false`).")))
+(should (string= result "#+BEGIN_SRC go
+package main
+#+END_SRC
+*** Explanation:
+1. *Initialization*: We create a boolean slice ~prime~ of size ~n+1~, where 
each
+index represents whether the number is prime (~true~) or not (~false~)."
+
 (defun ellama-test-max-common-prefix ()
   "Test the `ellama-max-common-prefix` function."
   (should (equal (ellama-max-common-prefix "" "") ""))



[elpa] externals/ellama 6db46052ed 7/9: Add fill-column variable to test-ellama-md-to-org-inline-code

2025-03-24 Thread ELPA Syncer
branch: externals/ellama
commit 6db46052ed5697c79ed4fedd3017ca36e92d5077
Author: Sergey Kostyaev 
Commit: Sergey Kostyaev 

Add fill-column variable to test-ellama-md-to-org-inline-code

Updated the `test-ellama-md-to-org-inline-code` test by adding a 
`fill-column`
variable set to 80. This ensures that the markdown to org translation 
respects
line width limits during testing.
---
 tests/test-ellama.el | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/tests/test-ellama.el b/tests/test-ellama.el
index 29ef24ff02..97a3389b67 100644
--- a/tests/test-ellama.el
+++ b/tests/test-ellama.el
@@ -438,7 +438,8 @@ $P_\\theta$
 /more italic/"
 
 (ert-deftest test-ellama-md-to-org-inline-code ()
-  (let ((result (ellama--translate-markdown-to-org-filter "```go
+  (let* ((fill-column 80)
+ (result (ellama--translate-markdown-to-org-filter "```go
 package main
 ```
 ### Explanation:



[elpa] externals/ellama updated (8588296419 -> a5bea6db68)

2025-03-24 Thread ELPA Syncer
elpasync pushed a change to branch externals/ellama.

  from  8588296419 Merge pull request #294 from 
s-kostyaev/add-ellama-session-line-minor-modes
   new  c5a5532fb3 Fix marker handling in block processing
   new  87d7b067c5 Improve text processing in `ellama.el`
   new  5f77d4bb43 Remove redundant group parameter from definitions
   new  b8e7468f1c Refactor session line update functions
   new  6c1fe02ff5 Remove hooks from ellama minor modes
   new  eb8584e610 Bump version
   new  6db46052ed Add fill-column variable to 
test-ellama-md-to-org-inline-code
   new  c74721144a Declare org-fill-paragraph in ellama.el
   new  a5bea6db68 Merge pull request #301 from 
s-kostyaev/fix-markdown-to-org-transformation-filter


Summary of changes:
 NEWS.org |  12 
 ellama.el| 172 ---
 tests/test-ellama.el |  15 +
 3 files changed, 79 insertions(+), 120 deletions(-)



[elpa] externals/ellama c74721144a 8/9: Declare org-fill-paragraph in ellama.el

2025-03-24 Thread ELPA Syncer
branch: externals/ellama
commit c74721144a2ce15bf5563c57bd5d6d94c994612b
Author: Sergey Kostyaev 
Commit: Sergey Kostyaev 

Declare org-fill-paragraph in ellama.el

Declared org-fill-paragraph function to fix linter warning.
---
 ellama.el | 1 +
 1 file changed, 1 insertion(+)

diff --git a/ellama.el b/ellama.el
index 10ecda5aa0..dff74191a3 100644
--- a/ellama.el
+++ b/ellama.el
@@ -1203,6 +1203,7 @@ EVENT is an argument for mweel scroll."
 Works inside BUFFER starting at POINT.
 If POINT is nil, current point will be used.
 FILTER is a function for text transformation."
+  (declare-function org-fill-paragraph "org")
   (with-current-buffer
   buffer
 (let* ((beg-marker (make-marker))



[nongnu] elpa/helm updated (5359372ac2 -> 7770b153c4)

2025-03-24 Thread ELPA Syncer
elpasync pushed a change to branch elpa/helm.

  from  5359372ac2 Add byte compile file async action to HFF
   new  ba2ecc6254 Add byte recompile directory async action to HFF
   new  dc0ed5b94e Add recover file action to HFF
   new  7770b153c4 Expand macros in lambdas one time for all at compile time


Summary of changes:
 helm-files.el | 44 +++-
 1 file changed, 27 insertions(+), 17 deletions(-)



[elpa] main 9f33fb4116: elpa-packages (minuet): Papers haven't arrived yet

2025-03-24 Thread Stefan Monnier via
branch: main
commit 9f33fb4116397f1f9415d34f922a743dc220dbec
Author: Stefan Monnier 
Commit: Stefan Monnier 

elpa-packages (minuet): Papers haven't arrived yet
---
 elpa-packages | 8 
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/elpa-packages b/elpa-packages
index 240c5b716d..4776b5e0fb 100644
--- a/elpa-packages
+++ b/elpa-packages
@@ -537,10 +537,10 @@
  (minibuffer-line  :url nil)
  (minimap  :url nil)
  ;; FIXME: Waiting for copyright paperwork.
- (minuet   :url "https://github.com/milanglacier/minuet-ai.el";
-  :ignored-files ("LICENSE")
-  :readme "README.md"
-  :news "CHANGELOG.md")
+ ;; (minuet:url "https://github.com/milanglacier/minuet-ai.el";
+ ;;  :ignored-files ("LICENSE")
+ ;;  :readme "README.md"
+ ;;  :news "CHANGELOG.md")
  (mmm-mode :url "https://github.com/dgutov/mmm-mode";
   :doc "mmm.texi")
  (modus-themes :url "https://github.com/protesilaos/modus-themes";



[nongnu] elpa/helm ba2ecc6254 1/3: Add byte recompile directory async action to HFF

2025-03-24 Thread ELPA Syncer
branch: elpa/helm
commit ba2ecc62544aa152cb49cb35408a9e82a19f6c84
Author: Thierry Volpiatto 
Commit: Thierry Volpiatto 

Add byte recompile directory async action to HFF
---
 helm-files.el | 5 +
 1 file changed, 5 insertions(+)

diff --git a/helm-files.el b/helm-files.el
index e7e4244612..e22997c6f4 100644
--- a/helm-files.el
+++ b/helm-files.el
@@ -96,6 +96,7 @@
 (declare-function helm-epa-collect-id-from-candidates "helm-epa")
 (declare-function helm-epa-collect-keys-from-candidates "helm-epa")
 (declare-function async-byte-compile-file "async-bytecomp.el")
+(declare-function async-byte-recompile-directory "async-bytecomp.el")
 
 (defvar term-char-mode-point-at-process-mark)
 (defvar term-char-mode-buffer-read-only)
@@ -4579,6 +4580,10 @@ Arg FILE is the real part of candidate, a filename with 
no props."
. (lambda (_candidate)
(cl-loop for file in (helm-marked-candidates)
 do (async-byte-compile-file file
+  ("Byte recompile directory async"
+   . (lambda (_)
+   (async-byte-recompile-directory
+helm-ff-default-directory)))
   ("Load File(s) `M-L'" . helm-find-files-load-files))
 2))
   ((string-match (concat (regexp-opt load-suffixes) "\\'") candidate)



[nongnu] elpa/gptel c5ffae2fe1: gptel-org: Fix branching context prompt creation bug

2025-03-24 Thread ELPA Syncer
branch: elpa/gptel
commit c5ffae2fe1ebfa43b157a017a7de5d60fa86eaa1
Author: Karthik Chikmagalur 
Commit: Karthik Chikmagalur 

gptel-org: Fix branching context prompt creation bug

* gptel-org.el (gptel-org--create-prompt): When using branching
context, we always want to include text from (point-min) before
the first headline, as we consider it part of the lineage of the
org element that point is in.  However, if there is a headline
at (point-min), it should only be included if it's part of the
lineage.  This distinction was lost in the recent changes to
branching context handling.  Introduce it again.

* test: Update with tests for the bug fixed in this commit.
---
 gptel-org.el | 15 +--
 test |  2 +-
 2 files changed, 10 insertions(+), 7 deletions(-)

diff --git a/gptel-org.el b/gptel-org.el
index dc4e74d855..cc05e524e5 100644
--- a/gptel-org.el
+++ b/gptel-org.el
@@ -226,12 +226,15 @@ value of `gptel-org-branching-context', which see."
   (org-element-at-point) 
#'gptel-org--element-begin
 '(headline) 'with-self) )
  ;; lineage-map returns the full lineage in the unnarrowed
- ;; buffer.  Remove heading start positions at or before
- ;; (point-min) that are invalid due to narrowing, and add
- ;; (point-min) explicitly
- (start-bounds (nconc (cl-delete-if (lambda (p) (<= p 
(point-min)))
-full-bounds)
-  (list (point-min
+ ;; buffer.  Remove heading start positions before (point-min)
+ ;; that are invalid due to narrowing, and add (point-min) if
+ ;; it's not already included in the lineage
+ (start-bounds
+  (nconc (cl-delete-if (lambda (p) (< p (point-min)))
+   full-bounds)
+ (unless (save-excursion (goto-char (point-min))
+ (looking-at-p outline-regexp))
+   (list (point-min)
  (end-bounds
   (cl-loop
;; (car start-bounds) is the begining of the current 
element,
diff --git a/test b/test
index 6efb724892..9556080bcc 16
--- a/test
+++ b/test
@@ -1 +1 @@
-Subproject commit 6efb724892b9646a7fc1622ee1217a88c69180bc
+Subproject commit 9556080bcc8dee4bfec86cf78190892dd2493c46



[nongnu] elpa/helm dc0ed5b94e 2/3: Add recover file action to HFF

2025-03-24 Thread ELPA Syncer
branch: elpa/helm
commit dc0ed5b94ecb6057260c64b118424d5683743ded
Author: Thierry Volpiatto 
Commit: Thierry Volpiatto 

Add recover file action to HFF
---
 helm-files.el | 5 +
 1 file changed, 5 insertions(+)

diff --git a/helm-files.el b/helm-files.el
index e22997c6f4..748cc8b720 100644
--- a/helm-files.el
+++ b/helm-files.el
@@ -4543,6 +4543,11 @@ Arg FILE is the real part of candidate, a filename with 
no props."
 (when (file-regular-p candidate)
   (setq actions (helm-append-at-nth
  actions '(("Checksum File" . helm-ff-checksum)) 4)))
+(when (file-exists-p (expand-file-name
+  (format "#%s#" (helm-basename candidate))
+  (helm-basedir candidate)))
+  (setq actions (helm-append-at-nth
+ actions '(("Recover file" . recover-file)) 4)))
 (cond ((and (file-exists-p candidate)
 (string-match helm-ff--trash-directory-regexp
   (helm-basedir (expand-file-name candidate)))



[elpa] externals/minuet e0fdc2023b 22/97: chore: pass checkdoc lint.

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit e0fdc2023baca7097b245c624d8825582b443c34
Author: Milan Glacier 
Commit: Milan Glacier 

chore: pass checkdoc lint.
---
 minuet.el | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/minuet.el b/minuet.el
index 179819f89d..936a2f55bb 100644
--- a/minuet.el
+++ b/minuet.el
@@ -1034,10 +1034,10 @@ When enabled, Minuet will automatically show 
suggestions while you type."
 
 (defvar minuet-active-mode-map
 (let ((map (make-sparse-keymap))) map)
-"Keymap used when minuet-active-mode is enabled.")
+"Keymap used when `minuet-active-mode' is enabled.")
 
 (define-minor-mode minuet-active-mode
-"When there is an active suggestion in minuet."
+"Activated when there is an active suggestion in minuet."
 :init-value nil
 :keymap minuet-active-mode-map)
 



[elpa] externals/minuet 135b8feaab 21/97: doc: fix typo.

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit 135b8feaab60aedeb385d86150579d66e1e5dc61
Author: Milan Glacier 
Commit: Milan Glacier 

doc: fix typo.
---
 README.md | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/README.md b/README.md
index 4c3ef90006..697066c905 100644
--- a/README.md
+++ b/README.md
@@ -66,7 +66,7 @@ Currently you need to install from github via `package-vc` or
 :init
 (general-define-key
  ;; use completion-in-region for completion
- "M-y" #'minuet-completion-region
+ "M-y" #'minuet-completion-in-region
  ;; use overlay for completion
  "M-i" #'minuet-show-suggestion)
 



[elpa] externals/minuet a601ce3125 41/97: doc: update README.

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit a601ce3125f2b903b6ee7cfb08a9ce943f62030c
Author: Milan Glacier 
Commit: Milan Glacier 

doc: update README.
---
 README.md | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/README.md b/README.md
index 8f509667a0..d9cce85300 100644
--- a/README.md
+++ b/README.md
@@ -69,7 +69,9 @@ Currently you need to install from github via `package-vc` or
 :bind
 (("M-y" . #'minuet-complete-with-minibuffer) ;; use minibuffer for 
completion
  ("M-i" . #'minuet-show-suggestion) ;; use overlay for completion
+
  :map minuet-active-mode-map
+ ;; These keymaps activate only when a minuet suggestion is displayed in 
the current buffer
  ("M-p" . #'minuet-previous-suggestion) ;; invoke completion or cycle to 
next completion
  ("M-n" . #'minuet-next-suggestion) ;; invoke completion or cycle to 
previous completion
  ("M-A" . #'minuet-accept-suggestion) ;; accept whole completion



[elpa] externals/minuet 837d26f58b 66/97: doc: update README.

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit 837d26f58b92bf03e6434c988099f557c1f4b7d6
Author: Milan Glacier 
Commit: Milan Glacier 

doc: update README.
---
 README.md | 7 ---
 1 file changed, 4 insertions(+), 3 deletions(-)

diff --git a/README.md b/README.md
index 34fa8b9ce3..2b18852b58 100644
--- a/README.md
+++ b/README.md
@@ -159,7 +159,8 @@ If using Ollama, you need to assign an arbitrary, non-null 
environment variable
 as a placeholder for it to function.
 
 Alternatively, you can provide a function that returns the API key. This
-function should be fast as it will be called with each completion request.
+function should return the result instantly as it will be called with each
+completion request.
 
 ```lisp
 ;; Good
@@ -519,8 +520,8 @@ request timeout from outputing too many tokens.
 
 If your setup failed, there are two most likely reasons:
 
-1. You are setting the API key to a literal value instead of the environment
-   variable name.
+1. You may set the API key incorrectly. Checkout the [API Key](#api-keys)
+   section to see how to correctly specify the API key.
 2. You are using a model or a context window that is too large, causing
completion items to timeout before returning any tokens. This is 
particularly
common with local LLM. It is recommended to start with the following 
settings



[elpa] externals/minuet 6a07b00d11 09/97: refactor: update auto suggestion triggering condition.

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit 6a07b00d113224a3ddf044becddc180b7f173f8d
Author: Milan Glacier 
Commit: Milan Glacier 

refactor: update auto suggestion triggering condition.
---
 minuet.el | 18 +++---
 1 file changed, 15 insertions(+), 3 deletions(-)

diff --git a/minuet.el b/minuet.el
index 79253c578d..610195a507 100644
--- a/minuet.el
+++ b/minuet.el
@@ -980,11 +980,23 @@ to be called when completion items arrive."
 "Setup auto-suggestion with `post-command-hook'."
 (add-hook 'post-command-hook #'minuet--maybe-show-suggestion nil t))
 
+(defun minuet--is-minuet-command ()
+"Return t if current command is a minuet command."
+(and this-command
+ (symbolp this-command)
+ (string-match-p "^minuet" (symbol-name this-command))
+ (message "minuet command executed")))
+
+(defun minuet--is-not-on-throttle ()
+"Return t if current time since last time is larger than the throttle 
delay."
+(or (null minuet--last-auto-suggestion-time)
+(> (float-time (time-since minuet--last-auto-suggestion-time))
+   minuet-auto-suggestion-throttle-delay)))
+
 (defun minuet--maybe-show-suggestion ()
 "Show suggestion with debouncing and throttling."
-(when (or (null minuet--last-auto-suggestion-time)
-  (> (float-time (time-since minuet--last-auto-suggestion-time))
- minuet-auto-suggestion-throttle-delay))
+(when (and (minuet--is-not-on-throttle)
+   (not (minuet--is-minuet-command)))
 (when minuet--debounce-timer
 (cancel-timer minuet--debounce-timer))
 (setq minuet--debounce-timer



[elpa] branch externals/minuet created (now 55f6527b2b)

2025-03-24 Thread ELPA Syncer
elpasync pushed a change to branch externals/minuet.

at  55f6527b2b doc: update README.

This branch includes the following new commits:

   new  4dbbceaad4 initial commit.
   new  526d8be6d8 doc: update README.
   new  ef057e07b5 chore: add license.
   new  93056be934 chore: pass linter test.
   new  819028cb75 doc: update comment string.
   new  b958b505ae doc: update README.
   new  15e7bbb279 chore: update gitignore.
   new  8b9ea6ff1c fix: use idle timer and fix buffer changing check for 
auto-suggestion.
   new  6a07b00d11 refactor: update auto suggestion triggering condition.
   new  a4f6ce017e fix: clean up code.
   new  d6f0098c62 doc: update README.
   new  bdf181c66f doc: update README.
   new  64c24f303e doc: update README.
   new  bffeba26d8 doc: update README.
   new  67ca0959d0 doc: update README.
   new  37f1607d2a chore: standardize indentation using EditorConfig and 
dir-locals.el.
   new  36d3b5348c chore: update editor config.
   new  49e36de4b5 feat: add minuet-active-mode for better keybinding 
management
   new  49502af28f doc: update README.
   new  7c81055c3d doc: update README.
   new  135b8feaab doc: fix typo.
   new  e0fdc2023b chore: pass checkdoc lint.
   new  79fb85db8d feat: api-key can be customized via a function.
   new  32085f5efc fix: fix api-key fetching for OpenAI provider.
   new  2767e12df9 chore: remove obsolete function call.
   new  2248735858 doc: update README.
   new  001e9fe417 refactor: only get buffer content after context size 
computation.
   new  b46da708c1 README: Use `:bind` instead of general-define-key for 
wider support
   new  4ed8a466d5 README: Small indentation fix to match removal of 
`general-use-key`
   new  e27348ea90 doc: Use `:bind` instead of general-define-key for wider 
accessibility (#7)
   new  74194a182e feat!: replace `minuet-completion-in-region` with 
`minuet-complete-with-mini-buffer`.
   new  6aacdce682 docs: update README.md
   new  f4a49dc75d chore: fix byte compiler warning.
   new  6a7f5a2c4a Merge pull request #9 from eltociear/patch-1
   new  3ac83dc334 gitignore: Ignore *.elc files from byte-compilation
   new  80bb9de797 Merge pull request #10 from mwolson/feat/ignore-elc-files
   new  b106155b80 chore: deploy melpazoid for github CI.
   new  6437545648 Merge pull request #11 from milanglacier/chore/melpazoid
   new  4e114c4b3e doc: update README.
   new  04ec5092fa chore: remove obsolete function call.
   new  a601ce3125 doc: update README.
   new  ebca9d72c0 feat: add numeric prefix support to 
minuet-accept-suggestion-line. (#12)
   new  f9c21914bc doc: update README.
   new  bee2c3b1c9 feat!: change default context window to 16000
   new  1f31be1e30 refactor: update prompt system for FIM models. (#15)
   new  b92b1f07d9 feat: add chat input template. (#16)
   new  b382a436bd refactor: rename :additional context field to 
:language-and-tab.
   new  58990620fe doc: update number of completions recommendation.
   new  5cff2add1e doc: update README.
   new  83a76653a4 refactor: cache json body for openai-fim-base function.
   new  4211e33361 doc: update README.
   new  3a342b44b3 feat: truncate incomplete lines at window boundaries for 
chat input
   new  e0fff84721 fix: ensure symbol-value is only called on symbols in 
`minuet--eval-value`.
   new  face48fd9a docs: add experimental Gemini configuration setup
   new  126af4dc86 doc: update instruction for ollama user for choosing FIM 
models.
   new  df2478180b refactor: improve fim provider error message.
   new  cc8c890413 doc: update README and package description.
   new  88975cd910 doc: update troubleshooting section.
   new  a44e1a5f86 feat!: change default debounce delay to 0.4 seconds.
   new  ab3dd8d06d feat: add consult support for 
`minuet-complete-with-minibuffer`. (#20)
   new  86998b7482 fix: don't show "(1/1)" when there is only 1 available 
suggestion.
   new  aa0920b5c9 docs: add server demand note for deepseek model
   new  cbc9e5a265 chore: fix CI warnings.
   new  17661cdf82 doc: update README.
   new  bde3350eae doc: fix typo.
   new  837d26f58b doc: update README.
   new  cac38ebe2d doc: update instruction on setting context_window for 
ollama.
   new  034317580d feat!: change default gemini model to gemini-2.0-flash.
   new  571aefc4ec doc: update instruction on gemini service.
   new  5d9007318e feat!: remove deprecated `minuet-completion-in-region` 
command.
   new  655fcfcb15 chore: release v0.4.0.
   new  b85f03ddd5 fix: fix minuet version.
   new  59e0da86a4 chore: release v0.4.1.
   new  fe312696f3 doc: fix broken link.
   new  5be76e8448 fix: ensure overlay is put after cursor.
   new  31e651d639 feat!: change claude default model to h

[elpa] externals/minuet 4dbbceaad4 01/97: initial commit.

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit 4dbbceaad4f9a72144c0a15658fa41fbcd8d261c
Author: Milan Glacier 
Commit: Milan Glacier 

initial commit.
---
 .gitignore |   2 +
 README.md  | 400 ++
 assets/minuet-completion-in-region.jpg | Bin 0 -> 101413 bytes
 assets/minuet-overlay.jpg  | Bin 0 -> 41102 bytes
 minuet.el  | 953 +
 prompt.md  | 157 ++
 6 files changed, 1512 insertions(+)

diff --git a/.gitignore b/.gitignore
new file mode 100644
index 00..d166713bc6
--- /dev/null
+++ b/.gitignore
@@ -0,0 +1,2 @@
+.tags
+.DS_Store
diff --git a/README.md b/README.md
new file mode 100644
index 00..506847b621
--- /dev/null
+++ b/README.md
@@ -0,0 +1,400 @@
+- [Minuet AI](#minuet-ai)
+- [Features](#features)
+- [Requirements](#requirements)
+- [Installation](#installation)
+- [API Keys](#api-keys)
+- [Selecting a Provider or Model](#selecting-a-provider-or-model)
+- [System Prompt](#system-prompt)
+- [Configuration](#configuration)
+  - [minuet-provider](#minuet-provider)
+  - [minuet-context-window](#minuet-context-window)
+  - [minuet-context-ratio](#minuet-context-ratio)
+  - [minuet-request-timeout](#minuet-request-timeout)
+  - [minuet-add-single-line-entry](#minuet-add-single-line-entry)
+  - [minuet-n-completions](#minuet-n-completions)
+- [Provider Options](#provider-options)
+  - [OpenAI](#openai)
+  - [Claude](#claude)
+  - [Codestral](#codestral)
+  - [Gemini](#gemini)
+  - [OpenAI-compatible](#openai-compatible)
+  - [OpenAI-FIM-Compatible](#openai-fim-compatible)
+
+# Minuet AI
+
+Minuet AI: Dance with Intelligence in Your Code 💃.
+
+`Minuet-ai` brings the grace and harmony of a minuet to your coding process.
+Just as dancers move during a minuet.
+
+# Features
+
+- AI-powered code completion
+- Support for multiple AI providers (OpenAI, Claude, Gemini, Codestral,
+  Huggingface, and OpenAI-compatible services)
+- Customizable configuration options
+- Streaming support to enable completion delivery even with slower LLMs
+
+**With completion-in-region**:
+
+![example-completion-in-region](./assets/minuet-completion-in-region.jpg)
+
+**With overlay frontend**:
+
+![example-overlay](./assets/minuet-overlay.jpg)
+
+# Requirements
+
+- emacs 29+
+- plz 0.9+
+- dash
+- An API key for at least one of the supported AI providers
+
+# Installation
+
+Currently you need to install from github via `package-vc` or
+`straight`, or manually install this package.
+
+```elisp
+
+;; install with straight
+(straight-use-package '(minuet :host github :repo "milanglacier/minuet-ai.el"))
+
+(use-package minuet
+:init
+(general-define-key
+ ;; use completion-in-region for completion
+ "M-y" #'minuet-completion-region
+ ;; use overlay for completion
+ "M-p" #'minuet-previous-suggestion ;; invoke completion or cycle to next 
completion
+ "M-n" #'minuet-next-suggestion ;; invoke completion or cycle to previous 
completion
+ "M-A" #'minuet-accept-suggestion ;; accept whole completion
+ "M-a" #'minuet-accept-suggestion-line ;; accept current line completion
+ "M-e" #'minuet-dismiss-suggestion)
+
+ ;; if you want to enable auto suggestion.
+ ;; Note that you can manually invoke completions without enable 
minuet-auto-suggestion-mode
+ (add-hook 'prog-mode-hook #'minuet-auto-suggestion-mode)
+
+:config
+(setq minuet-provider 'openai-fim-compatible)
+)
+```
+
+Example for Ollama
+
+
+
+```elisp
+(use-package minuet
+:init
+(general-define-key
+ ;; use completion-in-region for completion
+ "M-y" #'minuet-completion-region
+ ;; use overlay for completion
+ "M-p" #'minuet-previous-suggestion ;; invoke completion or cycle to next 
completion
+ "M-n" #'minuet-next-suggestion ;; invoke completion or cycle to previous 
completion
+ "M-A" #'minuet-accept-suggestion ;; accept whole completion
+ "M-a" #'minuet-accept-suggestion-line ;; accept current line completion
+ "M-e" #'minuet-dismiss-suggestion)
+
+ ;; if you want to enable auto suggestion.
+ ;; Note that you can manually invoke completions without enable 
minuet-auto-suggestion-mode
+ (add-hook 'prog-mode-hook #'minuet-auto-suggestion-mode)
+
+:config
+(setq minuet-provider 'openai-fim-compatible)
+(plist-put minuet-openai-fim-compatible-options :end-point 
"http://localhost:11434/v1/completions";)
+;; an arbitrary non-null environment variable as placeholder
+(plist-put minuet-openai-fim-compatible-options :name "Ollama")
+(plist-put minuet-openai-fim-compatible-options :api-key "TERM")
+(plist-put minuet-openai-fim-compatible-options :model "qwen2.5-coder:3b")
+)
+```
+
+
+
+# API Keys
+
+Minuet AI requires API keys to function. Set the following environment 
variables:
+
+- `OPENAI_API_KEY` for OpenAI
+- `GEMINI_API_KEY` for Gemini
+- `ANTHROPIC_API_KEY` for Cl

[elpa] externals/minuet a4f6ce017e 10/97: fix: clean up code.

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit a4f6ce017e46f9dee8f6487d28f580c09cfb06a2
Author: Milan Glacier 
Commit: Milan Glacier 

fix: clean up code.
---
 minuet.el | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/minuet.el b/minuet.el
index 610195a507..660adeefbd 100644
--- a/minuet.el
+++ b/minuet.el
@@ -984,8 +984,7 @@ to be called when completion items arrive."
 "Return t if current command is a minuet command."
 (and this-command
  (symbolp this-command)
- (string-match-p "^minuet" (symbol-name this-command))
- (message "minuet command executed")))
+ (string-match-p "^minuet" (symbol-name this-command
 
 (defun minuet--is-not-on-throttle ()
 "Return t if current time since last time is larger than the throttle 
delay."



[elpa] externals/minuet 74c3ab10c3 86/97: feat: `minuet-configure-provider` can configure api-key as a function.

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit 74c3ab10c33a44bfc7f35c6d8496bb0fccfdb326
Author: Milan Glacier 
Commit: Milan Glacier 

feat: `minuet-configure-provider` can configure api-key as a function.

Allow functions as API key providers and preserve existing API key
when empty input is given. Support both string and function values for
the API key configuration.
---
 minuet.el | 14 +-
 1 file changed, 9 insertions(+), 5 deletions(-)

diff --git a/minuet.el b/minuet.el
index 64af3494b6..bcaa99dea3 100644
--- a/minuet.el
+++ b/minuet.el
@@ -1225,12 +1225,16 @@ their endpoint and API key."
 (let* ((current-endpoint (plist-get options :end-point))
(current-api-key (plist-get options :api-key))
(endpoint (read-string "Endpoint URL: " (or 
current-endpoint "")))
-   (api-key (read-string "API Key Environment Variable: "
- (if (stringp current-api-key)
- current-api-key
- ""
+   (api-key (read-string "API Key Environment Variable or 
Function: "
+ (cond ((stringp current-api-key) 
current-api-key)
+   ((symbolp current-api-key) 
(symbol-name current-api-key))
+   (t ""
+   ;; If the user enters nothing via `read-string`, retain the 
current API key.
+   (final-api-key (cond ((equal "" api-key) current-api-key)
+((functionp (intern api-key)) (intern 
api-key))
+(t api-key
 (plist-put options :end-point endpoint)
-(plist-put options :api-key api-key)))
+(plist-put options :api-key final-api-key)))
 
 (setq minuet-provider provider)
 (message "Minuet provider configured to %s with model %s" 
provider-name model)))



[elpa] externals/minuet fe312696f3 74/97: doc: fix broken link.

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit fe312696f3d155c9ba0d1bc55d10c5dfc7a93362
Author: Milan Glacier 
Commit: Milan Glacier 

doc: fix broken link.
---
 README.md | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/README.md b/README.md
index 41cbfb420f..20310cf3e9 100644
--- a/README.md
+++ b/README.md
@@ -4,7 +4,7 @@
 - [Installation](#installation)
 - [API Keys](#api-keys)
 - [Selecting a Provider or Model](#selecting-a-provider-or-model)
-- [System Prompt](#system-prompt)
+- [Prompt](#prompt)
 - [Configuration](#configuration)
   - [minuet-provider](#minuet-provider)
   - [minuet-context-window](#minuet-context-window)



[elpa] externals/minuet 17661cdf82 64/97: doc: update README.

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit 17661cdf826ecc779b232665a41ab3d6bf48db7c
Author: Milan Glacier 
Commit: Milan Glacier 

doc: update README.
---
 README.md | 22 --
 prompt.md |  6 --
 2 files changed, 16 insertions(+), 12 deletions(-)

diff --git a/README.md b/README.md
index c747b7db79..bc9b62aef1 100644
--- a/README.md
+++ b/README.md
@@ -97,7 +97,9 @@ managers.
 
 ```
 
-Example for Ollama:
+**LLM Provider Examples**:
+
+**Ollama (`qwen-2.5-coder:3b`)**:
 
 
 
@@ -119,7 +121,7 @@ Example for Ollama:
 
 
 
-Example for Fireworks with `llama-3.3-70b` model:
+**Fireworks (`llama-3.3-70b`)**:
 
 
 
@@ -178,8 +180,8 @@ Ollama using the `openai-fim-compatible` provider.
 
 Note: as of January 27, 2025, the high server demand from deepseek may
 significantly slow down the default provider used by Minuet
-(`openai-fim-compatible` with deepseek). We recommend trying
-alternative providers instead.
+(`openai-fim-compatible` with deepseek). We recommend trying alternative
+providers instead.
 
 # Prompt
 
@@ -273,7 +275,7 @@ You can customize the provider options using `plist-put`, 
for example:
 )
 ```
 
-To pass optional parameters (like `max_tokens` and `top_p`) to send to the REST
+To pass optional parameters (like `max_tokens` and `top_p`) to send to the curl
 request, you can use function `minuet-set-optional-options`:
 
 ```lisp
@@ -483,11 +485,11 @@ For example, you can set the `end_point` to
 
 
 Additionally, for Ollama users, it is essential to verify whether the model's
-template supports FIM completion. For example,
-[qwen2.5-coder's 
template](https://ollama.com/library/qwen2.5-coder/blobs/e94a8ecb9327)
-is a supported model. However it may come as a surprise to some users that,
-`deepseek-coder` does not support the FIM template, and you should use
-`deepseek-coder-v2` instead.
+template supports FIM completion. For example, qwen2.5-coder offers FIM 
support,
+as suggested in its
+[template]((https://ollama.com/library/qwen2.5-coder/blobs/e94a8ecb9327).
+However it may come as a surprise to some users that, `deepseek-coder` does not
+support the FIM template, and you should use `deepseek-coder-v2` instead.
 
 The following config is the default.
 
diff --git a/prompt.md b/prompt.md
index 63e06975ce..12740910c9 100644
--- a/prompt.md
+++ b/prompt.md
@@ -107,8 +107,6 @@ def fibonacci(n):
 ## Default Chat Input Example
 
 The chat input represents the final prompt delivered to the LLM for completion.
-Its template follows a structured format similar to the system prompt and can 
be
-customized as follows:
 
 The chat input template follows a structure similar to the system prompt and 
can
 be customized using the following format:
@@ -137,6 +135,10 @@ plist containing the following values:
 - `:before-cursor`
 - `:after-cursor`
 - `:language-and-tab`
+- `:is-incomplete-before`: indicates whether the context before the cursor is
+  incomplete
+- `:is-incomplete-after`: indicates whether the context after the cursor is
+  incomplete
 
 ## Customization
 



[elpa] externals/minuet fffbb3a39a 93/97: chore: release v0.4.4

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit fffbb3a39a996fabb65b8f06ab5422bb53c500cd
Author: Milan Glacier 
Commit: Milan Glacier 

chore: release v0.4.4
---
 CHANGELOG.md | 19 ++-
 minuet.el|  2 +-
 2 files changed, 19 insertions(+), 2 deletions(-)

diff --git a/CHANGELOG.md b/CHANGELOG.md
index 93e34c9cd7..af64f6d422 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,18 +1,35 @@
+# Version 0.4.4 (2025-03-10)
+
+## Features
+
+- `minuet-configure-provider` can configure api-key as a named function.
+
+## Documentation
+
+- Update LLM provider example from Fireworks to Openrouter.
+
+## Chore
+
+- Reformat the code using 2 spaces indent.
+
 # Version 0.4.3 (2025-02-18)
 
 ## Documentation
 
-- Added recipes for llama.cpp.
+- Add recipes for llama.cpp.
 
 # Version 0.4.2 (2025-02-13)
 
 ## Breaking Changes
+
 - Change claude default model to haiku-3.5.
 
 ## Features
+
 - Add command `minuet-configure-provider`.
 
 ## Bug Fixes
+
 - Ensure overlay is put after cursor.
 
 # Version 0.4.1 (2025-02-10)
diff --git a/minuet.el b/minuet.el
index 8651cd3587..71f7c1eae7 100644
--- a/minuet.el
+++ b/minuet.el
@@ -2,7 +2,7 @@
 
 ;; Author: Milan Glacier 
 ;; Maintainer: Milan Glacier 
-;; Version: 0.4.3
+;; Version: 0.4.4
 ;; URL: https://github.com/milanglacier/minuet-ai.el
 ;; Package-Requires: ((emacs "29") (plz "0.9") (dash "2.19.1"))
 



[elpa] externals/minuet df2478180b 56/97: refactor: improve fim provider error message.

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit df2478180b180d2a967e6f331535c1f8d45eaadb
Author: Milan Glacier 
Commit: Milan Glacier 

refactor: improve fim provider error message.

Also add troubleshooting section in README.
---
 README.md | 15 +++
 minuet.el |  7 +++
 2 files changed, 22 insertions(+)

diff --git a/README.md b/README.md
index b9c37c967b..fad4351afb 100644
--- a/README.md
+++ b/README.md
@@ -505,3 +505,18 @@ request timeout from outputing too many tokens.
 ```
 
 
+
+# Troubleshooting
+
+If your setup failed, there are two most likely reasons:
+
+1. You are setting the API key to a literal value instead of the environment
+   variable name.
+2. You are using a context window that is too large, causing completion items
+   to timeout before returning. It is recommended to:
+   - Test with manual completion first
+   - Use a smaller context window (e.g., `context_window = 768`)
+   - Set a longer request timeout (e.g., `request_timeout = 5`) to
+ evaluate your provider's response time
+
+To diagnose issues, examine the buffer content from `*minut*`
diff --git a/minuet.el b/minuet.el
index 9e4af4be27..d8183d133f 100644
--- a/minuet.el
+++ b/minuet.el
@@ -739,6 +739,13 @@ Return nil if not exists or is an empty string."
(getenv api-key)
(when (functionp api-key)
(funcall api-key)
+(when (or (null key)
+  (string-empty-p key))
+(minuet--log
+ (if (stringp api-key)
+ (format "%s is not a valid environment variable.
+If using ollama you can just set it to 'TERM'." api-key)
+ "The api-key function returns nil or returns an empty 
string")))
 (and (not (equal key "")) key)))
 
 



[elpa] externals/minuet d6f0098c62 11/97: doc: update README.

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit d6f0098c6225bf417bbae6ba117ee3eca05217bd
Author: Milan Glacier 
Commit: Milan Glacier 

doc: update README.
---
 README.md | 75 ++-
 1 file changed, 41 insertions(+), 34 deletions(-)

diff --git a/README.md b/README.md
index cb6337688d..80e2632bf4 100644
--- a/README.md
+++ b/README.md
@@ -30,8 +30,8 @@ Just as dancers move during a minuet.
 # Features
 
 - AI-powered code completion
-- Support for multiple AI providers (OpenAI, Claude, Gemini, Codestral,
-  Huggingface, and OpenAI-compatible services)
+- Support for multiple AI providers (OpenAI, Claude, Gemini,
+  Codestral, and OpenAI-compatible services)
 - Customizable configuration options
 - Streaming support to enable completion delivery even with slower LLMs
 
@@ -78,30 +78,16 @@ Currently you need to install from github via `package-vc` 
or
 
 :config
 (setq minuet-provider 'openai-fim-compatible)
-)
+
+(minuet-set-optional-options minuet-openai-fim-compatible-options 
:max_tokens 256))
 ```
 
-Example for Ollama
+Example for Ollama:
 
 
 
 ```elisp
 (use-package minuet
-:init
-(general-define-key
- ;; use completion-in-region for completion
- "M-y" #'minuet-completion-region
- ;; use overlay for completion
- "M-p" #'minuet-previous-suggestion ;; invoke completion or cycle to next 
completion
- "M-n" #'minuet-next-suggestion ;; invoke completion or cycle to previous 
completion
- "M-A" #'minuet-accept-suggestion ;; accept whole completion
- "M-a" #'minuet-accept-suggestion-line ;; accept current line completion
- "M-e" #'minuet-dismiss-suggestion)
-
- ;; if you want to enable auto suggestion.
- ;; Note that you can manually invoke completions without enable 
minuet-auto-suggestion-mode
- (add-hook 'prog-mode-hook #'minuet-auto-suggestion-mode)
-
 :config
 (setq minuet-provider 'openai-fim-compatible)
 (plist-put minuet-openai-fim-compatible-options :end-point 
"http://localhost:11434/v1/completions";)
@@ -109,7 +95,26 @@ Example for Ollama
 (plist-put minuet-openai-fim-compatible-options :name "Ollama")
 (plist-put minuet-openai-fim-compatible-options :api-key "TERM")
 (plist-put minuet-openai-fim-compatible-options :model "qwen2.5-coder:3b")
-)
+
+(minuet-set-optional-options minuet-openai-fim-compatible-options 
:max_tokens 256))
+```
+
+
+
+Example for Fireworks with `llama-3.3-70b` model:
+
+
+
+```elisp
+(use-package minuet
+:config
+(setq minuet-provider 'openai-compatible)
+(plist-put minuet-openai-compatible-options :end-point 
"https://api.fireworks.ai/inference/v1/chat/completions";)
+(plist-put minuet-openai-compatible-options :api-key "FIREWORKS_API_KEY")
+(plist-put minuet-openai-compatible-options :model 
"accounts/fireworks/models/llama-v3p3-70b-instruct")
+
+(minuet-set-optional-options minuet-openai-compatible-options :max_tokens 
256)
+(minuet-set-optional-options minuet-openai-compatible-options :top_p 0.9))
 ```
 
 
@@ -122,7 +127,6 @@ Minuet AI requires API keys to function. Set the following 
environment variables
 - `GEMINI_API_KEY` for Gemini
 - `ANTHROPIC_API_KEY` for Claude
 - `CODESTRAL_API_KEY` for Codestral
-- `HF_API_KEY` for Huggingface
 - Custom environment variable for OpenAI-compatible services (as specified in 
your configuration)
 
 **Note:** Provide the name of the environment variable to Minuet
@@ -162,7 +166,7 @@ Set the provider you want to use for completion with 
minuet, available
 options: `openai`, `openai-compatible`, `claude`, `gemini`,
 `openai-fim-compatible`, and `codestral`.
 
-The default is `openai-fim-compatible` (with deepseek).
+The default is `openai-fim-compatible` using the deepseek endpoint.
 
 You can use `ollama` with either `openai-compatible` or
 `openai-fim-compatible` provider, depending on your model is a chat
@@ -217,6 +221,7 @@ You can customize the provider options using `plist-put`, 
for example:
 (plist-put minuet-openai-options :model "gpt-4o")
 
 ;; change openai-compatible provider to use fireworks
+(setq minuet-provider 'openai-compatible)
 (plist-put minuet-openai-compatible-options :end-point 
"https://api.fireworks.ai/inference/v1/chat/completions";)
 (plist-put minuet-openai-compatible-options :api-key "FIREWORKS_API_KEY")
 (plist-put minuet-openai-compatible-options :model 
"accounts/fireworks/models/llama-v3p3-70b-instruct")
@@ -336,19 +341,19 @@ settings following the example:
 
 ```lisp
 (minuet-set-optional-options minuet-gemini-options
-:generationConfig
-'(:maxOutputTokens 256
-:topP 0.9))
+ :generationConfig
+ '(:maxOutputTokens 256
+   :topP 0.9))
 (minuet-set-optional-options minuet-gemini-options
-:safetySe

[elpa] externals/minuet b85f03ddd5 72/97: fix: fix minuet version.

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit b85f03ddd5109e5a733eda054acaabfefa47ae1a
Author: Milan Glacier 
Commit: Milan Glacier 

fix: fix minuet version.
---
 minuet.el | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/minuet.el b/minuet.el
index a4bd1e756a..345c7552d8 100644
--- a/minuet.el
+++ b/minuet.el
@@ -2,7 +2,7 @@
 
 ;; Author: Milan Glacier 
 ;; Maintainer: Milan Glacier 
-;; Version: 0.3
+;; Version: 0.4.1
 ;; URL: https://github.com/milanglacier/minuet-ai.el
 ;; Package-Requires: ((emacs "29") (plz "0.9") (dash "2.19.1"))
 



[elpa] externals/minuet 034317580d 68/97: feat!: change default gemini model to gemini-2.0-flash.

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit 034317580d67f5eb3113a0d597c509ccbcc57adc
Author: Milan Glacier 
Commit: Milan Glacier 

feat!: change default gemini model to gemini-2.0-flash.
---
 minuet.el | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/minuet.el b/minuet.el
index eafa72bc97..19077b98e4 100644
--- a/minuet.el
+++ b/minuet.el
@@ -317,7 +317,7 @@ def fibonacci(n):
 "Config options for Minuet OpenAI FIM compatible provider.")
 
 (defvar minuet-gemini-options
-`(:model "gemini-1.5-flash-latest"
+`(:model "gemini-2.0-flash"
   :api-key "GEMINI_API_KEY"
   :system
   (:template minuet-default-system-template



[elpa] externals/minuet 49e36de4b5 18/97: feat: add minuet-active-mode for better keybinding management

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit 49e36de4b50054ce5b4afba4cc9553dd4416d308
Author: Milan Glacier 
Commit: Milan Glacier 

feat: add minuet-active-mode for better keybinding management
---
 README.md | 17 -
 minuet.el | 15 +--
 2 files changed, 25 insertions(+), 7 deletions(-)

diff --git a/README.md b/README.md
index 09867c8e4a..f3b4b014c4 100644
--- a/README.md
+++ b/README.md
@@ -68,11 +68,7 @@ Currently you need to install from github via `package-vc` or
  ;; use completion-in-region for completion
  "M-y" #'minuet-completion-region
  ;; use overlay for completion
- "M-p" #'minuet-previous-suggestion ;; invoke completion or cycle to next 
completion
- "M-n" #'minuet-next-suggestion ;; invoke completion or cycle to previous 
completion
- "M-A" #'minuet-accept-suggestion ;; accept whole completion
- "M-a" #'minuet-accept-suggestion-line ;; accept current line completion
- "M-e" #'minuet-dismiss-suggestion)
+ "M-i" #'minuet-show-suggestion)
 
  ;; if you want to enable auto suggestion.
  ;; Note that you can manually invoke completions without enable 
minuet-auto-suggestion-mode
@@ -81,6 +77,17 @@ Currently you need to install from github via `package-vc` or
 :config
 (setq minuet-provider 'openai-fim-compatible)
 
+;; if you are using evil, this is required.
+(add-hook 'minuet-active-mode-hook #'evil-normalize-keymaps)
+
+(general-define-key
+ :keymaps 'minuet-active-mode-map
+ "M-p" #'minuet-previous-suggestion ;; invoke completion or cycle to next 
completion
+ "M-n" #'minuet-next-suggestion ;; invoke completion or cycle to previous 
completion
+ "M-A" #'minuet-accept-suggestion ;; accept whole completion
+ "M-a" #'minuet-accept-suggestion-line ;; accept current line completion
+ "M-e" #'minuet-dismiss-suggestion)
+
 (minuet-set-optional-options minuet-openai-fim-compatible-options 
:max_tokens 256))
 ```
 
diff --git a/minuet.el b/minuet.el
index 660adeefbd..179819f89d 100644
--- a/minuet.el
+++ b/minuet.el
@@ -322,7 +322,8 @@ symbol, return its value.  Else return itself."
 (minuet--cancel-requests))
 (when minuet--current-overlay
 (delete-overlay minuet--current-overlay)
-(setq minuet--current-overlay nil))
+(setq minuet--current-overlay nil)
+(minuet-active-mode -1))
 (remove-hook 'post-command-hook #'minuet--on-cursor-moved t)
 (setq minuet--last-point nil))
 
@@ -359,7 +360,8 @@ symbol, return its value.  Else return itself."
  total)
  'face 'minuet-suggestion-face))
 (overlay-put ov 'minuet t)
-(setq minuet--current-overlay ov)))
+(setq minuet--current-overlay ov)
+(minuet-active-mode 1)))
 
 ;;;###autoload
 (defun minuet-next-suggestion ()
@@ -1030,5 +1032,14 @@ When enabled, Minuet will automatically show suggestions 
while you type."
 (minuet--setup-auto-suggestion)
 (minuet--cleanup-auto-suggestion)))
 
+(defvar minuet-active-mode-map
+(let ((map (make-sparse-keymap))) map)
+"Keymap used when minuet-active-mode is enabled.")
+
+(define-minor-mode minuet-active-mode
+"When there is an active suggestion in minuet."
+:init-value nil
+:keymap minuet-active-mode-map)
+
 (provide 'minuet)
 ;;; minuet.el ends here



[elpa] externals/minuet c837149120 92/97: chore: reformat code.

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit c837149120ddff0cbb7a490cc60c513276b9703d
Author: Milan Glacier 
Commit: Milan Glacier 

chore: reformat code.
---
 minuet.el | 292 +++---
 1 file changed, 146 insertions(+), 146 deletions(-)

diff --git a/minuet.el b/minuet.el
index 05d79c7a26..8651cd3587 100644
--- a/minuet.el
+++ b/minuet.el
@@ -849,41 +849,41 @@ arrive."
 completion-items)
 (dotimes (_ total-try)
   (minuet--with-temp-response
-   (push
-(plz 'post (plist-get options :end-point)
- :headers `(("Content-Type" . "application/json")
-("Accept" . "application/json")
-("Authorization" . ,(concat "Bearer " 
(minuet--get-api-key (plist-get options :api-key)
- :timeout minuet-request-timeout
- :body body
- :as 'string
- :filter (minuet--make-process-stream-filter --response--)
- :then
- (lambda (json)
-   (when-let* ((result (minuet--stream-decode json get-text-fn)))
- ;; insert the current result into the completion items list
- (push result completion-items))
-   (setq completion-items (minuet--filter-context-sequence-in-items
-   completion-items
-   context))
-   (setq completion-items (minuet--remove-spaces completion-items))
-   (funcall callback completion-items))
- :else
- (lambda (err)
-   (if (equal (car (plz-error-curl-error err)) 28)
-   (progn
- (minuet--log (format "%s Request timeout" name))
- (when-let* ((result (minuet--stream-decode-raw 
--response-- get-text-fn)))
-   (push result completion-items)))
- (minuet--log (format "An error occured when sending request 
to %s" name))
- (minuet--log err))
-   (setq completion-items
- (minuet--filter-context-sequence-in-items
-  completion-items
-  context))
-   (setq completion-items (minuet--remove-spaces completion-items))
-   (funcall callback completion-items)))
-minuet--current-requests)
+(push
+ (plz 'post (plist-get options :end-point)
+   :headers `(("Content-Type" . "application/json")
+  ("Accept" . "application/json")
+  ("Authorization" . ,(concat "Bearer " 
(minuet--get-api-key (plist-get options :api-key)
+   :timeout minuet-request-timeout
+   :body body
+   :as 'string
+   :filter (minuet--make-process-stream-filter --response--)
+   :then
+   (lambda (json)
+ (when-let* ((result (minuet--stream-decode json get-text-fn)))
+   ;; insert the current result into the completion items list
+   (push result completion-items))
+ (setq completion-items (minuet--filter-context-sequence-in-items
+ completion-items
+ context))
+ (setq completion-items (minuet--remove-spaces completion-items))
+ (funcall callback completion-items))
+   :else
+   (lambda (err)
+ (if (equal (car (plz-error-curl-error err)) 28)
+ (progn
+   (minuet--log (format "%s Request timeout" name))
+   (when-let* ((result (minuet--stream-decode-raw --response-- 
get-text-fn)))
+ (push result completion-items)))
+   (minuet--log (format "An error occured when sending request to 
%s" name))
+   (minuet--log err))
+ (setq completion-items
+   (minuet--filter-context-sequence-in-items
+completion-items
+context))
+ (setq completion-items (minuet--remove-spaces completion-items))
+ (funcall callback completion-items)))
+ minuet--current-requests)
 
 (defun minuet--codestral-complete (context callback)
   "Complete code with codestral.
@@ -924,41 +924,41 @@ OPTIONS are the provider options.  the completion items 
from json.
 CONTEXT is to be used to build the prompt.  CALLBACK is the function
 to be called when completion items arrive."
   (minuet--with-temp-response
-   (push
-(plz 'post (plist-get options :end-point)
- :headers
- `(("Content-Type" . "application/json")
-   ("Accept" . "application/json")
-   ("Authorization" . ,(concat "Bearer " (minuet--get-api-key 
(plist-get options :api-key)
- :timeout minuet-request-timeout
- :body
- (json-serialize
-  `(,@(plist-get options :optional)
-:stream t
-

[elpa] externals/minuet 83a76653a4 50/97: refactor: cache json body for openai-fim-base function.

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit 83a76653a40b7c5f2f7cdaf0c8ecb3b61415ab7c
Author: Milan Glacier 
Commit: Milan Glacier 

refactor: cache json body for openai-fim-base function.
---
 minuet.el | 26 +-
 1 file changed, 13 insertions(+), 13 deletions(-)

diff --git a/minuet.el b/minuet.el
index 6d4258ca2c..fe51146c5b 100644
--- a/minuet.el
+++ b/minuet.el
@@ -810,6 +810,18 @@ prompt.  CALLBACK is the function to be called when 
completion items
 arrive."
 (let ((total-try (or minuet-n-completions 1))
   (name (plist-get options :name))
+  (body (json-serialize
+ `(,@(plist-get options :optional)
+   :stream t
+   :model ,(plist-get options :model)
+   :prompt ,(funcall (--> options
+  (plist-get it :template)
+  (plist-get it :prompt))
+ context)
+   ,@(when-let* ((suffix-fn (--> options
+ (plist-get it :template)
+ (plist-get it :suffix
+ (list :suffix (funcall suffix-fn context))
   completion-items)
 (dotimes (_ total-try)
 (minuet--with-temp-response
@@ -819,19 +831,7 @@ arrive."
  ("Accept" . "application/json")
  ("Authorization" . ,(concat "Bearer " 
(minuet--get-api-key (plist-get options :api-key)
   :timeout minuet-request-timeout
-  :body
-  (json-serialize
-   `(,@(plist-get options :optional)
- :stream t
- :model ,(plist-get options :model)
- :prompt ,(funcall (--> options
-(plist-get it :template)
-(plist-get it :prompt))
-   context)
- ,@(when-let* ((suffix-fn (--> options
-   (plist-get it :template)
-   (plist-get it :suffix
-   (list :suffix (funcall suffix-fn context)
+  :body body
   :as 'string
   :filter (minuet--make-process-stream-filter --response--)
   :then



[elpa] externals/minuet 1c12dc3652 94/97: doc: update instruction for evil user for defining `minuet-active-mode-map`.

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit 1c12dc36523e1dd98e1086fd0c04b40489de28bd
Author: Milan Glacier 
Commit: Milan Glacier 

doc: update instruction for evil user for defining `minuet-active-mode-map`.
---
 README.md | 24 +---
 1 file changed, 17 insertions(+), 7 deletions(-)

diff --git a/README.md b/README.md
index 8b1299261d..acc648a94c 100644
--- a/README.md
+++ b/README.md
@@ -90,9 +90,19 @@ managers.
 ;; You can use M-x minuet-configure-provider to interactively configure 
provider and model
 (setq minuet-provider 'openai-fim-compatible)
 
-;; Required when defining minuet-ative-mode-map in insert/normal states.
-;; Not required when defining minuet-active-mode-map without evil state.
-(add-hook 'minuet-active-mode-hook #'evil-normalize-keymaps)
+;; For Evil users: When defining `minuet-ative-mode-map` in insert
+;; or normal states, the following one-liner is required.
+
+;; This is *not* necessary when defining `minuet-active-mode-map`.
+
+;; To minimize frequent overhead, it is recommended to avoid adding
+;; `evil-normalize-keymaps` to `minuet-active-mode-hook`. Instead,
+;; bind keybindings directly within `minuet-active-mode-map` using
+;; standard Emacs key sequences, such as `M-xxx`. This approach should
+;; not conflict with Evil's keybindings, as Evil primarily avoids
+;; using `M-xxx` bindings.
+
+;; (add-hook 'minuet-active-mode-hook #'evil-normalize-keymaps)
 
 (minuet-set-optional-options minuet-openai-fim-compatible-options 
:max_tokens 256))
 
@@ -584,10 +594,10 @@ request timeout from outputing too many tokens.
 (minuet-set-optional-options minuet-openai-fim-compatible-options :top_p 0.9)
 ```
 
-For example bash scripts to run llama.cpp based on your local
-computing power, please refer to [recipes.md](./recipes.md). Note
-that the model for `llama.cpp` must be determined when you launch the
-`llama.cpp` server and cannot be changed thereafter.
+For example bash scripts to run llama.cpp based on your local computing power,
+please refer to [recipes.md](./recipes.md). Note that the model for `llama.cpp`
+must be determined when you launch the `llama.cpp` server and cannot be changed
+thereafter.
 
 
 



[elpa] externals/minuet b106155b80 37/97: chore: deploy melpazoid for github CI.

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit b106155b8054667fca4160237dcc32a97ce0ba3c
Author: Milan Glacier 
Commit: Milan Glacier 

chore: deploy melpazoid for github CI.
---
 .github/workflows/melpazoid.yml | 26 ++
 1 file changed, 26 insertions(+)

diff --git a/.github/workflows/melpazoid.yml b/.github/workflows/melpazoid.yml
new file mode 100644
index 00..64605e6431
--- /dev/null
+++ b/.github/workflows/melpazoid.yml
@@ -0,0 +1,26 @@
+# melpazoid  build checks.
+
+name: melpazoid
+on: [push, pull_request]
+
+jobs:
+  build:
+runs-on: ubuntu-latest
+steps:
+- uses: actions/checkout@v3
+- name: Set up Python 3.10
+  uses: actions/setup-python@v4
+  with:
+python-version: '3.10'
+- name: Install
+  run: |
+python -m pip install --upgrade pip
+sudo apt-get install emacs && emacs --version
+git clone https://github.com/riscy/melpazoid.git ~/melpazoid
+pip install ~/melpazoid
+- name: Run
+  env:
+LOCAL_REPO: ${{ github.workspace }}
+RECIPE: (minuet :repo "milanglacier/minuet-ai.el" :fetcher github)
+EXIST_OK: false
+  run: echo $GITHUB_REF && make -C ~/melpazoid



[elpa] externals/minuet 3a342b44b3 52/97: feat: truncate incomplete lines at window boundaries for chat input

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit 3a342b44b3f8701f70963acc70b27313292bf671
Author: Milan Glacier 
Commit: Milan Glacier 

feat: truncate incomplete lines at window boundaries for chat input

Prevent partial lines at context boundaries from confusing LLMs by
ensuring they receive only complete lines of code. Though semantic
completeness still isn't guaranteed, this change eliminates truncated
code fragments that could lead to incorrect code understanding and
suggestions.
---
 minuet.el | 36 +++-
 1 file changed, 27 insertions(+), 9 deletions(-)

diff --git a/minuet.el b/minuet.el
index fe51146c5b..faa3444d21 100644
--- a/minuet.el
+++ b/minuet.el
@@ -509,26 +509,34 @@ Also print the MESSAGE when MESSAGE-P is t."
(point-max (point-max))
(n-chars-after (- point-max point))
(before-start (point-min))
-   (after-end point-max))
+   (after-end point-max)
+   (is-incomplete-before nil)
+   (is-incomplete-after nil))
 ;; Calculate context window boundaries before extracting text
 (when (>= (+ n-chars-before n-chars-after) minuet-context-window)
 (cond ((< n-chars-before (* minuet-context-ratio 
minuet-context-window))
;; If context before cursor does not exceed context-window,
;; only limit after-cursor content
-   (setq after-end (+ point (- minuet-context-window 
n-chars-before
+   (setq after-end (+ point (- minuet-context-window 
n-chars-before))
+ is-incomplete-after t))
   ((< n-chars-after (* (- 1 minuet-context-ratio) 
minuet-context-window))
;; If context after cursor does not exceed context-window,
;; limit before-cursor content
-   (setq before-start (- point (- minuet-context-window 
n-chars-after
+   (setq before-start (- point (- minuet-context-window 
n-chars-after))
+ is-incomplete-before t))
   (t
;; At middle of file, use ratio to determine both boundaries
-   (setq after-end (+ point (floor (* minuet-context-window (- 
1 minuet-context-ratio
+   (setq is-incomplete-before t
+ is-incomplete-after t
+ after-end (+ point (floor (* minuet-context-window (- 
1 minuet-context-ratio
  before-start (+ (point-min)
  (max 0 (- n-chars-before
(floor (* 
minuet-context-window minuet-context-ratio)
 `(:before-cursor ,(buffer-substring-no-properties before-start point)
   :after-cursor ,(buffer-substring-no-properties point after-end)
-  :language-and-tab ,(format "%s\n%s" (minuet--add-language-comment) 
(minuet--add-tab-comment)
+  :language-and-tab ,(format "%s\n%s" (minuet--add-language-comment) 
(minuet--add-tab-comment))
+  :is-incomplete-before ,is-incomplete-before
+  :is-incomplete-after ,is-incomplete-after)))
 
 (defun minuet--make-chat-llm-shot (context options)
 "Build the final chat input for chat llm.
@@ -1105,12 +1113,22 @@ to be called when completion items arrive."
 (plist-get ctx :language-and-tab))
 
 (defun minuet--default-chat-input-before-cursor-function (ctx)
-"Default function to get before cursor from CTX."
-(plist-get ctx :before-cursor))
+"Default function to get before cursor from CTX.
+If context is incomplete, remove first line to avoid partial code."
+(let ((text (plist-get ctx :before-cursor))
+  (incomplete (plist-get ctx :is-incomplete-before)))
+(when incomplete
+(setq text (replace-regexp-in-string "\\`.*\n" "" text)))
+text))
 
 (defun minuet--default-chat-input-after-cursor-function (ctx)
-"Default function to get after cursor from CTX."
-(plist-get ctx :after-cursor))
+"Default function to get after cursor from CTX.
+If context is incomplete, remove last line to avoid partial code."
+(let ((text (plist-get ctx :after-cursor))
+  (incomplete (plist-get ctx :is-incomplete-after)))
+(when incomplete
+(setq text (replace-regexp-in-string "\n.*\\'" "" text)))
+text))
 
 (defun minuet--cleanup-auto-suggestion ()
 "Clean up auto-suggestion timers and hooks."



[elpa] externals/minuet 49502af28f 19/97: doc: update README.

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit 49502af28fb785add6eac39f5866f20b3b39de5b
Author: Milan Glacier 
Commit: Milan Glacier 

doc: update README.
---
 README.md | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/README.md b/README.md
index f3b4b014c4..153fff176c 100644
--- a/README.md
+++ b/README.md
@@ -77,7 +77,8 @@ Currently you need to install from github via `package-vc` or
 :config
 (setq minuet-provider 'openai-fim-compatible)
 
-;; if you are using evil, this is required.
+;; Required when defining minuet-ative-mode-map in insert/normal states.
+;; Not required when defining minuet-active-mode-map without evil state.
 (add-hook 'minuet-active-mode-hook #'evil-normalize-keymaps)
 
 (general-define-key



[elpa] externals/minuet 819028cb75 05/97: doc: update comment string.

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit 819028cb75c71bda5d619cdf10f58898b3a1cda4
Author: Milan Glacier 
Commit: Milan Glacier 

doc: update comment string.
---
 minuet.el | 140 ++
 1 file changed, 95 insertions(+), 45 deletions(-)

diff --git a/minuet.el b/minuet.el
index e2c7b8b4d2..9d6e79a0f9 100644
--- a/minuet.el
+++ b/minuet.el
@@ -26,8 +26,9 @@
 ;; Floor, Boston, MA 02110-1301, USA.
 
 ;;; Commentary:
-;; This package implements an AI-powered code completion tool for Emacs. It
-;; supports to use a variety of LLMs to generate code completions.
+;; This package implements an AI-powered code completion tool for
+;; Emacs.  It supports to use a variety of LLMs to generate code
+;; completions.
 
 ;;; Code:
 
@@ -88,7 +89,8 @@ If any function in this list returns non-nil, 
auto-suggestions will not be shown
 (defvar-local minuet--debounce-timer nil
 "Timer for debouncing auto-suggestions.")
 
-(defvar minuet-buffer-name "*minuet*" "The basename for minuet buffers")
+(defvar minuet-buffer-name "*minuet*" "The basename for minuet buffers.")
+
 (defcustom minuet-provider 'openai-fim-compatible
 "The provider to use for code completion.
 Must be one of the supported providers: codestral, openai, claude, etc."
@@ -108,9 +110,9 @@ This limits how much surrounding code is sent to the LLM 
for context."
 
 (defcustom minuet-context-ratio 0.75
 "Ratio of context before cursor vs after cursor.
-When the total characters exceed the context window, this ratio determines
-how much context to keep before vs after the cursor. A larger ratio means
-more context before the cursor will be used."
+When the total characters exceed the context window, this ratio
+determines how much context to keep before vs after the cursor.  A
+larger ratio means more context before the cursor will be used."
 :type 'float
 :group 'minuet)
 
@@ -129,21 +131,21 @@ completion item containing only its first line."
 (defcustom minuet-after-cursor-filter-length 15
 "Length of context after cursor used to filter completion text.
 Defines the length of non-whitespace context after the cursor used to
-filter completion text. Set to 0 to disable filtering.
+filter completion text.  Set to 0 to disable filtering.
 
-Example: With after_cursor_filter_length = 3 and context:
-'def fib(n):\\n|\\n\\nfib(5)' (where | represents cursor position),
-if the completion text contains 'fib', then 'fib' and subsequent text
-will be removed. This setting filters repeated text generated by the
-LLM. A large value (e.g., 15) is recommended to avoid false positives."
+Example: With after_cursor_filter_length = 3 and context: 'def
+fib(n):\\n|\\n\\nfib(5)' (where | represents cursor position), if the
+completion text contains 'fib', then 'fib' and subsequent text will be
+removed.  This setting filters repeated text generated by the LLM.  A
+large value (e.g., 15) is recommended to avoid false positives."
 :type 'integer
 :group 'minuet)
 
 (defcustom minuet-n-completions 3
 "Number of completion items to request from the language model.
-This number is encoded as part of the prompt for the chat LLM. Note that
-when `minuet-add-single-line-entry' is true, the actual number of
-returned items may exceed this value. Additionally, the LLM cannot
+This number is encoded as part of the prompt for the chat LLM.  Note
+that when `minuet-add-single-line-entry' is true, the actual number of
+returned items may exceed this value.  Additionally, the LLM cannot
 guarantee the exact number of completion items specified, as this
 parameter serves only as a prompt guideline."
 :type 'integer
@@ -161,7 +163,7 @@ enclosed in markers:
 Note that the user's code will be prompted in reverse order: first the code
 after the cursor, then the code before the cursor.
 "
-"The default prompt for minuet completion")
+"The default prompt for minuet completion.")
 
 (defvar minuet-default-guidelines
 "Guidelines:
@@ -174,7 +176,7 @@ after the cursor, then the code before the cursor.
additional comments or markdown code block fences. Return the result 
directly.
 6. Keep each completion option concise, limiting it to a single line or a few 
lines.
 7. Create entirely new code completion that DO NOT REPEAT OR COPY any user's 
existing code around ."
-"The default guidelines for minuet completion")
+"The default guidelines for minuet completion.")
 
 (defvar minuet-default-n-completion-template
 "8. Provide at most %d completion items."
@@ -182,7 +184,7 @@ after the cursor, then the code before the cursor.
 
 (defvar minuet-default-system-template
 "{{{:prompt}}}\n{{{:guidelines}}}\n{{{:n-completions-template}}}"
-"The default template for minuet system template")
+"The default template for minuet system template.")
 
 (defvar minuet-default-fewshots
 `((:role "user"
@@ -221,7 +223,7 @@ def fibonacci(n):
:n-completions-template minuet-default-n-completi

[elpa] externals/minuet a44e1a5f86 59/97: feat!: change default debounce delay to 0.4 seconds.

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit a44e1a5f86de64e778b58c18d72aba76dc44af4d
Author: Milan Glacier 
Commit: Milan Glacier 

feat!: change default debounce delay to 0.4 seconds.
---
 README.md | 2 +-
 minuet.el | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/README.md b/README.md
index 61dd1c90b0..93a6f74f04 100644
--- a/README.md
+++ b/README.md
@@ -244,7 +244,7 @@ If resource efficiency is imporant, it is recommended to 
set this value to `1`.
 ## minuet-auto-suggestion-debounce-delay
 
 The delay in seconds before sending a completion request after typing stops. 
The
-default is `0.2` seconds.
+default is `0.4` seconds.
 
 ## minuet-auto-suggestion-throttle-delay
 
diff --git a/minuet.el b/minuet.el
index bcaf0a57c8..78f0c616d0 100644
--- a/minuet.el
+++ b/minuet.el
@@ -52,7 +52,7 @@
 (declare-function evil-emacs-state-p "evil-states")
 (declare-function evil-insert-state-p "evil-states")
 
-(defcustom minuet-auto-suggestion-debounce-delay 0.2
+(defcustom minuet-auto-suggestion-debounce-delay 0.4
 "Debounce delay in seconds for auto-suggestions."
 :type 'number
 :group 'minuet)



[elpa] externals/minuet 3e896b9950 83/97: chore: release v0.4.3

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit 3e896b99500f77a73e92b0c6e7a8f13d60c7ef88
Author: Milan Glacier 
Commit: Milan Glacier 

chore: release v0.4.3
---
 CHANGELOG.md | 6 ++
 minuet.el| 4 ++--
 2 files changed, 8 insertions(+), 2 deletions(-)

diff --git a/CHANGELOG.md b/CHANGELOG.md
index b11b6fcac6..93e34c9cd7 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,3 +1,9 @@
+# Version 0.4.3 (2025-02-18)
+
+## Documentation
+
+- Added recipes for llama.cpp.
+
 # Version 0.4.2 (2025-02-13)
 
 ## Breaking Changes
diff --git a/minuet.el b/minuet.el
index 6e33b8f712..64af3494b6 100644
--- a/minuet.el
+++ b/minuet.el
@@ -2,7 +2,7 @@
 
 ;; Author: Milan Glacier 
 ;; Maintainer: Milan Glacier 
-;; Version: 0.4.2
+;; Version: 0.4.3
 ;; URL: https://github.com/milanglacier/minuet-ai.el
 ;; Package-Requires: ((emacs "29") (plz "0.9") (dash "2.19.1"))
 
@@ -34,7 +34,7 @@
 ;;   (DeepSeek, Codestral, and some Ollama models).
 ;;
 ;; Minuet supports multiple AI providers (OpenAI, Claude, Gemini,
-;; Codestral, Ollama, and OpenAI-compatible providers)
+;; Codestral, Ollama, Llama.cpp, and OpenAI-compatible providers)
 ;;
 ;; You can use it with overlay-based ghost text via
 ;; `minuet-show-suggestion' or selecting the candidates via



[elpa] externals/minuet 6aacdce682 32/97: docs: update README.md

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit 6aacdce682bab26a90a74cf30def83bdd89d024f
Author: Ikko Eltociear Ashimine 
Commit: GitHub 

docs: update README.md

paramters -> parameters
---
 README.md | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/README.md b/README.md
index 247e4fa546..2961ba0df2 100644
--- a/README.md
+++ b/README.md
@@ -249,7 +249,7 @@ You can customize the provider options using `plist-put`, 
for example:
 )
 ```
 
-To pass optional paramters (like `max_tokens` and `top_p`) to send to
+To pass optional parameters (like `max_tokens` and `top_p`) to send to
 the REST request, you can use function
 `minuet-set-optional-options`:
 



[elpa] externals/minuet bc1239027e 78/97: chore: release v0.4.2

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit bc1239027e6cc3e4288d91bcbdb5891cb2dbfa5f
Author: Milan Glacier 
Commit: Milan Glacier 

chore: release v0.4.2
---
 CHANGELOG.md | 11 +++
 minuet.el|  2 +-
 2 files changed, 12 insertions(+), 1 deletion(-)

diff --git a/CHANGELOG.md b/CHANGELOG.md
index d4409f3e78..b11b6fcac6 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,3 +1,14 @@
+# Version 0.4.2 (2025-02-13)
+
+## Breaking Changes
+- Change claude default model to haiku-3.5.
+
+## Features
+- Add command `minuet-configure-provider`.
+
+## Bug Fixes
+- Ensure overlay is put after cursor.
+
 # Version 0.4.1 (2025-02-10)
 
 ## Bug Fixes
diff --git a/minuet.el b/minuet.el
index a6d55cb3a2..c54fa84eab 100644
--- a/minuet.el
+++ b/minuet.el
@@ -2,7 +2,7 @@
 
 ;; Author: Milan Glacier 
 ;; Maintainer: Milan Glacier 
-;; Version: 0.4.1
+;; Version: 0.4.2
 ;; URL: https://github.com/milanglacier/minuet-ai.el
 ;; Package-Requires: ((emacs "29") (plz "0.9") (dash "2.19.1"))
 



[elpa] externals/minuet 9cf3a6f5aa 89/97: refactor: clean up code according to emacs-devel suggestion.

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit 9cf3a6f5aa007633ec196d6a3d9181bbc1396162
Author: Milan Glacier 
Commit: Milan Glacier 

refactor: clean up code according to emacs-devel suggestion.

Clean up code according to suggestion from Stefan Monnier:
https://lists.gnu.org/archive/html/emacs-devel/2025-03/msg00578.html
---
 .gitignore |  4 
 minuet.el  | 61 -
 2 files changed, 28 insertions(+), 37 deletions(-)

diff --git a/.gitignore b/.gitignore
index cc7ca80deb..c22623ce67 100644
--- a/.gitignore
+++ b/.gitignore
@@ -2,3 +2,7 @@
 .DS_Store
 .aider*
 *.elc
+
+# ELPA-generated files
+/minuet-autoloads.el
+/minuet-pkg.el
diff --git a/minuet.el b/minuet.el
index afef558392..edfa887971 100644
--- a/minuet.el
+++ b/minuet.el
@@ -58,8 +58,7 @@
 
 (defcustom minuet-auto-suggestion-debounce-delay 0.4
 "Debounce delay in seconds for auto-suggestions."
-:type 'number
-:group 'minuet)
+:type 'number)
 
 (defcustom minuet-auto-suggestion-block-functions 
'(minuet-evil-not-insert-state-p)
 "List of functions to determine whether auto-suggestions should be blocked.
@@ -67,13 +66,11 @@
 Each function should return non-nil if auto-suggestions should be
 blocked.  If any function in this list returns non-nil,
 auto-suggestions will not be shown."
-:type '(repeat function)
-:group 'minuet)
+:type '(repeat function))
 
 (defcustom minuet-auto-suggestion-throttle-delay 1.0
 "Minimum time in seconds between auto-suggestions."
-:type 'number
-:group 'minuet)
+:type 'number)
 
 (defface minuet-suggestion-face
 '((t :inherit shadow))
@@ -117,36 +114,31 @@ Must be one of the supported providers: codestral, 
openai, claude, etc."
(const :tag "Claude" claude)
(const :tag "OpenAI Compatible" openai-compatible)
(const :tag "OpenAI FIM Compatible" openai-fim-compatible)
-   (const :tag "Gemini" gemini))
-:group 'minuet)
+   (const :tag "Gemini" gemini)))
 
 (defcustom minuet-context-window 16000
 "The maximum total characters of the context before and after cursor.
 This limits how much surrounding code is sent to the LLM for context.
 The default is 16000 characters which would roughly equate 4000
 tokens."
-:type 'integer
-:group 'minuet)
+:type 'integer)
 
 (defcustom minuet-context-ratio 0.75
 "Ratio of context before cursor vs after cursor.
 When the total characters exceed the context window, this ratio
 determines how much context to keep before vs after the cursor.  A
 larger ratio means more context before the cursor will be used."
-:type 'float
-:group 'minuet)
+:type 'float)
 
 (defcustom minuet-request-timeout 3
 "Maximum timeout in seconds for sending completion requests."
-:type 'integer
-:group 'minuet)
+:type 'integer)
 
 (defcustom minuet-add-single-line-entry t
 "Whether to create additional single-line completion items.
 When non-nil and a completion item has multiple lines, create another
 completion item containing only its first line."
-:type 'boolean
-:group 'minuet)
+:type 'boolean)
 
 (defcustom minuet-after-cursor-filter-length 15
 "Length of context after cursor used to filter completion text.
@@ -160,8 +152,7 @@ completion text contains \"fib\", then \"fib\" and 
subsequent text
 will be removed.  This setting filters repeated text generated by the
 LLM.  A large value (e.g., 15) is recommended to avoid false
 positives."
-:type 'integer
-:group 'minuet)
+:type 'integer)
 
 (defcustom minuet-n-completions 3
 "Number of completion items.
@@ -171,8 +162,7 @@ that when `minuet-add-single-line-entry` is true, the 
actual number of
 returned items may exceed this value.  Additionally, the LLM cannot
 guarantee the exact number of completion items specified, as this
 parameter serves only as a prompt guideline.  The default is `3`."
-:type 'integer
-:group 'minuet)
+:type 'integer)
 
 (defvar minuet-default-prompt
 "You are the backend of an AI-powered code completion engine. Your task is 
to
@@ -512,17 +502,15 @@ Also print the MESSAGE when MESSAGE-P is t."
 
 (defun minuet--remove-spaces (items)
 "Remove trailing and leading spaces in each item in ITEMS."
-;; emacs use \\` and \\' to match the beginning/end of the string,
+;; Emacs use \\` and \\' to match the beginning/end of the string,
 ;; ^ and $ are used to match bol or eol
 (setq items (mapcar (lambda (x)
 (if (or (equal x "")
 (string-match "\\`[\s\t\n]+\\'" x))
 nil
-(setq x (replace-regexp-in-string 
"[\s\t\n]+\\'" "" x)
-  x (replace-regexp-in-string 
"\\`[\s\t\n]+" "" x
+(string-trim x)))
 items

[elpa] externals/minuet 5cff2add1e 49/97: doc: update README.

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit 5cff2add1efd9b395c74f71c28cb951c5558c3e1
Author: Milan Glacier 
Commit: Milan Glacier 

doc: update README.
---
 README.md | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/README.md b/README.md
index 94d3df19d5..284e08eb6f 100644
--- a/README.md
+++ b/README.md
@@ -104,6 +104,8 @@ Example for Ollama:
 :config
 (setq minuet-provider 'openai-fim-compatible)
 (setq minuet-n-completions 1) ; recommended for Local LLM for resource 
saving
+; I recommend you start with a small context window firstly, and gradually 
increase it based on your local computing power.
+(setq minuet-context-window 512)
 (plist-put minuet-openai-fim-compatible-options :end-point 
"http://localhost:11434/v1/completions";)
 ;; an arbitrary non-null environment variable as placeholder
 (plist-put minuet-openai-fim-compatible-options :name "Ollama")



[elpa] externals/minuet 58990620fe 48/97: doc: update number of completions recommendation.

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit 58990620fed7f755076d9b5befa9bc095181e583
Author: Milan Glacier 
Commit: Milan Glacier 

doc: update number of completions recommendation.
---
 README.md | 16 ++--
 minuet.el |  9 +
 2 files changed, 15 insertions(+), 10 deletions(-)

diff --git a/README.md b/README.md
index 70b6dba310..94d3df19d5 100644
--- a/README.md
+++ b/README.md
@@ -103,6 +103,7 @@ Example for Ollama:
 (use-package minuet
 :config
 (setq minuet-provider 'openai-fim-compatible)
+(setq minuet-n-completions 1) ; recommended for Local LLM for resource 
saving
 (plist-put minuet-openai-fim-compatible-options :end-point 
"http://localhost:11434/v1/completions";)
 ;; an arbitrary non-null environment variable as placeholder
 (plist-put minuet-openai-fim-compatible-options :name "Ollama")
@@ -227,12 +228,15 @@ option has no impact for overlay-based suggesion.
 
 ## minuet-n-completions
 
-Number of completion items to request from the language model. This number is
-encoded as part of the prompt for the chat LLM. Note that when
-`minuet-add-single-line-entry` is true, the actual number of returned items may
-exceed this value. Additionally, the LLM cannot guarantee the exact number of
-completion items specified, as this parameter serves only as a prompt 
guideline.
-The default is `3`.
+For FIM model, this is the number of requests to send. For chat LLM ,
+this is the number of completions encoded as part of the prompt. Note
+that when `minuet-add-single-line-entry` is true, the actual number of
+returned items may exceed this value. Additionally, the LLM cannot
+guarantee the exact number of completion items specified, as this
+parameter serves only as a prompt guideline.  The default is `3`.
+
+If resource efficiency is imporant, it is recommended to set this
+value to `1`.
 
 ## minuet-auto-suggestion-debounce-delay
 
diff --git a/minuet.el b/minuet.el
index b9544c7024..6d4258ca2c 100644
--- a/minuet.el
+++ b/minuet.el
@@ -151,12 +151,13 @@ positives."
 :group 'minuet)
 
 (defcustom minuet-n-completions 3
-"Number of completion items to request from the language model.
-This number is encoded as part of the prompt for the chat LLM.  Note
-that when `minuet-add-single-line-entry' is true, the actual number of
+"Number of completion items.
+For FIM model, this is the number of requests to send.  For chat LLM ,
+this is the number of completions encoded as part of the prompt.  Note
+that when `minuet-add-single-line-entry` is true, the actual number of
 returned items may exceed this value.  Additionally, the LLM cannot
 guarantee the exact number of completion items specified, as this
-parameter serves only as a prompt guideline."
+parameter serves only as a prompt guideline.  The default is `3`."
 :type 'integer
 :group 'minuet)
 



[elpa] externals/minuet 86998b7482 61/97: fix: don't show "(1/1)" when there is only 1 available suggestion.

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit 86998b748262f0a2edce792adbce56b2c52037e5
Author: Milan Glacier 
Commit: Milan Glacier 

fix: don't show "(1/1)" when there is only 1 available suggestion.
---
 minuet.el | 11 ++-
 1 file changed, 6 insertions(+), 5 deletions(-)

diff --git a/minuet.el b/minuet.el
index 111392c8d1..f73aceef74 100644
--- a/minuet.el
+++ b/minuet.el
@@ -407,11 +407,12 @@ Also cancel any pending requests unless NO-CANCEL is t."
   minuet--current-suggestion-index index
   minuet--last-point (point))
 (overlay-put ov 'after-string
- (propertize (format "%s (%d/%d)"
- suggestion
- (1+ index)
- total)
- 'face 'minuet-suggestion-face))
+ (propertize
+  (format "%s%s"
+  suggestion
+  (if (= total minuet-n-completions 1) ""
+  (format " (%d/%d)" (1+ index) total)))
+  'face 'minuet-suggestion-face))
 (overlay-put ov 'minuet t)
 (setq minuet--current-overlay ov)
 (minuet-active-mode 1)))



[elpa] externals/minuet 4cd42ed86f 95/97: doc: rearrange example config order.

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit 4cd42ed86f10d38a197b39f8ee897766c72338f5
Author: Milan Glacier 
Commit: Milan Glacier 

doc: rearrange example config order.
---
 README.md | 8 
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/README.md b/README.md
index acc648a94c..95420d1020 100644
--- a/README.md
+++ b/README.md
@@ -90,9 +90,13 @@ managers.
 ;; You can use M-x minuet-configure-provider to interactively configure 
provider and model
 (setq minuet-provider 'openai-fim-compatible)
 
+(minuet-set-optional-options minuet-openai-fim-compatible-options 
:max_tokens 64))
+
 ;; For Evil users: When defining `minuet-ative-mode-map` in insert
 ;; or normal states, the following one-liner is required.
 
+;; (add-hook 'minuet-active-mode-hook #'evil-normalize-keymaps)
+
 ;; This is *not* necessary when defining `minuet-active-mode-map`.
 
 ;; To minimize frequent overhead, it is recommended to avoid adding
@@ -102,10 +106,6 @@ managers.
 ;; not conflict with Evil's keybindings, as Evil primarily avoids
 ;; using `M-xxx` bindings.
 
-;; (add-hook 'minuet-active-mode-hook #'evil-normalize-keymaps)
-
-(minuet-set-optional-options minuet-openai-fim-compatible-options 
:max_tokens 256))
-
 ```
 
 **LLM Provider Examples**:



[elpa] externals/minuet 5253d754f0 79/97: refactor: minor cleanup.

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit 5253d754f0683aed3134f3a48853798714170763
Author: Milan Glacier 
Commit: Milan Glacier 

refactor: minor cleanup.
---
 minuet.el | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/minuet.el b/minuet.el
index c54fa84eab..4ca67f4f51 100644
--- a/minuet.el
+++ b/minuet.el
@@ -1218,7 +1218,7 @@ their endpoint and API key."
(current-model (plist-get options :model))
(model (read-string "Model: " (or current-model ""
 
-(setf (plist-get (symbol-value options-sym) :model) model)
+(plist-put options :model model)
 
 ;; For OpenAI compatible providers, also configure endpoint and API key
 (when (memq provider '(openai-compatible openai-fim-compatible))
@@ -1229,8 +1229,8 @@ their endpoint and API key."
  (if (stringp current-api-key)
  current-api-key
  ""
-(setf (plist-get (symbol-value options-sym) :end-point) 
endpoint)
-(setf (plist-get (symbol-value options-sym) :api-key) 
api-key)))
+(plist-put options :end-point endpoint)
+(plist-put options :api-key api-key)))
 
 (setq minuet-provider provider)
 (message "Minuet provider configured to %s with model %s" 
provider-name model)))



[elpa] externals/minuet e27348ea90 30/97: doc: Use `:bind` instead of general-define-key for wider accessibility (#7)

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit e27348ea903dbbf6051449ee1996767de5a3195f
Merge: 001e9fe417 4ed8a466d5
Author: milanglacier 
Commit: GitHub 

doc: Use `:bind` instead of general-define-key for wider accessibility (#7)
---
 README.md | 29 -
 1 file changed, 12 insertions(+), 17 deletions(-)

diff --git a/README.md b/README.md
index a5a498d87e..8332798902 100644
--- a/README.md
+++ b/README.md
@@ -66,16 +66,19 @@ Currently you need to install from github via `package-vc` 
or
 (straight-use-package '(minuet :host github :repo "milanglacier/minuet-ai.el"))
 
 (use-package minuet
-:init
-(general-define-key
- ;; use completion-in-region for completion
- "M-y" #'minuet-completion-in-region
- ;; use overlay for completion
- "M-i" #'minuet-show-suggestion)
+:bind (("M-y" . #'minuet-completion-in-region) ;; use completion-in-region 
for completion
+   ("M-i" . #'minuet-show-suggestion) ;; use overlay for completion
+   :map minuet-active-mode-map
+   ("M-p" . #'minuet-previous-suggestion) ;; invoke completion or 
cycle to next completion
+   ("M-n" . #'minuet-next-suggestion) ;; invoke completion or cycle to 
previous completion
+   ("M-A" . #'minuet-accept-suggestion) ;; accept whole completion
+   ("M-a" . #'minuet-accept-suggestion-line) ;; accept current line 
completion
+   ("M-e" . #'minuet-dismiss-suggestion))
 
- ;; if you want to enable auto suggestion.
- ;; Note that you can manually invoke completions without enable 
minuet-auto-suggestion-mode
- (add-hook 'prog-mode-hook #'minuet-auto-suggestion-mode)
+:init
+;; if you want to enable auto suggestion.
+;; Note that you can manually invoke completions without enable 
minuet-auto-suggestion-mode
+(add-hook 'prog-mode-hook #'minuet-auto-suggestion-mode)
 
 :config
 (setq minuet-provider 'openai-fim-compatible)
@@ -84,14 +87,6 @@ Currently you need to install from github via `package-vc` or
 ;; Not required when defining minuet-active-mode-map without evil state.
 (add-hook 'minuet-active-mode-hook #'evil-normalize-keymaps)
 
-(general-define-key
- :keymaps 'minuet-active-mode-map
- "M-p" #'minuet-previous-suggestion ;; invoke completion or cycle to next 
completion
- "M-n" #'minuet-next-suggestion ;; invoke completion or cycle to previous 
completion
- "M-A" #'minuet-accept-suggestion ;; accept whole completion
- "M-a" #'minuet-accept-suggestion-line ;; accept current line completion
- "M-e" #'minuet-dismiss-suggestion)
-
 (minuet-set-optional-options minuet-openai-fim-compatible-options 
:max_tokens 256))
 ```
 



[elpa] externals/minuet 4e114c4b3e 39/97: doc: update README.

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit 4e114c4b3e86ada1ab54e8fa641332a6076baca6
Author: Milan Glacier 
Commit: Milan Glacier 

doc: update README.
---
 README.md | 17 +
 1 file changed, 9 insertions(+), 8 deletions(-)

diff --git a/README.md b/README.md
index 2961ba0df2..8f509667a0 100644
--- a/README.md
+++ b/README.md
@@ -66,14 +66,15 @@ Currently you need to install from github via `package-vc` 
or
 (straight-use-package '(minuet :host github :repo "milanglacier/minuet-ai.el"))
 
 (use-package minuet
-:bind (("M-y" . #'minuet-complete-with-minibuffer) ;; use minibuffer for 
completion
-   ("M-i" . #'minuet-show-suggestion) ;; use overlay for completion
-   :map minuet-active-mode-map
-   ("M-p" . #'minuet-previous-suggestion) ;; invoke completion or 
cycle to next completion
-   ("M-n" . #'minuet-next-suggestion) ;; invoke completion or cycle to 
previous completion
-   ("M-A" . #'minuet-accept-suggestion) ;; accept whole completion
-   ("M-a" . #'minuet-accept-suggestion-line) ;; accept current line 
completion
-   ("M-e" . #'minuet-dismiss-suggestion))
+:bind
+(("M-y" . #'minuet-complete-with-minibuffer) ;; use minibuffer for 
completion
+ ("M-i" . #'minuet-show-suggestion) ;; use overlay for completion
+ :map minuet-active-mode-map
+ ("M-p" . #'minuet-previous-suggestion) ;; invoke completion or cycle to 
next completion
+ ("M-n" . #'minuet-next-suggestion) ;; invoke completion or cycle to 
previous completion
+ ("M-A" . #'minuet-accept-suggestion) ;; accept whole completion
+ ("M-a" . #'minuet-accept-suggestion-line) ;; accept current line 
completion
+ ("M-e" . #'minuet-dismiss-suggestion))
 
 :init
 ;; if you want to enable auto suggestion.



[elpa] externals/minuet b46da708c1 28/97: README: Use `:bind` instead of general-define-key for wider support

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit b46da708c1b118b774ad2d911d137e78ada2dd81
Author: Mike Olson 
Commit: Mike Olson 

README: Use `:bind` instead of general-define-key for wider support

Users might not have `general.el` installed, so this makes it easier to get 
started.
---
 README.md | 23 +--
 1 file changed, 9 insertions(+), 14 deletions(-)

diff --git a/README.md b/README.md
index a5a498d87e..54bbe9ec5b 100644
--- a/README.md
+++ b/README.md
@@ -66,13 +66,16 @@ Currently you need to install from github via `package-vc` 
or
 (straight-use-package '(minuet :host github :repo "milanglacier/minuet-ai.el"))
 
 (use-package minuet
-:init
-(general-define-key
- ;; use completion-in-region for completion
- "M-y" #'minuet-completion-in-region
- ;; use overlay for completion
- "M-i" #'minuet-show-suggestion)
+:bind (("M-y" . #'minuet-completion-in-region) ;; use completion-in-region 
for completion
+   ("M-i" . #'minuet-show-suggestion) ;; use overlay for completion
+   :map minuet-active-mode-map
+   ("M-p" . #'minuet-previous-suggestion) ;; invoke completion or 
cycle to next completion
+   ("M-n" . #'minuet-next-suggestion) ;; invoke completion or cycle to 
previous completion
+   ("M-A" . #'minuet-accept-suggestion) ;; accept whole completion
+   ("M-a" . #'minuet-accept-suggestion-line) ;; accept current line 
completion
+   ("M-e" . #'minuet-dismiss-suggestion))
 
+:init
  ;; if you want to enable auto suggestion.
  ;; Note that you can manually invoke completions without enable 
minuet-auto-suggestion-mode
  (add-hook 'prog-mode-hook #'minuet-auto-suggestion-mode)
@@ -84,14 +87,6 @@ Currently you need to install from github via `package-vc` or
 ;; Not required when defining minuet-active-mode-map without evil state.
 (add-hook 'minuet-active-mode-hook #'evil-normalize-keymaps)
 
-(general-define-key
- :keymaps 'minuet-active-mode-map
- "M-p" #'minuet-previous-suggestion ;; invoke completion or cycle to next 
completion
- "M-n" #'minuet-next-suggestion ;; invoke completion or cycle to previous 
completion
- "M-A" #'minuet-accept-suggestion ;; accept whole completion
- "M-a" #'minuet-accept-suggestion-line ;; accept current line completion
- "M-e" #'minuet-dismiss-suggestion)
-
 (minuet-set-optional-options minuet-openai-fim-compatible-options 
:max_tokens 256))
 ```
 



[elpa] externals/minuet b92b1f07d9 46/97: feat: add chat input template. (#16)

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit b92b1f07d94e514b5ebd6b8113b3a40645660b7c
Author: milanglacier 
Commit: GitHub 

feat: add chat input template. (#16)

Add configurable chat input template with dynamic placeholders similar
to system prompt.
---
 minuet.el | 162 --
 1 file changed, 115 insertions(+), 47 deletions(-)

diff --git a/minuet.el b/minuet.el
index 8492ff89fa..619618926e 100644
--- a/minuet.el
+++ b/minuet.el
@@ -34,6 +34,7 @@
 
 (require 'plz)
 (require 'dash)
+(require 'cl-lib)
 
 (defgroup minuet nil
 "Minuet group."
@@ -194,6 +195,14 @@ after the cursor, then the code before the cursor.
 "{{{:prompt}}}\n{{{:guidelines}}}\n{{{:n-completions-template}}}"
 "The default template for minuet system template.")
 
+(defvar minuet-default-chat-input-template
+"{{{:language-and-tab}}}
+
+{{{:context-after-cursor}}}
+
+{{{:context-before-cursor}}}"
+"The default template for minuet chat input.")
+
 (defvar minuet-default-fewshots
 `((:role "user"
:content "# language: python
@@ -231,6 +240,11 @@ def fibonacci(n):
:guidelines minuet-default-guidelines
:n-completions-template minuet-default-n-completion-template)
   :fewshots minuet-default-fewshots
+  :chat-input
+  (:template minuet-default-chat-input-template
+   :language-and-tab minuet--default-chat-input-language-and-tab-function
+   :context-before-cursor minuet--default-chat-input-before-cursor-function
+   :context-after-cursor minuet--default-chat-input-after-cursor-function)
   :optional nil)
 "Config options for Minuet Claude provider.")
 
@@ -243,6 +257,11 @@ def fibonacci(n):
:guidelines minuet-default-guidelines
:n-completions-template minuet-default-n-completion-template)
   :fewshots minuet-default-fewshots
+  :chat-input
+  (:template minuet-default-chat-input-template
+   :language-and-tab minuet--default-chat-input-language-and-tab-function
+   :context-before-cursor minuet--default-chat-input-before-cursor-function
+   :context-after-cursor minuet--default-chat-input-after-cursor-function)
   :optional nil)
 "Config options for Minuet OpenAI provider.")
 
@@ -265,6 +284,11 @@ def fibonacci(n):
:guidelines minuet-default-guidelines
:n-completions-template minuet-default-n-completion-template)
   :fewshots minuet-default-fewshots
+  :chat-input
+  (:template minuet-default-chat-input-template
+   :language-and-tab minuet--default-chat-input-language-and-tab-function
+   :context-before-cursor minuet--default-chat-input-before-cursor-function
+   :context-after-cursor minuet--default-chat-input-after-cursor-function)
   :optional nil)
 "Config options for Minuet OpenAI compatible provider.")
 
@@ -287,6 +311,11 @@ def fibonacci(n):
:guidelines minuet-default-guidelines
:n-completions-template minuet-default-n-completion-template)
   :fewshots minuet-default-fewshots
+  :chat-input
+  (:template minuet-default-chat-input-template
+   :language-and-tab minuet--default-chat-input-language-and-tab-function
+   :context-before-cursor minuet--default-chat-input-before-cursor-function
+   :context-after-cursor minuet--default-chat-input-after-cursor-function)
   :optional nil)
 "Config options for Minuet Gemini provider.")
 
@@ -500,15 +529,36 @@ Also print the MESSAGE when MESSAGE-P is t."
   :after-cursor ,(buffer-substring-no-properties point after-end)
   :additional ,(format "%s\n%s" (minuet--add-language-comment) 
(minuet--add-tab-comment)
 
-(defun minuet--make-chat-llm-shot (context)
-"Build the prompt for chat llm from CONTEXT."
-(concat
- (plist-get context :additional)
- "\n\n"
- (plist-get context :after-cursor)
- "\n\n"
- (plist-get context :before-cursor)
- ""))
+(defun minuet--make-chat-llm-shot (context options)
+"Build the final chat input for chat llm.
+CONTEXT is read from current buffer content.
+OPTIONS should be the provider options plist."
+(let* ((chat-input (copy-tree (plist-get options :chat-input)))
+   (template (minuet--eval-value (plist-get chat-input :template)))
+   (parts nil))
+;; Remove template from options to avoid infinite recursion
+(setq chat-input (plist-put chat-input :template nil))
+;; Use cl-loop for better control flow
+(cl-loop with last-pos = 0
+ for match = (string-match "{{{\\(.+?\\)}}}" template last-pos)
+ until (not match)
+ for start-pos = (match-beginning 0)
+ for end-pos = (match-end 0)
+ for key = (match-string 1 template)
+ do
+ ;; Add text before placeholder
+ (when (> start-pos last-pos)
+ (push (substring template last-pos start-pos) parts))
+

[elpa] externals/minuet 15e7bbb279 07/97: chore: update gitignore.

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit 15e7bbb2793591a783575e96c368a44bc744b581
Author: Milan Glacier 
Commit: Milan Glacier 

chore: update gitignore.
---
 .gitignore | 1 +
 1 file changed, 1 insertion(+)

diff --git a/.gitignore b/.gitignore
index d166713bc6..ea84c42f8c 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,2 +1,3 @@
 .tags
 .DS_Store
+.aider*



[elpa] externals/minuet ebca9d72c0 42/97: feat: add numeric prefix support to minuet-accept-suggestion-line. (#12)

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit ebca9d72c09e040f12c6e56fbace58ba9c2ce532
Author: milanglacier 
Commit: GitHub 

feat: add numeric prefix support to minuet-accept-suggestion-line. (#12)
---
 README.md |  4 +++-
 minuet.el | 14 +-
 2 files changed, 12 insertions(+), 6 deletions(-)

diff --git a/README.md b/README.md
index d9cce85300..e2a0593c20 100644
--- a/README.md
+++ b/README.md
@@ -75,7 +75,9 @@ Currently you need to install from github via `package-vc` or
  ("M-p" . #'minuet-previous-suggestion) ;; invoke completion or cycle to 
next completion
  ("M-n" . #'minuet-next-suggestion) ;; invoke completion or cycle to 
previous completion
  ("M-A" . #'minuet-accept-suggestion) ;; accept whole completion
- ("M-a" . #'minuet-accept-suggestion-line) ;; accept current line 
completion
+ ;; Accept the first line of completion, or N lines with a numeric-prefix:
+ ;; e.g. C-u 2 M-a will accepts 2 lines of completion.
+ ("M-a" . #'minuet-accept-suggestion-line)
  ("M-e" . #'minuet-dismiss-suggestion))
 
 :init
diff --git a/minuet.el b/minuet.el
index f3e5780c5d..7f0abe625b 100644
--- a/minuet.el
+++ b/minuet.el
@@ -628,16 +628,20 @@ used to accumulate text output from a process.  After 
execution,
 (minuet--cleanup-suggestion))
 
 ;;;###autoload
-(defun minuet-accept-suggestion-line ()
-"Accept only the first line of the current overlay suggestion."
-(interactive)
+(defun minuet-accept-suggestion-line (&optional n)
+"Accept N lines of the current suggestion.
+When called interactively with a numeric prefix argument, accept that
+many lines.  Without a prefix argument, accept only the first line."
+(interactive "p")
 (when (and minuet--current-suggestions
minuet--current-overlay)
 (let* ((suggestion (nth minuet--current-suggestion-index
 minuet--current-suggestions))
-   (first-line (car (split-string suggestion "\n"
+   (lines (split-string suggestion "\n"))
+   (n (or n 1))
+   (selected-lines (seq-take lines n)))
 (minuet--cleanup-suggestion)
-(insert first-line
+(insert (string-join selected-lines "\n")
 
 ;;;###autoload
 (defun minuet-complete-with-minibuffer ()



[elpa] externals/minuet 1f31be1e30 45/97: refactor: update prompt system for FIM models. (#15)

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit 1f31be1e30825f423d417e8ef3aece26d7dcae0a
Author: milanglacier 
Commit: GitHub 

refactor: update prompt system for FIM models. (#15)
---
 README.md | 150 +++---
 minuet.el |  38 +++-
 prompt.md |  44 ++
 3 files changed, 137 insertions(+), 95 deletions(-)

diff --git a/README.md b/README.md
index d0ec4b5c09..70b6dba310 100644
--- a/README.md
+++ b/README.md
@@ -30,15 +30,14 @@ Just as dancers move during a minuet.
 # Features
 
 - AI-powered code completion with dual modes:
-  - Specialized prompts and various enhancements for chat-based LLMs
-on code completion tasks.
-  - Fill-in-the-middle (FIM) completion for compatible models
-(DeepSeek, Codestral, and some Ollama models).
-- Support for multiple AI providers (OpenAI, Claude, Gemini,
-  Codestral, Ollama, and OpenAI-compatible providers)
+  - Specialized prompts and various enhancements for chat-based LLMs on code
+completion tasks.
+  - Fill-in-the-middle (FIM) completion for compatible models (DeepSeek,
+Codestral, and some Ollama models).
+- Support for multiple AI providers (OpenAI, Claude, Gemini, Codestral, Ollama,
+  and OpenAI-compatible providers)
 - Customizable configuration options
-- Streaming support to enable completion delivery even with slower
-  LLMs
+- Streaming support to enable completion delivery even with slower LLMs
 
 **With minibuffer frontend**:
 
@@ -57,8 +56,8 @@ Just as dancers move during a minuet.
 
 # Installation
 
-Currently you need to install from github via `package-vc` or
-`straight`, or manually install this package.
+Currently you need to install from github via `package-vc` or `straight`, or
+manually install this package.
 
 ```elisp
 
@@ -135,24 +134,25 @@ Example for Fireworks with `llama-3.3-70b` model:
 
 # API Keys
 
-Minuet AI requires API keys to function. Set the following environment 
variables:
+Minuet AI requires API keys to function. Set the following environment
+variables:
 
 - `OPENAI_API_KEY` for OpenAI
 - `GEMINI_API_KEY` for Gemini
 - `ANTHROPIC_API_KEY` for Claude
 - `CODESTRAL_API_KEY` for Codestral
-- Custom environment variable for OpenAI-compatible services (as specified in 
your configuration)
+- Custom environment variable for OpenAI-compatible services (as specified in
+  your configuration)
 
-**Note:** Provide the name of the environment variable to Minuet
-inside the provider options, not the actual value. For instance, pass
-`OPENAI_API_KEY` to Minuet, not the value itself (e.g., `sk-`).
+**Note:** Provide the name of the environment variable to Minuet inside the
+provider options, not the actual value. For instance, pass `OPENAI_API_KEY` to
+Minuet, not the value itself (e.g., `sk-`).
 
-If using Ollama, you need to assign an arbitrary, non-null environment
-variable as a placeholder for it to function.
+If using Ollama, you need to assign an arbitrary, non-null environment variable
+as a placeholder for it to function.
 
-Alternatively, you can provide a function that returns the API
-key. This function should be fast as it will be called with each
-completion request.
+Alternatively, you can provide a function that returns the API key. This
+function should be fast as it will be called with each completion request.
 
 ```lisp
 ;; Good
@@ -164,88 +164,85 @@ completion request.
 
 # Selecting a Provider or Model
 
-The `gemini-flash` and `codestral` models offer high-quality output
-with free and fast processing. For optimal quality, consider using the
-`deepseek-chat` model, which is compatible with both
-`openai-fim-compatible` and `openai-compatible` providers. For local
-LLM inference, you can deploy either `qwen-coder` or `deepseek-coder`
-through Ollama using the `openai-fim-compatible` provider.
+The `gemini-flash` and `codestral` models offer high-quality output with free
+and fast processing. For optimal quality, consider using the `deepseek-chat`
+model, which is compatible with both `openai-fim-compatible` and
+`openai-compatible` providers. For local LLM inference, you can deploy either
+`qwen-coder` or `deepseek-coder` through Ollama using the
+`openai-fim-compatible` provider.
 
-# System Prompt
+# Prompt
 
-See [prompt](./prompt.md) for the default system prompt used by `minuet` and
+See [prompt](./prompt.md) for the default prompt used by `minuet` and
 instructions on customization.
 
-Please note that the System Prompt only applies to chat-based LLMs (OpenAI,
-OpenAI-Compatible, Claude, and Gemini). It does not apply to Codestral and
-OpenAI-FIM-compatible models.
+Note that `minuet` employs two distinct prompt systems:
+
+1. A system designed for chat-based LLMs (OpenAI, OpenAI-Compatible, Claude, 
and
+   Gemini)
+2. A separate system designed for Codestral and OpenAI-FIM-compatible models
 
 # Configuration
 
-Below are commonly used configuration options. To view the complete
-list of available settings, search for `

[elpa] externals/minuet 126af4dc86 55/97: doc: update instruction for ollama user for choosing FIM models.

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit 126af4dc86f68e037cdcb31b94a1e83ae0a9ebcf
Author: Milan Glacier 
Commit: Milan Glacier 

doc: update instruction for ollama user for choosing FIM models.
---
 README.md | 9 -
 1 file changed, 8 insertions(+), 1 deletion(-)

diff --git a/README.md b/README.md
index b5a1945142..b9c37c967b 100644
--- a/README.md
+++ b/README.md
@@ -171,7 +171,7 @@ The `gemini-flash` and `codestral` models offer 
high-quality output with free
 and fast processing. For optimal quality, consider using the `deepseek-chat`
 model, which is compatible with both `openai-fim-compatible` and
 `openai-compatible` providers. For local LLM inference, you can deploy either
-`qwen-coder` or `deepseek-coder` through Ollama using the
+`qwen-2.5-coder` or `deepseek-coder-v2` through Ollama using the
 `openai-fim-compatible` provider.
 
 # Prompt
@@ -475,6 +475,13 @@ For example, you can set the `end_point` to
 
 
 
+Additionally, for Ollama users, it is essential to verify whether the model's
+template supports FIM completion. For example,
+[qwen2.5-coder's 
template](https://ollama.com/library/qwen2.5-coder/blobs/e94a8ecb9327)
+is a supported model. However it may come as a surprise to some users that,
+`deepseek-coder` does not support the FIM template, and you should use
+`deepseek-coder-v2` instead.
+
 The following config is the default.
 
 ```lisp



[elpa] externals/minuet 74194a182e 31/97: feat!: replace `minuet-completion-in-region` with `minuet-complete-with-mini-buffer`.

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit 74194a182ea64c61528202b37484d31d0b6b3e15
Author: Milan Glacier 
Commit: Milan Glacier 

feat!: replace `minuet-completion-in-region` with 
`minuet-complete-with-mini-buffer`.

Also replace completion-in-region with completing-read.
---
 README.md |  7 ---
 minuet.el | 20 +---
 2 files changed, 13 insertions(+), 14 deletions(-)

diff --git a/README.md b/README.md
index 8332798902..247e4fa546 100644
--- a/README.md
+++ b/README.md
@@ -40,7 +40,7 @@ Just as dancers move during a minuet.
 - Streaming support to enable completion delivery even with slower
   LLMs
 
-**With completion-in-region**:
+**With minibuffer frontend**:
 
 ![example-completion-in-region](./assets/minuet-completion-in-region.jpg)
 
@@ -66,7 +66,7 @@ Currently you need to install from github via `package-vc` or
 (straight-use-package '(minuet :host github :repo "milanglacier/minuet-ai.el"))
 
 (use-package minuet
-:bind (("M-y" . #'minuet-completion-in-region) ;; use completion-in-region 
for completion
+:bind (("M-y" . #'minuet-complete-with-minibuffer) ;; use minibuffer for 
completion
("M-i" . #'minuet-show-suggestion) ;; use overlay for completion
:map minuet-active-mode-map
("M-p" . #'minuet-previous-suggestion) ;; invoke completion or 
cycle to next completion
@@ -88,6 +88,7 @@ Currently you need to install from github via `package-vc` or
 (add-hook 'minuet-active-mode-hook #'evil-normalize-keymaps)
 
 (minuet-set-optional-options minuet-openai-fim-compatible-options 
:max_tokens 256))
+
 ```
 
 Example for Ollama:
@@ -216,7 +217,7 @@ default is `3`.
 
 ## minuet-add-single-line-entry
 
-For `minuet-completion-in-region` function, Whether to create
+For `minuet-complete-with-minibuffer` function, Whether to create
 additional single-line completion items. When non-nil and a
 completion item has multiple lines, create another completion item
 containing only its first line. This option has no impact for
diff --git a/minuet.el b/minuet.el
index e8ac19f2db..445906349d 100644
--- a/minuet.el
+++ b/minuet.el
@@ -629,8 +629,8 @@ used to accumulate text output from a process.  After 
execution,
 (insert first-line
 
 ;;;###autoload
-(defun minuet-completion-in-region ()
-"Complete code in region with LLM."
+(defun minuet-complete-with-minibuffer ()
+"Complete using minibuffer interface."
 (interactive)
 (let ((current-buffer (current-buffer))
   (available-p-fn (intern (format "minuet--%s-available-p" 
minuet-provider)))
@@ -647,18 +647,13 @@ used to accumulate text output from a process.  After 
execution,
  (minuet--add-single-line-entry 
items)
  items)
items (-distinct items))
- ;; When there is only one completion item,
- ;; the completion-in-region function
- ;; automatically inserts the text into the
- ;; buffer. We want to prevent this automatic
- ;; behavior to ensure users can dismiss the
- ;; completion item if desired.
- (when (length= items 1)
- (push "" items))
  ;; close current minibuffer session, if any
  (when (active-minibuffer-window)
  (abort-recursive-edit))
- (completion-in-region (point) (point) items))
+ (when items
+ (when-let ((selected (completing-read "Complete: 
" items nil t)))
+ (unless (string-empty-p selected)
+ (insert selected)
 
 (defun minuet--get-api-key (api-key)
 "Get the api-key from API-KEY.
@@ -1043,5 +1038,8 @@ When enabled, Minuet will automatically show suggestions 
while you type."
 :init-value nil
 :keymap minuet-active-mode-map)
 
+;;;###autoload
+(define-obsolete-function-alias 'minuet-completion-in-region 
'minuet-complete-with-minibuffer "0.2")
+
 (provide 'minuet)
 ;;; minuet.el ends here



[elpa] externals/minuet b958b505ae 06/97: doc: update README.

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit b958b505ae54279eeebb6b84b35e06bd42eb34a3
Author: Milan Glacier 
Commit: Milan Glacier 

doc: update README.
---
 README.md | 17 +++--
 1 file changed, 11 insertions(+), 6 deletions(-)

diff --git a/README.md b/README.md
index 784304c941..cb6337688d 100644
--- a/README.md
+++ b/README.md
@@ -365,13 +365,18 @@ For example, you can set the `end_point` to
 The following config is the default.
 
 ```lisp
-(defvar minuet-openai-fim-compatible-options
-'(:model "deepseek-chat"
-  :end-point "https://api.deepseek.com/beta/completions";
-  :api-key "DEEPSEEK_API_KEY"
-  :name "Deepseek"
+(defvar minuet-openai-compatible-options
+`(:end-point "https://api.groq.com/openai/v1/chat/completions";
+  :api-key "GROQ_API_KEY"
+  :model "llama-3.3-70b-versatile"
+  :system
+  (:template minuet-default-system-template
+   :prompt minuet-default-prompt
+   :guidelines minuet-default-guidelines
+   :n-completions-template minuet-default-n-completion-template)
+  :fewshots minuet-default-fewshots
   :optional nil)
-"config options for Minuet OpenAI FIM compatible provider")
+"Config options for Minuet OpenAI compatible provider.")
 ```
 
 The following configuration is not the default, but recommended to prevent



[elpa] externals/minuet 0daf4532b7 87/97: fix: use `intern-soft` to check api key function existence in minuet-configure-provider.

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit 0daf4532b76d9962bdb4b87d23441abc34a4f846
Author: Milan Glacier 
Commit: Milan Glacier 

fix: use `intern-soft` to check api key function existence in 
minuet-configure-provider.
---
 minuet.el | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/minuet.el b/minuet.el
index bcaa99dea3..afef558392 100644
--- a/minuet.el
+++ b/minuet.el
@@ -1231,7 +1231,7 @@ their endpoint and API key."
(t ""
;; If the user enters nothing via `read-string`, retain the 
current API key.
(final-api-key (cond ((equal "" api-key) current-api-key)
-((functionp (intern api-key)) (intern 
api-key))
+((functionp (intern-soft api-key)) 
(intern-soft api-key))
 (t api-key
 (plist-put options :end-point endpoint)
 (plist-put options :api-key final-api-key)))



[elpa] externals/minuet 9df64dd5af 91/97: refactor: optimize system template evaluation.

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit 9df64dd5af157142d01110d69f953136f1263682
Author: Milan Glacier 
Commit: Milan Glacier 

refactor: optimize system template evaluation.
---
 minuet.el | 26 --
 1 file changed, 8 insertions(+), 18 deletions(-)

diff --git a/minuet.el b/minuet.el
index 610f622dc1..05d79c7a26 100644
--- a/minuet.el
+++ b/minuet.el
@@ -817,24 +817,14 @@ If using ollama you can just set it to 'TERM'." api-key)
"")))
 (setq tmpl (replace-regexp-in-string "{{{:n-completions-template}}}"
  n-completions-template
- tmpl))
-(map-do
- (lambda (k v)
-   (setq v (minuet--eval-value v))
-   (when (and (not (equal k :template))
-  (not (equal k :n-completions-template))
-  (stringp v))
- (setq tmpl
-   (replace-regexp-in-string
-(concat "{{{" (symbol-name k) "}}}")
-v
-tmpl
- template)
-;; replace placeholders that are not replaced
-(setq tmpl (replace-regexp-in-string "{{{.*}}}"
- ""
- tmpl))
-tmpl))
+ tmpl)
+  tmpl (replace-regexp-in-string
+"{{{\\([^{}]+\\)}}}"
+(lambda (str)
+  (minuet--eval-value (plist-get template (intern 
(match-string 1 str)
+tmpl)
+  ;; replace placeholders that are not replaced
+  tmpl (replace-regexp-in-string "{{{.*}}}" "" tmpl
 
 (defun minuet--openai-fim-complete-base (options get-text-fn context callback)
   "The base function to complete code with openai fim API.



[elpa] externals/minuet 6437545648 38/97: Merge pull request #11 from milanglacier/chore/melpazoid

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit 6437545648bbd3ef1f73fe0e572f3aeb798c8af0
Merge: 80bb9de797 b106155b80
Author: milanglacier 
Commit: GitHub 

Merge pull request #11 from milanglacier/chore/melpazoid

chore: deploy melpazoid for github CI.
---
 .github/workflows/melpazoid.yml | 26 ++
 1 file changed, 26 insertions(+)

diff --git a/.github/workflows/melpazoid.yml b/.github/workflows/melpazoid.yml
new file mode 100644
index 00..64605e6431
--- /dev/null
+++ b/.github/workflows/melpazoid.yml
@@ -0,0 +1,26 @@
+# melpazoid  build checks.
+
+name: melpazoid
+on: [push, pull_request]
+
+jobs:
+  build:
+runs-on: ubuntu-latest
+steps:
+- uses: actions/checkout@v3
+- name: Set up Python 3.10
+  uses: actions/setup-python@v4
+  with:
+python-version: '3.10'
+- name: Install
+  run: |
+python -m pip install --upgrade pip
+sudo apt-get install emacs && emacs --version
+git clone https://github.com/riscy/melpazoid.git ~/melpazoid
+pip install ~/melpazoid
+- name: Run
+  env:
+LOCAL_REPO: ${{ github.workspace }}
+RECIPE: (minuet :repo "milanglacier/minuet-ai.el" :fetcher github)
+EXIST_OK: false
+  run: echo $GITHUB_REF && make -C ~/melpazoid



[elpa] externals/minuet 4194846922 80/97: doc: update package description and README.

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit 419484692277c0151157e70a8956fc5e3c489d67
Author: Milan Glacier 
Commit: Milan Glacier 

doc: update package description and README.
---
 README.md | 2 +-
 minuet.el | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/README.md b/README.md
index 4ffdc0e671..b19b78d278 100644
--- a/README.md
+++ b/README.md
@@ -43,7 +43,7 @@ Just as dancers move during a minuet.
 
 ![example-completion-in-region](./assets/minuet-completion-in-region.jpg)
 
-**With overlay frontend**:
+**With overlay ghost text frontend**:
 
 ![example-overlay](./assets/minuet-overlay.jpg)
 
diff --git a/minuet.el b/minuet.el
index 4ca67f4f51..6e33b8f712 100644
--- a/minuet.el
+++ b/minuet.el
@@ -36,7 +36,7 @@
 ;; Minuet supports multiple AI providers (OpenAI, Claude, Gemini,
 ;; Codestral, Ollama, and OpenAI-compatible providers)
 ;;
-;; You can use it with overlay-based popup via
+;; You can use it with overlay-based ghost text via
 ;; `minuet-show-suggestion' or selecting the candidates via
 ;; `minuet-complete-with-minibuffer'.  You can toggle automatic
 ;; suggestion popup with `minuet-auto-suggestion-mode'.



[elpa] externals/minuet bffeba26d8 14/97: doc: update README.

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit bffeba26d86d786b696f05d8ebe2d293c3a8eadd
Author: Milan Glacier 
Commit: Milan Glacier 

doc: update README.
---
 README.md | 12 ++--
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/README.md b/README.md
index e50678db9c..b2176d3ff6 100644
--- a/README.md
+++ b/README.md
@@ -140,12 +140,12 @@ variable as a placeholder for it to function.
 
 # Selecting a Provider or Model
 
-For optimal performance, consider using the `deepseek-chat` model,
-which is compatible with both `openai-fim-compatible` and
-`openai-compatible` providers. Alternatively, the `gemini-flash` model
-offers a free and fast experience. For local LLM inference, you can
-deploy either `qwen-coder` or `deepseek-coder` through ollama using
-the `openai-fim-compatible` provider.
+The `gemini-flash` and `codestral` models offer high-quality output
+with free and fast processing. For optimal quality, consider using the
+`deepseek-chat` model, which is compatible with both
+`openai-fim-compatible` and `openai-compatible` providers. For local
+LLM inference, you can deploy either `qwen-coder` or `deepseek-coder`
+through Ollama using the `openai-fim-compatible` provider.
 
 # System Prompt
 



[elpa] externals/minuet e0fff84721 53/97: fix: ensure symbol-value is only called on symbols in `minuet--eval-value`.

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit e0fff8472187e6c6044bb3f3bab11b6ff94e6a72
Author: Milan Glacier 
Commit: Milan Glacier 

fix: ensure symbol-value is only called on symbols in `minuet--eval-value`.
---
 minuet.el | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/minuet.el b/minuet.el
index faa3444d21..9e4af4be27 100644
--- a/minuet.el
+++ b/minuet.el
@@ -345,7 +345,7 @@ If value is a function (either lambda or a callable 
symbol), eval the
 function (with no argument) and return the result.  Else if value is a
 symbol, return its value.  Else return itself."
 (cond ((functionp value) (funcall value))
-  ((boundp value) (symbol-value value))
+  ((and (symbolp value) (boundp value)) (symbol-value value))
   (t value)))
 
 (defun minuet--cancel-requests ()



[elpa] externals/minuet cbc9e5a265 63/97: chore: fix CI warnings.

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit cbc9e5a2658a0161eaaab3cfd4d8de7c7f04954f
Author: Milan Glacier 
Commit: Milan Glacier 

chore: fix CI warnings.
---
 .github/workflows/melpazoid.yml | 2 +-
 minuet.el   | 6 --
 2 files changed, 5 insertions(+), 3 deletions(-)

diff --git a/.github/workflows/melpazoid.yml b/.github/workflows/melpazoid.yml
index 64605e6431..6b34b7e71b 100644
--- a/.github/workflows/melpazoid.yml
+++ b/.github/workflows/melpazoid.yml
@@ -21,6 +21,6 @@ jobs:
 - name: Run
   env:
 LOCAL_REPO: ${{ github.workspace }}
-RECIPE: (minuet :repo "milanglacier/minuet-ai.el" :fetcher github)
+RECIPE: (minuet :fetcher github :repo "milanglacier/minuet-ai.el")
 EXIST_OK: false
   run: echo $GITHUB_REF && make -C ~/melpazoid
diff --git a/minuet.el b/minuet.el
index f73aceef74..eafa72bc97 100644
--- a/minuet.el
+++ b/minuet.el
@@ -28,8 +28,10 @@
 ;;; Commentary:
 ;; AI-powered code completion with dual modes:
 ;;
-;; - Specialized prompts and various enhancements for chat-based LLMs on code 
completion tasks.
-;; - Fill-in-the-middle (FIM) completion for compatible models (DeepSeek, 
Codestral, and some Ollama models).
+;; - Specialized prompts and various enhancements for chat-based LLMs
+;;   on code completion tasks.
+;; - Fill-in-the-middle (FIM) completion for compatible models
+;;   (DeepSeek, Codestral, and some Ollama models).
 ;;
 ;; Minuet supports multiple AI providers (OpenAI, Claude, Gemini,
 ;; Codestral, Ollama, and OpenAI-compatible providers)



[elpa] externals/minuet 330804f9e9 84/97: doc: update special tokens instruction for llama.cpp.

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit 330804f9e947847f92d7883901963115e6d05930
Author: Milan Glacier 
Commit: Milan Glacier 

doc: update special tokens instruction for llama.cpp.
---
 README.md  |  2 +-
 recipes.md | 10 +-
 2 files changed, 10 insertions(+), 2 deletions(-)

diff --git a/README.md b/README.md
index 46b7514686..f97ae24481 100644
--- a/README.md
+++ b/README.md
@@ -187,7 +187,7 @@ llama-server \
  minuet-openai-fim-compatible-options
  :prompt
  (defun minuet-llama-cpp-fim-qwen-prompt-function (ctx)
- (format "%s\n%s<|fim_suffix|>%s<|fim_middle|>"
+ (format "<|fim_prefix|>%s\n%s<|fim_suffix|>%s<|fim_middle|>"
  (plist-get ctx :language-and-tab)
  (plist-get ctx :before-cursor)
  (plist-get ctx :after-cursor)))
diff --git a/recipes.md b/recipes.md
index 8e11099309..9b088d4c90 100644
--- a/recipes.md
+++ b/recipes.md
@@ -59,7 +59,7 @@ llama-server \
  minuet-openai-fim-compatible-options
  :prompt
  (defun minuet-llama-cpp-fim-qwen-prompt-function (ctx)
- (format "%s\n%s<|fim_suffix|>%s<|fim_middle|>"
+ (format "<|fim_prefix|>%s\n%s<|fim_suffix|>%s<|fim_middle|>"
  (plist-get ctx :language-and-tab)
  (plist-get ctx :before-cursor)
  (plist-get ctx :after-cursor)))
@@ -68,6 +68,14 @@ llama-server \
 (minuet-set-optional-options minuet-openai-fim-compatible-options 
:max_tokens 56))
 ```
 
+> [!NOTE]
+> Symbols like `<|fim_begin|>` and `<|fim_suffix|>` are special tokens
+> that serve as prompt boundaries. Some LLMs, like Qwen2.5-Coder, have
+> been trained with specific tokens to better understand prompt
+> composition. Different LLMs use different special tokens during
+> training, so you should adjust these tokens according to your
+> preferred LLM.
+
 ## **Acknowledgment**
 
 - [llama.vim](https://github.com/ggml-org/llama.vim): A reference for CLI 
parameters used in launching the `llama.cpp` server.



[elpa] externals/minuet 31e651d639 76/97: feat!: change claude default model to haiku-3.5.

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit 31e651d639ed6ee0739ab75dca3a0efca4f31389
Author: Milan Glacier 
Commit: Milan Glacier 

feat!: change claude default model to haiku-3.5.
---
 minuet.el | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/minuet.el b/minuet.el
index d3820a97a1..65bef65609 100644
--- a/minuet.el
+++ b/minuet.el
@@ -245,7 +245,7 @@ def fibonacci(n):
 ")))
 
 (defvar minuet-claude-options
-`(:model "claude-3-5-sonnet-20241022"
+`(:model "claude-3-5-haiku-20241022"
   :max_tokens 512
   :api-key "ANTHROPIC_API_KEY"
   :system



[elpa] externals/minuet 37f1607d2a 16/97: chore: standardize indentation using EditorConfig and dir-locals.el.

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit 37f1607d2a9e886c44d08f6f7db03533e8616cf5
Author: Milan Glacier 
Commit: Milan Glacier 

chore: standardize indentation using EditorConfig and dir-locals.el.
---
 .dir-locals.el | 5 +
 .editorconfig  | 6 ++
 2 files changed, 11 insertions(+)

diff --git a/.dir-locals.el b/.dir-locals.el
new file mode 100644
index 00..5bcec0d8c0
--- /dev/null
+++ b/.dir-locals.el
@@ -0,0 +1,5 @@
+((lisp-mode
+  (lisp-body-indent . 4))
+ (emacs-lisp-mode
+  (lisp-body-indent . 4)
+  (editorconfig-lisp-use-default-indent . t)))
diff --git a/.editorconfig b/.editorconfig
new file mode 100644
index 00..07475385e8
--- /dev/null
+++ b/.editorconfig
@@ -0,0 +1,6 @@
+[*]
+trim_trailing_whitespace = true
+
+[*.el]
+indent_style = space
+indent_size = 4
\ No newline at end of file



[elpa] externals/minuet 3ac83dc334 35/97: gitignore: Ignore *.elc files from byte-compilation

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit 3ac83dc3340395d5cf70e1318c4880fc2302af54
Author: Mike Olson 
Commit: Mike Olson 

gitignore: Ignore *.elc files from byte-compilation
---
 .gitignore | 1 +
 1 file changed, 1 insertion(+)

diff --git a/.gitignore b/.gitignore
index ea84c42f8c..cc7ca80deb 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,3 +1,4 @@
 .tags
 .DS_Store
 .aider*
+*.elc



[elpa] externals/minuet 2767e12df9 25/97: chore: remove obsolete function call.

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit 2767e12df9e1426c969f9b6f34ee57a33315bdf0
Author: Milan Glacier 
Commit: Milan Glacier 

chore: remove obsolete function call.
---
 minuet.el | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/minuet.el b/minuet.el
index 6e909a0cd4..2c070af88d 100644
--- a/minuet.el
+++ b/minuet.el
@@ -773,7 +773,7 @@ arrive."
   :filter (minuet--make-process-stream-filter --response--)
   :then
   (lambda (json)
-  (when-let ((result (minuet--stream-decode json 
get-text-fn)))
+  (when-let* ((result (minuet--stream-decode json 
get-text-fn)))
   ;; insert the current result into the completion 
items list
   (push result completion-items))
   (setq completion-items 
(minuet--filter-context-sequence-in-items
@@ -786,7 +786,7 @@ arrive."
   (if (equal (car (plz-error-curl-error err)) 28)
   (progn
   (minuet--log (format "%s Request timeout" 
name))
-  (when-let ((result 
(minuet--stream-decode-raw --response-- get-text-fn)))
+  (when-let* ((result 
(minuet--stream-decode-raw --response-- get-text-fn)))
   (push result completion-items)))
   (minuet--log (format "An error occured when sending 
request to %s" name))
   (minuet--log err))



[elpa] externals/minuet 7c81055c3d 20/97: doc: update README.

2025-03-24 Thread ELPA Syncer
branch: externals/minuet
commit 7c81055c3da8d01879865a7fd557a5c9c9f4d2af
Author: Milan Glacier 
Commit: Milan Glacier 

doc: update README.
---
 README.md | 7 +++
 1 file changed, 7 insertions(+)

diff --git a/README.md b/README.md
index 153fff176c..4c3ef90006 100644
--- a/README.md
+++ b/README.md
@@ -146,6 +146,13 @@ inside the provider options, not the actual value. For 
instance, pass
 If using Ollama, you need to assign an arbitrary, non-null environment
 variable as a placeholder for it to function.
 
+```lisp
+;; Good
+(plist-put minuet-openai-compatible-options :api-key "FIREWORKS_API_KEY")
+;; Bad
+(plist-put minuet-openai-compatible-options :api-key "sk-x")
+```
+
 # Selecting a Provider or Model
 
 The `gemini-flash` and `codestral` models offer high-quality output



  1   2   >