@dxos/assistant-toolkit 0.8.4-main.74a063c4e0 → 0.8.4-main.765dc60934
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/LICENSE +102 -5
- package/dist/lib/neutral/{add-artifact-W2CRMEAZ.mjs → add-artifact-4IVGW6CI.mjs} +11 -11
- package/dist/lib/neutral/add-artifact-4IVGW6CI.mjs.map +7 -0
- package/dist/lib/neutral/agent-F4L7UXME.mjs +65 -0
- package/dist/lib/neutral/agent-F4L7UXME.mjs.map +7 -0
- package/dist/lib/neutral/{chunk-2SH4XUQR.mjs → chunk-5GPL2WXU.mjs} +121 -68
- package/dist/lib/neutral/chunk-5GPL2WXU.mjs.map +7 -0
- package/dist/lib/neutral/{chunk-AKMBURAD.mjs → chunk-7UCYAP3T.mjs} +30 -18
- package/dist/lib/neutral/chunk-7UCYAP3T.mjs.map +7 -0
- package/dist/lib/neutral/{chunk-6DPL2YY5.mjs → chunk-ANSF2BHN.mjs} +5 -6
- package/dist/lib/neutral/chunk-ANSF2BHN.mjs.map +7 -0
- package/dist/lib/neutral/chunk-BCT55UTL.mjs +75 -0
- package/dist/lib/neutral/chunk-BCT55UTL.mjs.map +7 -0
- package/dist/lib/neutral/{chunk-TKJH3CAH.mjs → chunk-COL54UJ3.mjs} +18 -11
- package/dist/lib/neutral/chunk-COL54UJ3.mjs.map +7 -0
- package/dist/lib/neutral/{chunk-BO4ZVH7M.mjs → chunk-EJAQUAKM.mjs} +3 -3
- package/dist/lib/neutral/chunk-EJAQUAKM.mjs.map +7 -0
- package/dist/lib/neutral/{chunk-YBTLIXQK.mjs → chunk-KGU725LW.mjs} +2 -2
- package/dist/lib/neutral/{chunk-YBTLIXQK.mjs.map → chunk-KGU725LW.mjs.map} +3 -3
- package/dist/lib/neutral/{chunk-B2PLQKOJ.mjs → chunk-KS3IA6FQ.mjs} +31 -33
- package/dist/lib/neutral/chunk-KS3IA6FQ.mjs.map +7 -0
- package/dist/lib/neutral/chunk-MMQ7HFL4.mjs +107 -0
- package/dist/lib/neutral/chunk-MMQ7HFL4.mjs.map +7 -0
- package/dist/lib/neutral/{chunk-VBSCQN37.mjs → chunk-NR3GTWRC.mjs} +4 -3
- package/dist/lib/neutral/chunk-NR3GTWRC.mjs.map +7 -0
- package/dist/lib/neutral/chunk-PLGEBNTO.mjs +65 -0
- package/dist/lib/neutral/chunk-PLGEBNTO.mjs.map +7 -0
- package/dist/lib/neutral/chunk-W2722TC5.mjs +70 -0
- package/dist/lib/neutral/chunk-W2722TC5.mjs.map +7 -0
- package/dist/lib/neutral/{chunk-MEZ4UFR6.mjs → chunk-WLR3BGO4.mjs} +2 -2
- package/dist/lib/neutral/chunk-WLR3BGO4.mjs.map +7 -0
- package/dist/lib/neutral/{chunk-AGG6OZNB.mjs → chunk-ZFXLTBZG.mjs} +4 -5
- package/dist/lib/neutral/chunk-ZFXLTBZG.mjs.map +7 -0
- package/dist/lib/neutral/{context-add-U5LSEQLG.mjs → context-add-S5MBW2NA.mjs} +5 -5
- package/dist/lib/neutral/context-add-S5MBW2NA.mjs.map +7 -0
- package/dist/lib/neutral/{context-remove-3YGXLVRA.mjs → context-remove-35O5T5N5.mjs} +5 -5
- package/dist/lib/neutral/context-remove-35O5T5N5.mjs.map +7 -0
- package/dist/lib/neutral/create-project-3AGXJ4TD.mjs +35 -0
- package/dist/lib/neutral/create-project-3AGXJ4TD.mjs.map +7 -0
- package/dist/lib/neutral/{delete-LHMZDJFA.mjs → delete-J3PMWP7Z.mjs} +4 -4
- package/dist/lib/neutral/delete-J3PMWP7Z.mjs.map +7 -0
- package/dist/lib/neutral/{enable-blueprints-4UMPKGUD.mjs → enable-blueprints-IVKST3WH.mjs} +5 -6
- package/dist/lib/neutral/enable-blueprints-IVKST3WH.mjs.map +7 -0
- package/dist/lib/neutral/{fetch-TLKREIZA.mjs → fetch-KHMHV7JR.mjs} +3 -3
- package/dist/lib/neutral/{fetch-TLKREIZA.mjs.map → fetch-KHMHV7JR.mjs.map} +1 -1
- package/dist/lib/neutral/{fetch-messages-AFX7ZAVE.mjs → fetch-messages-QOBBCTGC.mjs} +9 -24
- package/dist/lib/neutral/fetch-messages-QOBBCTGC.mjs.map +7 -0
- package/dist/lib/neutral/get-context-FBYWIP72.mjs +35 -0
- package/dist/lib/neutral/get-context-FBYWIP72.mjs.map +7 -0
- package/dist/lib/neutral/index.mjs +808 -142
- package/dist/lib/neutral/index.mjs.map +4 -4
- package/dist/lib/neutral/{load-KHLICMGJ.mjs → load-GAT3T2AD.mjs} +3 -3
- package/dist/lib/neutral/{load-KHLICMGJ.mjs.map → load-GAT3T2AD.mjs.map} +3 -3
- package/dist/lib/neutral/meta.json +1 -1
- package/dist/lib/neutral/{object-create-7J7D53FT.mjs → object-create-PL3WRP74.mjs} +5 -13
- package/dist/lib/neutral/object-create-PL3WRP74.mjs.map +7 -0
- package/dist/lib/neutral/{object-delete-QFXUHJ2D.mjs → object-delete-PZJQN5KW.mjs} +3 -3
- package/dist/lib/neutral/object-delete-PZJQN5KW.mjs.map +7 -0
- package/dist/lib/neutral/{object-update-C73HRM5F.mjs → object-update-R43N3VJX.mjs} +4 -4
- package/dist/lib/neutral/object-update-R43N3VJX.mjs.map +7 -0
- package/dist/lib/neutral/project-VVXXUMAI.mjs +23 -0
- package/dist/lib/neutral/{project-rules-IYRR6OQE.mjs → project-rules-KSVSOZJV.mjs} +24 -23
- package/dist/lib/neutral/project-rules-KSVSOZJV.mjs.map +7 -0
- package/dist/lib/neutral/{prompt-MWQPSPDW.mjs → prompt-INL55Q2B.mjs} +43 -66
- package/dist/lib/neutral/prompt-INL55Q2B.mjs.map +7 -0
- package/dist/lib/neutral/{qualifier-KIBSTV6F.mjs → qualifier-DAF4H7V3.mjs} +30 -46
- package/dist/lib/neutral/qualifier-DAF4H7V3.mjs.map +7 -0
- package/dist/lib/neutral/{query-ZMWWZ4I3.mjs → query-MP5NSQKO.mjs} +8 -6
- package/dist/lib/neutral/query-MP5NSQKO.mjs.map +7 -0
- package/dist/lib/neutral/{query-MN5B3MQF.mjs → query-U56GNEV6.mjs} +4 -4
- package/dist/lib/neutral/query-U56GNEV6.mjs.map +7 -0
- package/dist/lib/neutral/{query-blueprints-EKHEZAGD.mjs → query-blueprints-PLWYVOI3.mjs} +3 -4
- package/dist/lib/neutral/query-blueprints-PLWYVOI3.mjs.map +7 -0
- package/dist/lib/neutral/{relation-create-YWV2TUKS.mjs → relation-create-YAAAFTR2.mjs} +5 -13
- package/dist/lib/neutral/relation-create-YAAAFTR2.mjs.map +7 -0
- package/dist/lib/neutral/{relation-delete-JGGA4CYQ.mjs → relation-delete-IEPKERFR.mjs} +3 -3
- package/dist/lib/neutral/relation-delete-IEPKERFR.mjs.map +7 -0
- package/dist/lib/neutral/{save-ZWWNTBOD.mjs → save-GWAPLT3Z.mjs} +4 -4
- package/dist/lib/neutral/save-GWAPLT3Z.mjs.map +7 -0
- package/dist/lib/neutral/{schema-add-7WKPPKW4.mjs → schema-add-5BNIINRS.mjs} +3 -3
- package/dist/lib/neutral/schema-add-5BNIINRS.mjs.map +7 -0
- package/dist/lib/neutral/{schema-list-MIAIKERK.mjs → schema-list-54UK7S4R.mjs} +13 -5
- package/dist/lib/neutral/schema-list-54UK7S4R.mjs.map +7 -0
- package/dist/lib/neutral/{sync-issues-GQFVEV4W.mjs → sync-issues-DWY76B3M.mjs} +10 -23
- package/dist/lib/neutral/sync-issues-DWY76B3M.mjs.map +7 -0
- package/dist/lib/neutral/sync-triggers-NOIQLELD.mjs +135 -0
- package/dist/lib/neutral/sync-triggers-NOIQLELD.mjs.map +7 -0
- package/dist/lib/neutral/{tag-add-IKD4ADDM.mjs → tag-add-NLVRGTC6.mjs} +4 -4
- package/dist/lib/neutral/tag-add-NLVRGTC6.mjs.map +7 -0
- package/dist/lib/neutral/{tag-remove-PCSKCFT2.mjs → tag-remove-N4HFBIA2.mjs} +4 -4
- package/dist/lib/neutral/tag-remove-N4HFBIA2.mjs.map +7 -0
- package/dist/lib/neutral/testing/index.mjs +10 -15
- package/dist/lib/neutral/testing/index.mjs.map +3 -3
- package/dist/lib/neutral/{update-blueprints-ZNWR7BBN.mjs → update-blueprints-2SNK6HLG.mjs} +3 -4
- package/dist/lib/neutral/update-blueprints-2SNK6HLG.mjs.map +7 -0
- package/dist/lib/neutral/update-tasks-QQUR53RN.mjs +13 -0
- package/dist/lib/neutral/update-tasks-QQUR53RN.mjs.map +7 -0
- package/dist/types/src/blueprints/automation/blueprint.d.ts +2 -2
- package/dist/types/src/blueprints/automation/blueprint.d.ts.map +1 -1
- package/dist/types/src/blueprints/blueprint-manager/blueprint.d.ts +2 -2
- package/dist/types/src/blueprints/blueprint-manager/blueprint.d.ts.map +1 -1
- package/dist/types/src/blueprints/blueprint-manager/functions/definitions.d.ts +14 -13
- package/dist/types/src/blueprints/blueprint-manager/functions/definitions.d.ts.map +1 -1
- package/dist/types/src/blueprints/blueprint-manager/functions/enable-blueprints.d.ts +8 -8
- package/dist/types/src/blueprints/blueprint-manager/functions/enable-blueprints.d.ts.map +1 -1
- package/dist/types/src/blueprints/blueprint-manager/functions/index.d.ts +1 -1
- package/dist/types/src/blueprints/blueprint-manager/functions/index.d.ts.map +1 -1
- package/dist/types/src/blueprints/blueprint-manager/functions/query-blueprints.d.ts +6 -6
- package/dist/types/src/blueprints/blueprint-manager/functions/query-blueprints.d.ts.map +1 -1
- package/dist/types/src/blueprints/blueprint-manager/functions/update-blueprints.d.ts +2 -3
- package/dist/types/src/blueprints/blueprint-manager/functions/update-blueprints.d.ts.map +1 -1
- package/dist/types/src/blueprints/browser/blueprint.d.ts +2 -2
- package/dist/types/src/blueprints/browser/blueprint.d.ts.map +1 -1
- package/dist/types/src/blueprints/database/blueprint.d.ts +2 -2
- package/dist/types/src/blueprints/database/blueprint.d.ts.map +1 -1
- package/dist/types/src/blueprints/database/functions/context-add.d.ts +3 -3
- package/dist/types/src/blueprints/database/functions/context-add.d.ts.map +1 -1
- package/dist/types/src/blueprints/database/functions/context-remove.d.ts +3 -3
- package/dist/types/src/blueprints/database/functions/context-remove.d.ts.map +1 -1
- package/dist/types/src/blueprints/database/functions/definitions.d.ts +8 -7
- package/dist/types/src/blueprints/database/functions/definitions.d.ts.map +1 -1
- package/dist/types/src/blueprints/database/functions/index.d.ts +1 -1
- package/dist/types/src/blueprints/database/functions/index.d.ts.map +1 -1
- package/dist/types/src/blueprints/database/functions/load.d.ts +1 -1
- package/dist/types/src/blueprints/database/functions/load.d.ts.map +1 -1
- package/dist/types/src/blueprints/database/functions/object-create.d.ts +1 -1
- package/dist/types/src/blueprints/database/functions/object-create.d.ts.map +1 -1
- package/dist/types/src/blueprints/database/functions/object-delete.d.ts +1 -1
- package/dist/types/src/blueprints/database/functions/object-delete.d.ts.map +1 -1
- package/dist/types/src/blueprints/database/functions/object-update.d.ts +2 -2
- package/dist/types/src/blueprints/database/functions/object-update.d.ts.map +1 -1
- package/dist/types/src/blueprints/database/functions/query.d.ts +4 -3
- package/dist/types/src/blueprints/database/functions/query.d.ts.map +1 -1
- package/dist/types/src/blueprints/database/functions/relation-create.d.ts +2 -2
- package/dist/types/src/blueprints/database/functions/relation-create.d.ts.map +1 -1
- package/dist/types/src/blueprints/database/functions/relation-delete.d.ts +1 -1
- package/dist/types/src/blueprints/database/functions/relation-delete.d.ts.map +1 -1
- package/dist/types/src/blueprints/database/functions/schema-add.d.ts +1 -1
- package/dist/types/src/blueprints/database/functions/schema-add.d.ts.map +1 -1
- package/dist/types/src/blueprints/database/functions/schema-list.d.ts +1 -1
- package/dist/types/src/blueprints/database/functions/schema-list.d.ts.map +1 -1
- package/dist/types/src/blueprints/database/functions/tag-add.d.ts +1 -1
- package/dist/types/src/blueprints/database/functions/tag-add.d.ts.map +1 -1
- package/dist/types/src/blueprints/database/functions/tag-remove.d.ts +1 -1
- package/dist/types/src/blueprints/database/functions/tag-remove.d.ts.map +1 -1
- package/dist/types/src/blueprints/discord/blueprint.d.ts +2 -2
- package/dist/types/src/blueprints/discord/blueprint.d.ts.map +1 -1
- package/dist/types/src/blueprints/discord/functions/definitions.d.ts +2 -3
- package/dist/types/src/blueprints/discord/functions/definitions.d.ts.map +1 -1
- package/dist/types/src/blueprints/discord/functions/fetch-messages.d.ts +2 -3
- package/dist/types/src/blueprints/discord/functions/fetch-messages.d.ts.map +1 -1
- package/dist/types/src/blueprints/discord/functions/index.d.ts +1 -1
- package/dist/types/src/blueprints/discord/functions/index.d.ts.map +1 -1
- package/dist/types/src/blueprints/github/functions/definitions.d.ts +2 -3
- package/dist/types/src/blueprints/github/functions/definitions.d.ts.map +1 -1
- package/dist/types/src/blueprints/github/functions/fetch-prs.d.ts +2 -3
- package/dist/types/src/blueprints/github/functions/fetch-prs.d.ts.map +1 -1
- package/dist/types/src/blueprints/github/functions/index.d.ts +1 -1
- package/dist/types/src/blueprints/github/functions/index.d.ts.map +1 -1
- package/dist/types/src/blueprints/index.d.ts +0 -3
- package/dist/types/src/blueprints/index.d.ts.map +1 -1
- package/dist/types/src/blueprints/linear/blueprint.d.ts +2 -2
- package/dist/types/src/blueprints/linear/blueprint.d.ts.map +1 -1
- package/dist/types/src/blueprints/linear/functions/definitions.d.ts +2 -3
- package/dist/types/src/blueprints/linear/functions/definitions.d.ts.map +1 -1
- package/dist/types/src/blueprints/linear/functions/index.d.ts +1 -1
- package/dist/types/src/blueprints/linear/functions/index.d.ts.map +1 -1
- package/dist/types/src/blueprints/linear/functions/sync-issues.d.ts +2 -3
- package/dist/types/src/blueprints/linear/functions/sync-issues.d.ts.map +1 -1
- package/dist/types/src/blueprints/memory/blueprint.d.ts +2 -2
- package/dist/types/src/blueprints/memory/blueprint.d.ts.map +1 -1
- package/dist/types/src/blueprints/memory/functions/definitions.d.ts +4 -4
- package/dist/types/src/blueprints/memory/functions/definitions.d.ts.map +1 -1
- package/dist/types/src/blueprints/memory/functions/delete.d.ts +2 -2
- package/dist/types/src/blueprints/memory/functions/delete.d.ts.map +1 -1
- package/dist/types/src/blueprints/memory/functions/index.d.ts +1 -1
- package/dist/types/src/blueprints/memory/functions/index.d.ts.map +1 -1
- package/dist/types/src/blueprints/memory/functions/query.d.ts +2 -2
- package/dist/types/src/blueprints/memory/functions/query.d.ts.map +1 -1
- package/dist/types/src/blueprints/memory/functions/save.d.ts +2 -2
- package/dist/types/src/blueprints/memory/functions/save.d.ts.map +1 -1
- package/dist/types/src/blueprints/planning/blueprint.d.ts +2 -2
- package/dist/types/src/blueprints/planning/blueprint.d.ts.map +1 -1
- package/dist/types/src/blueprints/planning/functions/index.d.ts +2 -2
- package/dist/types/src/blueprints/planning/functions/index.d.ts.map +1 -1
- package/dist/types/src/blueprints/planning/functions/update-tasks.d.ts +16 -3
- package/dist/types/src/blueprints/planning/functions/update-tasks.d.ts.map +1 -1
- package/dist/types/src/blueprints/planning/functions/update-tasks.test.d.ts +2 -0
- package/dist/types/src/blueprints/planning/functions/update-tasks.test.d.ts.map +1 -0
- package/dist/types/src/blueprints/project/blueprint.d.ts +2 -2
- package/dist/types/src/blueprints/project/blueprint.d.ts.map +1 -1
- package/dist/types/src/blueprints/project/functions/add-artifact.d.ts +2 -6
- package/dist/types/src/blueprints/project/functions/add-artifact.d.ts.map +1 -1
- package/dist/types/src/blueprints/project/functions/agent.d.ts +1 -1
- package/dist/types/src/blueprints/project/functions/agent.d.ts.map +1 -1
- package/dist/types/src/blueprints/project/functions/definitions.d.ts +60 -45
- package/dist/types/src/blueprints/project/functions/definitions.d.ts.map +1 -1
- package/dist/types/src/blueprints/project/functions/get-context.d.ts +2 -13
- package/dist/types/src/blueprints/project/functions/get-context.d.ts.map +1 -1
- package/dist/types/src/blueprints/project/functions/index.d.ts +2 -2
- package/dist/types/src/blueprints/project/functions/index.d.ts.map +1 -1
- package/dist/types/src/blueprints/project/functions/qualifier.d.ts +27 -19
- package/dist/types/src/blueprints/project/functions/qualifier.d.ts.map +1 -1
- package/dist/types/src/blueprints/project/index.d.ts +2 -2
- package/dist/types/src/blueprints/project/index.d.ts.map +1 -1
- package/dist/types/src/blueprints/project-wizard/blueprint.d.ts +2 -2
- package/dist/types/src/blueprints/project-wizard/blueprint.d.ts.map +1 -1
- package/dist/types/src/blueprints/project-wizard/functions/create-project.d.ts +25 -18
- package/dist/types/src/blueprints/project-wizard/functions/create-project.d.ts.map +1 -1
- package/dist/types/src/blueprints/project-wizard/functions/definitions.d.ts +49 -34
- package/dist/types/src/blueprints/project-wizard/functions/definitions.d.ts.map +1 -1
- package/dist/types/src/blueprints/project-wizard/functions/index.d.ts +2 -2
- package/dist/types/src/blueprints/project-wizard/functions/index.d.ts.map +1 -1
- package/dist/types/src/blueprints/project-wizard/functions/project-rules.d.ts +1 -1
- package/dist/types/src/blueprints/project-wizard/functions/project-rules.d.ts.map +1 -1
- package/dist/types/src/blueprints/project-wizard/functions/sync-triggers.d.ts +23 -15
- package/dist/types/src/blueprints/project-wizard/functions/sync-triggers.d.ts.map +1 -1
- package/dist/types/src/blueprints/project-wizard/index.d.ts +2 -2
- package/dist/types/src/blueprints/project-wizard/index.d.ts.map +1 -1
- package/dist/types/src/blueprints/testing.d.ts +5 -13
- package/dist/types/src/blueprints/testing.d.ts.map +1 -1
- package/dist/types/src/blueprints/websearch/blueprint.d.ts +2 -2
- package/dist/types/src/blueprints/websearch/blueprint.d.ts.map +1 -1
- package/dist/types/src/blueprints/websearch/functions/definitions.d.ts +1 -1
- package/dist/types/src/blueprints/websearch/functions/definitions.d.ts.map +1 -1
- package/dist/types/src/blueprints/websearch/functions/fetch.d.ts +1 -1
- package/dist/types/src/blueprints/websearch/functions/fetch.d.ts.map +1 -1
- package/dist/types/src/blueprints/websearch/functions/index.d.ts +1 -1
- package/dist/types/src/blueprints/websearch/functions/index.d.ts.map +1 -1
- package/dist/types/src/blueprints/websearch/index.d.ts +1 -1
- package/dist/types/src/blueprints/websearch/index.d.ts.map +1 -1
- package/dist/types/src/blueprints/websearch/toolkit.d.ts +2 -2
- package/dist/types/src/blueprints/websearch/toolkit.d.ts.map +1 -1
- package/dist/types/src/crud/graph.d.ts +5 -7
- package/dist/types/src/crud/graph.d.ts.map +1 -1
- package/dist/types/src/errors.d.ts +6 -6
- package/dist/types/src/errors.d.ts.map +1 -1
- package/dist/types/src/functions/agent/definitions.d.ts +16 -15
- package/dist/types/src/functions/agent/definitions.d.ts.map +1 -1
- package/dist/types/src/functions/agent/index.d.ts +1 -1
- package/dist/types/src/functions/agent/index.d.ts.map +1 -1
- package/dist/types/src/functions/agent/prompt.d.ts +1 -1
- package/dist/types/src/functions/agent/prompt.d.ts.map +1 -1
- package/dist/types/src/functions/index.d.ts +0 -2
- package/dist/types/src/functions/index.d.ts.map +1 -1
- package/dist/types/src/sync/sync.d.ts +1 -2
- package/dist/types/src/sync/sync.d.ts.map +1 -1
- package/dist/types/src/testing/plugins.d.ts.map +1 -1
- package/dist/types/src/types/{Project.d.ts → Agent.d.ts} +38 -32
- package/dist/types/src/types/Agent.d.ts.map +1 -0
- package/dist/types/src/types/Chat.d.ts +8 -4
- package/dist/types/src/types/Chat.d.ts.map +1 -1
- package/dist/types/src/types/McpServer.d.ts +21 -0
- package/dist/types/src/types/McpServer.d.ts.map +1 -0
- package/dist/types/src/types/Memory.d.ts +1 -1
- package/dist/types/src/types/Memory.d.ts.map +1 -1
- package/dist/types/src/types/Plan.d.ts +17 -14
- package/dist/types/src/types/Plan.d.ts.map +1 -1
- package/dist/types/src/types/index.d.ts +2 -1
- package/dist/types/src/types/index.d.ts.map +1 -1
- package/dist/types/src/util/graphql.d.ts.map +1 -1
- package/dist/types/tsconfig.tsbuildinfo +1 -1
- package/package.json +26 -31
- package/src/blueprints/automation/blueprint.ts +3 -6
- package/src/blueprints/blueprint-manager/blueprint.conversations.json +1 -1
- package/src/blueprints/blueprint-manager/blueprint.test.ts +70 -44
- package/src/blueprints/blueprint-manager/blueprint.ts +4 -5
- package/src/blueprints/blueprint-manager/functions/definitions.ts +4 -5
- package/src/blueprints/blueprint-manager/functions/enable-blueprints.ts +3 -4
- package/src/blueprints/blueprint-manager/functions/index.ts +1 -1
- package/src/blueprints/blueprint-manager/functions/query-blueprints.ts +1 -2
- package/src/blueprints/blueprint-manager/functions/update-blueprints.ts +1 -2
- package/src/blueprints/browser/blueprint.test.ts +8 -10
- package/src/blueprints/browser/blueprint.ts +3 -4
- package/src/blueprints/database/blueprint.conversations.json +1 -1
- package/src/blueprints/database/blueprint.test.ts +89 -13
- package/src/blueprints/database/blueprint.ts +3 -4
- package/src/blueprints/database/functions/context-add.ts +3 -3
- package/src/blueprints/database/functions/context-remove.ts +3 -3
- package/src/blueprints/database/functions/definitions.ts +34 -17
- package/src/blueprints/database/functions/index.ts +1 -1
- package/src/blueprints/database/functions/load.ts +1 -1
- package/src/blueprints/database/functions/object-create.ts +1 -1
- package/src/blueprints/database/functions/object-delete.ts +1 -1
- package/src/blueprints/database/functions/object-update.ts +2 -2
- package/src/blueprints/database/functions/query.ts +9 -5
- package/src/blueprints/database/functions/relation-create.ts +1 -1
- package/src/blueprints/database/functions/relation-delete.ts +1 -1
- package/src/blueprints/database/functions/schema-add.ts +1 -1
- package/src/blueprints/database/functions/schema-list.ts +16 -10
- package/src/blueprints/database/functions/tag-add.ts +2 -2
- package/src/blueprints/database/functions/tag-remove.ts +2 -2
- package/src/blueprints/discord/blueprint.ts +3 -4
- package/src/blueprints/discord/functions/definitions.ts +2 -3
- package/src/blueprints/discord/functions/fetch-messages.test.ts +21 -27
- package/src/blueprints/discord/functions/fetch-messages.ts +4 -5
- package/src/blueprints/discord/functions/index.ts +1 -1
- package/src/blueprints/github/functions/definitions.ts +2 -3
- package/src/blueprints/github/functions/fetch-prs.ts +3 -3
- package/src/blueprints/github/functions/index.ts +1 -1
- package/src/blueprints/index.ts +0 -3
- package/src/blueprints/linear/blueprint.ts +3 -4
- package/src/blueprints/linear/functions/definitions.ts +2 -3
- package/src/blueprints/linear/functions/index.ts +1 -1
- package/src/blueprints/linear/functions/linear.test.ts +5 -7
- package/src/blueprints/linear/functions/sync-issues.ts +4 -5
- package/src/blueprints/memory/blueprint.conversations.json +1 -1
- package/src/blueprints/memory/blueprint.test.ts +5 -5
- package/src/blueprints/memory/blueprint.ts +4 -5
- package/src/blueprints/memory/functions/definitions.ts +1 -1
- package/src/blueprints/memory/functions/delete.ts +1 -1
- package/src/blueprints/memory/functions/index.ts +1 -1
- package/src/blueprints/memory/functions/query.ts +1 -1
- package/src/blueprints/memory/functions/save.ts +1 -1
- package/src/blueprints/planning/blueprint.ts +3 -4
- package/src/blueprints/planning/functions/index.ts +2 -2
- package/src/blueprints/planning/functions/{definitions.ts → update-tasks.md} +29 -50
- package/src/blueprints/planning/functions/update-tasks.test.ts +55 -0
- package/src/blueprints/planning/functions/update-tasks.ts +30 -8
- package/src/blueprints/project/blueprint.conversations.json +1 -1
- package/src/blueprints/project/blueprint.test.ts +215 -156
- package/src/blueprints/project/blueprint.ts +19 -20
- package/src/blueprints/project/functions/add-artifact.ts +6 -5
- package/src/blueprints/project/functions/agent.ts +47 -44
- package/src/blueprints/project/functions/definitions.ts +27 -30
- package/src/blueprints/project/functions/get-context.ts +10 -9
- package/src/blueprints/project/functions/index.ts +2 -2
- package/src/blueprints/project/functions/qualifier.ts +21 -21
- package/src/blueprints/project/index.ts +2 -2
- package/src/blueprints/project-wizard/blueprint.ts +24 -20
- package/src/blueprints/project-wizard/functions/create-project.ts +11 -12
- package/src/blueprints/project-wizard/functions/definitions.ts +20 -21
- package/src/blueprints/project-wizard/functions/index.ts +2 -2
- package/src/blueprints/project-wizard/functions/project-rules.ts +19 -18
- package/src/blueprints/project-wizard/functions/sync-triggers.ts +72 -77
- package/src/blueprints/project-wizard/index.ts +2 -2
- package/src/blueprints/testing.ts +14 -22
- package/src/blueprints/websearch/blueprint.conversations.json +1 -1
- package/src/blueprints/websearch/blueprint.test.ts +4 -4
- package/src/blueprints/websearch/blueprint.ts +2 -3
- package/src/blueprints/websearch/functions/definitions.ts +1 -1
- package/src/blueprints/websearch/functions/fetch.ts +1 -1
- package/src/blueprints/websearch/functions/index.ts +1 -1
- package/src/blueprints/websearch/index.ts +1 -1
- package/src/blueprints/websearch/toolkit.ts +2 -2
- package/src/crud/graph.test.ts +10 -12
- package/src/crud/graph.ts +125 -127
- package/src/functions/agent/definitions.ts +13 -10
- package/src/functions/agent/index.ts +1 -1
- package/src/functions/agent/prompt.conversations.json +1 -1
- package/src/functions/agent/prompt.test.ts +12 -16
- package/src/functions/agent/prompt.ts +47 -42
- package/src/functions/index.ts +0 -2
- package/src/sync/sync.ts +24 -14
- package/src/testing/plugins.tsx +9 -7
- package/src/types/Agent.ts +238 -0
- package/src/types/Chat.ts +2 -1
- package/src/types/McpServer.ts +37 -0
- package/src/types/Memory.ts +2 -1
- package/src/types/Plan.ts +3 -2
- package/src/types/index.ts +2 -1
- package/dist/lib/neutral/add-artifact-W2CRMEAZ.mjs.map +0 -7
- package/dist/lib/neutral/agent-CT44JSYM.mjs +0 -85
- package/dist/lib/neutral/agent-CT44JSYM.mjs.map +0 -7
- package/dist/lib/neutral/chunk-2SH4XUQR.mjs.map +0 -7
- package/dist/lib/neutral/chunk-6DPL2YY5.mjs.map +0 -7
- package/dist/lib/neutral/chunk-6FL4C6KD.mjs +0 -86
- package/dist/lib/neutral/chunk-6FL4C6KD.mjs.map +0 -7
- package/dist/lib/neutral/chunk-A4AVXKBT.mjs +0 -694
- package/dist/lib/neutral/chunk-A4AVXKBT.mjs.map +0 -7
- package/dist/lib/neutral/chunk-AGG6OZNB.mjs.map +0 -7
- package/dist/lib/neutral/chunk-AKMBURAD.mjs.map +0 -7
- package/dist/lib/neutral/chunk-B2PLQKOJ.mjs.map +0 -7
- package/dist/lib/neutral/chunk-BO4ZVH7M.mjs.map +0 -7
- package/dist/lib/neutral/chunk-HZM3HNAS.mjs +0 -78
- package/dist/lib/neutral/chunk-HZM3HNAS.mjs.map +0 -7
- package/dist/lib/neutral/chunk-ILZ2ODWC.mjs +0 -95
- package/dist/lib/neutral/chunk-ILZ2ODWC.mjs.map +0 -7
- package/dist/lib/neutral/chunk-KW45RMNS.mjs +0 -140
- package/dist/lib/neutral/chunk-KW45RMNS.mjs.map +0 -7
- package/dist/lib/neutral/chunk-LI6VMCJW.mjs +0 -27
- package/dist/lib/neutral/chunk-LI6VMCJW.mjs.map +0 -7
- package/dist/lib/neutral/chunk-MEZ4UFR6.mjs.map +0 -7
- package/dist/lib/neutral/chunk-TKJH3CAH.mjs.map +0 -7
- package/dist/lib/neutral/chunk-U26AX7D7.mjs +0 -76
- package/dist/lib/neutral/chunk-U26AX7D7.mjs.map +0 -7
- package/dist/lib/neutral/chunk-VBSCQN37.mjs.map +0 -7
- package/dist/lib/neutral/chunk-VDEDVOS6.mjs +0 -39
- package/dist/lib/neutral/chunk-VDEDVOS6.mjs.map +0 -7
- package/dist/lib/neutral/chunk-VHYUC3HO.mjs +0 -70
- package/dist/lib/neutral/chunk-VHYUC3HO.mjs.map +0 -7
- package/dist/lib/neutral/chunk-XT5ZSUS6.mjs +0 -363
- package/dist/lib/neutral/chunk-XT5ZSUS6.mjs.map +0 -7
- package/dist/lib/neutral/context-add-U5LSEQLG.mjs.map +0 -7
- package/dist/lib/neutral/context-remove-3YGXLVRA.mjs.map +0 -7
- package/dist/lib/neutral/create-P6I22VS5.mjs +0 -23
- package/dist/lib/neutral/create-P6I22VS5.mjs.map +0 -7
- package/dist/lib/neutral/create-project-NESP7QHJ.mjs +0 -36
- package/dist/lib/neutral/create-project-NESP7QHJ.mjs.map +0 -7
- package/dist/lib/neutral/delete-LHMZDJFA.mjs.map +0 -7
- package/dist/lib/neutral/document-create-53ZVNGFR.mjs +0 -57
- package/dist/lib/neutral/document-create-53ZVNGFR.mjs.map +0 -7
- package/dist/lib/neutral/enable-blueprints-4UMPKGUD.mjs.map +0 -7
- package/dist/lib/neutral/entity-extraction-EEMRVHPI.mjs +0 -196
- package/dist/lib/neutral/entity-extraction-EEMRVHPI.mjs.map +0 -7
- package/dist/lib/neutral/exa-P4G3DCYB.mjs +0 -28
- package/dist/lib/neutral/exa-P4G3DCYB.mjs.map +0 -7
- package/dist/lib/neutral/fetch-messages-AFX7ZAVE.mjs.map +0 -7
- package/dist/lib/neutral/get-context-LUOU7M3Z.mjs +0 -35
- package/dist/lib/neutral/get-context-LUOU7M3Z.mjs.map +0 -7
- package/dist/lib/neutral/mock-2ARYZ54S.mjs +0 -556
- package/dist/lib/neutral/mock-2ARYZ54S.mjs.map +0 -7
- package/dist/lib/neutral/object-create-7J7D53FT.mjs.map +0 -7
- package/dist/lib/neutral/object-delete-QFXUHJ2D.mjs.map +0 -7
- package/dist/lib/neutral/object-update-C73HRM5F.mjs.map +0 -7
- package/dist/lib/neutral/project-XFTFWHSY.mjs +0 -23
- package/dist/lib/neutral/project-rules-IYRR6OQE.mjs.map +0 -7
- package/dist/lib/neutral/prompt-MWQPSPDW.mjs.map +0 -7
- package/dist/lib/neutral/qualifier-KIBSTV6F.mjs.map +0 -7
- package/dist/lib/neutral/query-MN5B3MQF.mjs.map +0 -7
- package/dist/lib/neutral/query-ZMWWZ4I3.mjs.map +0 -7
- package/dist/lib/neutral/query-blueprints-EKHEZAGD.mjs.map +0 -7
- package/dist/lib/neutral/read-JJN7YXHI.mjs +0 -19
- package/dist/lib/neutral/read-JJN7YXHI.mjs.map +0 -7
- package/dist/lib/neutral/relation-create-YWV2TUKS.mjs.map +0 -7
- package/dist/lib/neutral/relation-delete-JGGA4CYQ.mjs.map +0 -7
- package/dist/lib/neutral/research-7JQEX7MU.mjs +0 -109
- package/dist/lib/neutral/research-7JQEX7MU.mjs.map +0 -7
- package/dist/lib/neutral/save-ZWWNTBOD.mjs.map +0 -7
- package/dist/lib/neutral/schema-add-7WKPPKW4.mjs.map +0 -7
- package/dist/lib/neutral/schema-list-MIAIKERK.mjs.map +0 -7
- package/dist/lib/neutral/sync-issues-GQFVEV4W.mjs.map +0 -7
- package/dist/lib/neutral/sync-triggers-MBKM6VIQ.mjs +0 -128
- package/dist/lib/neutral/sync-triggers-MBKM6VIQ.mjs.map +0 -7
- package/dist/lib/neutral/tag-add-IKD4ADDM.mjs.map +0 -7
- package/dist/lib/neutral/tag-remove-PCSKCFT2.mjs.map +0 -7
- package/dist/lib/neutral/update-HZ7A3ZA5.mjs +0 -20
- package/dist/lib/neutral/update-HZ7A3ZA5.mjs.map +0 -7
- package/dist/lib/neutral/update-blueprints-ZNWR7BBN.mjs.map +0 -7
- package/dist/lib/neutral/update-tasks-D5XKU3TE.mjs +0 -46
- package/dist/lib/neutral/update-tasks-D5XKU3TE.mjs.map +0 -7
- package/dist/types/src/blueprints/design/blueprint.d.ts +0 -4
- package/dist/types/src/blueprints/design/blueprint.d.ts.map +0 -1
- package/dist/types/src/blueprints/design/blueprint.test.d.ts +0 -2
- package/dist/types/src/blueprints/design/blueprint.test.d.ts.map +0 -1
- package/dist/types/src/blueprints/design/index.d.ts +0 -2
- package/dist/types/src/blueprints/design/index.d.ts.map +0 -1
- package/dist/types/src/blueprints/markdown/blueprint.d.ts +0 -4
- package/dist/types/src/blueprints/markdown/blueprint.d.ts.map +0 -1
- package/dist/types/src/blueprints/markdown/functions/create.d.ts +0 -8
- package/dist/types/src/blueprints/markdown/functions/create.d.ts.map +0 -1
- package/dist/types/src/blueprints/markdown/functions/definitions.d.ts +0 -45
- package/dist/types/src/blueprints/markdown/functions/definitions.d.ts.map +0 -1
- package/dist/types/src/blueprints/markdown/functions/index.d.ts +0 -4
- package/dist/types/src/blueprints/markdown/functions/index.d.ts.map +0 -1
- package/dist/types/src/blueprints/markdown/functions/read.d.ts +0 -17
- package/dist/types/src/blueprints/markdown/functions/read.d.ts.map +0 -1
- package/dist/types/src/blueprints/markdown/functions/update.d.ts +0 -16
- package/dist/types/src/blueprints/markdown/functions/update.d.ts.map +0 -1
- package/dist/types/src/blueprints/markdown/index.d.ts +0 -3
- package/dist/types/src/blueprints/markdown/index.d.ts.map +0 -1
- package/dist/types/src/blueprints/planning/functions/definitions.d.ts +0 -11
- package/dist/types/src/blueprints/planning/functions/definitions.d.ts.map +0 -1
- package/dist/types/src/blueprints/planning-old/blueprint.d.ts +0 -4
- package/dist/types/src/blueprints/planning-old/blueprint.d.ts.map +0 -1
- package/dist/types/src/blueprints/planning-old/blueprint.test.d.ts +0 -2
- package/dist/types/src/blueprints/planning-old/blueprint.test.d.ts.map +0 -1
- package/dist/types/src/blueprints/planning-old/functions/definitions.d.ts +0 -31
- package/dist/types/src/blueprints/planning-old/functions/definitions.d.ts.map +0 -1
- package/dist/types/src/blueprints/planning-old/functions/index.d.ts +0 -4
- package/dist/types/src/blueprints/planning-old/functions/index.d.ts.map +0 -1
- package/dist/types/src/blueprints/planning-old/functions/read.d.ts +0 -17
- package/dist/types/src/blueprints/planning-old/functions/read.d.ts.map +0 -1
- package/dist/types/src/blueprints/planning-old/functions/task-list.d.ts +0 -74
- package/dist/types/src/blueprints/planning-old/functions/task-list.d.ts.map +0 -1
- package/dist/types/src/blueprints/planning-old/functions/task-list.test.d.ts +0 -2
- package/dist/types/src/blueprints/planning-old/functions/task-list.test.d.ts.map +0 -1
- package/dist/types/src/blueprints/planning-old/functions/update.d.ts +0 -19
- package/dist/types/src/blueprints/planning-old/functions/update.d.ts.map +0 -1
- package/dist/types/src/blueprints/planning-old/index.d.ts +0 -3
- package/dist/types/src/blueprints/planning-old/index.d.ts.map +0 -1
- package/dist/types/src/blueprints/research/blueprint.d.ts +0 -4
- package/dist/types/src/blueprints/research/blueprint.d.ts.map +0 -1
- package/dist/types/src/blueprints/research/blueprint.test.d.ts +0 -2
- package/dist/types/src/blueprints/research/blueprint.test.d.ts.map +0 -1
- package/dist/types/src/blueprints/research/functions/definitions.d.ts +0 -21
- package/dist/types/src/blueprints/research/functions/definitions.d.ts.map +0 -1
- package/dist/types/src/blueprints/research/functions/document-create.d.ts +0 -12
- package/dist/types/src/blueprints/research/functions/document-create.d.ts.map +0 -1
- package/dist/types/src/blueprints/research/functions/index.d.ts +0 -4
- package/dist/types/src/blueprints/research/functions/index.d.ts.map +0 -1
- package/dist/types/src/blueprints/research/functions/research.d.ts +0 -18
- package/dist/types/src/blueprints/research/functions/research.d.ts.map +0 -1
- package/dist/types/src/blueprints/research/functions/research.test.d.ts +0 -2
- package/dist/types/src/blueprints/research/functions/research.test.d.ts.map +0 -1
- package/dist/types/src/blueprints/research/index.d.ts +0 -4
- package/dist/types/src/blueprints/research/index.d.ts.map +0 -1
- package/dist/types/src/blueprints/research/types/ResearchGraph.d.ts +0 -24
- package/dist/types/src/blueprints/research/types/ResearchGraph.d.ts.map +0 -1
- package/dist/types/src/blueprints/research/types/index.d.ts +0 -7
- package/dist/types/src/blueprints/research/types/index.d.ts.map +0 -1
- package/dist/types/src/functions/entity-extraction/definitions.d.ts +0 -182
- package/dist/types/src/functions/entity-extraction/definitions.d.ts.map +0 -1
- package/dist/types/src/functions/entity-extraction/entity-extraction.d.ts +0 -4
- package/dist/types/src/functions/entity-extraction/entity-extraction.d.ts.map +0 -1
- package/dist/types/src/functions/entity-extraction/entity-extraction.test.d.ts +0 -2
- package/dist/types/src/functions/entity-extraction/entity-extraction.test.d.ts.map +0 -1
- package/dist/types/src/functions/entity-extraction/index.d.ts +0 -4
- package/dist/types/src/functions/entity-extraction/index.d.ts.map +0 -1
- package/dist/types/src/functions/exa/data/exa-search-1748337321991.d.ts +0 -38
- package/dist/types/src/functions/exa/data/exa-search-1748337321991.d.ts.map +0 -1
- package/dist/types/src/functions/exa/data/exa-search-1748337331526.d.ts +0 -37
- package/dist/types/src/functions/exa/data/exa-search-1748337331526.d.ts.map +0 -1
- package/dist/types/src/functions/exa/data/exa-search-1748337344119.d.ts +0 -58
- package/dist/types/src/functions/exa/data/exa-search-1748337344119.d.ts.map +0 -1
- package/dist/types/src/functions/exa/data/index.d.ts +0 -3
- package/dist/types/src/functions/exa/data/index.d.ts.map +0 -1
- package/dist/types/src/functions/exa/definitions.d.ts +0 -9
- package/dist/types/src/functions/exa/definitions.d.ts.map +0 -1
- package/dist/types/src/functions/exa/exa.d.ts +0 -7
- package/dist/types/src/functions/exa/exa.d.ts.map +0 -1
- package/dist/types/src/functions/exa/index.d.ts +0 -4
- package/dist/types/src/functions/exa/index.d.ts.map +0 -1
- package/dist/types/src/functions/exa/mock.d.ts +0 -6
- package/dist/types/src/functions/exa/mock.d.ts.map +0 -1
- package/dist/types/src/types/Project.d.ts.map +0 -1
- package/src/blueprints/browser/blueprint.conversations.json +0 -1
- package/src/blueprints/design/blueprint.test.ts +0 -97
- package/src/blueprints/design/blueprint.ts +0 -41
- package/src/blueprints/design/index.ts +0 -5
- package/src/blueprints/markdown/blueprint.ts +0 -36
- package/src/blueprints/markdown/functions/create.ts +0 -20
- package/src/blueprints/markdown/functions/definitions.ts +0 -80
- package/src/blueprints/markdown/functions/index.ts +0 -13
- package/src/blueprints/markdown/functions/read.ts +0 -22
- package/src/blueprints/markdown/functions/update.ts +0 -22
- package/src/blueprints/markdown/index.ts +0 -11
- package/src/blueprints/planning-old/blueprint.test.ts +0 -122
- package/src/blueprints/planning-old/blueprint.ts +0 -106
- package/src/blueprints/planning-old/functions/definitions.ts +0 -53
- package/src/blueprints/planning-old/functions/index.ts +0 -12
- package/src/blueprints/planning-old/functions/read.ts +0 -24
- package/src/blueprints/planning-old/functions/task-list.test.ts +0 -99
- package/src/blueprints/planning-old/functions/task-list.ts +0 -165
- package/src/blueprints/planning-old/functions/update.ts +0 -31
- package/src/blueprints/planning-old/index.ts +0 -6
- package/src/blueprints/research/blueprint.test.ts +0 -7
- package/src/blueprints/research/blueprint.ts +0 -61
- package/src/blueprints/research/functions/definitions.ts +0 -87
- package/src/blueprints/research/functions/document-create.ts +0 -50
- package/src/blueprints/research/functions/index.ts +0 -12
- package/src/blueprints/research/functions/research-instructions.tpl +0 -106
- package/src/blueprints/research/functions/research.conversations.json +0 -1
- package/src/blueprints/research/functions/research.test.ts +0 -150
- package/src/blueprints/research/functions/research.ts +0 -137
- package/src/blueprints/research/index.ts +0 -7
- package/src/blueprints/research/types/ResearchGraph.ts +0 -62
- package/src/blueprints/research/types/index.ts +0 -32
- package/src/functions/entity-extraction/definitions.ts +0 -44
- package/src/functions/entity-extraction/entity-extraction.conversations.json +0 -1
- package/src/functions/entity-extraction/entity-extraction.test.ts +0 -74
- package/src/functions/entity-extraction/entity-extraction.ts +0 -159
- package/src/functions/entity-extraction/index.ts +0 -9
- package/src/functions/exa/data/exa-search-1748337321991.ts +0 -131
- package/src/functions/exa/data/exa-search-1748337331526.ts +0 -144
- package/src/functions/exa/data/exa-search-1748337344119.ts +0 -133
- package/src/functions/exa/data/index.ts +0 -11
- package/src/functions/exa/definitions.ts +0 -37
- package/src/functions/exa/exa.ts +0 -32
- package/src/functions/exa/index.ts +0 -12
- package/src/functions/exa/mock.ts +0 -62
- package/src/types/Project.ts +0 -201
- /package/dist/lib/neutral/{project-XFTFWHSY.mjs.map → project-VVXXUMAI.mjs.map} +0 -0
|
@@ -1,97 +0,0 @@
|
|
|
1
|
-
//
|
|
2
|
-
// Copyright 2025 DXOS.org
|
|
3
|
-
//
|
|
4
|
-
|
|
5
|
-
import { describe, it } from '@effect/vitest';
|
|
6
|
-
import * as Effect from 'effect/Effect';
|
|
7
|
-
import * as Layer from 'effect/Layer';
|
|
8
|
-
|
|
9
|
-
import { AiService, ConsolePrinter } from '@dxos/ai';
|
|
10
|
-
import { GenericToolkit } from '@dxos/ai';
|
|
11
|
-
import { AiServiceTestingPreset } from '@dxos/ai/testing';
|
|
12
|
-
import { AiConversation, GenerationObserver, ToolExecutionServices } from '@dxos/assistant';
|
|
13
|
-
import { Blueprint } from '@dxos/blueprints';
|
|
14
|
-
import { Obj, Ref } from '@dxos/echo';
|
|
15
|
-
import { Database, Feed } from '@dxos/echo';
|
|
16
|
-
import { acquireReleaseResource } from '@dxos/effect';
|
|
17
|
-
import { TestHelpers } from '@dxos/effect/testing';
|
|
18
|
-
import { Trace, TracingService } from '@dxos/functions';
|
|
19
|
-
import { FunctionInvocationServiceLayerTestMocked, TestDatabaseLayer } from '@dxos/functions-runtime/testing';
|
|
20
|
-
import { log } from '@dxos/log';
|
|
21
|
-
import { Markdown } from '@dxos/plugin-markdown/types';
|
|
22
|
-
import { Text } from '@dxos/schema';
|
|
23
|
-
import { trim } from '@dxos/util';
|
|
24
|
-
|
|
25
|
-
import { MarkdownHandlers } from '../markdown';
|
|
26
|
-
import DesignBlueprint from './blueprint';
|
|
27
|
-
|
|
28
|
-
describe('Design Blueprint', { timeout: 120_000 }, () => {
|
|
29
|
-
it.scoped(
|
|
30
|
-
'design blueprint',
|
|
31
|
-
Effect.fn(
|
|
32
|
-
function* ({ expect }) {
|
|
33
|
-
const observer = GenerationObserver.fromPrinter(new ConsolePrinter());
|
|
34
|
-
const feed = Feed.make();
|
|
35
|
-
yield* Database.add(feed);
|
|
36
|
-
const runtime = yield* Effect.runtime<Feed.FeedService>();
|
|
37
|
-
const conversation = yield* acquireReleaseResource(() => new AiConversation({ feed, runtime }));
|
|
38
|
-
|
|
39
|
-
const blueprint = DesignBlueprint.make();
|
|
40
|
-
yield* Database.add(blueprint);
|
|
41
|
-
yield* Effect.promise(() =>
|
|
42
|
-
conversation.context.bind({
|
|
43
|
-
blueprints: [Ref.make(blueprint)],
|
|
44
|
-
}),
|
|
45
|
-
);
|
|
46
|
-
|
|
47
|
-
const artifact = yield* Database.add(Markdown.make({ content: 'Hello, world!' }));
|
|
48
|
-
let prevContent = artifact.content;
|
|
49
|
-
|
|
50
|
-
{
|
|
51
|
-
const prompt = trim`
|
|
52
|
-
I want to design a new feature for our product.
|
|
53
|
-
|
|
54
|
-
We need to add a user profile system with the following requirements:
|
|
55
|
-
1. Users should be able to create and edit their profiles
|
|
56
|
-
2. Profile should include basic info like name, bio, avatar
|
|
57
|
-
3. Users can control privacy settings for their profile
|
|
58
|
-
4. Profile should show user's activity history
|
|
59
|
-
5. Need to consider data storage and security implications
|
|
60
|
-
|
|
61
|
-
Let's capture the key design decisions in our spec in ${Obj.getDXN(artifact)}
|
|
62
|
-
`;
|
|
63
|
-
|
|
64
|
-
yield* conversation.createRequest({ prompt, observer });
|
|
65
|
-
log.info('spec', { doc: artifact });
|
|
66
|
-
expect(artifact.content).not.toBe(prevContent);
|
|
67
|
-
prevContent = artifact.content;
|
|
68
|
-
}
|
|
69
|
-
|
|
70
|
-
{
|
|
71
|
-
const prompt = trim`
|
|
72
|
-
I want this to be built on top of Durable Objects and SQLite database.
|
|
73
|
-
Adjust the spec to reflect this.
|
|
74
|
-
`;
|
|
75
|
-
|
|
76
|
-
yield* conversation.createRequest({ observer, prompt });
|
|
77
|
-
expect(artifact.content).not.toBe(prevContent);
|
|
78
|
-
prevContent = artifact.content;
|
|
79
|
-
}
|
|
80
|
-
},
|
|
81
|
-
Effect.provide(
|
|
82
|
-
Layer.mergeAll(ToolExecutionServices, AiService.model('@anthropic/claude-3-5-sonnet-20241022')).pipe(
|
|
83
|
-
Layer.provideMerge(TestDatabaseLayer({ types: [Text.Text, Markdown.Document, Blueprint.Blueprint] })),
|
|
84
|
-
Layer.provideMerge(Layer.mergeAll(GenericToolkit.providerEmpty, AiServiceTestingPreset('direct'))),
|
|
85
|
-
Layer.provideMerge(
|
|
86
|
-
FunctionInvocationServiceLayerTestMocked({
|
|
87
|
-
functions: MarkdownHandlers,
|
|
88
|
-
}).pipe(Layer.provideMerge(TracingService.layerNoop)),
|
|
89
|
-
),
|
|
90
|
-
Layer.provideMerge(Trace.writerLayerNoop),
|
|
91
|
-
),
|
|
92
|
-
),
|
|
93
|
-
TestHelpers.provideTestContext,
|
|
94
|
-
TestHelpers.taggedTest('llm'),
|
|
95
|
-
),
|
|
96
|
-
);
|
|
97
|
-
});
|
|
@@ -1,41 +0,0 @@
|
|
|
1
|
-
//
|
|
2
|
-
// Copyright 2025 DXOS.org
|
|
3
|
-
//
|
|
4
|
-
|
|
5
|
-
import { type AppCapabilities } from '@dxos/app-toolkit';
|
|
6
|
-
import { Blueprint } from '@dxos/blueprints';
|
|
7
|
-
import { Ref } from '@dxos/echo';
|
|
8
|
-
import { Text } from '@dxos/schema';
|
|
9
|
-
import { trim } from '@dxos/util';
|
|
10
|
-
|
|
11
|
-
import { MarkdownCreate, MarkdownRead, MarkdownUpdate } from '../markdown';
|
|
12
|
-
|
|
13
|
-
const BLUEPRINT_KEY = 'org.dxos.blueprint.design';
|
|
14
|
-
|
|
15
|
-
const instructions = trim`
|
|
16
|
-
You manage a design spec based on the conversation.
|
|
17
|
-
The design spec is a markdown document that is used to record the tasks.
|
|
18
|
-
The design spec document follows a hierarchical structure, with nested markdown bulleted sections.
|
|
19
|
-
Use the appropriate tools to read and write the design spec document.
|
|
20
|
-
Maintain the document so that it can convey all relevant points from the conversation.
|
|
21
|
-
When replying to the user, be terse with your comments about design doc handling.
|
|
22
|
-
Do not announce when you read or write the design spec document.
|
|
23
|
-
`;
|
|
24
|
-
|
|
25
|
-
const make = () =>
|
|
26
|
-
Blueprint.make({
|
|
27
|
-
key: BLUEPRINT_KEY,
|
|
28
|
-
name: 'Design Spec',
|
|
29
|
-
description: 'Preserve the conversation in the design spec.',
|
|
30
|
-
instructions: {
|
|
31
|
-
source: Ref.make(Text.make(instructions)),
|
|
32
|
-
},
|
|
33
|
-
tools: Blueprint.toolDefinitions({ operations: [MarkdownCreate, MarkdownRead, MarkdownUpdate] }),
|
|
34
|
-
});
|
|
35
|
-
|
|
36
|
-
const blueprint: AppCapabilities.BlueprintDefinition = {
|
|
37
|
-
key: BLUEPRINT_KEY,
|
|
38
|
-
make,
|
|
39
|
-
};
|
|
40
|
-
|
|
41
|
-
export default blueprint;
|
|
@@ -1,36 +0,0 @@
|
|
|
1
|
-
//
|
|
2
|
-
// Copyright 2025 DXOS.org
|
|
3
|
-
//
|
|
4
|
-
|
|
5
|
-
import { type AppCapabilities } from '@dxos/app-toolkit';
|
|
6
|
-
import { Blueprint } from '@dxos/blueprints';
|
|
7
|
-
import { Ref } from '@dxos/echo';
|
|
8
|
-
import { Text } from '@dxos/schema';
|
|
9
|
-
import { trim } from '@dxos/util';
|
|
10
|
-
|
|
11
|
-
import { Create, Read, Update } from './functions';
|
|
12
|
-
|
|
13
|
-
const BLUEPRINT_KEY = 'org.dxos.blueprint.markdown';
|
|
14
|
-
|
|
15
|
-
const instructions = trim`
|
|
16
|
-
You read, write & create markdown documents.
|
|
17
|
-
`;
|
|
18
|
-
|
|
19
|
-
const make = () =>
|
|
20
|
-
Blueprint.make({
|
|
21
|
-
key: BLUEPRINT_KEY,
|
|
22
|
-
name: 'Markdown',
|
|
23
|
-
description: 'Work with markdown documents.',
|
|
24
|
-
agentCanEnable: true,
|
|
25
|
-
instructions: {
|
|
26
|
-
source: Ref.make(Text.make(instructions)),
|
|
27
|
-
},
|
|
28
|
-
tools: Blueprint.toolDefinitions({ operations: [Create, Read, Update] }),
|
|
29
|
-
});
|
|
30
|
-
|
|
31
|
-
const blueprint: AppCapabilities.BlueprintDefinition = {
|
|
32
|
-
key: BLUEPRINT_KEY,
|
|
33
|
-
make,
|
|
34
|
-
};
|
|
35
|
-
|
|
36
|
-
export default blueprint;
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
//
|
|
2
|
-
// Copyright 2025 DXOS.org
|
|
3
|
-
//
|
|
4
|
-
|
|
5
|
-
import * as Effect from 'effect/Effect';
|
|
6
|
-
|
|
7
|
-
import { Database, Ref } from '@dxos/echo';
|
|
8
|
-
import { Operation } from '@dxos/operation';
|
|
9
|
-
import { Markdown } from '@dxos/plugin-markdown/types';
|
|
10
|
-
|
|
11
|
-
import { Create } from './definitions';
|
|
12
|
-
|
|
13
|
-
export default Create.pipe(
|
|
14
|
-
Operation.withHandler(
|
|
15
|
-
Effect.fn(function* ({ name, content }) {
|
|
16
|
-
const doc = yield* Database.add(Markdown.make({ name, content }));
|
|
17
|
-
return { document: Ref.make(doc) };
|
|
18
|
-
}),
|
|
19
|
-
),
|
|
20
|
-
);
|
|
@@ -1,80 +0,0 @@
|
|
|
1
|
-
//
|
|
2
|
-
// Copyright 2025 DXOS.org
|
|
3
|
-
//
|
|
4
|
-
|
|
5
|
-
import * as Schema from 'effect/Schema';
|
|
6
|
-
|
|
7
|
-
import { Database, Ref } from '@dxos/echo';
|
|
8
|
-
import { Operation } from '@dxos/operation';
|
|
9
|
-
import { Markdown } from '@dxos/plugin-markdown/types';
|
|
10
|
-
|
|
11
|
-
export const Create = Operation.make({
|
|
12
|
-
meta: {
|
|
13
|
-
key: 'org.dxos.function.markdown.create',
|
|
14
|
-
name: 'Create markdown document',
|
|
15
|
-
description: 'Creates a new markdown document.',
|
|
16
|
-
},
|
|
17
|
-
input: Schema.Struct({
|
|
18
|
-
name: Schema.String.annotations({
|
|
19
|
-
description: 'Name of the document.',
|
|
20
|
-
}),
|
|
21
|
-
content: Schema.String.annotations({
|
|
22
|
-
description: 'Content of the document.',
|
|
23
|
-
}),
|
|
24
|
-
}),
|
|
25
|
-
output: Schema.Void,
|
|
26
|
-
services: [Database.Service],
|
|
27
|
-
});
|
|
28
|
-
|
|
29
|
-
export const Read = Operation.make({
|
|
30
|
-
meta: {
|
|
31
|
-
key: 'org.dxos.function.markdown.read',
|
|
32
|
-
name: 'Read markdown document',
|
|
33
|
-
description:
|
|
34
|
-
'Read markdown document. Note that result is a snapshot in time, and might have changed since the document was last read.',
|
|
35
|
-
},
|
|
36
|
-
input: Schema.Struct({
|
|
37
|
-
document: Ref.Ref(Markdown.Document).annotations({
|
|
38
|
-
description: 'The document to read.',
|
|
39
|
-
}),
|
|
40
|
-
}),
|
|
41
|
-
output: Schema.Struct({
|
|
42
|
-
content: Schema.String,
|
|
43
|
-
}),
|
|
44
|
-
services: [Database.Service],
|
|
45
|
-
});
|
|
46
|
-
|
|
47
|
-
export const Open = Operation.make({
|
|
48
|
-
meta: {
|
|
49
|
-
key: 'org.dxos.function.markdown.open',
|
|
50
|
-
name: 'Open',
|
|
51
|
-
description: 'Opens and reads the contents of a markdown document.',
|
|
52
|
-
},
|
|
53
|
-
input: Schema.Struct({
|
|
54
|
-
doc: Ref.Ref(Markdown.Document).annotations({
|
|
55
|
-
description: 'The ID of the markdown document.',
|
|
56
|
-
}),
|
|
57
|
-
}),
|
|
58
|
-
output: Schema.Struct({
|
|
59
|
-
content: Schema.String,
|
|
60
|
-
}),
|
|
61
|
-
services: [Database.Service],
|
|
62
|
-
});
|
|
63
|
-
|
|
64
|
-
export const Update = Operation.make({
|
|
65
|
-
meta: {
|
|
66
|
-
key: 'org.dxos.function.markdown.update',
|
|
67
|
-
name: 'Update markdown',
|
|
68
|
-
description: 'Updates the entire contents of the markdown document.',
|
|
69
|
-
},
|
|
70
|
-
input: Schema.Struct({
|
|
71
|
-
doc: Ref.Ref(Markdown.Document).annotations({
|
|
72
|
-
description: 'The ID of the document to write.',
|
|
73
|
-
}),
|
|
74
|
-
content: Schema.String.annotations({
|
|
75
|
-
description: 'New content to write to the document.',
|
|
76
|
-
}),
|
|
77
|
-
}),
|
|
78
|
-
output: Schema.Void,
|
|
79
|
-
services: [Database.Service],
|
|
80
|
-
});
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
//
|
|
2
|
-
// Copyright 2025 DXOS.org
|
|
3
|
-
//
|
|
4
|
-
|
|
5
|
-
import { OperationHandlerSet } from '@dxos/operation';
|
|
6
|
-
|
|
7
|
-
export * from './definitions';
|
|
8
|
-
|
|
9
|
-
export const MarkdownHandlers = OperationHandlerSet.lazy(
|
|
10
|
-
() => import('./create'),
|
|
11
|
-
() => import('./read'),
|
|
12
|
-
() => import('./update'),
|
|
13
|
-
);
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
//
|
|
2
|
-
// Copyright 2025 DXOS.org
|
|
3
|
-
//
|
|
4
|
-
|
|
5
|
-
import * as Effect from 'effect/Effect';
|
|
6
|
-
|
|
7
|
-
import { Database } from '@dxos/echo';
|
|
8
|
-
import { Operation } from '@dxos/operation';
|
|
9
|
-
|
|
10
|
-
import { Read } from './definitions';
|
|
11
|
-
|
|
12
|
-
export default Read.pipe(
|
|
13
|
-
Operation.withHandler(
|
|
14
|
-
Effect.fn(function* ({ document }) {
|
|
15
|
-
const { content } = yield* document.pipe(
|
|
16
|
-
Database.load,
|
|
17
|
-
Effect.flatMap((doc) => doc.content.pipe(Database.load)),
|
|
18
|
-
);
|
|
19
|
-
return { content };
|
|
20
|
-
}),
|
|
21
|
-
),
|
|
22
|
-
);
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
//
|
|
2
|
-
// Copyright 2025 DXOS.org
|
|
3
|
-
//
|
|
4
|
-
|
|
5
|
-
import * as Effect from 'effect/Effect';
|
|
6
|
-
|
|
7
|
-
import { Database, Obj } from '@dxos/echo';
|
|
8
|
-
import { Operation } from '@dxos/operation';
|
|
9
|
-
|
|
10
|
-
import { Update } from './definitions';
|
|
11
|
-
|
|
12
|
-
export default Update.pipe(
|
|
13
|
-
Operation.withHandler(
|
|
14
|
-
Effect.fn(function* ({ doc, content }) {
|
|
15
|
-
const document = yield* Database.load(doc);
|
|
16
|
-
const text = yield* Database.load(document.content);
|
|
17
|
-
Obj.change(text, (obj) => {
|
|
18
|
-
obj.content = content;
|
|
19
|
-
});
|
|
20
|
-
}),
|
|
21
|
-
),
|
|
22
|
-
);
|
|
@@ -1,122 +0,0 @@
|
|
|
1
|
-
//
|
|
2
|
-
// Copyright 2025 DXOS.org
|
|
3
|
-
//
|
|
4
|
-
|
|
5
|
-
import { describe, it } from '@effect/vitest';
|
|
6
|
-
import * as Effect from 'effect/Effect';
|
|
7
|
-
import * as Layer from 'effect/Layer';
|
|
8
|
-
|
|
9
|
-
import { AiService } from '@dxos/ai';
|
|
10
|
-
import { GenericToolkit } from '@dxos/ai';
|
|
11
|
-
import { AiServiceTestingPreset } from '@dxos/ai/testing';
|
|
12
|
-
import { AiConversation, ToolExecutionServices } from '@dxos/assistant';
|
|
13
|
-
import { Blueprint } from '@dxos/blueprints';
|
|
14
|
-
import { Obj, Ref } from '@dxos/echo';
|
|
15
|
-
import { Database, Feed } from '@dxos/echo';
|
|
16
|
-
import { acquireReleaseResource } from '@dxos/effect';
|
|
17
|
-
import { TestHelpers } from '@dxos/effect/testing';
|
|
18
|
-
import { Trace, TracingService } from '@dxos/functions';
|
|
19
|
-
import { FunctionImplementationResolver } from '@dxos/functions-runtime';
|
|
20
|
-
import { FunctionInvocationServiceLayerTestMocked, TestDatabaseLayer } from '@dxos/functions-runtime/testing';
|
|
21
|
-
import { log } from '@dxos/log';
|
|
22
|
-
import { Markdown } from '@dxos/plugin-markdown/types';
|
|
23
|
-
import { Text } from '@dxos/schema';
|
|
24
|
-
import { trim } from '@dxos/util';
|
|
25
|
-
|
|
26
|
-
import { type TestStep, runSteps } from '../testing';
|
|
27
|
-
import PlanningOldBlueprint from './blueprint';
|
|
28
|
-
import { TaskHandlers } from './functions';
|
|
29
|
-
|
|
30
|
-
describe('Planning Blueprint', { timeout: 120_000 }, () => {
|
|
31
|
-
const blueprint = PlanningOldBlueprint.make();
|
|
32
|
-
it.scoped(
|
|
33
|
-
'planning blueprint',
|
|
34
|
-
Effect.fn(
|
|
35
|
-
function* ({ expect }) {
|
|
36
|
-
const feed = Feed.make();
|
|
37
|
-
yield* Database.add(feed);
|
|
38
|
-
const runtime = yield* Effect.runtime<Feed.FeedService>();
|
|
39
|
-
const conversation = yield* acquireReleaseResource(() => new AiConversation({ feed, runtime }));
|
|
40
|
-
|
|
41
|
-
yield* Database.add(blueprint);
|
|
42
|
-
yield* Effect.promise(() =>
|
|
43
|
-
conversation.context.bind({
|
|
44
|
-
blueprints: [Ref.make(blueprint)],
|
|
45
|
-
}),
|
|
46
|
-
);
|
|
47
|
-
|
|
48
|
-
const artifact = yield* Database.add(Markdown.make());
|
|
49
|
-
let prevContent = artifact.content;
|
|
50
|
-
const matchList =
|
|
51
|
-
({ includes = [], excludes = [] }: { includes: RegExp[]; excludes?: RegExp[] }) =>
|
|
52
|
-
async () => {
|
|
53
|
-
const { content } = await artifact.content.load();
|
|
54
|
-
log.info('spec', { doc: artifact.content.target?.content });
|
|
55
|
-
expect(content).not.toBe(prevContent);
|
|
56
|
-
const text = content.toLowerCase();
|
|
57
|
-
for (const include of includes) {
|
|
58
|
-
expect(text.match(include), `does not include: ${include}`).toBeTruthy();
|
|
59
|
-
}
|
|
60
|
-
for (const exclude of excludes) {
|
|
61
|
-
expect(text.match(exclude), `includes: ${exclude}`).toBeFalsy();
|
|
62
|
-
}
|
|
63
|
-
prevContent = artifact.content;
|
|
64
|
-
};
|
|
65
|
-
|
|
66
|
-
const system = 'You are a helpful assistant.';
|
|
67
|
-
const steps: TestStep[] = [
|
|
68
|
-
{
|
|
69
|
-
system,
|
|
70
|
-
prompt: trim`
|
|
71
|
-
I'm building a shelf.
|
|
72
|
-
Maintain a shopping list here: ${Obj.getDXN(artifact)}
|
|
73
|
-
I need a hammer, nails, and a saw.
|
|
74
|
-
`,
|
|
75
|
-
test: matchList({
|
|
76
|
-
includes: [/- \[.+hammer/, /- \[.+nails/, /- \[.+saw/],
|
|
77
|
-
}),
|
|
78
|
-
},
|
|
79
|
-
{
|
|
80
|
-
system,
|
|
81
|
-
prompt: trim`
|
|
82
|
-
I will need a board too.
|
|
83
|
-
`,
|
|
84
|
-
test: matchList({
|
|
85
|
-
includes: [/- \[.+board/],
|
|
86
|
-
}),
|
|
87
|
-
},
|
|
88
|
-
{
|
|
89
|
-
system,
|
|
90
|
-
prompt: trim`
|
|
91
|
-
Actually I'm going to use screws and a screwdriver.
|
|
92
|
-
`,
|
|
93
|
-
test: matchList({
|
|
94
|
-
includes: [/- \[.+screwdriver/, /- \[.+screws/],
|
|
95
|
-
excludes: [/- \[.+hammer/, /- \[.+nails/],
|
|
96
|
-
}),
|
|
97
|
-
},
|
|
98
|
-
];
|
|
99
|
-
|
|
100
|
-
yield* runSteps(conversation, steps);
|
|
101
|
-
},
|
|
102
|
-
Effect.provide(
|
|
103
|
-
Layer.mergeAll(
|
|
104
|
-
TestDatabaseLayer({ types: [Text.Text, Markdown.Document, Blueprint.Blueprint] }),
|
|
105
|
-
ToolExecutionServices,
|
|
106
|
-
AiService.model('@anthropic/claude-3-5-sonnet-20241022'),
|
|
107
|
-
).pipe(
|
|
108
|
-
Layer.provideMerge(
|
|
109
|
-
FunctionInvocationServiceLayerTestMocked({ functions: TaskHandlers }).pipe(
|
|
110
|
-
Layer.provideMerge(Layer.mergeAll(TracingService.layerNoop, Trace.writerLayerNoop)),
|
|
111
|
-
),
|
|
112
|
-
),
|
|
113
|
-
Layer.provideMerge(FunctionImplementationResolver.layerTest({ functions: TaskHandlers })),
|
|
114
|
-
Layer.provideMerge(TestDatabaseLayer({ types: [Text.Text, Markdown.Document, Blueprint.Blueprint] })),
|
|
115
|
-
Layer.provideMerge(Layer.mergeAll(GenericToolkit.providerEmpty, AiServiceTestingPreset('direct'))),
|
|
116
|
-
),
|
|
117
|
-
),
|
|
118
|
-
TestHelpers.provideTestContext,
|
|
119
|
-
TestHelpers.taggedTest('llm'),
|
|
120
|
-
),
|
|
121
|
-
);
|
|
122
|
-
});
|
|
@@ -1,106 +0,0 @@
|
|
|
1
|
-
//
|
|
2
|
-
// Copyright 2025 DXOS.org
|
|
3
|
-
//
|
|
4
|
-
|
|
5
|
-
import { type AppCapabilities } from '@dxos/app-toolkit';
|
|
6
|
-
import { Blueprint } from '@dxos/blueprints';
|
|
7
|
-
import { Ref } from '@dxos/echo';
|
|
8
|
-
import { Text } from '@dxos/schema';
|
|
9
|
-
import { trim } from '@dxos/util';
|
|
10
|
-
|
|
11
|
-
import { ReadTasks, UpdateTasks } from './functions';
|
|
12
|
-
|
|
13
|
-
const BLUEPRINT_KEY = 'org.dxos.blueprint.planning';
|
|
14
|
-
|
|
15
|
-
/**
|
|
16
|
-
* Agent prompt instructions for managing hierarchical task lists.
|
|
17
|
-
*/
|
|
18
|
-
const instructions = trim`
|
|
19
|
-
You are a task management agent that maintains hierarchical task lists where each line is a task.
|
|
20
|
-
|
|
21
|
-
## Document Format
|
|
22
|
-
You will receive task lists with line numbers prefixed like:
|
|
23
|
-
|
|
24
|
-
${'```'}
|
|
25
|
-
1. - [ ] First main task
|
|
26
|
-
2. - [ ] Subtask 1: Research phase
|
|
27
|
-
3. - [x] Literature review
|
|
28
|
-
4. - [ ] Stakeholder interviews
|
|
29
|
-
5. - [ ] Subtask 2: Implementation
|
|
30
|
-
6. - [ ] Setup infrastructure
|
|
31
|
-
7. - [ ] Write core functionality
|
|
32
|
-
8. - [ ] Another main task
|
|
33
|
-
${'```'}
|
|
34
|
-
|
|
35
|
-
## Task Hierarchy
|
|
36
|
-
- 0 spaces: Top-level tasks
|
|
37
|
-
- 2 spaces: First-level subtasks
|
|
38
|
-
- 4 spaces: Second-level subtasks
|
|
39
|
-
- 6 spaces: Third-level subtasks (and so on)
|
|
40
|
-
|
|
41
|
-
## Available Operations
|
|
42
|
-
You can modify the task list using these operations:
|
|
43
|
-
|
|
44
|
-
1. **insertTask(lineNumber, text, completed?, indent?)** - Insert a new task
|
|
45
|
-
2. **deleteTask(lineNumber)** - Delete a task
|
|
46
|
-
3. **updateTaskText(lineNumber, text)** - Change task description
|
|
47
|
-
4. **toggleTaskCompletion(lineNumber, completed?)** - Mark task complete/incomplete
|
|
48
|
-
5. **setTaskIndent(lineNumber, indent)** - Change task hierarchy level
|
|
49
|
-
|
|
50
|
-
## Examples
|
|
51
|
-
|
|
52
|
-
### Example 1: Adding a subtask
|
|
53
|
-
**User:** "Add a subtask 'Code review' under the task on line 1"
|
|
54
|
-
**Response:** \`insertTask(2, "Code review", false, 2)\`
|
|
55
|
-
|
|
56
|
-
### Example 2: Marking a task complete
|
|
57
|
-
**User:** "Mark the task on line 3 as complete"
|
|
58
|
-
**Response:** \`toggleTaskCompletion(3, true)\`
|
|
59
|
-
|
|
60
|
-
### Example 3: Updating task text
|
|
61
|
-
**User:** "Change the task on line 5 to 'Backend implementation'"
|
|
62
|
-
**Response:** \`updateTaskText(5, "Backend implementation")\`
|
|
63
|
-
|
|
64
|
-
### Example 4: Creating a task hierarchy
|
|
65
|
-
**User:** "Add a main task 'Testing phase' with two subtasks"
|
|
66
|
-
**Response:**
|
|
67
|
-
\`\`\`
|
|
68
|
-
insertTask(999, "Testing phase", false, 0)
|
|
69
|
-
insertTask(999, "Unit tests", false, 2)
|
|
70
|
-
insertTask(999, "Integration tests", false, 2)
|
|
71
|
-
\`\`\`
|
|
72
|
-
|
|
73
|
-
### Example 5: Reorganizing hierarchy
|
|
74
|
-
**User:** "Move the task on line 4 to be a main task (top level)"
|
|
75
|
-
**Response:** \`setTaskIndent(4, 0)\`
|
|
76
|
-
|
|
77
|
-
### Example 6: Adding nested subtasks
|
|
78
|
-
**User:** "Add a sub-subtask 'Write test cases' under line 6"
|
|
79
|
-
**Response:** \`insertTask(7, "Write test cases", false, 4)\`
|
|
80
|
-
|
|
81
|
-
## Guidelines
|
|
82
|
-
- Always reference line numbers from the numbered document you receive
|
|
83
|
-
- Use line number 999 to append to the end of the document
|
|
84
|
-
- Maintain logical hierarchy (subtasks should be indented under their parent)
|
|
85
|
-
- Use appropriate indentation levels (0, 2, 4, 6, etc. spaces)
|
|
86
|
-
- When creating subtasks, consider the parent task's completion status
|
|
87
|
-
- Be precise with task descriptions and hierarchy levels
|
|
88
|
-
`;
|
|
89
|
-
|
|
90
|
-
const make = () =>
|
|
91
|
-
Blueprint.make({
|
|
92
|
-
key: BLUEPRINT_KEY,
|
|
93
|
-
name: 'Planning',
|
|
94
|
-
description: 'Plans and tracks complex tasks with artifact management.',
|
|
95
|
-
instructions: {
|
|
96
|
-
source: Ref.make(Text.make(instructions)),
|
|
97
|
-
},
|
|
98
|
-
tools: Blueprint.toolDefinitions({ operations: [ReadTasks, UpdateTasks] }),
|
|
99
|
-
});
|
|
100
|
-
|
|
101
|
-
const blueprint: AppCapabilities.BlueprintDefinition = {
|
|
102
|
-
key: BLUEPRINT_KEY,
|
|
103
|
-
make,
|
|
104
|
-
};
|
|
105
|
-
|
|
106
|
-
export default blueprint;
|
|
@@ -1,53 +0,0 @@
|
|
|
1
|
-
//
|
|
2
|
-
// Copyright 2025 DXOS.org
|
|
3
|
-
//
|
|
4
|
-
|
|
5
|
-
import * as Schema from 'effect/Schema';
|
|
6
|
-
|
|
7
|
-
import { Database, Ref } from '@dxos/echo';
|
|
8
|
-
import { Operation } from '@dxos/operation';
|
|
9
|
-
import { Markdown } from '@dxos/plugin-markdown/types';
|
|
10
|
-
|
|
11
|
-
export const ReadTasks = Operation.make({
|
|
12
|
-
meta: {
|
|
13
|
-
key: 'org.dxos.function.markdown.read-tasks',
|
|
14
|
-
name: 'Read',
|
|
15
|
-
description: 'Read markdown tasks.',
|
|
16
|
-
},
|
|
17
|
-
input: Schema.Struct({
|
|
18
|
-
doc: Ref.Ref(Markdown.Document).annotations({
|
|
19
|
-
description: 'The ID of the document to read.',
|
|
20
|
-
}),
|
|
21
|
-
}),
|
|
22
|
-
output: Schema.Struct({
|
|
23
|
-
content: Schema.String,
|
|
24
|
-
}),
|
|
25
|
-
services: [Database.Service],
|
|
26
|
-
});
|
|
27
|
-
|
|
28
|
-
export const UpdateTasks = Operation.make({
|
|
29
|
-
meta: {
|
|
30
|
-
key: 'org.dxos.function.markdown.update-tasks',
|
|
31
|
-
name: 'Update markdown',
|
|
32
|
-
description: 'Creates and updates tasks in markdown documents.',
|
|
33
|
-
},
|
|
34
|
-
input: Schema.Struct({
|
|
35
|
-
doc: Ref.Ref(Markdown.Document).annotations({
|
|
36
|
-
description: 'The ID of the document to update.',
|
|
37
|
-
}),
|
|
38
|
-
operations: Schema.optional(
|
|
39
|
-
Schema.Array(
|
|
40
|
-
Schema.Any.annotations({
|
|
41
|
-
description: 'Task operations to apply.',
|
|
42
|
-
}),
|
|
43
|
-
),
|
|
44
|
-
),
|
|
45
|
-
}),
|
|
46
|
-
output: Schema.Struct({
|
|
47
|
-
content: Schema.String,
|
|
48
|
-
numberedContent: Schema.String.annotations({
|
|
49
|
-
description: 'Content with line numbers for agent reference.',
|
|
50
|
-
}),
|
|
51
|
-
}),
|
|
52
|
-
services: [Database.Service],
|
|
53
|
-
});
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
//
|
|
2
|
-
// Copyright 2025 DXOS.org
|
|
3
|
-
//
|
|
4
|
-
|
|
5
|
-
import * as Effect from 'effect/Effect';
|
|
6
|
-
|
|
7
|
-
import { Database } from '@dxos/echo';
|
|
8
|
-
import { Operation } from '@dxos/operation';
|
|
9
|
-
|
|
10
|
-
import { ReadTasks } from './definitions';
|
|
11
|
-
|
|
12
|
-
export default ReadTasks.pipe(
|
|
13
|
-
Operation.withHandler(
|
|
14
|
-
Effect.fn(function* ({ doc }) {
|
|
15
|
-
const document = yield* Database.load(doc);
|
|
16
|
-
|
|
17
|
-
const { content } = yield* Database.load(document.content);
|
|
18
|
-
const lines = content.split('\n');
|
|
19
|
-
const len = String(lines.length).length;
|
|
20
|
-
const numbered = lines.map((line, i) => `${String(i + 1).padStart(len, ' ')}. ${line}`).join('\n');
|
|
21
|
-
return { content: numbered };
|
|
22
|
-
}),
|
|
23
|
-
),
|
|
24
|
-
);
|