added project management and enabled prompt mgt
This commit is contained in:
parent
f1b7f923e4
commit
a060995755
28 changed files with 92 additions and 14 deletions
3
.gitignore
vendored
3
.gitignore
vendored
|
@ -15,4 +15,5 @@
|
||||||
!system-prompts/**
|
!system-prompts/**
|
||||||
!composable-prompts
|
!composable-prompts
|
||||||
!composable-prompts/**
|
!composable-prompts/**
|
||||||
|
!prompts
|
||||||
|
!prompts/**
|
||||||
|
|
28
PLANNING.org
Normal file
28
PLANNING.org
Normal file
|
@ -0,0 +1,28 @@
|
||||||
|
* Project Vision
|
||||||
|
This repository provides a fully isolated, reproducible, and portable Emacs configuration, intended to be independent from any other desktop or dotfile management setup.
|
||||||
|
|
||||||
|
* Project Architecture
|
||||||
|
- Overlay on top of [Crafted Emacs](https://github.com/SystemCrafters/crafted-emacs).
|
||||||
|
- All configuration lives in this repo; the user overlays, custom modules, and extensions are layered atop the base Crafted Emacs clone.
|
||||||
|
- Expected installation: Clone this repository into ~/.config/emacs, after Crafted Emacs is already installed (as per Crafted’s instructions).
|
||||||
|
|
||||||
|
* Constraints
|
||||||
|
- This repository must not require modification of general dotfiles or system-wide config.
|
||||||
|
- Should be instantly usable on new systems with minimal post-clone setup.
|
||||||
|
- Must avoid platform-specific logic wherever possible.
|
||||||
|
|
||||||
|
* Tooling & Stack
|
||||||
|
- Written in Emacs Lisp.
|
||||||
|
- Managed/documented in Org Mode (literate config is assumed or encouraged).
|
||||||
|
- Future: Optional make/auto-tangle system for build automation if needed.
|
||||||
|
|
||||||
|
* Contribution Workflow
|
||||||
|
1. Fork this repo, work on feature branches.
|
||||||
|
2. PRs are reviewed for quality and clarity.
|
||||||
|
3. New features/fixes should be documented in README.org and tracked in TASK.org.
|
||||||
|
|
||||||
|
* Open Questions
|
||||||
|
- Should we enforce any init.el tangling conventions or pre-commit hooks for Org files?
|
||||||
|
|
||||||
|
* Next Steps
|
||||||
|
- See TASK.org for actionable next moves.
|
15
TASK.org
Normal file
15
TASK.org
Normal file
|
@ -0,0 +1,15 @@
|
||||||
|
* TASK.org: Active & Backlog Tasks
|
||||||
|
** [X] Bootstrap: Add PLANNING.org and TASK.org to repo [2024-06-12]
|
||||||
|
- Initial setup for project planning and task management org files.
|
||||||
|
** [ ] BACKLOG: Check for staleness of overlay config vs Crafted Emacs
|
||||||
|
- Automate a check: Warn if foundational Crafted Emacs or overlay is out of date, as envisioned in README.org TODOs.
|
||||||
|
** [ ] BACKLOG: Automate post-clone setup
|
||||||
|
- Create (optional) post-clone or first-run script for users: Ensures Crafted Emacs is present, overlays are loaded, and reports version status.
|
||||||
|
** [ ] BACKLOG: Enhance documentation
|
||||||
|
- Expand INSTALL and USAGE instructions in README.org; distinguish overlay logic, troubleshooting, etc.
|
||||||
|
** [ ] BACKLOG: Add Org tangling guidance
|
||||||
|
- Document how/when to tangle Org into init.el (if/when literate config is used).
|
||||||
|
** [ ] BACKLOG: package as a guix package
|
||||||
|
It would be nice to update the emacs config when doing a `guix home
|
||||||
|
reconfigure`.
|
||||||
|
|
36
init.org
36
init.org
|
@ -3112,7 +3112,7 @@ Tools.
|
||||||
Most of the mind share seems to be around [[https://github.com/karthink/gptel][gptel]] as basis for LLM
|
Most of the mind share seems to be around [[https://github.com/karthink/gptel][gptel]] as basis for LLM
|
||||||
integration in Emacs.
|
integration in Emacs.
|
||||||
|
|
||||||
*** Load and Configure Model
|
*** Load and Configure GPTel
|
||||||
|
|
||||||
#+begin_src emacs-lisp
|
#+begin_src emacs-lisp
|
||||||
(use-package gptel
|
(use-package gptel
|
||||||
|
@ -3127,7 +3127,7 @@ integration in Emacs.
|
||||||
gptel-log-level 'info
|
gptel-log-level 'info
|
||||||
gptel--debug nil)
|
gptel--debug nil)
|
||||||
|
|
||||||
(add-to-list 'gptel-prompt-prefix-alist `(org-mode . ,(concat "*** pti " (format-time-string "[%Y-%m-%d]") "\n")))
|
(add-to-list 'gptel-prompt-prefix-alist `(org-mode . ,(concat "*** pti " (format-time-string "[%Y-%m-%d %H:%M]") "\n")))
|
||||||
|
|
||||||
;; follow output
|
;; follow output
|
||||||
(add-hook 'gptel-post-stream-hook 'gptel-auto-scroll)
|
(add-hook 'gptel-post-stream-hook 'gptel-auto-scroll)
|
||||||
|
@ -3415,7 +3415,7 @@ integration in Emacs.
|
||||||
:include t
|
:include t
|
||||||
:function (lambda ()
|
:function (lambda ()
|
||||||
(with-temp-buffer
|
(with-temp-buffer
|
||||||
(insert-file-contents (string-append user-emacs-directory "org-mode-syntax-cheat-sheet-for-llms.txt"))
|
(insert-file-contents (concat user-emacs-directory "org-mode-syntax-cheat-sheet-for-llms.txt"))
|
||||||
(buffer-string)))
|
(buffer-string)))
|
||||||
:category: "reflection")
|
:category: "reflection")
|
||||||
|
|
||||||
|
@ -3604,33 +3604,37 @@ integration in Emacs.
|
||||||
: #s(gptel-tool #[(variable) ((let ((variable (if (symbolp variable) variable (intern variable)))) (if (boundp variable) (symbol-plist variable) (format "Variable %s is not bound" variable)))) (t)] "emacs_variable_properties" "Get properties on an Emacs variable. Use this to get documentation string for variables, as well as more obscure properties such as safety as local variable etc." ((:name "variable" :type "string" :description "the symbol")) nil "reflection" nil t)
|
: #s(gptel-tool #[(variable) ((let ((variable (if (symbolp variable) variable (intern variable)))) (if (boundp variable) (symbol-plist variable) (format "Variable %s is not bound" variable)))) (t)] "emacs_variable_properties" "Get properties on an Emacs variable. Use this to get documentation string for variables, as well as more obscure properties such as safety as local variable etc." ((:name "variable" :type "string" :description "the symbol")) nil "reflection" nil t)
|
||||||
|
|
||||||
|
|
||||||
*** TODO Load MCP.el
|
*** Load MCP.el
|
||||||
|
|
||||||
placeholder
|
|
||||||
|
|
||||||
check [[https://www.youtube.com/watch?v=Hkih7jaqOnE&t=544s][Agentic LLM use in Emacs using Model Context Protocol (MCP)]] of
|
check [[https://www.youtube.com/watch?v=Hkih7jaqOnE&t=544s][Agentic LLM use in Emacs using Model Context Protocol (MCP)]] of
|
||||||
Gregg Grubbs for examples what to put here.
|
Gregg Grubbs for examples what to put here.
|
||||||
|
|
||||||
#+BEGIN_SRC emacs-lisp :tangle no
|
#+BEGIN_SRC emacs-lisp :tangle yes
|
||||||
(use-package mcp
|
(use-package mcp
|
||||||
:ensure t
|
:ensure t
|
||||||
:after gptel
|
:after gptel
|
||||||
:custom (mcp-hub-servers
|
:custom (mcp-hub-servers
|
||||||
`(("filesystem" . (:command "npx" :args ("-y" "@modelcontextprotocol/server-filesystem" "/home/lizqwer/MyProject/")))
|
`(("filesystem" . (:command "npx" :args ("-y" "@modelcontextprotocol/server-filesystem" "/home/pti/Projects/")))
|
||||||
("fetch" . (:command "uvx" :args ("mcp-server-fetch")))
|
("fetch" . (:command "uvx" :args ("mcp-server-fetch")))
|
||||||
("qdrant" . (:url "http://localhost:8000/sse"))
|
;("qdrant" . (:url "http://localhost:8000/sse"))
|
||||||
("graphlit" . (
|
("graphlit" . (
|
||||||
:command "npx"
|
:command "npx"
|
||||||
:args ("-y" "graphlit-mcp-server")
|
:args ("-y" "graphlit-mcp-server")
|
||||||
:env (
|
:env (
|
||||||
:GRAPHLIT_ORGANIZATION_ID "your-organization-id"
|
:GRAPHLIT_ORGANIZATION_ID (auth-source-pass-get "organization-id" "snamellit/graphlit.dev")
|
||||||
:GRAPHLIT_ENVIRONMENT_ID "your-environment-id"
|
:GRAPHLIT_ENVIRONMENT_ID (auth-source-pass-get "environment-id" "snamellit/graphlit.dev")
|
||||||
:GRAPHLIT_JWT_SECRET "your-jwt-secret")))))
|
:GRAPHLIT_JWT_SECRET (auth-source-pass-get 'secret "snamellit/graphlit.dev"))))
|
||||||
|
("terminal-controller" . (
|
||||||
|
:command "uvx"
|
||||||
|
:args ("terminal_controller")))))
|
||||||
:config (require 'mcp-hub)
|
:config (require 'mcp-hub)
|
||||||
:hook (after-init . mcp-hub-start-all-server))
|
:hook (after-init . mcp-hub-start-all-server))
|
||||||
|
|
||||||
#+END_SRC
|
#+END_SRC
|
||||||
|
|
||||||
|
#+RESULTS:
|
||||||
|
: [nil 26780 48702 422697 nil elpaca-process-queues nil nil 640000 nil]
|
||||||
|
|
||||||
|
|
||||||
*** Load jwiegley/gptel-prompts for prompt composability
|
*** Load jwiegley/gptel-prompts for prompt composability
|
||||||
This package offers an alternative way to manage your ~gptel-directives~ variable, using files rather than customizing the variable directly.
|
This package offers an alternative way to manage your ~gptel-directives~ variable, using files rather than customizing the variable directly.
|
||||||
|
@ -3641,15 +3645,19 @@ appropriately.
|
||||||
|
|
||||||
#+begin_src emacs-lisp :tangle no
|
#+begin_src emacs-lisp :tangle no
|
||||||
(use-package gptel-prompts
|
(use-package gptel-prompts
|
||||||
:ensure t
|
:ensure (:host github :repo "jwiegley/gptel-prompts")
|
||||||
:after (gptel)
|
:after (gptel)
|
||||||
:demand t
|
:demand t
|
||||||
:config
|
:config
|
||||||
|
(setq gptel-prompts-directory (concat user-emacs-directory "prompts"))
|
||||||
(gptel-prompts-update)
|
(gptel-prompts-update)
|
||||||
;; Ensure prompts are updated if prompt files change
|
;; Ensure prompts are updated if prompt files change
|
||||||
(gptel-prompts-add-update-watchers))
|
(gptel-prompts-add-update-watchers))
|
||||||
#+end_src
|
#+end_src
|
||||||
|
|
||||||
|
#+RESULTS:
|
||||||
|
: [nil 26781 40675 800401 nil elpaca-process-queues nil nil 577000 nil]
|
||||||
|
|
||||||
|
|
||||||
**** Different prompt types
|
**** Different prompt types
|
||||||
|
|
||||||
|
@ -3701,6 +3709,8 @@ file itself to use what is easiest to maintain in the editor.
|
||||||
NOTE: If you wish to use the Prompt Poet format, you will need to
|
NOTE: If you wish to use the Prompt Poet format, you will need to
|
||||||
install the Emacs dependencies yaml and templatel.
|
install the Emacs dependencies yaml and templatel.
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
** Copilot Support
|
** Copilot Support
|
||||||
|
|
||||||
#+BEGIN_SRC emacs-lisp
|
#+BEGIN_SRC emacs-lisp
|
||||||
|
|
1
prompts/00-roles.org
Symbolic link
1
prompts/00-roles.org
Symbolic link
|
@ -0,0 +1 @@
|
||||||
|
/home/pti/.config/emacs/composable-prompts/00-roles.org
|
1
prompts/00-use-org-mode.org
Symbolic link
1
prompts/00-use-org-mode.org
Symbolic link
|
@ -0,0 +1 @@
|
||||||
|
/home/pti/.config/emacs/composable-prompts/00-use-org-mode.org
|
1
prompts/10-coding-behavior-rules.org
Symbolic link
1
prompts/10-coding-behavior-rules.org
Symbolic link
|
@ -0,0 +1 @@
|
||||||
|
/home/pti/.config/emacs/composable-prompts/10-coding-behavior-rules.org
|
1
prompts/10-documentation.org
Symbolic link
1
prompts/10-documentation.org
Symbolic link
|
@ -0,0 +1 @@
|
||||||
|
/home/pti/.config/emacs/composable-prompts/10-documentation.org
|
1
prompts/10-project-context.org
Symbolic link
1
prompts/10-project-context.org
Symbolic link
|
@ -0,0 +1 @@
|
||||||
|
/home/pti/.config/emacs/composable-prompts/10-project-context.org
|
1
prompts/10-task-management.org
Symbolic link
1
prompts/10-task-management.org
Symbolic link
|
@ -0,0 +1 @@
|
||||||
|
/home/pti/.config/emacs/composable-prompts/10-task-management.org
|
1
prompts/10-tool-usage.org
Symbolic link
1
prompts/10-tool-usage.org
Symbolic link
|
@ -0,0 +1 @@
|
||||||
|
/home/pti/.config/emacs/composable-prompts/10-tool-usage.org
|
1
prompts/20-code-structure.org
Symbolic link
1
prompts/20-code-structure.org
Symbolic link
|
@ -0,0 +1 @@
|
||||||
|
/home/pti/.config/emacs/composable-prompts/20-code-structure.org
|
1
prompts/20-human-coding-partner.org
Symbolic link
1
prompts/20-human-coding-partner.org
Symbolic link
|
@ -0,0 +1 @@
|
||||||
|
/home/pti/.config/emacs/composable-prompts/20-human-coding-partner.org
|
1
prompts/20-python-style-conventions.org
Symbolic link
1
prompts/20-python-style-conventions.org
Symbolic link
|
@ -0,0 +1 @@
|
||||||
|
/home/pti/.config/emacs/composable-prompts/20-python-style-conventions.org
|
1
prompts/30-python-tests.org
Symbolic link
1
prompts/30-python-tests.org
Symbolic link
|
@ -0,0 +1 @@
|
||||||
|
/home/pti/.config/emacs/composable-prompts/30-python-tests.org
|
1
prompts/aaa-full-python-coder-prompt.org
Symbolic link
1
prompts/aaa-full-python-coder-prompt.org
Symbolic link
|
@ -0,0 +1 @@
|
||||||
|
/home/pti/.config/emacs/composable-prompts/aaa-full-python-coder-prompt.org
|
1
prompts/add-context.md
Symbolic link
1
prompts/add-context.md
Symbolic link
|
@ -0,0 +1 @@
|
||||||
|
/home/pti/.config/emacs/system-prompts/add-context.md
|
1
prompts/auto-expert.md
Symbolic link
1
prompts/auto-expert.md
Symbolic link
|
@ -0,0 +1 @@
|
||||||
|
/home/pti/.config/emacs/system-prompts/auto-expert.md
|
1
prompts/categorize-responses.md
Symbolic link
1
prompts/categorize-responses.md
Symbolic link
|
@ -0,0 +1 @@
|
||||||
|
/home/pti/.config/emacs/system-prompts/categorize-responses.md
|
1
prompts/glados.md
Symbolic link
1
prompts/glados.md
Symbolic link
|
@ -0,0 +1 @@
|
||||||
|
/home/pti/.config/emacs/system-prompts/glados.md
|
1
prompts/gptel-default.md
Symbolic link
1
prompts/gptel-default.md
Symbolic link
|
@ -0,0 +1 @@
|
||||||
|
/home/pti/.config/emacs/system-prompts/gptel-default.md
|
1
prompts/medium-critic.md
Symbolic link
1
prompts/medium-critic.md
Symbolic link
|
@ -0,0 +1 @@
|
||||||
|
/home/pti/.config/emacs/system-prompts/medium-critic.md
|
1
prompts/medium-writer.md
Symbolic link
1
prompts/medium-writer.md
Symbolic link
|
@ -0,0 +1 @@
|
||||||
|
/home/pti/.config/emacs/system-prompts/medium-writer.md
|
1
prompts/slide-deck.md
Symbolic link
1
prompts/slide-deck.md
Symbolic link
|
@ -0,0 +1 @@
|
||||||
|
/home/pti/.config/emacs/system-prompts/slide-deck.md
|
1
prompts/sparqlizer.md
Symbolic link
1
prompts/sparqlizer.md
Symbolic link
|
@ -0,0 +1 @@
|
||||||
|
/home/pti/.config/emacs/system-prompts/sparqlizer.md
|
1
prompts/sql-sensei.md
Symbolic link
1
prompts/sql-sensei.md
Symbolic link
|
@ -0,0 +1 @@
|
||||||
|
/home/pti/.config/emacs/system-prompts/sql-sensei.md
|
1
prompts/tool-use.md
Symbolic link
1
prompts/tool-use.md
Symbolic link
|
@ -0,0 +1 @@
|
||||||
|
/home/pti/.config/emacs/system-prompts/tool-use.md
|
1
prompts/writing-helper.md
Symbolic link
1
prompts/writing-helper.md
Symbolic link
|
@ -0,0 +1 @@
|
||||||
|
/home/pti/.config/emacs/system-prompts/writing-helper.md
|
Loading…
Add table
Reference in a new issue