mirror of
https://github.com/MODSetter/SurfSense.git
synced 2026-05-17 18:35:19 +02:00
Add system prompt defaults constant for copy-on-write overrides
This commit is contained in:
parent
0b0806a1be
commit
2024e9b1ed
1 changed files with 76 additions and 0 deletions
76
surfsense_backend/app/prompts/system_defaults.py
Normal file
76
surfsense_backend/app/prompts/system_defaults.py
Normal file
|
|
@ -0,0 +1,76 @@
|
|||
SYSTEM_PROMPT_DEFAULTS: list[dict] = [
|
||||
{
|
||||
"slug": "fix-grammar",
|
||||
"name": "Fix grammar",
|
||||
"prompt": (
|
||||
"Fix the grammar and spelling in the following text."
|
||||
" Return only the corrected text, nothing else.\n\n{selection}"
|
||||
),
|
||||
"mode": "transform",
|
||||
"icon": "check",
|
||||
},
|
||||
{
|
||||
"slug": "make-shorter",
|
||||
"name": "Make shorter",
|
||||
"prompt": (
|
||||
"Make the following text more concise while preserving its meaning."
|
||||
" Return only the shortened text, nothing else.\n\n{selection}"
|
||||
),
|
||||
"mode": "transform",
|
||||
"icon": "minimize",
|
||||
},
|
||||
{
|
||||
"slug": "translate",
|
||||
"name": "Translate",
|
||||
"prompt": (
|
||||
"Translate the following text to English."
|
||||
" If it is already in English, translate it to French."
|
||||
" Return only the translation, nothing else.\n\n{selection}"
|
||||
),
|
||||
"mode": "transform",
|
||||
"icon": "languages",
|
||||
},
|
||||
{
|
||||
"slug": "rewrite",
|
||||
"name": "Rewrite",
|
||||
"prompt": (
|
||||
"Rewrite the following text to improve clarity and readability."
|
||||
" Return only the rewritten text, nothing else.\n\n{selection}"
|
||||
),
|
||||
"mode": "transform",
|
||||
"icon": "pen-line",
|
||||
},
|
||||
{
|
||||
"slug": "summarize",
|
||||
"name": "Summarize",
|
||||
"prompt": (
|
||||
"Summarize the following text concisely."
|
||||
" Return only the summary, nothing else.\n\n{selection}"
|
||||
),
|
||||
"mode": "transform",
|
||||
"icon": "list",
|
||||
},
|
||||
{
|
||||
"slug": "explain",
|
||||
"name": "Explain",
|
||||
"prompt": "Explain the following text in simple terms:\n\n{selection}",
|
||||
"mode": "explore",
|
||||
"icon": "book-open",
|
||||
},
|
||||
{
|
||||
"slug": "ask-knowledge-base",
|
||||
"name": "Ask my knowledge base",
|
||||
"prompt": "Search my knowledge base for information related to:\n\n{selection}",
|
||||
"mode": "explore",
|
||||
"icon": "search",
|
||||
},
|
||||
{
|
||||
"slug": "look-up-web",
|
||||
"name": "Look up on the web",
|
||||
"prompt": "Search the web for information about:\n\n{selection}",
|
||||
"mode": "explore",
|
||||
"icon": "globe",
|
||||
},
|
||||
]
|
||||
|
||||
SYSTEM_PROMPT_SLUGS: set[str] = {p["slug"] for p in SYSTEM_PROMPT_DEFAULTS}
|
||||
Loading…
Add table
Add a link
Reference in a new issue