Menu

#6 [Discussion] Plugin / scripting system for custom prompt wrappers

open
nobody
2026-05-24
2026-05-24
Anonymous
No

Originally created by: phantasmat2018

Status: Wishlist / open discussion.

Idea: allow users to write custom "prompt wrappers" - small scripts that have access to runtime variables (selected text, clipboard, current time, active window title) and can compose prompts dynamically before sending to the LLM.

Example use cases

  • "Translate to language of the user's system locale" (use CultureInfo automatically)
  • "Summarize but include the source URL if visible in the active window title"
  • "Apply different prompts based on which app is active" (Word vs Slack vs IDE)
  • "Inject today's date into the prompt automatically"

Potential implementations

  1. Lua via NLua - small footprint, sandboxable, well-supported
  2. JavaScript via Jint - bigger, more familiar to users, harder to sandbox
  3. CSX (C# scripting) via Microsoft.CodeAnalysis.Scripting - type-safe but heavyweight

Risks

  • Security: arbitrary user code runs in our process. Scripts should NOT be able to read arbitrary files / network without explicit user consent.
  • API design: what variables are exposed? What helpers? Need a stable contract.
  • UI: where do scripts live? In-app editor? Or just file paths?

Discussion

What would you actually script? Comment with use cases - if there's clear demand for specific patterns, we can implement those without a full scripting runtime.

Discussion


Log in to post a comment.

Auth0 Logo