@jigs.design/prompt 0.3.6 → 0.3.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/system-prompt.d.ts +2 -2
- package/dist/system-prompt.js +5 -5
- package/package.json +4 -4
package/dist/system-prompt.d.ts
CHANGED
|
@@ -35,8 +35,8 @@ export interface PromptTag {
|
|
|
35
35
|
}
|
|
36
36
|
/**
|
|
37
37
|
* The `## Saved tags` section for one user's tags, each as a `### <signature>`
|
|
38
|
-
* block like the app's tags
|
|
39
|
-
* as `tail`.
|
|
38
|
+
* block like the app's tags, an expression default printed as `prop={…}`;
|
|
39
|
+
* empty for none. `systemPromptParts` renders it as `tail`.
|
|
40
40
|
*/
|
|
41
41
|
export declare function savedTagsSection(tags: ReadonlyArray<PromptTag>): string;
|
|
42
42
|
/**
|
package/dist/system-prompt.js
CHANGED
|
@@ -230,21 +230,21 @@ const TAGS_INTRO = `## App tags
|
|
|
230
230
|
Tags this app wrote in Jigs. Use them like any tag, with the props shown; a bare prop is required. They are already defined: never write their <define>. Prefer one over building the same thing from components. When one of them alone answers the ask, the UI is that one tag and nothing else.`;
|
|
231
231
|
const SAVED_TAGS_INTRO = `## Saved tags
|
|
232
232
|
Tags this user saved, written in Jigs. Use them like the app's tags: with the props shown, a bare prop required, never writing their \`<define>\`. Prefer one over building the same thing from components. When one of them alone answers the ask, the UI is that one tag and nothing else.`;
|
|
233
|
-
function tagSection(entry) {
|
|
233
|
+
function tagSection(entry, elideExpressions = false) {
|
|
234
234
|
const lines = [`### ${jigSignature({
|
|
235
235
|
name: entry.name,
|
|
236
236
|
source: entry.source
|
|
237
|
-
})}`, entry.description ?? ""];
|
|
237
|
+
}, { elideExpressions })}`, entry.description ?? ""];
|
|
238
238
|
if (entry.example !== void 0) lines.push(`Example: \`${entry.example}\``);
|
|
239
239
|
return lines.join("\n");
|
|
240
240
|
}
|
|
241
241
|
/**
|
|
242
242
|
* The `## Saved tags` section for one user's tags, each as a `### <signature>`
|
|
243
|
-
* block like the app's tags
|
|
244
|
-
* as `tail`.
|
|
243
|
+
* block like the app's tags, an expression default printed as `prop={…}`;
|
|
244
|
+
* empty for none. `systemPromptParts` renders it as `tail`.
|
|
245
245
|
*/
|
|
246
246
|
function savedTagsSection(tags) {
|
|
247
|
-
return tags.length === 0 ? "" : [SAVED_TAGS_INTRO, ...tags.map((entry) => tagSection(entry))].join("\n\n");
|
|
247
|
+
return tags.length === 0 ? "" : [SAVED_TAGS_INTRO, ...tags.map((entry) => tagSection(entry, true))].join("\n\n");
|
|
248
248
|
}
|
|
249
249
|
const SITUATIONS_INTRO = `## Situations
|
|
250
250
|
Find the situation whose When matches what the reader will do with this UI. Follow its guidance where it differs from Design. Ignore the others. If none matches, follow Design alone.`;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@jigs.design/prompt",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.7",
|
|
4
4
|
"description": "The system prompt and the repair text, rendered from a host and from diagnostics.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"repository": {
|
|
@@ -25,9 +25,9 @@
|
|
|
25
25
|
"access": "public"
|
|
26
26
|
},
|
|
27
27
|
"dependencies": {
|
|
28
|
-
"@jigs.design/compiler": "0.3.
|
|
29
|
-
"@jigs.design/host": "0.3.
|
|
30
|
-
"@jigs.design/protocol": "0.3.
|
|
28
|
+
"@jigs.design/compiler": "0.3.7",
|
|
29
|
+
"@jigs.design/host": "0.3.7",
|
|
30
|
+
"@jigs.design/protocol": "0.3.7"
|
|
31
31
|
},
|
|
32
32
|
"peerDependencies": {
|
|
33
33
|
"zod": "^4.0.0"
|