Skip to content

rajp152k/fabric-gpt.el

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 

Repository files navigation

Fabric Prompts for gptel

fabric crowd sources prompts, gptel is a versatile LLM client for emacs. I wanted fabric prompts to be usable via gptel.

Overview

  • pickup the fabric patterns subdirectory via a no-cone sparse checkout
  • filter patterns that have a system prompt available based on a “system.md exists” predicate
  • a completing read then allows to hit gptel-send with the selected pattern, without altering your existing custom gptel-message

Installation

Doom Emacs

In your packages.el, after your gptel fetch:

(package! fabric-gpt.el
  :recipe (:host github :repo "/rajp152k/fabric-gpt.el"))

In your config.el, after your gptel config:

(use-package! fabric-gpt.el
  :after gptel
  :config
  (setq fabric-gpt.el-root "<root dir to cache fabric patterns>")
  (fabric-gpt.el-sync-patterns))

Usage

fabric-gpt.el-send

This is the primary exposure for utilizing fabric patterns.

I would recommend you bind (fabric-gptel-send) to something handy, I use “leader i g f f” as it is mnemonically aligned with what gptel exposes via “leader i g [hsm]”

Upon invocation, a completing read will ask for the desired pattern (with all the bells and whistles of your favourite completion engine (I’m using vertico))

Syncing patterns

I bind (fabric-gpt.el-sync-patterns) to “leader i g f s” to fetch any new patterns from the fabric upstream

These are pulled into your <fabric-gpt.el-root>/fabric

Close Future

  • better documentation
  • youtube tutorial
  • testing and polishing the edges

Contributing

  • suggestions, ideas, bug reports, PRs welcome
  • I do need to refine this a lot

About

Fabric Prompts for emacs gpt.el

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published