@nodaro/shared 2.22.0 → 2.23.0
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/index.cjs.map +1 -1
- package/dist/index.d.cts +43 -1
- package/dist/index.d.ts +43 -1
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
- package/src/index.ts +1 -0
- package/src/types.ts +43 -0
package/package.json
CHANGED
package/src/index.ts
CHANGED
package/src/types.ts
CHANGED
|
@@ -214,6 +214,49 @@ export interface ConnectedReference {
|
|
|
214
214
|
* The single new structured-shape field for external (API/MCP/SDK) parity.
|
|
215
215
|
*/
|
|
216
216
|
readonly identityLock?: { enabled: boolean; text?: string }
|
|
217
|
+
/**
|
|
218
|
+
* PER-USE identity description for this reference — what the caller wants the
|
|
219
|
+
* model told about this subject THIS TIME, overriding whatever the entity's
|
|
220
|
+
* library record says. Wherever a reference's identity description already
|
|
221
|
+
* renders (the legacy identity bullet's `— <desc>` part, a `{image:N:label}`
|
|
222
|
+
* directive's descriptor) it WINS over `characterCanonicalDescription` /
|
|
223
|
+
* `locationCanonicalDescription` / `description`; where the HYBRID format
|
|
224
|
+
* renders no description at all, it adds one trailing `<binding> — <override>.`
|
|
225
|
+
* line instead.
|
|
226
|
+
*
|
|
227
|
+
* The two formats are deliberately ASYMMETRIC where a reference renders no
|
|
228
|
+
* directive at all — a plain upload (`manual` / `wired-image`, non-extra) that
|
|
229
|
+
* is neither `@`-mentioned nor `{image:N}`-covered: the LEGACY format stays
|
|
230
|
+
* silent, and the override is not surfaced there (a bullet would force a
|
|
231
|
+
* fidelity verb onto an opaque image); the HYBRID format — the production
|
|
232
|
+
* default — adds the trailing line above for it.
|
|
233
|
+
*
|
|
234
|
+
* DISTINCT from `description`, which stays the reference's own label slot (the
|
|
235
|
+
* free text an extra-ref row / an upstream node carries) — a caller that edits
|
|
236
|
+
* the wording for ONE use writes it here, so the label is untouched and
|
|
237
|
+
* dropping the override falls back to the library wording. Absent →
|
|
238
|
+
* byte-identical to a caller that never sent it.
|
|
239
|
+
*/
|
|
240
|
+
readonly descriptionOverride?: string
|
|
241
|
+
}
|
|
242
|
+
|
|
243
|
+
/**
|
|
244
|
+
* A reference the caller can NAME and DESCRIBE but has no media for — a cast
|
|
245
|
+
* role no entity has been bound to yet, an analysis slot, a character the author
|
|
246
|
+
* has only written down. It carries no `url`, so it attaches no reference image
|
|
247
|
+
* and claims no `@image_N` seat; it reaches the model purely as prose
|
|
248
|
+
* (`<Name> — <description>.`), rendered in ONE place per lane by
|
|
249
|
+
* `@nodaro/prompts`' `renderDescribedReferenceLines`.
|
|
250
|
+
*
|
|
251
|
+
* Correlation with the prompt body is BY NAME: the caller leaves the name in the
|
|
252
|
+
* prose (never an indexed `@slug:N` mention — that grammar is url-gated) and the
|
|
253
|
+
* described line tells the model who that name is.
|
|
254
|
+
*/
|
|
255
|
+
export interface DescribedReference {
|
|
256
|
+
/** Display name exactly as it appears in the prompt prose (e.g. "Natalie"). */
|
|
257
|
+
readonly name: string
|
|
258
|
+
/** What the model should picture when it reads that name. */
|
|
259
|
+
readonly description: string
|
|
217
260
|
}
|
|
218
261
|
|
|
219
262
|
/** Default label per source — used by `@` autocomplete and inventory fallback. */
|