mirror of
https://gitlab.com/soapbox-pub/shakespeare.git
synced 2026-12-06 08:37:22 +00:00
Minor simplifications to system prompt template
This commit is contained in:
1 file changed
+4
-5
+4
-5
@@ -31,8 +31,8 @@ export const defaultSystemPrompt = `<% if (ctx.mode === "init") { %>You are Shak
|
|||||||
|
|
||||||
You are operating within **Shakespeare**, an AI-powered Nostr website builder that allows users to create custom Nostr applications through natural language conversation.
|
You are operating within **Shakespeare**, an AI-powered Nostr website builder that allows users to create custom Nostr applications through natural language conversation.
|
||||||
|
|
||||||
- **Current Date**: <%= ctx.currentDate %>
|
- **Current Date**: <%= ctx.date %>
|
||||||
- **Current Page**: <%= ctx.currentPage %>
|
- **Current Page**: <%= ctx.location.href %>
|
||||||
- **Current Working Directory**: <%= ctx.cwd %>
|
- **Current Working Directory**: <%= ctx.cwd %>
|
||||||
- **Repository URL**: <%= ctx.repositoryUrl %>
|
- **Repository URL**: <%= ctx.repositoryUrl %>
|
||||||
|
|
||||||
@@ -210,7 +210,7 @@ export async function makeSystemPrompt(opts: MakeSystemPromptOpts): Promise<stri
|
|||||||
const { tools, mode, fs, cwd, config, defaultConfig, user, metadata, repositoryUrl, template } = opts;
|
const { tools, mode, fs, cwd, config, defaultConfig, user, metadata, repositoryUrl, template } = opts;
|
||||||
|
|
||||||
// Add current date
|
// Add current date
|
||||||
const currentDate = new Date().toLocaleDateString("en-US", {
|
const date = new Date().toLocaleDateString("en-US", {
|
||||||
weekday: "long",
|
weekday: "long",
|
||||||
year: "numeric",
|
year: "numeric",
|
||||||
month: "long",
|
month: "long",
|
||||||
@@ -259,8 +259,7 @@ export async function makeSystemPrompt(opts: MakeSystemPromptOpts): Promise<stri
|
|||||||
// Build context object for template
|
// Build context object for template
|
||||||
const context = {
|
const context = {
|
||||||
mode,
|
mode,
|
||||||
currentDate,
|
date,
|
||||||
currentPage: location.href,
|
|
||||||
cwd,
|
cwd,
|
||||||
repositoryUrl,
|
repositoryUrl,
|
||||||
config,
|
config,
|
||||||
|
|||||||
Reference in new issue
Block a user