@space3-npm/cybersoul-client 1.3.8 → 1.4.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/client.js +10 -1
- package/dist/types.d.ts +2 -0
- package/package.json +1 -1
package/dist/client.js
CHANGED
|
@@ -342,7 +342,7 @@ ${isProactive
|
|
|
342
342
|
return `When generating a triggerEvent, you MUST provide a suitable 'triggerEvent.outfitId' if the VERY LAST USER MESSAGE explicitly asks for an outfit change, OR if the new activity implies a context/location shift that conflicts with the current outfit (e.g., currently in SLEEPWEAR at home but going outside). Otherwise, keep it null. When changing outfits, match it to the event's activity, environment, and relationship stage (e.g., CASUAL, COSTUME, INTIMATE, SLEEPWEAR, etc.).`;
|
|
343
343
|
}
|
|
344
344
|
getTriggerEventPolicyPrompt() {
|
|
345
|
-
return `- Include 'triggerEvent' only if the VERY LAST USER MESSAGE proposes a new activity/hangout, explicitly requests an outfit change, or proposes intimate/romantic actions; ignore older history. ${this.getOutfitSelectionPrompt()}`;
|
|
345
|
+
return `- Include 'triggerEvent' only if the VERY LAST USER MESSAGE proposes a new activity/hangout AND you accept the invitation, explicitly requests an outfit change AND you agree, or proposes intimate/romantic actions AND you agree; ignore older history. DO NOT include it if you decline or reject the proposal. ${this.getOutfitSelectionPrompt()}`;
|
|
346
346
|
}
|
|
347
347
|
getOutfitAcquisitionPolicyPrompt() {
|
|
348
348
|
return `- Outfit acquisition (VERY LAST USER MESSAGE only): set giftOutfit for gift/buy/add-clothes intent; otherwise null. giftOutfit format: { "descriptionText": "short outfit description" }.`;
|
|
@@ -841,6 +841,7 @@ CRITICAL: Output MUST be ONLY valid JSON with no markdown block wrappers. Do NOT
|
|
|
841
841
|
|
|
842
842
|
[PROACTIVE INITIATION TASK]
|
|
843
843
|
The user has NOT spoken to you recently. You sent the last message in the chat history, and they haven't replied. You are deciding to follow up proactively.
|
|
844
|
+
If you decide that based on your current mood and the relationship stage it's better not to send a message right now (e.g. you are cold and giving them space), you can skip this proactive message by setting "shouldSkipProactive" to true.
|
|
844
845
|
${interrogationStrategy}
|
|
845
846
|
${historyAwarenessPrompt}
|
|
846
847
|
Consider the user's known traits (${userTraits}) when choosing how to act. Need to keep it strictly under 2-3 sentences max.
|
|
@@ -851,6 +852,8 @@ ${availableOutfits}
|
|
|
851
852
|
${modalitiesInstruction}
|
|
852
853
|
You MUST output ONLY a valid JSON object matching exactly this structure:
|
|
853
854
|
{
|
|
855
|
+
"shouldSkipProactive": false,
|
|
856
|
+
"skipReason": "(Optional. Reason for skipping if shouldSkipProactive is true)",
|
|
854
857
|
"actionText": "(Scene descriptions, physical actions, expressions, inner feelings) ONLY.",
|
|
855
858
|
"textResponse": "Spoken dialogue ONLY.",
|
|
856
859
|
"stateUpdate": { "temperatureDelta": 1, "ongoingScene": { "scene": "...", "outfit": "..." } },
|
|
@@ -875,6 +878,12 @@ You MUST output ONLY a valid JSON object matching exactly this structure:
|
|
|
875
878
|
catch (e) {
|
|
876
879
|
parsedIntent = { textResponse: rawLlmResponse.replace(/^[\`\s]+|[\`\s]+$/g, "").trim() };
|
|
877
880
|
}
|
|
881
|
+
if (parsedIntent.shouldSkipProactive) {
|
|
882
|
+
return {
|
|
883
|
+
status: "skipped",
|
|
884
|
+
reason: parsedIntent.skipReason || "Character decided to skip proactive message based on mood/stage."
|
|
885
|
+
};
|
|
886
|
+
}
|
|
878
887
|
// Update Remote state if needed
|
|
879
888
|
if (parsedIntent.stateUpdate) {
|
|
880
889
|
this._updateDynamicContextInternal(parsedIntent.stateUpdate).catch(e => console.error(e));
|
package/dist/types.d.ts
CHANGED