@cursor/july 0.1.108 → 0.1.109
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/AGENTS.md +2 -6
- package/README.md +3 -6
- package/dist/channels/bitbucket/api.d.ts +41 -0
- package/dist/channels/bitbucket/api.d.ts.map +1 -1
- package/dist/channels/bitbucket/api.js +260 -0
- package/dist/channels/bitbucket/binding.d.ts +4 -0
- package/dist/channels/bitbucket/binding.d.ts.map +1 -1
- package/dist/channels/bitbucket/binding.js +16 -0
- package/dist/channels/bitbucket/index.d.ts +1 -1
- package/dist/channels/bitbucket/index.d.ts.map +1 -1
- package/dist/channels/bitbucket/index.js +1 -1
- package/dist/channels/gitlab/api.d.ts +27 -0
- package/dist/channels/gitlab/api.d.ts.map +1 -1
- package/dist/channels/gitlab/api.js +88 -0
- package/dist/channels/gitlab/binding.d.ts +5 -0
- package/dist/channels/gitlab/binding.d.ts.map +1 -1
- package/dist/channels/gitlab/binding.js +10 -0
- package/dist/channels/gitlab/index.d.ts +1 -1
- package/dist/channels/gitlab/index.d.ts.map +1 -1
- package/dist/channels/gitlab/index.js +1 -1
- package/dist/channels/slack/dispatch.d.ts +10 -0
- package/dist/channels/slack/dispatch.d.ts.map +1 -1
- package/dist/channels/slack/dispatch.js +20 -3
- package/dist/channels/slack/slack-channel.d.ts +12 -5
- package/dist/channels/slack/slack-channel.d.ts.map +1 -1
- package/dist/channels/slack/slack-channel.js +59 -8
- package/dist/docs/404.html +2 -2
- package/dist/docs/assets/{app.BASKM3M4.js → app.Cr-wVbnB.js} +1 -1
- package/dist/docs/assets/{building-with-agents.md.CUSWxlP_.js → building-with-agents.md.D0KbSkJn.js} +2 -2
- package/dist/docs/assets/{building-with-agents.md.CUSWxlP_.lean.js → building-with-agents.md.D0KbSkJn.lean.js} +1 -1
- package/dist/docs/assets/chunks/@localSearchIndexroot.CFVQ4S17.js +1 -0
- package/dist/docs/assets/chunks/{VPLocalSearchBox.BOKxlYGP.js → VPLocalSearchBox.CVQERt56.js} +1 -1
- package/dist/docs/assets/chunks/{theme.DbDZW-zb.js → theme.Dnsd3XOn.js} +2 -2
- package/dist/docs/assets/concepts.md.B4o63Gul.js +1 -0
- package/dist/docs/assets/evals.md.C7JLjoEP.js +211 -0
- package/dist/docs/assets/evals.md.C7JLjoEP.lean.js +1 -0
- package/dist/docs/assets/guides_bitbucket.md.DZPzmUjU.js +10 -0
- package/dist/docs/assets/guides_bitbucket.md.DZPzmUjU.lean.js +1 -0
- package/dist/docs/assets/{guides_github.md.BH33UEBJ.js → guides_github.md.TZaTZlfz.js} +13 -3
- package/dist/docs/assets/{guides_github.md.BH33UEBJ.lean.js → guides_github.md.TZaTZlfz.lean.js} +1 -1
- package/dist/docs/assets/guides_gitlab.md.BmqwQfdG.js +14 -0
- package/dist/docs/assets/guides_gitlab.md.BmqwQfdG.lean.js +1 -0
- package/dist/docs/assets/{guides_webhooks.md.DKdA43Qm.js → guides_webhooks.md.CJK484ex.js} +2 -2
- package/dist/docs/assets/{hillclimbing.md.CpTGTCle.js → hillclimbing.md.BOiVo1tf.js} +1 -1
- package/dist/docs/assets/index.md.DD9Q2XuJ.js +5 -0
- package/dist/docs/assets/{index.md.BjH1w2ZW.lean.js → index.md.DD9Q2XuJ.lean.js} +1 -1
- package/dist/docs/assets/{reference_channels.md.D-qTqwcq.js → reference_channels.md.CAo-iK4j.js} +2 -2
- package/dist/docs/assets/{reference_channels.md.D-qTqwcq.lean.js → reference_channels.md.CAo-iK4j.lean.js} +1 -1
- package/dist/docs/assets/{reference_cli.md.Ca26u0Es.js → reference_cli.md.Deg7849l.js} +1 -1
- package/dist/docs/assets/{reference_extensions.md.CPWt00ds.js → reference_extensions.md.ZAVUyuEX.js} +2 -2
- package/dist/docs/assets/{reference_hooks.md.Ddt5DdgJ.js → reference_hooks.md.BlM_bOg6.js} +3 -3
- package/dist/docs/assets/{reference_hooks.md.Ddt5DdgJ.lean.js → reference_hooks.md.BlM_bOg6.lean.js} +1 -1
- package/dist/docs/assets/{reference_http-api.md.oySXBO8o.js → reference_http-api.md.BwaCo-VO.js} +1 -1
- package/dist/docs/assets/{reference_playground.md.4myJPxrf.js → reference_playground.md.DLnoaczX.js} +1 -1
- package/dist/docs/assets/{reference_playground.md.4myJPxrf.lean.js → reference_playground.md.DLnoaczX.lean.js} +1 -1
- package/dist/docs/assets/{reference_project-layout.md.DuBu9a96.js → reference_project-layout.md.BEU8MtQV.js} +3 -3
- package/dist/docs/assets/{reference_project-layout.md.DuBu9a96.lean.js → reference_project-layout.md.BEU8MtQV.lean.js} +1 -1
- package/dist/docs/assets/reference_sessions.md.CyXV1MUw.js +1 -0
- package/dist/docs/assets/skills_deploy.md.CWqi_ZxW.js +35 -0
- package/dist/docs/assets/skills_deploy.md.CWqi_ZxW.lean.js +1 -0
- package/dist/docs/assets/{skills_evals.md.BhovOvrl.js → skills_evals.md.DFxYPErF.js} +3 -3
- package/dist/docs/assets/skills_evals.md.DFxYPErF.lean.js +1 -0
- package/dist/docs/assets/{skills_framework-map.md.D-tFZhFS.js → skills_framework-map.md.BxLSOhSY.js} +1 -1
- package/dist/docs/assets/skills_index.md.DL7EHaQ-.js +1 -0
- package/dist/docs/assets/skills_index.md.DL7EHaQ-.lean.js +1 -0
- package/dist/docs/assets/{storage.md.BOHeqk2M.js → storage.md.BUrhJ-Zz.js} +4 -4
- package/dist/docs/assets/{storage.md.BOHeqk2M.lean.js → storage.md.BUrhJ-Zz.lean.js} +1 -1
- package/dist/docs/building-with-agents.html +5 -5
- package/dist/docs/building-with-agents.md +3 -2
- package/dist/docs/concepts.html +5 -5
- package/dist/docs/concepts.md +2 -4
- package/dist/docs/deployment.html +4 -4
- package/dist/docs/evals.html +161 -35
- package/dist/docs/evals.md +612 -297
- package/dist/docs/guides/agent-to-agent.html +4 -4
- package/dist/docs/guides/bitbucket.html +36 -0
- package/dist/docs/guides/bitbucket.md +84 -0
- package/dist/docs/guides/cloud-agents.html +4 -4
- package/dist/docs/guides/convert-automation.html +4 -4
- package/dist/docs/guides/github.html +17 -7
- package/dist/docs/guides/github.md +31 -0
- package/dist/docs/guides/gitlab.html +40 -0
- package/dist/docs/guides/gitlab.md +92 -0
- package/dist/docs/guides/grokbot-agents.html +4 -4
- package/dist/docs/guides/human-in-the-loop.html +4 -4
- package/dist/docs/guides/improve.html +4 -4
- package/dist/docs/guides/mcp-oauth.html +4 -4
- package/dist/docs/guides/opentelemetry.html +4 -4
- package/dist/docs/guides/slack.html +5 -5
- package/dist/docs/guides/webhooks.html +6 -6
- package/dist/docs/guides/webhooks.md +4 -2
- package/dist/docs/hashmap.json +1 -1
- package/dist/docs/hillclimbing.html +6 -6
- package/dist/docs/hillclimbing.md +2 -2
- package/dist/docs/index.html +6 -6
- package/dist/docs/index.md +10 -6
- package/dist/docs/llms-full.txt +1113 -778
- package/dist/docs/llms.txt +6 -5
- package/dist/docs/quickstart.html +4 -4
- package/dist/docs/reference/agent-config.html +4 -4
- package/dist/docs/reference/artifacts.html +4 -4
- package/dist/docs/reference/channels.html +6 -6
- package/dist/docs/reference/channels.md +16 -3
- package/dist/docs/reference/cli.html +6 -6
- package/dist/docs/reference/cli.md +6 -4
- package/dist/docs/reference/connections.html +4 -4
- package/dist/docs/reference/extensions.html +7 -7
- package/dist/docs/reference/extensions.md +0 -3
- package/dist/docs/reference/hooks.html +7 -7
- package/dist/docs/reference/hooks.md +9 -12
- package/dist/docs/reference/http-api.html +6 -6
- package/dist/docs/reference/http-api.md +2 -3
- package/dist/docs/reference/instructions.html +4 -4
- package/dist/docs/reference/playground.html +5 -5
- package/dist/docs/reference/playground.md +0 -4
- package/dist/docs/reference/project-layout.html +7 -7
- package/dist/docs/reference/project-layout.md +1 -8
- package/dist/docs/reference/prompt.html +4 -4
- package/dist/docs/reference/result.html +4 -4
- package/dist/docs/reference/schedules.html +4 -4
- package/dist/docs/reference/sessions.html +5 -5
- package/dist/docs/reference/sessions.md +1 -2
- package/dist/docs/reference/skills.html +4 -4
- package/dist/docs/reference/subagents.html +4 -4
- package/dist/docs/reference/tools.html +4 -4
- package/dist/docs/scaffolding-agents.html +4 -4
- package/dist/docs/skills/create-agent.html +4 -4
- package/dist/docs/skills/debug.html +4 -4
- package/dist/docs/skills/deploy.html +61 -0
- package/dist/docs/skills/deploy.md +161 -0
- package/dist/docs/skills/evals.html +8 -8
- package/dist/docs/skills/evals.md +44 -6
- package/dist/docs/skills/framework-map.html +5 -5
- package/dist/docs/skills/framework-map.md +1 -2
- package/dist/docs/skills/github.html +4 -4
- package/dist/docs/skills/hillclimb.html +4 -4
- package/dist/docs/skills/index.html +6 -6
- package/dist/docs/skills/index.md +1 -1
- package/dist/docs/skills/mcp-auth.html +4 -4
- package/dist/docs/skills/otel.html +4 -4
- package/dist/docs/skills/setup-slack.html +4 -4
- package/dist/docs/storage.html +8 -8
- package/dist/docs/storage.md +15 -24
- package/dist/docs/templates/agentic-owners.html +4 -4
- package/dist/docs/templates/agents-md.html +4 -4
- package/dist/docs/templates/code-wiki.html +4 -4
- package/dist/docs/templates/demo.html +4 -4
- package/dist/docs/templates/grokbot-agents.html +4 -4
- package/dist/docs/templates/pr-autofixer.html +4 -4
- package/dist/docs/templates/security-help.html +4 -4
- package/dist/docs/templates/security-reviewer.html +4 -4
- package/dist/docs/templates/triage.html +4 -4
- package/dist/docs/troubleshooting.html +4 -4
- package/dist/extensions.d.ts +2 -3
- package/dist/extensions.d.ts.map +1 -1
- package/dist/extensions.js +2 -5
- package/dist/index.d.ts +2 -3
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -2
- package/dist/internal/authored-alias-hooks.d.ts +5 -0
- package/dist/internal/authored-alias-hooks.d.ts.map +1 -1
- package/dist/internal/authored-alias-hooks.js +17 -0
- package/dist/internal/authored-loaders.d.ts +4 -0
- package/dist/internal/authored-loaders.d.ts.map +1 -1
- package/dist/internal/authored-loaders.js +21 -2
- package/dist/internal/cli-ax.d.ts +1 -2
- package/dist/internal/cli-ax.d.ts.map +1 -1
- package/dist/internal/cli-ax.js +1 -2
- package/dist/internal/continuation-channel.d.ts.map +1 -1
- package/dist/internal/continuation-channel.js +2 -2
- package/dist/internal/continuation-identity.js +8 -3
- package/dist/internal/discovery/agent.d.ts +1 -1
- package/dist/internal/discovery/agent.d.ts.map +1 -1
- package/dist/internal/discovery/agent.js +0 -5
- package/dist/internal/discovery/extension-overlay.d.ts +1 -2
- package/dist/internal/discovery/extension-overlay.d.ts.map +1 -1
- package/dist/internal/discovery/extension-overlay.js +0 -14
- package/dist/internal/discovery/extensions.d.ts +1 -2
- package/dist/internal/discovery/extensions.d.ts.map +1 -1
- package/dist/internal/discovery/extensions.js +4 -22
- package/dist/internal/discovery/info.d.ts.map +1 -1
- package/dist/internal/discovery/info.js +42 -24
- package/dist/internal/discovery/modules.js +0 -1
- package/dist/internal/discovery/project.d.ts.map +1 -1
- package/dist/internal/discovery/project.js +0 -16
- package/dist/internal/eval-runner.js +0 -1
- package/dist/internal/framework-file-storage.d.ts +4 -5
- package/dist/internal/framework-file-storage.d.ts.map +1 -1
- package/dist/internal/framework-file-storage.js +4 -5
- package/dist/internal/framework-storage-selection.d.ts +2 -2
- package/dist/internal/framework-storage-selection.js +2 -2
- package/dist/internal/init-scaffold.d.ts.map +1 -1
- package/dist/internal/init-scaffold.js +1 -2
- package/dist/internal/install-cursor-skills.d.ts +5 -2
- package/dist/internal/install-cursor-skills.d.ts.map +1 -1
- package/dist/internal/install-cursor-skills.js +25 -5
- package/dist/internal/run-client.d.ts +1 -1
- package/dist/internal/sdk-runner.js +1 -1
- package/dist/internal/server.js +0 -14
- package/dist/internal/session-engine.d.ts +5 -35
- package/dist/internal/session-engine.d.ts.map +1 -1
- package/dist/internal/session-engine.js +17 -162
- package/dist/internal/storage-coordinator.d.ts +5 -19
- package/dist/internal/storage-coordinator.d.ts.map +1 -1
- package/dist/internal/storage-coordinator.js +3 -62
- package/dist/internal/storage-roles.d.ts +4 -9
- package/dist/internal/storage-roles.d.ts.map +1 -1
- package/dist/internal/storage-roles.js +2 -2
- package/dist/playground/assets/index-Bhxzrcf6.css +1 -0
- package/dist/playground/assets/index-CqLX5uF3.js +67 -0
- package/dist/playground/index.html +2 -2
- package/dist/storage-backends/cursor-hosted-v2.d.ts +4 -5
- package/dist/storage-backends/cursor-hosted-v2.d.ts.map +1 -1
- package/dist/storage-backends/cursor-hosted-v2.js +4 -5
- package/dist/storage-backends/cursor-hosted.d.ts +1 -2
- package/dist/storage-backends/cursor-hosted.d.ts.map +1 -1
- package/dist/storage-backends/cursor-hosted.js +0 -30
- package/dist/storage-backends/file-kv.d.ts +9 -12
- package/dist/storage-backends/file-kv.d.ts.map +1 -1
- package/dist/storage-backends/file-kv.js +11 -47
- package/dist/storage-protocol.d.ts +3 -11
- package/dist/storage-protocol.d.ts.map +1 -1
- package/dist/storage-protocol.js +3 -11
- package/dist/storage.d.ts +8 -36
- package/dist/storage.d.ts.map +1 -1
- package/dist/storage.js +8 -44
- package/dist/types.d.ts +20 -57
- package/dist/types.d.ts.map +1 -1
- package/docs/README.md +10 -6
- package/docs/building-with-agents.md +3 -2
- package/docs/concepts.md +2 -4
- package/docs/evals.md +613 -298
- package/docs/guides/bitbucket.md +89 -0
- package/docs/guides/github.md +31 -0
- package/docs/guides/gitlab.md +97 -0
- package/docs/guides/webhooks.md +4 -2
- package/docs/hillclimbing.md +2 -2
- package/docs/reference/channels.md +16 -3
- package/docs/reference/cli.md +6 -4
- package/docs/reference/extensions.md +0 -3
- package/docs/reference/hooks.md +9 -12
- package/docs/reference/http-api.md +2 -3
- package/docs/reference/playground.md +0 -4
- package/docs/reference/project-layout.md +1 -8
- package/docs/reference/sessions.md +1 -2
- package/docs/skills/index.md +2 -2
- package/docs/storage.md +15 -24
- package/package.json +1 -7
- package/skills/deploy/SKILL.md +169 -0
- package/skills/evals/SKILL.md +45 -8
- package/skills/framework-map/SKILL.md +1 -2
- package/src/channels/bitbucket/api.ts +341 -0
- package/src/channels/bitbucket/binding.ts +25 -0
- package/src/channels/bitbucket/index.ts +2 -0
- package/src/channels/gitlab/api.ts +123 -0
- package/src/channels/gitlab/binding.ts +12 -0
- package/src/channels/gitlab/index.ts +1 -0
- package/src/channels/slack/dispatch.ts +30 -0
- package/src/channels/slack/slack-channel.ts +69 -7
- package/src/extensions.ts +2 -6
- package/src/index.ts +0 -3
- package/src/internal/authored-alias-hooks.ts +32 -0
- package/src/internal/authored-loaders.ts +26 -2
- package/src/internal/cli-ax.ts +1 -2
- package/src/internal/continuation-channel.ts +2 -1
- package/src/internal/continuation-identity.ts +10 -2
- package/src/internal/discovery/agent.ts +1 -7
- package/src/internal/discovery/extension-overlay.ts +0 -18
- package/src/internal/discovery/extensions.ts +2 -26
- package/src/internal/discovery/info.ts +3 -13
- package/src/internal/discovery/modules.ts +0 -1
- package/src/internal/discovery/project.ts +0 -16
- package/src/internal/eval-runner.ts +0 -1
- package/src/internal/framework-file-storage.ts +4 -5
- package/src/internal/framework-storage-selection.ts +2 -2
- package/src/internal/init-scaffold.ts +1 -2
- package/src/internal/install-cursor-skills.ts +38 -5
- package/src/internal/run-client.ts +1 -1
- package/src/internal/sdk-runner.ts +1 -1
- package/src/internal/server.ts +0 -16
- package/src/internal/session-engine.ts +14 -202
- package/src/internal/storage-coordinator.ts +5 -76
- package/src/internal/storage-roles.ts +4 -9
- package/src/storage-backends/cursor-hosted-v2.ts +4 -7
- package/src/storage-backends/cursor-hosted.ts +0 -37
- package/src/storage-backends/file-kv.ts +10 -51
- package/src/storage-protocol.ts +3 -17
- package/src/storage.ts +10 -101
- package/src/types.ts +19 -56
- package/templates/demo/README.md +10 -6
- package/templates/demo/agent/channels/github.ts +2 -0
- package/templates/demo/agent/channels/queue.ts +6 -2
- package/templates/demo/agent/lib/repos.ts +5 -0
- package/templates/demo/init.json +25 -0
- package/dist/ab.d.ts +0 -209
- package/dist/ab.d.ts.map +0 -1
- package/dist/ab.js +0 -246
- package/dist/docs/ab.html +0 -80
- package/dist/docs/ab.md +0 -332
- package/dist/docs/assets/ab.md.mlVgqvSk.js +0 -54
- package/dist/docs/assets/ab.md.mlVgqvSk.lean.js +0 -1
- package/dist/docs/assets/chunks/@localSearchIndexroot.BHZYsNVi.js +0 -1
- package/dist/docs/assets/concepts.md.DgEcZOfT.js +0 -1
- package/dist/docs/assets/evals.md.C1ekS3k2.js +0 -85
- package/dist/docs/assets/evals.md.C1ekS3k2.lean.js +0 -1
- package/dist/docs/assets/index.md.BjH1w2ZW.js +0 -5
- package/dist/docs/assets/reference_sessions.md.CueyOHSL.js +0 -1
- package/dist/docs/assets/skills_ab.md.CsFNatVx.js +0 -26
- package/dist/docs/assets/skills_ab.md.CsFNatVx.lean.js +0 -1
- package/dist/docs/assets/skills_evals.md.BhovOvrl.lean.js +0 -1
- package/dist/docs/assets/skills_index.md.DKwIxzGg.js +0 -1
- package/dist/docs/assets/skills_index.md.DKwIxzGg.lean.js +0 -1
- package/dist/docs/skills/ab.html +0 -52
- package/dist/docs/skills/ab.md +0 -50
- package/dist/internal/ab-collector.d.ts +0 -44
- package/dist/internal/ab-collector.d.ts.map +0 -1
- package/dist/internal/ab-collector.js +0 -142
- package/dist/internal/ab-fold.d.ts +0 -36
- package/dist/internal/ab-fold.d.ts.map +0 -1
- package/dist/internal/ab-fold.js +0 -175
- package/dist/internal/ab-snapshot.d.ts +0 -68
- package/dist/internal/ab-snapshot.d.ts.map +0 -1
- package/dist/internal/ab-snapshot.js +0 -208
- package/dist/internal/discovery/ab.d.ts +0 -9
- package/dist/internal/discovery/ab.d.ts.map +0 -1
- package/dist/internal/discovery/ab.js +0 -113
- package/dist/playground/assets/index-BMDqAeXu.js +0 -67
- package/dist/playground/assets/index-LUgJoWdL.css +0 -1
- package/docs/ab.md +0 -337
- package/skills/ab/SKILL.md +0 -58
- package/src/ab.ts +0 -430
- package/src/internal/ab-collector.ts +0 -200
- package/src/internal/ab-fold.ts +0 -232
- package/src/internal/ab-snapshot.ts +0 -331
- package/src/internal/discovery/ab.ts +0 -131
- /package/dist/docs/assets/{concepts.md.DgEcZOfT.lean.js → concepts.md.B4o63Gul.lean.js} +0 -0
- /package/dist/docs/assets/{guides_webhooks.md.DKdA43Qm.lean.js → guides_webhooks.md.CJK484ex.lean.js} +0 -0
- /package/dist/docs/assets/{hillclimbing.md.CpTGTCle.lean.js → hillclimbing.md.BOiVo1tf.lean.js} +0 -0
- /package/dist/docs/assets/{reference_cli.md.Ca26u0Es.lean.js → reference_cli.md.Deg7849l.lean.js} +0 -0
- /package/dist/docs/assets/{reference_extensions.md.CPWt00ds.lean.js → reference_extensions.md.ZAVUyuEX.lean.js} +0 -0
- /package/dist/docs/assets/{reference_http-api.md.oySXBO8o.lean.js → reference_http-api.md.BwaCo-VO.lean.js} +0 -0
- /package/dist/docs/assets/{reference_sessions.md.CueyOHSL.lean.js → reference_sessions.md.CyXV1MUw.lean.js} +0 -0
- /package/dist/docs/assets/{skills_framework-map.md.D-tFZhFS.lean.js → skills_framework-map.md.BxLSOhSY.lean.js} +0 -0
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: "Bitbucket"
|
|
3
|
+
description: "Wake your agent from pull requests, comments, and pushes on Bitbucket Cloud or Bitbucket Data Center."
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# Bitbucket agents
|
|
7
|
+
|
|
8
|
+
Use `bitbucketChannel()` for Bitbucket Cloud and Bitbucket Data Center. The
|
|
9
|
+
channel detects the source from each signed payload and normalizes Data Center
|
|
10
|
+
events to the Bitbucket Cloud event vocabulary.
|
|
11
|
+
|
|
12
|
+
## Define the channel
|
|
13
|
+
|
|
14
|
+
Author `agent/channels/bitbucket.ts`:
|
|
15
|
+
|
|
16
|
+
```ts
|
|
17
|
+
import { bitbucketChannel } from "@cursor/july/channels/bitbucket";
|
|
18
|
+
|
|
19
|
+
export default bitbucketChannel({});
|
|
20
|
+
```
|
|
21
|
+
|
|
22
|
+
Without `onPullRequest`, new pull requests start turns. Data Center updates
|
|
23
|
+
also start turns when the source branch has new commits. Comments and pushes
|
|
24
|
+
are opt-in through `onPullRequestComment` and `onPush`. Use `onEvent` for
|
|
25
|
+
other event types. Set `webhookEvents` when managed event delivery must
|
|
26
|
+
subscribe to an event that only `onEvent` handles.
|
|
27
|
+
|
|
28
|
+
Filter comment hooks by author before starting a turn. This prevents comments
|
|
29
|
+
posted by the agent from triggering another turn.
|
|
30
|
+
|
|
31
|
+
`ctx.bitbucket.api` can read pull requests, post comments, and create build
|
|
32
|
+
statuses. See the [Channels reference](../reference/channels.md) for hook
|
|
33
|
+
return values and session behavior.
|
|
34
|
+
|
|
35
|
+
## Connect Bitbucket
|
|
36
|
+
|
|
37
|
+
Set a repository hook secret and API token:
|
|
38
|
+
|
|
39
|
+
```bash
|
|
40
|
+
BITBUCKET_WEBHOOK_SECRET=...
|
|
41
|
+
BITBUCKET_TOKEN=...
|
|
42
|
+
```
|
|
43
|
+
|
|
44
|
+
Add a repository webhook for
|
|
45
|
+
`https://<your-host>/<slug>/v1/channels/bitbucket`. Use the same secret on
|
|
46
|
+
both sides. The channel verifies the `X-Hub-Signature` HMAC before it parses
|
|
47
|
+
the payload.
|
|
48
|
+
|
|
49
|
+
Bitbucket Cloud uses its 2.0 API by default. Data Center also needs its REST
|
|
50
|
+
API base:
|
|
51
|
+
|
|
52
|
+
```ts
|
|
53
|
+
export default bitbucketChannel({
|
|
54
|
+
apiBaseUrl: "https://bitbucket.example.com/rest/api/1.0",
|
|
55
|
+
repos: ["PLATFORM/api"],
|
|
56
|
+
});
|
|
57
|
+
```
|
|
58
|
+
|
|
59
|
+
You can set `BITBUCKET_API_BASE_URL` instead.
|
|
60
|
+
|
|
61
|
+
## Test locally
|
|
62
|
+
|
|
63
|
+
Start the agent, then replay a pull request you can read:
|
|
64
|
+
|
|
65
|
+
```bash
|
|
66
|
+
agent-sdk dev
|
|
67
|
+
agent-sdk bitbucket replay \
|
|
68
|
+
https://bitbucket.example.com/projects/PLATFORM/repos/api/pull-requests/42
|
|
69
|
+
```
|
|
70
|
+
|
|
71
|
+
Replay supports Bitbucket Cloud and Data Center URLs. `BITBUCKET_TOKEN` needs
|
|
72
|
+
pull request read access. The command reads the pull request, creates a payload
|
|
73
|
+
in the matching dialect, and sends it through the same channel route. Use
|
|
74
|
+
`--events '*'` to replay the supported events declared by the channel. Use
|
|
75
|
+
`--dry-run --out fixtures/bitbucket` to save fixtures.
|
|
76
|
+
|
|
77
|
+
```bash
|
|
78
|
+
agent-sdk bitbucket events --dir .
|
|
79
|
+
agent-sdk bitbucket forward --dir .
|
|
80
|
+
```
|
|
81
|
+
|
|
82
|
+
`forward` prints the repository-hook and HTTPS tunnel setup for live
|
|
83
|
+
deliveries.
|
|
84
|
+
|
|
85
|
+
## Related
|
|
86
|
+
|
|
87
|
+
- [Channels reference](../reference/channels.md)
|
|
88
|
+
- [Webhooks and custom channels](./webhooks.md)
|
|
89
|
+
- [Evals](../evals.md)
|
package/docs/guides/github.md
CHANGED
|
@@ -79,6 +79,37 @@ snapshot in the wake.
|
|
|
79
79
|
This is the preferred production path: no public URL, no repo admin
|
|
80
80
|
webhook, and no inbound network for GitHub deliveries.
|
|
81
81
|
|
|
82
|
+
## Connect GitHub Enterprise Server
|
|
83
|
+
|
|
84
|
+
GitHub Enterprise Server uses the same `githubChannel()` hooks and normalized
|
|
85
|
+
events. Connect it through the direct webhook route. Set the REST API base and
|
|
86
|
+
credentials for your server:
|
|
87
|
+
|
|
88
|
+
```ts
|
|
89
|
+
export default githubChannel({
|
|
90
|
+
api: {
|
|
91
|
+
apiBaseUrl: "https://github.example.com/api/v3",
|
|
92
|
+
},
|
|
93
|
+
credentials: {
|
|
94
|
+
token: () => process.env.GITHUB_TOKEN,
|
|
95
|
+
webhookSecret: () => process.env.GITHUB_WEBHOOK_SECRET,
|
|
96
|
+
},
|
|
97
|
+
onPullRequest: (ctx, pr) =>
|
|
98
|
+
pr.action === "opened" ? { auth: defaultGitHubAuth(ctx) } : null,
|
|
99
|
+
});
|
|
100
|
+
```
|
|
101
|
+
|
|
102
|
+
Add a repository webhook for
|
|
103
|
+
`https://<your-host>/<slug>/v1/channels/github`. Use the same webhook secret
|
|
104
|
+
on the server and in `GITHUB_WEBHOOK_SECRET`. The channel verifies
|
|
105
|
+
`X-Hub-Signature-256` before it parses the payload.
|
|
106
|
+
|
|
107
|
+
Cursor account event pull, `github replay`, and `github forward` target
|
|
108
|
+
GitHub.com. Test Enterprise Server integrations by posting saved webhook
|
|
109
|
+
fixtures to a local `--dev` server. Leave `GITHUB_WEBHOOK_SECRET` unset for
|
|
110
|
+
this local test so the channel admits unsigned loopback deliveries. Use a real
|
|
111
|
+
delivery from your server so the fixture matches its version.
|
|
112
|
+
|
|
82
113
|
## Define the channel
|
|
83
114
|
|
|
84
115
|
Author `agent/channels/github.ts` with `githubChannel()` from
|
|
@@ -0,0 +1,97 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: "GitLab"
|
|
3
|
+
description: "Wake your agent from GitLab merge requests, notes, pipelines, and pushes on GitLab.com or self-managed GitLab."
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# GitLab agents
|
|
7
|
+
|
|
8
|
+
Use `gitlabChannel()` for GitLab.com and self-managed GitLab. The channel
|
|
9
|
+
verifies project hooks, normalizes their payloads, and gives each hook a
|
|
10
|
+
project-bound `ctx.gitlab` API client.
|
|
11
|
+
|
|
12
|
+
## Define the channel
|
|
13
|
+
|
|
14
|
+
Author `agent/channels/gitlab.ts`:
|
|
15
|
+
|
|
16
|
+
```ts
|
|
17
|
+
import { gitlabChannel } from "@cursor/july/channels/gitlab";
|
|
18
|
+
|
|
19
|
+
export default gitlabChannel({});
|
|
20
|
+
```
|
|
21
|
+
|
|
22
|
+
Without `onMergeRequest`, new and reopened merge requests start turns.
|
|
23
|
+
Updates start turns only when they include new commits. Notes, pushes, and
|
|
24
|
+
pipelines are opt-in through `onNote`, `onPush`, and `onPipeline`.
|
|
25
|
+
Use `onEvent` for other GitLab event types. Set `webhookEvents` when managed
|
|
26
|
+
event delivery must subscribe to an event that only `onEvent` handles.
|
|
27
|
+
|
|
28
|
+
Filter note hooks by author before starting a turn. This prevents comments
|
|
29
|
+
posted by the agent from triggering another turn.
|
|
30
|
+
|
|
31
|
+
`ctx.gitlab` can call the project REST API and create commit statuses. See the
|
|
32
|
+
[Channels reference](../reference/channels.md) for hook return values and
|
|
33
|
+
session behavior.
|
|
34
|
+
|
|
35
|
+
## Connect GitLab
|
|
36
|
+
|
|
37
|
+
On Cursor-managed hosting, use the signed-in Cursor account:
|
|
38
|
+
|
|
39
|
+
```ts
|
|
40
|
+
export default gitlabChannel({
|
|
41
|
+
cursorAccount: {
|
|
42
|
+
projects: ["acme/platform"],
|
|
43
|
+
},
|
|
44
|
+
});
|
|
45
|
+
```
|
|
46
|
+
|
|
47
|
+
For direct webhooks, set a project hook secret and API token:
|
|
48
|
+
|
|
49
|
+
```bash
|
|
50
|
+
GITLAB_WEBHOOK_SECRET=...
|
|
51
|
+
GITLAB_TOKEN=...
|
|
52
|
+
```
|
|
53
|
+
|
|
54
|
+
Add a project webhook for
|
|
55
|
+
`https://<your-host>/<slug>/v1/channels/gitlab`. Use the same value for the
|
|
56
|
+
GitLab secret token and `GITLAB_WEBHOOK_SECRET`. The channel checks
|
|
57
|
+
`X-Gitlab-Token` before it parses the payload.
|
|
58
|
+
|
|
59
|
+
Self-managed GitLab also needs its REST API base:
|
|
60
|
+
|
|
61
|
+
```ts
|
|
62
|
+
export default gitlabChannel({
|
|
63
|
+
apiBaseUrl: "https://gitlab.example.com/api/v4",
|
|
64
|
+
projects: ["acme/platform"],
|
|
65
|
+
});
|
|
66
|
+
```
|
|
67
|
+
|
|
68
|
+
You can set `GITLAB_API_BASE_URL` instead.
|
|
69
|
+
|
|
70
|
+
## Test locally
|
|
71
|
+
|
|
72
|
+
Start the agent, then replay a merge request you can read:
|
|
73
|
+
|
|
74
|
+
```bash
|
|
75
|
+
agent-sdk dev
|
|
76
|
+
agent-sdk gitlab replay \
|
|
77
|
+
https://gitlab.example.com/acme/platform/-/merge_requests/42
|
|
78
|
+
```
|
|
79
|
+
|
|
80
|
+
`GITLAB_TOKEN` needs API read access. Replay reads the merge request,
|
|
81
|
+
creates GitLab-shaped payloads, and sends them through the same channel route.
|
|
82
|
+
Use `--events '*'` to replay the supported events declared by the channel.
|
|
83
|
+
Use `--dry-run --out fixtures/gitlab` to save fixtures.
|
|
84
|
+
|
|
85
|
+
```bash
|
|
86
|
+
agent-sdk gitlab events --dir .
|
|
87
|
+
agent-sdk gitlab forward --dir .
|
|
88
|
+
```
|
|
89
|
+
|
|
90
|
+
GitLab has no local webhook relay. `forward` prints the project-hook and HTTPS
|
|
91
|
+
tunnel setup for live deliveries.
|
|
92
|
+
|
|
93
|
+
## Related
|
|
94
|
+
|
|
95
|
+
- [Channels reference](../reference/channels.md)
|
|
96
|
+
- [Webhooks and custom channels](./webhooks.md)
|
|
97
|
+
- [Evals](../evals.md)
|
package/docs/guides/webhooks.md
CHANGED
|
@@ -9,7 +9,8 @@ A custom channel gives the agent its own HTTP surface. You get routes
|
|
|
9
9
|
with validated payloads, sessions keyed to something in your domain (a
|
|
10
10
|
thread, a ticket, a PR), and replies delivered back to the caller. The
|
|
11
11
|
[Slack](./slack.md) and [GitHub](./github.md) packs build on this
|
|
12
|
-
mechanism.
|
|
12
|
+
mechanism. The [GitLab](./gitlab.md) and [Bitbucket](./bitbucket.md) packs
|
|
13
|
+
use it too. This page is the mechanism itself.
|
|
13
14
|
|
|
14
15
|
## What you already have
|
|
15
16
|
|
|
@@ -463,6 +464,7 @@ from any PR you can read. See the [GitHub guide](./github.md).
|
|
|
463
464
|
Continue with these pages:
|
|
464
465
|
|
|
465
466
|
- [Channels reference](../reference/channels.md): the full authoring API
|
|
466
|
-
- [GitHub](./github.md)
|
|
467
|
+
- [GitHub](./github.md), [GitLab](./gitlab.md),
|
|
468
|
+
[Bitbucket](./bitbucket.md), and [Slack](./slack.md): the packaged channels
|
|
467
469
|
- [Sessions and streaming](../reference/sessions.md): events your
|
|
468
470
|
channel can subscribe to
|
package/docs/hillclimbing.md
CHANGED
|
@@ -72,9 +72,9 @@ Pin the input first. A moving fixture is noise. For GitHub agents, use `agent-sd
|
|
|
72
72
|
|
|
73
73
|
## How do I lock a hillclimb improvement with an eval?
|
|
74
74
|
|
|
75
|
-
Every kept change needs an eval that would have failed before the change: a tool-choice gate,
|
|
75
|
+
Every kept change needs an eval that would have failed before the change: a tool-choice gate, a `maxToolCalls` bound, or an output-shape check. Run `agent-sdk eval --dir . --json` between rounds. Never weaken an existing gate to pass the round.
|
|
76
76
|
|
|
77
|
-
Details live in [
|
|
77
|
+
Details live in [Keep improvements with regression evals](./evals.md#keep-improvements-with-regression-evals). The evals skill will author the case with you.
|
|
78
78
|
|
|
79
79
|
## What habits help hillclimbing stay reliable?
|
|
80
80
|
|
|
@@ -8,7 +8,8 @@ description: "The authoring reference for defineChannel, the built-in HTTP chann
|
|
|
8
8
|
A channel is the surface an agent lives on. The built-in HTTP session
|
|
9
9
|
channel is always mounted. Custom channels declare their own routes
|
|
10
10
|
under `/v1/channels/<id>`. The Slack and GitHub packs are prebuilt
|
|
11
|
-
channels with platform transports.
|
|
11
|
+
channels with platform transports. GitLab and Bitbucket packs cover their
|
|
12
|
+
hosted and self-managed products. This page is the authoring reference;
|
|
12
13
|
for the walkthrough, see the [Webhooks guide](../guides/webhooks.md).
|
|
13
14
|
|
|
14
15
|
## Built-in HTTP channel
|
|
@@ -134,7 +135,7 @@ Handlers receive the Fetch `Request` and an args object:
|
|
|
134
135
|
`workspaceFiles`, `workspaceDir`, `cloud` (attach cloud repos for this
|
|
135
136
|
session), `auth` (defaults to the request principal), `state` (starting
|
|
136
137
|
channel state for new sessions), `title` (session display title), and
|
|
137
|
-
`purpose` (`"eval"`
|
|
138
|
+
`purpose` (`"eval"` marks the session as regression traffic).
|
|
138
139
|
|
|
139
140
|
## Events
|
|
140
141
|
|
|
@@ -215,7 +216,19 @@ model turn), `{ task }` (host work), or `null`, and CLI tooling for
|
|
|
215
216
|
replay and live forwarding. Author `agent/channels/github.ts` with
|
|
216
217
|
`githubChannel()`. Opt-in `progress.commitStatus` and `progress.banner`
|
|
217
218
|
converge a merge-box check and sticky PR comment from default stream
|
|
218
|
-
events.
|
|
219
|
+
events. Supports GitHub.com and GitHub Enterprise Server. Guide:
|
|
220
|
+
[GitHub](../guides/github.md).
|
|
221
|
+
|
|
222
|
+
**GitLab** (`@cursor/july/channels/gitlab`): verified project hooks for
|
|
223
|
+
merge requests, notes, pipelines, pushes, and custom event types. Supports
|
|
224
|
+
GitLab.com and self-managed GitLab. Author `agent/channels/gitlab.ts` with
|
|
225
|
+
`gitlabChannel()`. Guide: [GitLab](../guides/gitlab.md).
|
|
226
|
+
|
|
227
|
+
**Bitbucket** (`@cursor/july/channels/bitbucket`): verified repository hooks
|
|
228
|
+
for pull requests, comments, pushes, and custom event types. Supports
|
|
229
|
+
Bitbucket Cloud and Bitbucket Data Center through one normalized hook API.
|
|
230
|
+
Author `agent/channels/bitbucket.ts` with `bitbucketChannel()`. Guide:
|
|
231
|
+
[Bitbucket](../guides/bitbucket.md).
|
|
219
232
|
|
|
220
233
|
**Deployments** (`@cursor/july/channels/deployments`): pull deploy
|
|
221
234
|
events. Declare `events` and handle each one in `onEvent`. Each event
|
package/docs/reference/cli.md
CHANGED
|
@@ -366,8 +366,10 @@ agent-sdk eval status <evalId> --prod --slug pr-approver
|
|
|
366
366
|
agent-sdk eval cancel <evalId> --prod --slug pr-approver
|
|
367
367
|
```
|
|
368
368
|
|
|
369
|
-
`eval` runs `evals/**/*.eval.{ts,js}` on an ephemeral server
|
|
370
|
-
`--
|
|
369
|
+
`eval` runs `evals/**/*.eval.{ts,js}` on an ephemeral server. With
|
|
370
|
+
`--prod` or `--url`, the target server runs its own evals as a
|
|
371
|
+
server-side batch. Select one or more exact case IDs, file ID prefixes,
|
|
372
|
+
or tags.
|
|
371
373
|
Omit selectors to run all cases. Repeated `--tag` flags use OR matching.
|
|
372
374
|
|
|
373
375
|
An eval run requires `evals/evals.config.{ts,js}` with `maxConcurrency`
|
|
@@ -378,13 +380,13 @@ between 1 and 200. Timeout priority is the case's `timeoutMs`, the CLI's
|
|
|
378
380
|
| --- | --- |
|
|
379
381
|
| `--list` | Print discovered cases without running. `--list --json` prints them as an array. |
|
|
380
382
|
| `--tag <tag>` | Run cases with this tag. Repeated flags use OR matching. |
|
|
381
|
-
| `--json` | Print `{ ok, passed, failed, results }
|
|
383
|
+
| `--json` | Print `{ ok, passed, failed, scored, skipped, strict, results }`; see [Run evals in CI](../evals.md#run-evals-in-ci) for the result shape. |
|
|
382
384
|
| `--verbose` | Stream `t.log` lines and reply snippets. |
|
|
383
385
|
| `--no-stream` | Hide live progress on stderr. |
|
|
384
386
|
| `--strict` | Exit `1` when a scored case misses a soft threshold. |
|
|
385
387
|
| `--max-concurrency <n>` | Override `maxConcurrency` from `evals.config.ts`. |
|
|
386
388
|
| `--junit <path>` | Write JUnit XML for CI annotations. |
|
|
387
|
-
| `--artifacts <dir>` | Write run artifacts here. The default is a timestamped directory under
|
|
389
|
+
| `--artifacts <dir>` | Write run artifacts here. The default is a timestamped directory under `evals/` in the project state directory (not affected by `--state-root`). |
|
|
388
390
|
| `--no-artifacts` | Skip run artifacts. |
|
|
389
391
|
| `--skip-report` | Ignore reporters from `evals.config.ts` and eval files. |
|
|
390
392
|
| `--out <path>` | Also write the full results JSON to this path (also for `eval status <evalId>`). |
|
|
@@ -59,7 +59,6 @@ namespace:
|
|
|
59
59
|
| `subagents/<id>/` | subagent `<ns>__<id>` |
|
|
60
60
|
| `instructions.md` / `.ts` / dir | appended to the agent's system prompt |
|
|
61
61
|
| `sandbox/workspace/**` | seeded into each local session workspace |
|
|
62
|
-
| `ab.ts` / `ab/<name>.ts` | A/B experiment `<ns>__<name>` |
|
|
63
62
|
| `artifacts.ts` | artifact kinds `<ns>__<kind>` |
|
|
64
63
|
|
|
65
64
|
The root agent still needs its own `instructions.md`. Extension
|
|
@@ -76,7 +75,6 @@ or is outside discovery:
|
|
|
76
75
|
| `agent.ts` | One `defineAgent` runtime per agent |
|
|
77
76
|
| `storage.ts` | One `host.kv` / `host.files` backend |
|
|
78
77
|
| `otel.ts` | One OTLP exporter |
|
|
79
|
-
| `ab.config.ts` | One experiment-platform config; `ab.ts` / `ab/` still merge |
|
|
80
78
|
| `playground/` | Custom chips are a Vite glob of the agent tree, not a discovery walk |
|
|
81
79
|
| `extensions/` | Nested mounts are not loaded |
|
|
82
80
|
| `sandbox.ts` | Custom sandbox backends stay on the agent |
|
|
@@ -117,7 +115,6 @@ it alive.
|
|
|
117
115
|
| `schedules/<name>.ts` | `disableSchedule()` |
|
|
118
116
|
| `subagents/<id>.ts` | `disableSubagent()` |
|
|
119
117
|
| `instructions.ts` | `disableInstructions()` |
|
|
120
|
-
| `ab.ts` / `ab/<name>.ts` | `disableAB()` |
|
|
121
118
|
| `artifacts.ts` | `disableArtifacts()` |
|
|
122
119
|
|
|
123
120
|
`disable()` is the same brand as the slot helpers above and works in
|
package/docs/reference/hooks.md
CHANGED
|
@@ -88,7 +88,7 @@ exported from `@cursor/july`.
|
|
|
88
88
|
|
|
89
89
|
| Member | What it is |
|
|
90
90
|
| --- | --- |
|
|
91
|
-
| `ctx.session` | Read-only session info: `id`, `channelId`, `mode` (`chat` or `task`), `purpose` (`live` or `eval`), `auth`, plus `title
|
|
91
|
+
| `ctx.session` | Read-only session info: `id`, `channelId`, `mode` (`chat` or `task`), `purpose` (`live` or `eval`), `auth`, plus `title` and `sdkAgentId` when set |
|
|
92
92
|
| `ctx.agent` | `{ name }` of the agent the event belongs to |
|
|
93
93
|
| `ctx.channel` | `{ id, continuationToken }`. The token is `null` when the session can't take follow-ups |
|
|
94
94
|
| `ctx.host.kv` | Durable JSON, shared by every session of the agent; the [storage backend](../storage.md#author-kv-ctx-host-kv) decides whether it survives a hosted replace. Prefix keys with `ctx.session.id` for per-session state |
|
|
@@ -119,17 +119,17 @@ Each event reaches a hook at most once. A restart doesn't replay the log
|
|
|
119
119
|
into hooks, so a mirror needs no dedupe, and the event log rather than
|
|
120
120
|
the hook's copy is the source of truth.
|
|
121
121
|
|
|
122
|
-
## Hooks, channel events,
|
|
122
|
+
## Hooks, channel events, or evals?
|
|
123
123
|
|
|
124
124
|
All of them consume the same stream, for different jobs:
|
|
125
125
|
|
|
126
|
-
| | Hooks | Channel `events` | Evals |
|
|
127
|
-
| --- | --- | --- | --- |
|
|
128
|
-
| Scope | every session of the agent | sessions the channel owns | one test turn |
|
|
129
|
-
| Job | observe: audit, metrics, mirrors, derived state | deliver: replies back to the channel's surface | assert: gates over the trajectory |
|
|
130
|
-
| Context | `ctx.host`, `ctx.artifacts`, session info | `channel.state`, `setContinuationToken`, `ctx.host`, session info | the `t` assertion helpers |
|
|
131
|
-
| Can affect the run | no | yes, it owns the surface | n/a |
|
|
132
|
-
| Authored at | `agent/hooks/*.ts` | channel config | `evals/**/*.eval.ts` |
|
|
126
|
+
| | Hooks | Channel `events` | Evals |
|
|
127
|
+
| --- | --- | --- | --- |
|
|
128
|
+
| Scope | every session of the agent | sessions the channel owns | one test turn |
|
|
129
|
+
| Job | observe: audit, metrics, mirrors, derived state | deliver: replies back to the channel's surface | assert: gates over the trajectory |
|
|
130
|
+
| Context | `ctx.host`, `ctx.artifacts`, session info | `channel.state`, `setContinuationToken`, `ctx.host`, session info | the `t` assertion helpers |
|
|
131
|
+
| Can affect the run | no | yes, it owns the surface | n/a |
|
|
132
|
+
| Authored at | `agent/hooks/*.ts` | channel config | `evals/**/*.eval.ts` |
|
|
133
133
|
|
|
134
134
|
## When not to use a hook
|
|
135
135
|
|
|
@@ -141,7 +141,6 @@ All of them consume the same stream, for different jobs:
|
|
|
141
141
|
| Block, approve, or rewrite a tool call | [`needsApproval`](./tools.md#gate-a-tool-on-human-approval) on the tool |
|
|
142
142
|
| Act on the final assistant text, or fail a bad turn | [`defineResult`](./result.md) |
|
|
143
143
|
| Gate a change on behavior | [Evals](../evals.md) |
|
|
144
|
-
| Compare two prompts on live traffic | [`defineAB`](../ab.md) |
|
|
145
144
|
|
|
146
145
|
## Patterns
|
|
147
146
|
|
|
@@ -267,5 +266,3 @@ Continue with these pages:
|
|
|
267
266
|
- [Deployment](../deployment.md#observability): runtime logs and export
|
|
268
267
|
paths
|
|
269
268
|
- [Channels](./channels.md#events): the delivery-side counterpart
|
|
270
|
-
- [Live A/B metrics](../ab.md): sticky variants over the same event
|
|
271
|
-
stream
|
|
@@ -152,12 +152,11 @@ These read-only routes describe the running agent.
|
|
|
152
152
|
|
|
153
153
|
| Route | What it does |
|
|
154
154
|
| ---------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
155
|
-
| `GET /v1/info` | The discovered surface: model, tools, skills, MCP connections, subagents, channels and routes (with schemas), schedules, hooks,
|
|
155
|
+
| `GET /v1/info` | The discovered surface: model, tools, skills, MCP connections, subagents, channels and routes (with schemas), schedules, hooks, diagnostics |
|
|
156
156
|
| `GET /v1/tools` | The live tool catalog: authored server tools plus advertised MCP passthroughs under model-facing names, as light `{ name, title?, source? }` entries. `session` / `continuationToken` query parameters bind the listing to a session identity (advertised inventories can be tenant-scoped); a connection whose listing fails is skipped and reported in `connectionErrors` |
|
|
157
157
|
| `GET /v1/tools/:name` | One catalog tool's full description: description, execution, `needsApproval`, `effect`, input and output schemas, source connection. Same session binding as the listing; unknown names get `404` with the available names |
|
|
158
158
|
| `GET /v1/health` | Per-agent liveness, no auth |
|
|
159
159
|
| `GET /v1/logs?after=N` | Recent server log lines, with a polling cursor |
|
|
160
|
-
| `GET /v1/abs` | [Live A/B metrics](../ab.md): per-session assignments and aggregate arm totals |
|
|
161
160
|
|
|
162
161
|
## Artifacts
|
|
163
162
|
|
|
@@ -216,7 +215,7 @@ the final `completed` or `failed` status. Batch errors appear on the
|
|
|
216
215
|
snapshot returned by the poll. Entries within `filterIds` and `tags`
|
|
217
216
|
use OR semantics. When both fields are present, a case must match one
|
|
218
217
|
entry from each field. Listed runs persist across restarts when storage is configured; see
|
|
219
|
-
[Storage](../storage.md#eval-
|
|
218
|
+
[Storage](../storage.md#eval-table). Otherwise they are
|
|
220
219
|
process-memory only.
|
|
221
220
|
|
|
222
221
|
## Dev-mode routes
|
|
@@ -37,8 +37,6 @@ Use the playground to chat, try channel routes, and inspect sessions.
|
|
|
37
37
|
an [extension](./extensions.md) cannot contribute them.
|
|
38
38
|
- **Raw events pane**: flip it on to inspect the event stream.
|
|
39
39
|
- **Logs tab**: recent server log lines, polled from `GET /v1/logs`.
|
|
40
|
-
- **A/Bs tab**: per-session and aggregate
|
|
41
|
-
[live A/B metrics](../ab.md) from `GET /v1/abs`.
|
|
42
40
|
|
|
43
41
|
In multi-agent mode each agent has its own playground at
|
|
44
42
|
`/<slug>/playground`, and `/` is an index of them all.
|
|
@@ -61,5 +59,3 @@ Continue with these pages:
|
|
|
61
59
|
- [Sessions and streaming](./sessions.md): the streams it renders
|
|
62
60
|
- [Human-in-the-loop](../guides/human-in-the-loop.md): the approval
|
|
63
61
|
buttons in context
|
|
64
|
-
- [Live A/B metrics](../ab.md): the assignments and results in the A/Bs
|
|
65
|
-
tab
|
|
@@ -11,8 +11,7 @@ how the Agent SDK loads it.
|
|
|
11
11
|
|
|
12
12
|
## Folder structure
|
|
13
13
|
|
|
14
|
-
For the capabilities below, identity
|
|
15
|
-
experiments can override their file-derived name.
|
|
14
|
+
For the capabilities below, identity comes from the path.
|
|
16
15
|
|
|
17
16
|
| Path | Resolves to |
|
|
18
17
|
| --- | --- |
|
|
@@ -24,8 +23,6 @@ experiments can override their file-derived name.
|
|
|
24
23
|
| `agent/extensions/ci.ts` | extension mount `ci`; its contributions become `ci__<name>` |
|
|
25
24
|
| `agent/extensions/notion.ts` | Cursor plugin mount `notion` (`cursorPlugin`); its skills, agents, and MCP servers become `notion__<name>` |
|
|
26
25
|
| `agent/channels/drive.ts` | channel `drive`, routes under `/v1/channels/drive` |
|
|
27
|
-
| `agent/ab.ts` | A/B experiment `ab` unless `name` overrides it |
|
|
28
|
-
| `agent/ab/concise.ts` | A/B experiment `concise` unless `name` overrides it |
|
|
29
26
|
|
|
30
27
|
The root agent takes its name from `package.json` `name`, falling back
|
|
31
28
|
to the directory name. When serving multiple agents, the slug is the
|
|
@@ -77,8 +74,6 @@ Each path maps to a capability and a reference page.
|
|
|
77
74
|
| `agent/channels/*.ts` | HTTP surfaces beyond the built-in session API; `slack.ts` and `github.ts` use the platform packs | [Channels](./channels.md) |
|
|
78
75
|
| `agent/hooks/*.ts` | Observe-only event subscribers, never fatal | [Hooks](./hooks.md) |
|
|
79
76
|
| `agent/otel.ts` | `defineOtel` OTLP export (traces, metrics, optional logs) | [OpenTelemetry](../guides/opentelemetry.md) |
|
|
80
|
-
| `agent/ab.ts`, `agent/ab/*.ts` | `defineAB` experiments with sticky variants and live metrics | [Live A/B metrics](../ab.md) |
|
|
81
|
-
| `agent/ab.config.ts` | `defineABConfig` shared A/B settings | [Live A/B metrics](../ab.md) |
|
|
82
77
|
| `agent/storage.ts` | `defineStorage` backend for the durable `host.kv` / `host.files` APIs | [Storage](../storage.md) |
|
|
83
78
|
| `agent/artifacts.ts` | `defineArtifacts` kinds, the `tag_artifact` opt-in, and retention | [Artifacts](./artifacts.md) |
|
|
84
79
|
| `agent/result.ts` | `defineResult` host `commit` on the final assistant text | [Turn result](./result.md) |
|
|
@@ -115,6 +110,4 @@ Continue with these pages:
|
|
|
115
110
|
|
|
116
111
|
- [Agent config](./agent-config.md): the runtime config at the root
|
|
117
112
|
- [Tools](./tools.md): add typed actions under `agent/tools/`
|
|
118
|
-
- [Live A/B metrics](../ab.md): compare variants from `agent/ab.ts` or
|
|
119
|
-
`agent/ab/`
|
|
120
113
|
- [Concepts](../concepts.md): why the filesystem is the interface
|
|
@@ -80,7 +80,7 @@ within one session. The `at` field is an ISO-8601 timestamp.
|
|
|
80
80
|
|
|
81
81
|
| Phase | Events | What they tell you |
|
|
82
82
|
| --- | --- | --- |
|
|
83
|
-
| Session | `session.started`,
|
|
83
|
+
| Session | `session.started`, `session.waiting`, `session.completed`, `session.failed` | Session creation, readiness, and task completion |
|
|
84
84
|
| Agent | `agent.bound` | Cloud conversation URL |
|
|
85
85
|
| Input | `message.received` | A user message was accepted |
|
|
86
86
|
| Turn | `turn.queued`, `turn.started`, `turn.completed`, `turn.failed` | Queue position under a [`maxRunningTurns` cap](./agent-config.md#concurrency), then turn status, final result, and token usage |
|
|
@@ -164,5 +164,4 @@ view.
|
|
|
164
164
|
|
|
165
165
|
- [HTTP API](./http-api.md)
|
|
166
166
|
- [Hooks](./hooks.md)
|
|
167
|
-
- [Live A/B metrics](../ab.md)
|
|
168
167
|
- [How the Agent SDK works](../concepts.md)
|
package/docs/skills/index.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
title: "Coding-agent skills"
|
|
3
|
-
description: "Task guides that ship with the Agent SDK for scaffolding, evals, channels, and hillclimbing."
|
|
3
|
+
description: "Task guides that ship with the Agent SDK for scaffolding, deployment, evals, channels, and hillclimbing."
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
# Coding-agent skills
|
|
@@ -17,10 +17,10 @@ to use each one.
|
|
|
17
17
|
| [framework-map](./framework-map.md) | Learn the project layout and runtimes |
|
|
18
18
|
| [create-agent](./create-agent.md) | Scaffold and verify a new agent |
|
|
19
19
|
| [evals](./evals.md) | Write fixtures and regression checks |
|
|
20
|
-
| [ab](./ab.md) | Compare variants on live traffic |
|
|
21
20
|
| [otel](./otel.md) | Export OpenTelemetry traces |
|
|
22
21
|
| [hillclimb](./hillclimb.md) | Improve an agent against fixed inputs |
|
|
23
22
|
| [github](./github.md) | Add GitHub webhooks and replay events |
|
|
24
23
|
| [setup-slack](./setup-slack.md) | Connect an agent to Slack |
|
|
25
24
|
| [mcp-auth](./mcp-auth.md) | Authorize host MCP OAuth |
|
|
25
|
+
| [deploy](./deploy.md) | Deploy with an attached service account |
|
|
26
26
|
| [debug](./debug.md) | Diagnose a local run |
|
package/docs/storage.md
CHANGED
|
@@ -6,8 +6,8 @@ description: "Point the Agent SDK's durable storage at a backend you own with de
|
|
|
6
6
|
# Storage
|
|
7
7
|
|
|
8
8
|
The Agent SDK owns durable storage for sessions, continuation tokens,
|
|
9
|
-
reminders, playground eval history
|
|
10
|
-
|
|
9
|
+
reminders, and playground eval history. It chooses the keys, when to
|
|
10
|
+
read and write, and how to restore after restart.
|
|
11
11
|
|
|
12
12
|
The Agent SDK owns key encoding. Backends must accept the keys they are
|
|
13
13
|
given. Do not fail `put` to enforce a shorter cap.
|
|
@@ -41,9 +41,9 @@ export default defineStorage({
|
|
|
41
41
|
## Which fields to provide
|
|
42
42
|
|
|
43
43
|
Implement the small KV core (`put`/`get`/`delete`/`list` plus the `cas`
|
|
44
|
-
group) and you get **full functionality**: eval-run
|
|
45
|
-
|
|
46
|
-
|
|
44
|
+
group) and you get **full functionality**: eval-run history is derived
|
|
45
|
+
over the core automatically. The dedicated `evals` group is a
|
|
46
|
+
backend-native optimization, not a required-or-lose-history hook.
|
|
47
47
|
|
|
48
48
|
| Field | Required | Role |
|
|
49
49
|
| --- | --- | --- |
|
|
@@ -54,36 +54,28 @@ are backend-native optimizations, not required-or-lose-history hooks.
|
|
|
54
54
|
| `delete` | For cleanup | Remove a key |
|
|
55
55
|
| `name` | No | Label surfaced on `GET /v1/info` diagnostics |
|
|
56
56
|
| `policy` | No | Timing knobs; see [Policy](#policy) |
|
|
57
|
-
| `evals` | No | Backend-native eval-runs table; derived over the core when omitted. See [Eval
|
|
58
|
-
| `abs` | No | Backend-native A/B metrics table; derived over the core when omitted. See [Eval and A/B tables](#eval-and-a-b-tables) |
|
|
57
|
+
| `evals` | No | Backend-native eval-runs table; derived over the core when omitted. See [Eval table](#eval-table) |
|
|
59
58
|
|
|
60
59
|
A throwing `put` is logged and dropped. It never fails a turn. When
|
|
61
60
|
resolving a missing continuation token, a throwing `get` fails the
|
|
62
61
|
follow-up so a store outage does not open a new session. Return
|
|
63
62
|
`undefined` only for a real miss.
|
|
64
63
|
|
|
65
|
-
## Eval
|
|
64
|
+
## Eval table
|
|
66
65
|
|
|
67
|
-
|
|
68
|
-
values.
|
|
69
|
-
authored, `defineStorage` derives it over the KV core, so a backend
|
|
70
|
-
implements only the core loses nothing. Author
|
|
71
|
-
backend has a better native shape (a real database table, an
|
|
72
|
-
pipeline). The built-in `fileKv` and `cursorHostedStorage`
|
|
66
|
+
The dedicated `evals` table group carries structured rows instead of
|
|
67
|
+
opaque KV values. It is an **optional optimization**: when the group is
|
|
68
|
+
not authored, `defineStorage` derives it over the KV core, so a backend
|
|
69
|
+
that implements only the core loses nothing. Author the group only when
|
|
70
|
+
the backend has a better native shape (a real database table, an
|
|
71
|
+
analytics pipeline). The built-in `fileKv` and `cursorHostedStorage`
|
|
72
|
+
both do.
|
|
73
73
|
|
|
74
74
|
`evals` keeps playground eval batches across restarts (`put`, `delete`,
|
|
75
75
|
`list` over run snapshots keyed by `runId`). A core missing `delete` or
|
|
76
76
|
`list` leaves eval history in memory until restart.
|
|
77
77
|
See [Evals](./evals.md#configure-eval-runs).
|
|
78
78
|
|
|
79
|
-
`abs` exports live A/B metrics: `putSample` appends one cumulative
|
|
80
|
-
metric sample per enrolled experiment on each completed or failed turn;
|
|
81
|
-
optional `putSnapshot` / `getSnapshot` store and serve back the latest
|
|
82
|
-
aggregate so a replacement host can still serve the A/Bs surface.
|
|
83
|
-
`putSample` and `putSnapshot` need only core `put`; `getSnapshot` needs
|
|
84
|
-
core `get`. Session event logs remain the assignment source of truth
|
|
85
|
-
either way. See [Live A/B metrics](./ab.md).
|
|
86
|
-
|
|
87
79
|
## Policy
|
|
88
80
|
|
|
89
81
|
Two knobs change behavior:
|
|
@@ -118,8 +110,7 @@ With `get` and `list`, serve can rebuild local state from your store:
|
|
|
118
110
|
- At startup, the Agent SDK loads recent sessions up to the restore caps.
|
|
119
111
|
- On demand, a missing continuation token resolves through the store
|
|
120
112
|
and resumes that session.
|
|
121
|
-
- Playground eval history
|
|
122
|
-
sink.
|
|
113
|
+
- Playground eval history can load from the same sink.
|
|
123
114
|
|
|
124
115
|
A turn in flight at crash time is not replayed. The next follow-up
|
|
125
116
|
resumes from the last flushed state.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cursor/july",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.109",
|
|
4
4
|
"description": "(early alpha) Filesystem-first framework for defining Cursor agents as markdown and TypeScript and serving them over channels with the Cursor SDK.",
|
|
5
5
|
"license": "SEE LICENSE IN LICENSE.md",
|
|
6
6
|
"repository": {
|
|
@@ -214,12 +214,6 @@
|
|
|
214
214
|
"import": "./dist/evals/loaders.js",
|
|
215
215
|
"default": "./dist/evals/loaders.js"
|
|
216
216
|
},
|
|
217
|
-
"./ab": {
|
|
218
|
-
"anysphere-source": "./src/ab.ts",
|
|
219
|
-
"types": "./dist/ab.d.ts",
|
|
220
|
-
"import": "./dist/ab.js",
|
|
221
|
-
"default": "./dist/ab.js"
|
|
222
|
-
},
|
|
223
217
|
"./artifacts": {
|
|
224
218
|
"anysphere-source": "./src/artifacts.ts",
|
|
225
219
|
"types": "./dist/artifacts.d.ts",
|