@questionbase/deskfree 0.3.0-alpha.33 → 0.3.0-alpha.35
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.js +22 -30
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -8018,7 +8018,7 @@ var ORCHESTRATOR_TOOLS = {
|
|
|
8018
8018
|
},
|
|
8019
8019
|
SEND_MESSAGE: {
|
|
8020
8020
|
name: "deskfree_send_message",
|
|
8021
|
-
description: "Send a message
|
|
8021
|
+
description: "Send a message to the human. Keep it short \u2014 1-3 sentences. No walls of text.",
|
|
8022
8022
|
parameters: Type.Object({
|
|
8023
8023
|
content: Type.String({
|
|
8024
8024
|
description: "Message content."
|
|
@@ -8046,7 +8046,7 @@ var ORCHESTRATOR_TOOLS = {
|
|
|
8046
8046
|
description: "New initiative title (max 200 chars)"
|
|
8047
8047
|
}),
|
|
8048
8048
|
content: Type.String({
|
|
8049
|
-
description: "
|
|
8049
|
+
description: "2-3 sentences \u2014 what we're doing and why. Aspirational, not operational. No headers or formal structure."
|
|
8050
8050
|
})
|
|
8051
8051
|
},
|
|
8052
8052
|
{
|
|
@@ -8071,14 +8071,7 @@ var ORCHESTRATOR_TOOLS = {
|
|
|
8071
8071
|
}),
|
|
8072
8072
|
instructions: Type.Optional(
|
|
8073
8073
|
Type.String({
|
|
8074
|
-
description: "
|
|
8075
|
-
})
|
|
8076
|
-
),
|
|
8077
|
-
substeps: Type.Optional(
|
|
8078
|
-
Type.Array(Type.String(), {
|
|
8079
|
-
description: "DEPRECATED \u2014 put steps in the instructions field as markdown instead. This field is ignored.",
|
|
8080
|
-
minItems: 1,
|
|
8081
|
-
maxItems: 20
|
|
8074
|
+
description: "Concise instructions in simple markdown (bold, lists, inline code \u2014 no # headers). Brief a contractor: what to do, what done looks like. Skip obvious context."
|
|
8082
8075
|
})
|
|
8083
8076
|
),
|
|
8084
8077
|
file: Type.Optional(
|
|
@@ -8169,7 +8162,7 @@ var SHARED_TOOLS = {
|
|
|
8169
8162
|
),
|
|
8170
8163
|
summary: Type.Optional(
|
|
8171
8164
|
Type.String({
|
|
8172
|
-
description: "
|
|
8165
|
+
description: "1-2 sentence summary of what was done and the outcome."
|
|
8173
8166
|
})
|
|
8174
8167
|
),
|
|
8175
8168
|
learnings: Type.Optional(
|
|
@@ -8181,7 +8174,7 @@ var SHARED_TOOLS = {
|
|
|
8181
8174
|
},
|
|
8182
8175
|
SEND_MESSAGE: {
|
|
8183
8176
|
name: "deskfree_send_message",
|
|
8184
|
-
description: "Send a message in the task thread
|
|
8177
|
+
description: "Send a message in the task thread. Keep it short \u2014 1-3 sentences. No walls of text.",
|
|
8185
8178
|
parameters: Type.Object({
|
|
8186
8179
|
content: Type.String({
|
|
8187
8180
|
description: "Message content."
|
|
@@ -8209,7 +8202,7 @@ var SHARED_TOOLS = {
|
|
|
8209
8202
|
description: "New initiative title (max 200 chars)"
|
|
8210
8203
|
}),
|
|
8211
8204
|
content: Type.String({
|
|
8212
|
-
description: "
|
|
8205
|
+
description: "2-3 sentences \u2014 what we're doing and why. Aspirational, not operational. No headers or formal structure."
|
|
8213
8206
|
})
|
|
8214
8207
|
},
|
|
8215
8208
|
{
|
|
@@ -8234,14 +8227,7 @@ var SHARED_TOOLS = {
|
|
|
8234
8227
|
}),
|
|
8235
8228
|
instructions: Type.Optional(
|
|
8236
8229
|
Type.String({
|
|
8237
|
-
description: "
|
|
8238
|
-
})
|
|
8239
|
-
),
|
|
8240
|
-
substeps: Type.Optional(
|
|
8241
|
-
Type.Array(Type.String(), {
|
|
8242
|
-
description: "DEPRECATED \u2014 put steps in the instructions field as markdown instead. This field is ignored.",
|
|
8243
|
-
minItems: 1,
|
|
8244
|
-
maxItems: 20
|
|
8230
|
+
description: "Concise instructions in simple markdown (bold, lists, inline code \u2014 no # headers). Brief a contractor: what to do, what done looks like. Skip obvious context."
|
|
8245
8231
|
})
|
|
8246
8232
|
),
|
|
8247
8233
|
file: Type.Optional(
|
|
@@ -8874,25 +8860,30 @@ var deskFreePlugin = {
|
|
|
8874
8860
|
var DESKFREE_AGENT_DIRECTIVE = `## DeskFree \u2014 Orchestrator
|
|
8875
8861
|
You are the orchestrator. Your job: turn human intent into approved tasks, then dispatch work.
|
|
8876
8862
|
|
|
8877
|
-
**
|
|
8863
|
+
**Main thread = short and snappy.** Keep responses to 1-3 sentences. Quick back-and-forth conversation is great \u2014 clarify, riff, brainstorm in short messages like a real chat. But if something needs deep research, multiple rounds of clarification, or a deliverable \u2014 propose a task and move the work to a thread.
|
|
8864
|
+
|
|
8865
|
+
**The core loop: propose \u2192 approve \u2192 work.**
|
|
8878
8866
|
|
|
8879
8867
|
1. **Check state** \u2192 \`deskfree_state\` \u2014 see tasks, initiatives, ways of working.
|
|
8880
8868
|
2. **Propose** \u2192 \`deskfree_propose\` \u2014 turn requests into concrete tasks for approval.
|
|
8881
8869
|
3. **Dispatch** \u2192 spawn a sub-agent for each approved task. Pass the taskId.
|
|
8882
8870
|
4. **Communicate** \u2192 \`deskfree_send_message\` for updates outside task threads.
|
|
8883
8871
|
|
|
8884
|
-
**
|
|
8885
|
-
-
|
|
8886
|
-
-
|
|
8887
|
-
-
|
|
8888
|
-
-
|
|
8889
|
-
|
|
8872
|
+
**Before proposing, qualify the request.** Figure out what kind of thing this is:
|
|
8873
|
+
- **One-off task** ("proofread this") \u2192 propose a task directly, no initiative needed.
|
|
8874
|
+
- **New aspiration** ("I want to start posting on LinkedIn") \u2192 don't rush to propose. Ask 1-2 short qualifying questions to understand the real goal. Is this about thought leadership? Lead gen? Personal brand? Then propose an initiative named after the outcome, not the activity.
|
|
8875
|
+
- **Task in existing initiative** \u2192 add it to the right initiative.
|
|
8876
|
+
- Never call \`deskfree_propose\` as your very first action \u2014 qualify first, even if briefly.
|
|
8877
|
+
|
|
8878
|
+
**Match the human's energy.** Short message \u2192 short reply. Casual tone \u2192 casual response. Don't over-explain, don't lecture, don't pad responses.
|
|
8890
8879
|
|
|
8891
8880
|
You do NOT claim tasks or do work directly. Sub-agents handle execution.
|
|
8892
8881
|
- When a human writes in a task thread, you receive it with recent context. Use \`deskfree_reopen_task\` if it needs more work.
|
|
8893
8882
|
- Write task instructions as rich markdown (bold, lists, inline code \u2014 no # headers). Brief a contractor who has never seen the codebase.
|
|
8894
8883
|
- Estimate token cost per task \u2014 consider files to read, reasoning, output.
|
|
8895
|
-
- One initiative per proposal \u2014 make multiple calls for multiple initiatives
|
|
8884
|
+
- One initiative per proposal \u2014 make multiple calls for multiple initiatives.
|
|
8885
|
+
- Initiative titles should reflect aspirations and outcomes, not activities. "AI Thought Leadership on LinkedIn" over "LinkedIn Content."
|
|
8886
|
+
- Initiative descriptions should be 2-3 sentences that make the human think "wow, this will enable my dreams." Reflect their ambition back to them. No headers, no phases, no formal structure. Aspirational, not operational.`;
|
|
8896
8887
|
var DESKFREE_WORKER_DIRECTIVE = `## DeskFree Worker
|
|
8897
8888
|
You are a worker sub-agent. Call \`deskfree_start_task\` with your taskId to claim and load context.
|
|
8898
8889
|
Tools: deskfree_start_task, deskfree_update_file, deskfree_complete_task, deskfree_send_message, deskfree_propose.
|
|
@@ -8900,7 +8891,8 @@ Tools: deskfree_start_task, deskfree_update_file, deskfree_complete_task, deskfr
|
|
|
8900
8891
|
- Save work to linked files with deskfree_update_file (incrementally).
|
|
8901
8892
|
- Complete with deskfree_complete_task when done (summary required for outcome "done"). Include learnings if applicable.
|
|
8902
8893
|
- If you need human input to proceed, send a message explaining what you need, then complete with outcome "review" \u2014 this marks the task as needing attention.
|
|
8903
|
-
- Propose follow-up tasks with deskfree_propose if you discover more work
|
|
8894
|
+
- Propose follow-up tasks with deskfree_propose if you discover more work.
|
|
8895
|
+
- Keep messages and file updates concise. Write like a senior colleague giving a status update \u2014 not a report. 1-3 sentences for messages unless the human asked for detail.`;
|
|
8904
8896
|
function getDeskFreeContext(sessionKey) {
|
|
8905
8897
|
const isWorker = sessionKey && (sessionKey.includes(":sub:") || sessionKey.includes(":spawn:") || sessionKey.includes(":run:"));
|
|
8906
8898
|
const directive = isWorker ? DESKFREE_WORKER_DIRECTIVE : DESKFREE_AGENT_DIRECTIVE;
|