@cursor/july 0.1.113 → 0.1.114
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/docs/404.html +2 -2
- package/dist/docs/assets/{app.CAeK13eM.js → app.BqkJwOZ-.js} +4 -4
- package/dist/docs/assets/chunks/@localSearchIndexroot.BnSgidYE.js +1 -0
- package/dist/docs/assets/chunks/{VPLocalSearchBox.C9LbPHod.js → VPLocalSearchBox.BJAi2KiV.js} +1 -1
- package/dist/docs/assets/chunks/{arc.CmMq2zmS.js → arc.BZpXTgvV.js} +1 -1
- package/dist/docs/assets/chunks/{architectureDiagram-Q4EWVU46.CCXB8Uj5.js → architectureDiagram-Q4EWVU46.WYI-7F-Y.js} +1 -1
- package/dist/docs/assets/chunks/{baseUniq.CyQo6eLe.js → baseUniq.CZaUPpg0.js} +1 -1
- package/dist/docs/assets/chunks/{blockDiagram-DXYQGD6D.JYq6w91N.js → blockDiagram-DXYQGD6D.D6UES2pD.js} +1 -1
- package/dist/docs/assets/chunks/{c4Diagram-AHTNJAMY.BRV8GPJJ.js → c4Diagram-AHTNJAMY.cwebIe4i.js} +1 -1
- package/dist/docs/assets/chunks/channel.DdM5EfNW.js +1 -0
- package/dist/docs/assets/chunks/{chunk-4BX2VUAB.Bv4ooYQR.js → chunk-4BX2VUAB.fVyFnjxg.js} +1 -1
- package/dist/docs/assets/chunks/{chunk-4TB4RGXK.t4JtKPcj.js → chunk-4TB4RGXK.BanufG1c.js} +1 -1
- package/dist/docs/assets/chunks/{chunk-55IACEB6.34lCHj9Y.js → chunk-55IACEB6.VaSMz5-2.js} +1 -1
- package/dist/docs/assets/chunks/{chunk-EDXVE4YY.BSwrPNrt.js → chunk-EDXVE4YY.CN2diZOM.js} +1 -1
- package/dist/docs/assets/chunks/{chunk-FMBD7UC4.Beeun-R-.js → chunk-FMBD7UC4.g4ivypu3.js} +1 -1
- package/dist/docs/assets/chunks/{chunk-OYMX7WX6.BUUFUcJc.js → chunk-OYMX7WX6.GZXKn9JJ.js} +1 -1
- package/dist/docs/assets/chunks/{chunk-QZHKN3VN.B2XjHzN_.js → chunk-QZHKN3VN.itXxJZCd.js} +1 -1
- package/dist/docs/assets/chunks/{chunk-YZCP3GAM.CLYG8znk.js → chunk-YZCP3GAM.-rw2GfvX.js} +1 -1
- package/dist/docs/assets/chunks/classDiagram-6PBFFD2Q.CjfGHeg2.js +1 -0
- package/dist/docs/assets/chunks/classDiagram-v2-HSJHXN6E.CjfGHeg2.js +1 -0
- package/dist/docs/assets/chunks/clone.wSOICb_f.js +1 -0
- package/dist/docs/assets/chunks/{cose-bilkent-S5V4N54A.DVEa6fZp.js → cose-bilkent-S5V4N54A.CmaI5br0.js} +1 -1
- package/dist/docs/assets/chunks/{dagre-KV5264BT.C9PZQK-S.js → dagre-KV5264BT.4wY9S4Kt.js} +1 -1
- package/dist/docs/assets/chunks/{diagram-5BDNPKRD.DoN0uv3Y.js → diagram-5BDNPKRD.Pc3c0u9W.js} +1 -1
- package/dist/docs/assets/chunks/{diagram-G4DWMVQ6.Czv3duqx.js → diagram-G4DWMVQ6.CYrWz-nj.js} +1 -1
- package/dist/docs/assets/chunks/{diagram-MMDJMWI5.BinJ5kWb.js → diagram-MMDJMWI5.Bgj5hukb.js} +1 -1
- package/dist/docs/assets/chunks/{diagram-TYMM5635.DW326M4K.js → diagram-TYMM5635.DGMEXalS.js} +1 -1
- package/dist/docs/assets/chunks/{erDiagram-SMLLAGMA.U2pR_OA7.js → erDiagram-SMLLAGMA.GepTV9Im.js} +1 -1
- package/dist/docs/assets/chunks/{flowDiagram-DWJPFMVM.ByWJXeYK.js → flowDiagram-DWJPFMVM.DVKywg3j.js} +1 -1
- package/dist/docs/assets/chunks/{ganttDiagram-T4ZO3ILL.OquF0Rtg.js → ganttDiagram-T4ZO3ILL.C7qt9Mlo.js} +1 -1
- package/dist/docs/assets/chunks/{gitGraphDiagram-UUTBAWPF.Bpn01P7X.js → gitGraphDiagram-UUTBAWPF.U30_r82P.js} +1 -1
- package/dist/docs/assets/chunks/{graph.CNRB6ETL.js → graph.CyyMyAWv.js} +1 -1
- package/dist/docs/assets/chunks/{infoDiagram-42DDH7IO.CqhknMWi.js → infoDiagram-42DDH7IO.Dn9ACW3y.js} +1 -1
- package/dist/docs/assets/chunks/{ishikawaDiagram-UXIWVN3A.C6xpR2af.js → ishikawaDiagram-UXIWVN3A.DlIdIGOA.js} +1 -1
- package/dist/docs/assets/chunks/{journeyDiagram-VCZTEJTY.Cg5f7oB3.js → journeyDiagram-VCZTEJTY.DZj4vy4E.js} +1 -1
- package/dist/docs/assets/chunks/{kanban-definition-6JOO6SKY.Cx9YTwlU.js → kanban-definition-6JOO6SKY.Dl63eMUV.js} +1 -1
- package/dist/docs/assets/chunks/{layout.ljS-wFtK.js → layout.BLHZLWPH.js} +1 -1
- package/dist/docs/assets/chunks/{linear.jSxNrsFC.js → linear.aXKGKaNw.js} +1 -1
- package/dist/docs/assets/chunks/{min.Cum8AlQw.js → min.zWnFcpcc.js} +1 -1
- package/dist/docs/assets/chunks/{mindmap-definition-QFDTVHPH.BLiysLpe.js → mindmap-definition-QFDTVHPH.Qs4MQBea.js} +1 -1
- package/dist/docs/assets/chunks/{pieDiagram-DEJITSTG.BoIDyuKF.js → pieDiagram-DEJITSTG.BmPHgsk7.js} +1 -1
- package/dist/docs/assets/chunks/{quadrantDiagram-34T5L4WZ.DLkpDytR.js → quadrantDiagram-34T5L4WZ.D5MQ3gwA.js} +1 -1
- package/dist/docs/assets/chunks/{requirementDiagram-MS252O5E.DqTVqSu2.js → requirementDiagram-MS252O5E.CkdUFrO7.js} +1 -1
- package/dist/docs/assets/chunks/{sankeyDiagram-XADWPNL6.CG_6FF7j.js → sankeyDiagram-XADWPNL6.KZrljrAV.js} +1 -1
- package/dist/docs/assets/chunks/{sequenceDiagram-FGHM5R23.BIp9602K.js → sequenceDiagram-FGHM5R23.XMoEW-Lx.js} +1 -1
- package/dist/docs/assets/chunks/{stateDiagram-FHFEXIEX.COSXsD9I.js → stateDiagram-FHFEXIEX.BmTzePLj.js} +1 -1
- package/dist/docs/assets/chunks/stateDiagram-v2-QKLJ7IA2.Cu5X28zZ.js +1 -0
- package/dist/docs/assets/chunks/{theme.CXJ7PNwy.js → theme.BfQzpxsg.js} +2 -2
- package/dist/docs/assets/chunks/{timeline-definition-GMOUNBTQ.CXdVqkLq.js → timeline-definition-GMOUNBTQ.Dug0oamp.js} +1 -1
- package/dist/docs/assets/chunks/{vennDiagram-DHZGUBPP.CZxGuc4r.js → vennDiagram-DHZGUBPP.BOTHrEFu.js} +1 -1
- package/dist/docs/assets/chunks/{wardley-RL74JXVD.3oVgfqQk.js → wardley-RL74JXVD.DXy2i1LS.js} +1 -1
- package/dist/docs/assets/chunks/{wardleyDiagram-NUSXRM2D.6_irCgGJ.js → wardleyDiagram-NUSXRM2D.CoXKdfi6.js} +1 -1
- package/dist/docs/assets/chunks/{xychartDiagram-5P7HB3ND.TRPe92m3.js → xychartDiagram-5P7HB3ND.DXoSCjAW.js} +1 -1
- package/dist/docs/assets/{deployment.md.D2jQZuFx.js → deployment.md.D2YX7u_I.js} +1 -1
- package/dist/docs/assets/{guides_agent-to-agent.md.CD4T5FIl.js → guides_agent-to-agent.md.C6kPY8nu.js} +2 -2
- package/dist/docs/assets/{guides_cloud-agents.md.Cp1O3u-X.js → guides_cloud-agents.md.BPJqTZjT.js} +1 -1
- package/dist/docs/assets/{guides_grokbot-agents.md.CMhZNdEU.js → guides_grokbot-agents.md.CzV715v8.js} +1 -1
- package/dist/docs/assets/guides_hooks.md.BT9GLwEp.js +50 -0
- package/dist/docs/assets/guides_hooks.md.BT9GLwEp.lean.js +1 -0
- package/dist/docs/assets/{guides_jev.md.F5fAkkfN.js → guides_jev.md.DeSCqMaO.js} +6 -44
- package/dist/docs/assets/guides_jev.md.DeSCqMaO.lean.js +1 -0
- package/dist/docs/assets/reference_agent-config.md.BRxAlnRy.js +36 -0
- package/dist/docs/assets/{reference_agent-config.md.DGPyw7ms.lean.js → reference_agent-config.md.BRxAlnRy.lean.js} +1 -1
- package/dist/docs/assets/reference_artifacts.md.KRX0sAdt.js +18 -0
- package/dist/docs/assets/reference_artifacts.md.KRX0sAdt.lean.js +1 -0
- package/dist/docs/assets/reference_channels.md.DZr14vm7.js +23 -0
- package/dist/docs/assets/reference_channels.md.DZr14vm7.lean.js +1 -0
- package/dist/docs/assets/{reference_connections.md.Je9dMsdd.js → reference_connections.md.DJGUCxrr.js} +18 -30
- package/dist/docs/assets/{reference_connections.md.Je9dMsdd.lean.js → reference_connections.md.DJGUCxrr.lean.js} +1 -1
- package/dist/docs/assets/{reference_evals.md.DNJzM_yf.js → reference_evals.md.C6umwNC6.js} +6 -7
- package/dist/docs/assets/reference_evals.md.C6umwNC6.lean.js +1 -0
- package/dist/docs/assets/{reference_extensions.md.Cv5aLCz_.js → reference_extensions.md.DbNYu-DP.js} +3 -3
- package/dist/docs/assets/{reference_extensions.md.Cv5aLCz_.lean.js → reference_extensions.md.DbNYu-DP.lean.js} +1 -1
- package/dist/docs/assets/reference_hooks.md.BfOkhTU0.js +45 -0
- package/dist/docs/assets/{reference_hooks.md.B7uzNENk.lean.js → reference_hooks.md.BfOkhTU0.lean.js} +1 -1
- package/dist/docs/assets/reference_http-api.md.DdwtBeCj.js +11 -0
- package/dist/docs/assets/{reference_http-api.md.CduHavZ2.lean.js → reference_http-api.md.DdwtBeCj.lean.js} +1 -1
- package/dist/docs/assets/reference_instructions.md.B2mcIzT6.js +14 -0
- package/dist/docs/assets/reference_instructions.md.B2mcIzT6.lean.js +1 -0
- package/dist/docs/assets/reference_playground.md.CyrQD_n3.js +1 -0
- package/dist/docs/assets/reference_playground.md.CyrQD_n3.lean.js +1 -0
- package/dist/docs/assets/reference_project-layout.md.BEMzxAkq.js +19 -0
- package/dist/docs/assets/{reference_project-layout.md.BGhgpy9V.lean.js → reference_project-layout.md.BEMzxAkq.lean.js} +1 -1
- package/dist/docs/assets/reference_prompt.md.BFrqjHFL.js +9 -0
- package/dist/docs/assets/reference_prompt.md.BFrqjHFL.lean.js +1 -0
- package/dist/docs/assets/reference_schedules.md.BB9N3tRR.js +47 -0
- package/dist/docs/assets/reference_schedules.md.BB9N3tRR.lean.js +1 -0
- package/dist/docs/assets/reference_sessions.md.BBp-GIt-.js +1 -0
- package/dist/docs/assets/{reference_sessions.md.1_6Vyv7x.lean.js → reference_sessions.md.BBp-GIt-.lean.js} +1 -1
- package/dist/docs/assets/reference_skills.md.BVmi3UJ_.js +15 -0
- package/dist/docs/assets/{reference_skills.md.DjQkRefx.lean.js → reference_skills.md.BVmi3UJ_.lean.js} +1 -1
- package/dist/docs/assets/reference_subagents.md.DRoRy2Uj.js +10 -0
- package/dist/docs/assets/{reference_subagents.md.Dl16gcBj.lean.js → reference_subagents.md.DRoRy2Uj.lean.js} +1 -1
- package/dist/docs/assets/{reference_tools.md.B1dH1lpa.js → reference_tools.md.CgocLDX1.js} +9 -6
- package/dist/docs/assets/{reference_tools.md.B1dH1lpa.lean.js → reference_tools.md.CgocLDX1.lean.js} +1 -1
- package/dist/docs/assets/troubleshooting.md.HY95rCCz.js +1 -0
- package/dist/docs/building-with-agents.html +35 -35
- package/dist/docs/deployment.html +37 -37
- package/dist/docs/deployment.md +1 -1
- package/dist/docs/evals.html +35 -35
- package/dist/docs/guides/agent-to-agent.html +38 -38
- package/dist/docs/guides/agent-to-agent.md +11 -12
- package/dist/docs/guides/bitbucket.html +35 -35
- package/dist/docs/guides/cloud-agents.html +36 -36
- package/dist/docs/guides/cloud-agents.md +1 -1
- package/dist/docs/guides/convert-automation.html +35 -35
- package/dist/docs/guides/github.html +35 -35
- package/dist/docs/guides/gitlab.html +35 -35
- package/dist/docs/guides/grokbot-agents.html +37 -37
- package/dist/docs/guides/grokbot-agents.md +1 -1
- package/dist/docs/guides/hooks.html +109 -0
- package/dist/docs/guides/hooks.md +111 -0
- package/dist/docs/guides/improve.html +35 -35
- package/dist/docs/guides/jev.html +42 -80
- package/dist/docs/guides/jev.md +22 -79
- package/dist/docs/guides/mcp-oauth.html +36 -36
- package/dist/docs/guides/opentelemetry.html +35 -35
- package/dist/docs/guides/slack.html +35 -35
- package/dist/docs/guides/webhooks.html +35 -35
- package/dist/docs/hashmap.json +1 -1
- package/dist/docs/hillclimbing.html +35 -35
- package/dist/docs/index.html +35 -35
- package/dist/docs/llms-full.txt +993 -1303
- package/dist/docs/llms.txt +8 -7
- package/dist/docs/quickstart.html +35 -35
- package/dist/docs/reference/agent-config.html +42 -46
- package/dist/docs/reference/agent-config.md +48 -81
- package/dist/docs/reference/artifacts.html +39 -40
- package/dist/docs/reference/artifacts.md +71 -70
- package/dist/docs/reference/channels.html +41 -61
- package/dist/docs/reference/channels.md +134 -201
- package/dist/docs/reference/cli.html +35 -35
- package/dist/docs/reference/connections.html +54 -66
- package/dist/docs/reference/connections.md +92 -128
- package/dist/docs/reference/evals.html +42 -43
- package/dist/docs/reference/evals.md +42 -50
- package/dist/docs/reference/extensions.html +38 -38
- package/dist/docs/reference/extensions.md +9 -13
- package/dist/docs/reference/hooks.html +39 -67
- package/dist/docs/reference/hooks.md +72 -146
- package/dist/docs/reference/http-api.html +39 -39
- package/dist/docs/reference/http-api.md +137 -161
- package/dist/docs/reference/instructions.html +39 -39
- package/dist/docs/reference/instructions.md +21 -36
- package/dist/docs/reference/playground.html +36 -36
- package/dist/docs/reference/playground.md +26 -43
- package/dist/docs/reference/project-layout.html +38 -38
- package/dist/docs/reference/project-layout.md +12 -17
- package/dist/docs/reference/prompt.html +42 -42
- package/dist/docs/reference/prompt.md +18 -13
- package/dist/docs/reference/schedules.html +56 -91
- package/dist/docs/reference/schedules.md +52 -99
- package/dist/docs/reference/sessions.html +36 -36
- package/dist/docs/reference/sessions.md +36 -40
- package/dist/docs/reference/skills.html +38 -38
- package/dist/docs/reference/skills.md +15 -26
- package/dist/docs/reference/subagents.html +38 -38
- package/dist/docs/reference/subagents.md +20 -30
- package/dist/docs/reference/tools.html +44 -41
- package/dist/docs/reference/tools.md +45 -64
- package/dist/docs/templates/agentic-owners.html +35 -35
- package/dist/docs/templates/pr-autofixer.html +35 -35
- package/dist/docs/templates/security-reviewer.html +35 -35
- package/dist/docs/templates/thermo-quality-review.html +35 -35
- package/dist/docs/templates/thermo-review.html +35 -35
- package/dist/docs/templates/triage.html +35 -35
- package/dist/docs/troubleshooting.html +36 -36
- package/dist/docs/troubleshooting.md +1 -1
- package/dist/playground/assets/{index-DSMAewbx.css → index-C61EWMBK.css} +1 -1
- package/dist/playground/index.html +2 -2
- package/docs/deployment.md +1 -1
- package/docs/guides/agent-to-agent.md +11 -12
- package/docs/guides/cloud-agents.md +1 -1
- package/docs/guides/grokbot-agents.md +1 -1
- package/docs/guides/hooks.md +116 -0
- package/docs/guides/jev.md +23 -80
- package/docs/reference/agent-config.md +48 -81
- package/docs/reference/artifacts.md +72 -71
- package/docs/reference/channels.md +135 -202
- package/docs/reference/connections.md +93 -129
- package/docs/reference/evals.md +43 -51
- package/docs/reference/extensions.md +9 -13
- package/docs/reference/hooks.md +72 -146
- package/docs/reference/http-api.md +137 -161
- package/docs/reference/instructions.md +22 -37
- package/docs/reference/playground.md +26 -43
- package/docs/reference/project-layout.md +12 -17
- package/docs/reference/prompt.md +20 -15
- package/docs/reference/schedules.md +52 -99
- package/docs/reference/sessions.md +36 -40
- package/docs/reference/skills.md +15 -26
- package/docs/reference/subagents.md +20 -30
- package/docs/reference/tools.md +45 -64
- package/docs/troubleshooting.md +1 -1
- package/package.json +1 -1
- package/dist/docs/assets/chunks/@localSearchIndexroot.Ck9E52Ls.js +0 -1
- package/dist/docs/assets/chunks/channel.BHiYmnZ4.js +0 -1
- package/dist/docs/assets/chunks/classDiagram-6PBFFD2Q.Degh8l90.js +0 -1
- package/dist/docs/assets/chunks/classDiagram-v2-HSJHXN6E.Degh8l90.js +0 -1
- package/dist/docs/assets/chunks/clone.BIywbczV.js +0 -1
- package/dist/docs/assets/chunks/stateDiagram-v2-QKLJ7IA2.qrxrbFsX.js +0 -1
- package/dist/docs/assets/guides_jev.md.F5fAkkfN.lean.js +0 -1
- package/dist/docs/assets/reference_agent-config.md.DGPyw7ms.js +0 -40
- package/dist/docs/assets/reference_artifacts.md.Bu_4HmsD.js +0 -19
- package/dist/docs/assets/reference_artifacts.md.Bu_4HmsD.lean.js +0 -1
- package/dist/docs/assets/reference_channels.md.nFWbzAic.js +0 -43
- package/dist/docs/assets/reference_channels.md.nFWbzAic.lean.js +0 -1
- package/dist/docs/assets/reference_evals.md.DNJzM_yf.lean.js +0 -1
- package/dist/docs/assets/reference_hooks.md.B7uzNENk.js +0 -73
- package/dist/docs/assets/reference_http-api.md.CduHavZ2.js +0 -11
- package/dist/docs/assets/reference_instructions.md.CU1My5My.js +0 -14
- package/dist/docs/assets/reference_instructions.md.CU1My5My.lean.js +0 -1
- package/dist/docs/assets/reference_playground.md.Ch2d0Iqi.js +0 -1
- package/dist/docs/assets/reference_playground.md.Ch2d0Iqi.lean.js +0 -1
- package/dist/docs/assets/reference_project-layout.md.BGhgpy9V.js +0 -19
- package/dist/docs/assets/reference_prompt.md.Ccp0R53H.js +0 -1
- package/dist/docs/assets/reference_prompt.md.Ccp0R53H.lean.js +0 -1
- package/dist/docs/assets/reference_schedules.md.B2Nm6FaD.js +0 -82
- package/dist/docs/assets/reference_schedules.md.B2Nm6FaD.lean.js +0 -1
- package/dist/docs/assets/reference_sessions.md.1_6Vyv7x.js +0 -1
- package/dist/docs/assets/reference_skills.md.DjQkRefx.js +0 -15
- package/dist/docs/assets/reference_subagents.md.Dl16gcBj.js +0 -10
- package/dist/docs/assets/troubleshooting.md.mnfFG2Em.js +0 -1
- /package/dist/docs/assets/{deployment.md.D2jQZuFx.lean.js → deployment.md.D2YX7u_I.lean.js} +0 -0
- /package/dist/docs/assets/{guides_agent-to-agent.md.CD4T5FIl.lean.js → guides_agent-to-agent.md.C6kPY8nu.lean.js} +0 -0
- /package/dist/docs/assets/{guides_cloud-agents.md.Cp1O3u-X.lean.js → guides_cloud-agents.md.BPJqTZjT.lean.js} +0 -0
- /package/dist/docs/assets/{guides_grokbot-agents.md.CMhZNdEU.lean.js → guides_grokbot-agents.md.CzV715v8.lean.js} +0 -0
- /package/dist/docs/assets/{troubleshooting.md.mnfFG2Em.lean.js → troubleshooting.md.HY95rCCz.lean.js} +0 -0
- /package/dist/playground/assets/{index-De_lpFxE.js → index-CrMWlgUU.js} +0 -0
|
@@ -8,8 +8,8 @@
|
|
|
8
8
|
/>
|
|
9
9
|
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
|
10
10
|
<title>agent-serve playground</title>
|
|
11
|
-
<script type="module" crossorigin src="./assets/index-
|
|
12
|
-
<link rel="stylesheet" crossorigin href="./assets/index-
|
|
11
|
+
<script type="module" crossorigin src="./assets/index-CrMWlgUU.js"></script>
|
|
12
|
+
<link rel="stylesheet" crossorigin href="./assets/index-C61EWMBK.css">
|
|
13
13
|
</head>
|
|
14
14
|
<body>
|
|
15
15
|
<div id="root"></div>
|
package/docs/deployment.md
CHANGED
|
@@ -191,7 +191,7 @@ per-caller and channel-specific auth.
|
|
|
191
191
|
|
|
192
192
|
Use `agent-sdk logs --prod` for runtime output,
|
|
193
193
|
[OpenTelemetry](./guides/opentelemetry.md) for traces and metrics, and
|
|
194
|
-
[session traces](./reference/sessions.md#
|
|
194
|
+
[session traces](./reference/sessions.md#inspect-a-saved-event-stream)
|
|
195
195
|
for one conversation.
|
|
196
196
|
|
|
197
197
|
## Related
|
|
@@ -76,8 +76,8 @@ await ctx.host.mcp.callTool("weather", "check", {
|
|
|
76
76
|
});
|
|
77
77
|
```
|
|
78
78
|
|
|
79
|
-
The peer owns this session
|
|
80
|
-
|
|
79
|
+
The peer owns this session, so follow-ups continue the specialist's
|
|
80
|
+
context.
|
|
81
81
|
|
|
82
82
|
## Call a deterministic peer tool
|
|
83
83
|
|
|
@@ -122,14 +122,13 @@ complete agent you would also run, inspect, or expose on its own.
|
|
|
122
122
|
|
|
123
123
|
## Affinity
|
|
124
124
|
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
only that caller can continue or check the session.
|
|
125
|
+
Those turns show up in the peer's playground. Only the session owner
|
|
126
|
+
can continue or check them.
|
|
128
127
|
|
|
129
128
|
## Practices
|
|
130
129
|
|
|
131
|
-
- Give each caller a one-way routing rule
|
|
132
|
-
|
|
130
|
+
- Give each caller a one-way routing rule, and don't configure reciprocal
|
|
131
|
+
routes for the same request.
|
|
133
132
|
|
|
134
133
|
- Prefer `ask` when the specialist should reason. Use `call_tool` when
|
|
135
134
|
host code already knows which server tool to run.
|
|
@@ -140,12 +139,12 @@ only that caller can continue or check the session.
|
|
|
140
139
|
|
|
141
140
|
## Other hosts
|
|
142
141
|
|
|
143
|
-
Peers
|
|
144
|
-
|
|
142
|
+
Peers require the default multi-agent layout; unknown slugs and
|
|
143
|
+
self-references fail at startup.
|
|
145
144
|
|
|
146
|
-
|
|
147
|
-
and protect it with `--bearer-token`.
|
|
148
|
-
[Deployment guide](../deployment.md) owns that hosting setup.
|
|
145
|
+
If a cloud-runtime turn needs a self-hosted peer, set `--public-url` to
|
|
146
|
+
the shared host's reachable URL and protect it with `--bearer-token`.
|
|
147
|
+
The [Deployment guide](../deployment.md) owns that hosting setup.
|
|
149
148
|
|
|
150
149
|
## Related
|
|
151
150
|
|
|
@@ -11,7 +11,7 @@ agent, keep talking while it works, inspect the result, and steer or
|
|
|
11
11
|
stop the same branch.
|
|
12
12
|
|
|
13
13
|
This is different from choosing
|
|
14
|
-
[`runtime: "cloud"`](../reference/agent-config.md#
|
|
14
|
+
[`runtime: "cloud"`](../reference/agent-config.md#runtime).
|
|
15
15
|
That setting moves this agent's turns to a cloud VM; this extension lets
|
|
16
16
|
the agent delegate separate coding tasks.
|
|
17
17
|
|
|
@@ -142,5 +142,5 @@ directory and disable that tool. See
|
|
|
142
142
|
overlays
|
|
143
143
|
- [Tool approvals](../reference/tools.md#gate-a-tool-on-human-approval):
|
|
144
144
|
approve asks
|
|
145
|
-
- [Agent config](../reference/agent-config.md#
|
|
145
|
+
- [Agent config](../reference/agent-config.md#runtime): local
|
|
146
146
|
and hosted runtimes
|
|
@@ -0,0 +1,116 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: "Hooks"
|
|
3
|
+
description: "Observe session events for metrics, alerts, and other side effects without changing the turn."
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# Hooks
|
|
7
|
+
|
|
8
|
+
Hooks observe session events after they are recorded and run side effects such
|
|
9
|
+
as updating metrics or sending alerts. They never change the turn, prompt, or
|
|
10
|
+
reply. Author them under `agent/hooks/` with `defineHook` from
|
|
11
|
+
`@cursor/july/hooks`.
|
|
12
|
+
|
|
13
|
+
## Meter token usage
|
|
14
|
+
|
|
15
|
+
With [OpenTelemetry](./opentelemetry.md) configured, this hook adds a live
|
|
16
|
+
turn's reported input and output tokens to your counters. Eval runs stay quiet,
|
|
17
|
+
so the dashboard reflects live traffic instead of the test suite.
|
|
18
|
+
|
|
19
|
+
```ts
|
|
20
|
+
// agent/hooks/usage.ts
|
|
21
|
+
import { defineHook } from "@cursor/july/hooks";
|
|
22
|
+
|
|
23
|
+
export default defineHook({
|
|
24
|
+
events: {
|
|
25
|
+
async "turn.completed"(event, ctx) {
|
|
26
|
+
if (ctx.session.purpose === "eval") {
|
|
27
|
+
return;
|
|
28
|
+
}
|
|
29
|
+
if (event.data.usage === undefined) {
|
|
30
|
+
return;
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
const { inputTokens, outputTokens } = event.data.usage;
|
|
34
|
+
ctx.host.otel.increment("acme.tokens.input", inputTokens);
|
|
35
|
+
ctx.host.otel.increment("acme.tokens.output", outputTokens);
|
|
36
|
+
},
|
|
37
|
+
},
|
|
38
|
+
});
|
|
39
|
+
```
|
|
40
|
+
|
|
41
|
+
## Alert on failure
|
|
42
|
+
|
|
43
|
+
Set `PAGER_WEBHOOK_URL` to your pager's webhook. When a live turn fails, this
|
|
44
|
+
hook posts the agent, session, and failure message there. Eval runs and
|
|
45
|
+
interrupted turns stay quiet, so tests and preemptions do not page anyone.
|
|
46
|
+
|
|
47
|
+
```ts
|
|
48
|
+
// agent/hooks/page-on-failure.ts
|
|
49
|
+
import { defineHook } from "@cursor/july/hooks";
|
|
50
|
+
|
|
51
|
+
export default defineHook({
|
|
52
|
+
events: {
|
|
53
|
+
async "turn.failed"(event, ctx) {
|
|
54
|
+
if (ctx.session.purpose === "eval") {
|
|
55
|
+
return;
|
|
56
|
+
}
|
|
57
|
+
if (event.data.message === "turn interrupted") {
|
|
58
|
+
return;
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
const pagerUrl = process.env.PAGER_WEBHOOK_URL;
|
|
62
|
+
if (pagerUrl === undefined) {
|
|
63
|
+
return;
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
await fetch(pagerUrl, {
|
|
67
|
+
method: "POST",
|
|
68
|
+
headers: { "content-type": "application/json" },
|
|
69
|
+
body: JSON.stringify({
|
|
70
|
+
agent: ctx.agent.name,
|
|
71
|
+
session: ctx.session.id,
|
|
72
|
+
channel: ctx.channel.id,
|
|
73
|
+
message: event.data.message,
|
|
74
|
+
}),
|
|
75
|
+
signal: AbortSignal.timeout(5_000),
|
|
76
|
+
});
|
|
77
|
+
},
|
|
78
|
+
},
|
|
79
|
+
});
|
|
80
|
+
```
|
|
81
|
+
|
|
82
|
+
## Events / when hooks run
|
|
83
|
+
|
|
84
|
+
Use event names from the
|
|
85
|
+
[session event vocabulary](../reference/sessions.md#stream-events). A hook
|
|
86
|
+
receives each matching event after it is recorded, and the model does not wait
|
|
87
|
+
for the handler.
|
|
88
|
+
|
|
89
|
+
Within one session, handlers run one at a time. A slow handler delays later
|
|
90
|
+
handlers for that session, but it does not delay the model or handlers for
|
|
91
|
+
other sessions. Hooks also fire for evals, so check
|
|
92
|
+
`ctx.session.purpose === "eval"` before metering or paging. A restart does not
|
|
93
|
+
replay recorded events into hooks.
|
|
94
|
+
|
|
95
|
+
## When not to use a hook
|
|
96
|
+
|
|
97
|
+
| Want | Use instead |
|
|
98
|
+
| --- | --- |
|
|
99
|
+
| Add context before the model | `instructions.md`, skills, or `workspaceFiles` |
|
|
100
|
+
| Deliver to Slack or a PR | Channel [`events`](../reference/channels.md#events) or packs |
|
|
101
|
+
| Block or approve a tool | [`needsApproval`](../reference/tools.md#gate-a-tool-on-human-approval) |
|
|
102
|
+
| Gate final assistant text | `defineResult` |
|
|
103
|
+
| Gate behavior | [Evals](../evals.md) |
|
|
104
|
+
|
|
105
|
+
[Cursor Agent hooks](https://cursor.com/docs/agent/hooks) in
|
|
106
|
+
`.cursor/hooks.json` are a different product. They can observe, block, or
|
|
107
|
+
modify the local agent loop.
|
|
108
|
+
|
|
109
|
+
## Related
|
|
110
|
+
|
|
111
|
+
- [Hooks reference](../reference/hooks.md): payloads, context, and discovery
|
|
112
|
+
- [Sessions: stream events](../reference/sessions.md#stream-events): event
|
|
113
|
+
vocabulary and payload sequence
|
|
114
|
+
- [OpenTelemetry](./opentelemetry.md): export traces and custom metrics
|
|
115
|
+
- [Channels: events](../reference/channels.md#events): deliver replies back to
|
|
116
|
+
Slack, source control, or another surface
|
package/docs/guides/jev.md
CHANGED
|
@@ -1,19 +1,15 @@
|
|
|
1
1
|
---
|
|
2
2
|
title: "Jev"
|
|
3
|
-
description: "Use typed Jev decisions to filter
|
|
3
|
+
description: "Use typed Jev decisions to filter findings, route pull requests, and gate review actions."
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
# Use Jev in review tools
|
|
7
7
|
|
|
8
|
-
Use Jev
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
Ask one question per judgment. If an approval depends on risk, test
|
|
15
|
-
coverage, and the size of the change, ask three questions in one call
|
|
16
|
-
and combine the answers in code.
|
|
8
|
+
Use Jev when a review workflow needs a typed decision instead of prose.
|
|
9
|
+
A review agent can filter speculative findings, classify pull request
|
|
10
|
+
risk, choose a reviewer, or decide whether a merge needs a documentation
|
|
11
|
+
follow-up. Jev returns a choice, score, or probability; your TypeScript
|
|
12
|
+
decides what happens next.
|
|
17
13
|
|
|
18
14
|
Set `TYPESAFE_API_KEY`. The default model is `jev-latest`.
|
|
19
15
|
|
|
@@ -26,11 +22,12 @@ export default jev();
|
|
|
26
22
|
|
|
27
23
|
## Start only the review turns you need
|
|
28
24
|
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
25
|
+
Call Jev from a channel hook before a model turn starts. When a pull
|
|
26
|
+
request opens or becomes ready for review, this hook sends its title,
|
|
27
|
+
body, labels, and filenames to Jev to decide whether the change needs
|
|
28
|
+
security review. A result that clears the threshold starts the review
|
|
29
|
+
turn; otherwise, the hook returns `null`, so the agent doesn't run or
|
|
30
|
+
post to GitHub.
|
|
34
31
|
|
|
35
32
|
```ts
|
|
36
33
|
// agent/channels/github.ts
|
|
@@ -86,8 +83,7 @@ export default githubChannel({
|
|
|
86
83
|
});
|
|
87
84
|
```
|
|
88
85
|
|
|
89
|
-
|
|
90
|
-
the diff itself.
|
|
86
|
+
Jev receives only the pull request metadata shown here, not the diff.
|
|
91
87
|
|
|
92
88
|
## Filter findings before you post them
|
|
93
89
|
|
|
@@ -192,8 +188,8 @@ approval event.
|
|
|
192
188
|
|
|
193
189
|
After a pull request merges, a code-wiki agent can ask whether the
|
|
194
190
|
change introduced a durable fact that belongs in the docs. A low
|
|
195
|
-
probability
|
|
196
|
-
pull request
|
|
191
|
+
probability skips the follow-up, while a high probability opens a
|
|
192
|
+
documentation pull request.
|
|
197
193
|
|
|
198
194
|
```ts
|
|
199
195
|
import { above, decide } from "@cursor/july/extensions/jev";
|
|
@@ -218,14 +214,14 @@ return openDocsPullRequest({ title, summary });
|
|
|
218
214
|
|
|
219
215
|
## Write tools with Jev
|
|
220
216
|
|
|
221
|
-
`decide`
|
|
222
|
-
|
|
223
|
-
makes the same request and returns `{ answers }`.
|
|
217
|
+
Call `decide` from a channel hook, server tool, or router when you want
|
|
218
|
+
the answer map directly. Use `evaluate` when you want `{ answers }`.
|
|
224
219
|
|
|
225
220
|
Use a boolean for a yes-or-no gate, a choice for a closed set such as
|
|
226
|
-
risk tiers or owners, and a score for an ordered rubric. `above`
|
|
227
|
-
a boolean probability or score
|
|
228
|
-
|
|
221
|
+
risk tiers or owners, and a score for an ordered rubric. `above` returns
|
|
222
|
+
`true` when a boolean probability or score meets the threshold.
|
|
223
|
+
`needsHuman` returns `true` when a boolean probability or the selected
|
|
224
|
+
choice's probability falls below the confidence threshold.
|
|
229
225
|
|
|
230
226
|
Keep the questions atomic and combine them in TypeScript. For example,
|
|
231
227
|
ask separately whether a finding is real, whether its impact is
|
|
@@ -235,8 +231,8 @@ rule that decides whether all three are enough to post.
|
|
|
235
231
|
## Let the agent ask Jev
|
|
236
232
|
|
|
237
233
|
Mounting the extension adds a read-only harness tool named
|
|
238
|
-
`<namespace>__evaluate`. With the
|
|
239
|
-
`jev__evaluate`.
|
|
234
|
+
`<namespace>__evaluate`. With the `agent/extensions/jev.ts` mount shown
|
|
235
|
+
earlier, the model sees `jev__evaluate`.
|
|
240
236
|
|
|
241
237
|
The tool accepts one state and a list of boolean, choice, or score
|
|
242
238
|
questions. It returns `{ answers }` and never posts, approves, or opens
|
|
@@ -278,59 +274,6 @@ export default jev({
|
|
|
278
274
|
the exported helpers, so project tools can still import `decide`,
|
|
279
275
|
`above`, and `needsHuman`.
|
|
280
276
|
|
|
281
|
-
## Jev and trajectory evals
|
|
282
|
-
|
|
283
|
-
An eval checks a whole turn: the agent called the read, and it stayed
|
|
284
|
-
off approve. `decide` is the one call inside the tool, before GitHub.
|
|
285
|
-
Use the [Evals guide](../evals.md) when you want the turn to keep
|
|
286
|
-
behaving. Use `decide` when the tool itself needs a tier or a yes.
|
|
287
|
-
|
|
288
|
-
## Test without the live API
|
|
289
|
-
|
|
290
|
-
Pass `fetch` and `apiKey` and the same `decide` path runs in a test.
|
|
291
|
-
|
|
292
|
-
```ts
|
|
293
|
-
import { decide } from "@cursor/july/extensions/jev";
|
|
294
|
-
|
|
295
|
-
const answers = await decide({
|
|
296
|
-
state: {
|
|
297
|
-
title: "Skip the refund auth check",
|
|
298
|
-
summary: "acme/checkout#42 drops the session check on POST /refunds.",
|
|
299
|
-
},
|
|
300
|
-
questions: {
|
|
301
|
-
risk: {
|
|
302
|
-
type: "choice",
|
|
303
|
-
instructions: "What risk tier is this pull request?",
|
|
304
|
-
criteria: {
|
|
305
|
-
"very-low": "docs, formatting, or a mechanical rename",
|
|
306
|
-
low: "a local change with tests and no new trust boundary",
|
|
307
|
-
medium: "auth, billing, or a behavior change callers depend on",
|
|
308
|
-
high: "a likely exploit, data loss, or a broken public contract",
|
|
309
|
-
},
|
|
310
|
-
},
|
|
311
|
-
},
|
|
312
|
-
apiKey: "sk-test",
|
|
313
|
-
fetch: async () =>
|
|
314
|
-
new Response(
|
|
315
|
-
JSON.stringify({
|
|
316
|
-
answers: {
|
|
317
|
-
risk: {
|
|
318
|
-
type: "choice",
|
|
319
|
-
choice: "high",
|
|
320
|
-
probabilities: {
|
|
321
|
-
"very-low": 0.02,
|
|
322
|
-
low: 0.05,
|
|
323
|
-
medium: 0.18,
|
|
324
|
-
high: 0.75,
|
|
325
|
-
},
|
|
326
|
-
},
|
|
327
|
-
},
|
|
328
|
-
}),
|
|
329
|
-
{ status: 200 }
|
|
330
|
-
),
|
|
331
|
-
});
|
|
332
|
-
```
|
|
333
|
-
|
|
334
277
|
## Practices
|
|
335
278
|
|
|
336
279
|
- Pass the pull request title, a short summary, and the draft finding.
|
|
@@ -3,11 +3,11 @@ title: "Agent config"
|
|
|
3
3
|
description: "defineAgent at agent/agent.ts: the model, the local and cloud runtimes, and serving programmatically."
|
|
4
4
|
---
|
|
5
5
|
|
|
6
|
-
# Agent config
|
|
6
|
+
# Agent config
|
|
7
7
|
|
|
8
|
-
`agent/agent.ts` default-exports `defineAgent(config)
|
|
9
|
-
|
|
10
|
-
|
|
8
|
+
`agent/agent.ts` default-exports `defineAgent(config)`, which sets the
|
|
9
|
+
model, execution runtime, and runtime-specific defaults. Every root
|
|
10
|
+
config field is optional.
|
|
11
11
|
|
|
12
12
|
```ts
|
|
13
13
|
import { defineAgent } from "@cursor/july";
|
|
@@ -27,9 +27,7 @@ export default defineAgent({
|
|
|
27
27
|
});
|
|
28
28
|
```
|
|
29
29
|
|
|
30
|
-
##
|
|
31
|
-
|
|
32
|
-
`defineAgent` accepts these fields.
|
|
30
|
+
## Agent fields
|
|
33
31
|
|
|
34
32
|
| Field | Type | Meaning |
|
|
35
33
|
| --- | --- | --- |
|
|
@@ -38,14 +36,14 @@ export default defineAgent({
|
|
|
38
36
|
| `description` | string | What the agent is for. Required on subagents; the parent model reads it to decide when to delegate. Documentation-only on the root. |
|
|
39
37
|
| `instructions` | string | Inline instructions. Prefer `instructions.md`; this exists for subagents and generated configs. |
|
|
40
38
|
| `runtime` | `"local"` or `"cloud"` | Where turns execute. Default `"local"`. |
|
|
41
|
-
| `cloud` | object | Cloud agent defaults: repos, env, envVars
|
|
39
|
+
| `cloud` | object | Cloud agent defaults: repos, env, envVars. Used when `runtime` is `"cloud"`, and as the base merged under per-session `cloud` send options. |
|
|
42
40
|
| `local` | `{ cwd?, workspaceDir?, sandbox? }` | Local harness defaults; ignored for cloud turns. See [Local options](#local-options). |
|
|
43
|
-
| `hosting` | `{ egressDomains?, secretNames? }` |
|
|
44
|
-
| `concurrency` | `{ maxRunningTurns? }` |
|
|
41
|
+
| `hosting` | `{ egressDomains?, secretNames? }` | `agent-sdk deploy` declarations for allowed egress domains and expected secret names. Ignored by local serving. |
|
|
42
|
+
| `concurrency` | `{ maxRunningTurns? }` | Agent-wide turn admission limit. See [Concurrency](#concurrency). |
|
|
45
43
|
| `builtinTools` | `{ reminders? }` | Framework-provided model-facing tools, opted in per capability. See [Built-in tools](#built-in-tools). |
|
|
46
|
-
| `tools` | `ToolName[]` | Allowlist of built-in harness tools offered to the model. Unset = the model's full standard toolset. See [
|
|
44
|
+
| `tools` | `ToolName[]` | Allowlist of built-in harness tools offered to the model. Unset = the model's full standard toolset. See [Harness tools](#harness-tools). |
|
|
47
45
|
|
|
48
|
-
##
|
|
46
|
+
## Model
|
|
49
47
|
|
|
50
48
|
`model` is a Cursor model id string, or `{ id, params }`. Effort and
|
|
51
49
|
speed are params, not id suffixes. The SDK rejects suffix-style ids
|
|
@@ -67,24 +65,17 @@ A plain string works when you don't need params:
|
|
|
67
65
|
model: "composer-2.5",
|
|
68
66
|
```
|
|
69
67
|
|
|
70
|
-
##
|
|
68
|
+
## Runtime
|
|
71
69
|
|
|
72
|
-
`runtime: "local"` (the default) runs turns on
|
|
73
|
-
|
|
74
|
-
all apply.
|
|
70
|
+
`runtime: "local"` (the default) runs turns on this machine. Server
|
|
71
|
+
tools, skills, sandbox seeds, and tool approvals all apply.
|
|
75
72
|
|
|
76
|
-
`runtime: "cloud"` runs turns on Cursor cloud agents
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
`--public-url` or `--cloud-tools-url` is set (omitted with a warning
|
|
80
|
-
otherwise), and instructions and agent-tool catalogs are prepended to
|
|
81
|
-
the first prompt, because the local session workspace is not the cloud
|
|
82
|
-
VM.
|
|
73
|
+
`runtime: "cloud"` runs turns on Cursor cloud agents. Pass a `cloud`
|
|
74
|
+
block with the repositories the VM needs. See [Tools](./tools.md) for
|
|
75
|
+
server- and agent-tool behavior on cloud turns.
|
|
83
76
|
|
|
84
|
-
`validate` warns when `runtime: "cloud"` is combined with agent tools
|
|
85
|
-
|
|
86
|
-
when skills or sandbox seeds are present (they sync onto an Agent Store
|
|
87
|
-
rather than the session workspace), and when the `cloud` block is
|
|
77
|
+
`validate` warns when `runtime: "cloud"` is combined with agent tools,
|
|
78
|
+
when skills or sandbox seeds are present, and when the `cloud` block is
|
|
88
79
|
missing.
|
|
89
80
|
|
|
90
81
|
## Local options
|
|
@@ -93,18 +84,15 @@ missing.
|
|
|
93
84
|
|
|
94
85
|
`local.workspaceDir` points every session at one shared harness cwd,
|
|
95
86
|
for agents that work inside an existing checkout. It takes precedence
|
|
96
|
-
over `cwd`, and a per-send `workspaceDir` still wins over both.
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
serve process instead of once per session. The trade: sessions share a
|
|
100
|
-
working tree, so a file one turn writes is visible to the next.
|
|
87
|
+
over `cwd`, and a per-send `workspaceDir` still wins over both.
|
|
88
|
+
Sessions share a working tree, so a file one turn writes is visible to
|
|
89
|
+
the next.
|
|
101
90
|
|
|
102
91
|
`local.sandbox` runs the harness inside Cursor's local sandbox. It's
|
|
103
|
-
off by default
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
than a prompt-level one.
|
|
92
|
+
off by default: shell then auto-approves and inherits the serve process
|
|
93
|
+
environment, including any credentials the host holds. Turn it on for
|
|
94
|
+
agents whose turns read untrusted input (webhook payloads, PR diffs,
|
|
95
|
+
inbound chat); it's a tool boundary, not a prompt-level one.
|
|
108
96
|
|
|
109
97
|
### Local cwd
|
|
110
98
|
|
|
@@ -120,13 +108,12 @@ does not leak rules, skills, or MCP servers into the turn. A standalone git
|
|
|
120
108
|
root keeps the in-project session workspace. Point `cwd` at a checkout only
|
|
121
109
|
when the agent should inherit that tree.
|
|
122
110
|
|
|
123
|
-
##
|
|
111
|
+
## Harness tools
|
|
124
112
|
|
|
125
113
|
Use `tools` to limit which built-in Cursor harness tools the model can
|
|
126
114
|
call. Omit it to keep the standard toolset. When you set it, the model
|
|
127
115
|
gets only the tools you list. An empty list disables all native
|
|
128
|
-
built-in tools.
|
|
129
|
-
stay disabled until you add them.
|
|
116
|
+
built-in tools. New platform tools stay disabled until you add them.
|
|
130
117
|
|
|
131
118
|
```ts
|
|
132
119
|
export default defineAgent({
|
|
@@ -137,12 +124,13 @@ export default defineAgent({
|
|
|
137
124
|
});
|
|
138
125
|
```
|
|
139
126
|
|
|
140
|
-
The Agent SDK always adds `"mcp"` to a configured allowlist
|
|
141
|
-
server tools in `agent/tools/`
|
|
142
|
-
expose declared connections and servers from the harness
|
|
143
|
-
ambient `.cursor` config. To exclude a checkout's MCP
|
|
144
|
-
`local.cwd` outside the checkout. See
|
|
145
|
-
`local.sandbox` makes MCP tool calls fail
|
|
127
|
+
The Agent SDK always adds `"mcp"` to a configured allowlist, because
|
|
128
|
+
authored server tools in `agent/tools/` reach the model over MCP. MCP
|
|
129
|
+
can also expose declared connections and servers from the harness
|
|
130
|
+
directory's ambient `.cursor` config. To exclude a checkout's MCP
|
|
131
|
+
servers, point `local.cwd` outside the checkout. See
|
|
132
|
+
[Local cwd](#local-cwd). `local.sandbox` makes MCP tool calls fail
|
|
133
|
+
closed.
|
|
146
134
|
|
|
147
135
|
Use the SDK's public tool names, including `"shell"`, `"read"`,
|
|
148
136
|
`"edit"`, `"grep"`, `"glob"`, `"ls"`, and `"task"`. Unknown names
|
|
@@ -159,8 +147,7 @@ Two names have broader effects:
|
|
|
159
147
|
Tool allowlists work only with the local runtime. A
|
|
160
148
|
`runtime: "cloud"` agent that sets `tools` fails at serve startup.
|
|
161
149
|
The Agent SDK also refuses per-send cloud sessions from a hybrid agent
|
|
162
|
-
with an allowlist.
|
|
163
|
-
access.
|
|
150
|
+
with an allowlist.
|
|
164
151
|
|
|
165
152
|
The allowlist controls which tools the model can call. It does not
|
|
166
153
|
isolate the serve host. For agents that process untrusted input, also
|
|
@@ -168,10 +155,10 @@ set `local: { sandbox: true }`.
|
|
|
168
155
|
|
|
169
156
|
## Cloud options
|
|
170
157
|
|
|
171
|
-
|
|
172
|
-
`{ url, startingRef? }`), environment selection, `envVars
|
|
173
|
-
|
|
174
|
-
|
|
158
|
+
The `cloud` block sets default repositories (each
|
|
159
|
+
`{ url, startingRef? }`), environment selection, and `envVars`. A local
|
|
160
|
+
agent uses the same block as the base config when a channel opens a
|
|
161
|
+
cloud-attached session per send (the `cloud` option on
|
|
175
162
|
[`send`](./channels.md#handler-arguments)).
|
|
176
163
|
|
|
177
164
|
## Concurrency
|
|
@@ -194,9 +181,8 @@ export default defineAgent({
|
|
|
194
181
|
## Built-in tools
|
|
195
182
|
|
|
196
183
|
`builtinTools` opts into framework-provided model-facing tools. Each
|
|
197
|
-
enabled capability
|
|
198
|
-
|
|
199
|
-
like authored tools. Authored tools with the same name win, with a
|
|
184
|
+
enabled capability shows up as ordinary server tools, so turns, direct
|
|
185
|
+
calls, `info`, and the playground treat them like authored tools. Authored tools with the same name win, with a
|
|
200
186
|
warning, and like all server tools they run on the local runtime.
|
|
201
187
|
|
|
202
188
|
`builtinTools: { reminders: true }` adds three tools bound to the
|
|
@@ -205,22 +191,6 @@ current conversation over `host.reminders`: `reminders_create`,
|
|
|
205
191
|
continuation key can't arm reminders. See
|
|
206
192
|
[Schedules and reminders](./schedules.md#reminders).
|
|
207
193
|
|
|
208
|
-
## Generate instructions
|
|
209
|
-
|
|
210
|
-
When the system prompt must be computed, author `agent/instructions.ts`
|
|
211
|
-
instead of markdown:
|
|
212
|
-
|
|
213
|
-
```ts
|
|
214
|
-
import { defineInstructions } from "@cursor/july";
|
|
215
|
-
|
|
216
|
-
export default defineInstructions({
|
|
217
|
-
markdown: `You are the on-call assistant for ${process.env.TEAM_NAME}.`,
|
|
218
|
-
});
|
|
219
|
-
```
|
|
220
|
-
|
|
221
|
-
The directory form and the runtime mapping are in
|
|
222
|
-
[Instructions](./instructions.md).
|
|
223
|
-
|
|
224
194
|
## Serve programmatically
|
|
225
195
|
|
|
226
196
|
`serve(dirOrProject, options)` embeds the server in your own process:
|
|
@@ -230,7 +200,7 @@ import { serve } from "@cursor/july";
|
|
|
230
200
|
|
|
231
201
|
const handle = await serve("./my-agent", {
|
|
232
202
|
port: 3000,
|
|
233
|
-
apiKey: process.env.CURSOR_API_KEY,
|
|
203
|
+
apiKey: process.env.CURSOR_API_KEY,
|
|
234
204
|
});
|
|
235
205
|
console.log(`listening on ${handle.url}`);
|
|
236
206
|
// handle.callTool(...), handle.dispatchSchedule("heartbeat"),
|
|
@@ -239,17 +209,14 @@ console.log(`listening on ${handle.url}`);
|
|
|
239
209
|
|
|
240
210
|
Host settings match the documented [CLI](./cli.md) `serve` flags.
|
|
241
211
|
`serve()` also accepts `discovery` (project-loading options) and
|
|
242
|
-
`mode: "single" | "multi"`.
|
|
243
|
-
|
|
244
|
-
`
|
|
245
|
-
when unset), then `CURSOR_SERVICE_ACCOUNT_KEY`, then the key stored by
|
|
246
|
-
`agent-sdk login`. On a host that has both the service-account key and a
|
|
247
|
-
bind file, the file principal wins.
|
|
248
|
-
|
|
249
|
-
## What's next
|
|
212
|
+
`mode: "single" | "multi"`. Pass `apiKey` or use the same Cursor
|
|
213
|
+
credential as the CLI: `CURSOR_API_KEY`, `CURSOR_API_KEY_FILE`,
|
|
214
|
+
`CURSOR_SERVICE_ACCOUNT_KEY`, or `agent-sdk login`.
|
|
250
215
|
|
|
251
|
-
|
|
216
|
+
## Related
|
|
252
217
|
|
|
253
218
|
- [Instructions](./instructions.md): the required half of a minimal
|
|
254
219
|
agent
|
|
255
220
|
- [CLI](./cli.md): the `serve` flags `serve()` accepts
|
|
221
|
+
- [Sessions](./sessions.md): workspaces, identifiers, and turn admission
|
|
222
|
+
- [Schedules](./schedules.md): reminder tools opted in here
|