@parcha/agentrun-serve 0.1.0-beta.37 → 0.1.0-beta.38
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/CHANGELOG.md +282 -0
- package/README.md +155 -92
- package/dist/agent-rows.d.ts +1 -1
- package/dist/agents-store.d.ts +35 -3
- package/dist/agents-store.js +39 -14
- package/dist/answer-json.d.ts +34 -1
- package/dist/answer-json.js +91 -9
- package/dist/api-only.d.ts +1 -1
- package/dist/api-only.js +2 -2
- package/dist/browser-cost.js +52 -93
- package/dist/cap.d.ts +0 -390
- package/dist/cap.js +4 -937
- package/dist/catalog.js +1 -1
- package/dist/composio-preset.d.ts +17 -0
- package/dist/composio-preset.js +43 -1
- package/dist/computer-calls.d.ts +36 -24
- package/dist/computer-calls.js +110 -27
- package/dist/computer-live.d.ts +5 -0
- package/dist/computer-live.js +12 -0
- package/dist/computer-setting.d.ts +15 -2
- package/dist/computer-setting.js +20 -4
- package/dist/computer-view.d.ts +3 -2
- package/dist/computer-view.js +5 -4
- package/dist/computer-viewer.js +26 -12
- package/dist/computers.d.ts +4 -1
- package/dist/computers.js +12 -6
- package/dist/console/assets/index-CjqQirbo.css +1 -0
- package/dist/console/assets/index-b6-XY5A9.js +576 -0
- package/dist/console/index.html +2 -2
- package/dist/console-links.d.ts +2 -0
- package/dist/console-links.js +3 -0
- package/dist/decisions.js +4 -0
- package/dist/faux-computers.js +4 -2
- package/dist/harness-opencode/adapter.js +7 -3
- package/dist/harness-opencode/facts.js +0 -2
- package/dist/harness-opencode/host/policy.d.ts +2 -5
- package/dist/harness-opencode/host/policy.js +8 -32
- package/dist/harness-table.d.ts +0 -2
- package/dist/harness-table.js +0 -2
- package/dist/host-tools.d.ts +1 -5
- package/dist/host-tools.js +7 -10
- package/dist/hosted-search.d.ts +0 -2
- package/dist/hosted-search.js +0 -21
- package/dist/key-words.d.ts +3 -2
- package/dist/key-words.js +4 -2
- package/dist/learn/check.d.ts +6 -1
- package/dist/learn/check.js +12 -4
- package/dist/learn/commit.d.ts +10 -0
- package/dist/learn/commit.js +18 -4
- package/dist/learn/compile.d.ts +243 -0
- package/dist/learn/compile.js +471 -0
- package/dist/learn/general.d.ts +3 -0
- package/dist/learn/general.js +4 -2
- package/dist/learn/grade.d.ts +1 -1
- package/dist/learn/grade.js +7 -6
- package/dist/learn/notes.d.ts +8 -0
- package/dist/learn/notes.js +18 -0
- package/dist/learn/promote.d.ts +253 -0
- package/dist/learn/promote.js +428 -0
- package/dist/learn/refit.d.ts +39 -0
- package/dist/learn/refit.js +236 -0
- package/dist/learn/reflect.d.ts +5 -25
- package/dist/learn/reflect.js +14 -131
- package/dist/learn/replay-calls.d.ts +63 -0
- package/dist/learn/replay-calls.js +158 -0
- package/dist/learn/skills.d.ts +17 -9
- package/dist/learn/skills.js +132 -42
- package/dist/learn/workflow-nodes.d.ts +15 -0
- package/dist/learn/workflow-nodes.js +44 -0
- package/dist/learned-nodes.d.ts +50 -2
- package/dist/learned-nodes.js +41 -2
- package/dist/learned-workflow.d.ts +19 -3
- package/dist/learned-workflow.js +105 -26
- package/dist/learning-batch.d.ts +2 -2
- package/dist/learning-batch.js +1 -1
- package/dist/learning-cost.d.ts +18 -6
- package/dist/learning-cost.js +15 -7
- package/dist/learning-routes.d.ts +14 -2
- package/dist/learning-routes.js +14 -3
- package/dist/learning-words.d.ts +7 -0
- package/dist/learning-words.js +7 -0
- package/dist/learning.d.ts +31 -6
- package/dist/learning.js +7 -4
- package/dist/llm.js +0 -3
- package/dist/mcp-gateway.d.ts +12 -20
- package/dist/mcp-gateway.js +16 -44
- package/dist/mcp-oauth.d.ts +5 -0
- package/dist/mcp-oauth.js +1 -1
- package/dist/mcp-pin-first.d.ts +37 -0
- package/dist/mcp-pin-first.js +107 -0
- package/dist/mcp-probe.d.ts +8 -9
- package/dist/mcp-probe.js +16 -33
- package/dist/mcp-servers-store.d.ts +89 -22
- package/dist/mcp-servers-store.js +131 -25
- package/dist/mcp-sources.d.ts +39 -0
- package/dist/mcp-sources.js +74 -0
- package/dist/mcp-store.d.ts +11 -0
- package/dist/mcp-store.js +16 -2
- package/dist/mcp-wire.d.ts +22 -0
- package/dist/mcp-wire.js +36 -0
- package/dist/mcp.js +3 -3
- package/dist/meta-tool-names.d.ts +1 -0
- package/dist/meta-tool-names.js +3 -0
- package/dist/model.d.ts +13 -0
- package/dist/model.js +46 -15
- package/dist/monid.d.ts +51 -25
- package/dist/monid.js +226 -140
- package/dist/openapi.js +336 -66
- package/dist/paid-calls.d.ts +26 -29
- package/dist/paid-calls.js +46 -102
- package/dist/propose.d.ts +7 -1
- package/dist/propose.js +18 -6
- package/dist/provider.js +9 -2
- package/dist/reflect-range.js +2 -1
- package/dist/rows.d.ts +5 -3
- package/dist/rows.js +15 -4
- package/dist/run-launch.d.ts +13 -0
- package/dist/run-launch.js +6 -0
- package/dist/run-learning-served.d.ts +13 -2
- package/dist/run-manifest.d.ts +5 -0
- package/dist/run-manifest.js +20 -0
- package/dist/run-secrets.js +2 -3
- package/dist/run-timeline-served.js +5 -2
- package/dist/run-view.d.ts +17 -6
- package/dist/run-view.js +51 -22
- package/dist/runnable.d.ts +0 -3
- package/dist/runnable.js +37 -29
- package/dist/runner/adapter-loop.d.ts +24 -10
- package/dist/runner/adapter-loop.js +852 -314
- package/dist/runner/adapter-run-spec.d.ts +12 -6
- package/dist/runner/adapter-run-spec.js +97 -46
- package/dist/runner/adapters/pi-computer.d.ts +3 -1
- package/dist/runner/adapters/pi-computer.js +13 -5
- package/dist/runner/adapters/pi.d.ts +16 -7
- package/dist/runner/adapters/pi.js +94 -33
- package/dist/runner/cli-run-spec.js +67 -27
- package/dist/runner/computer-channel.js +2 -1
- package/dist/runner/conformance/harness.d.ts +3 -0
- package/dist/runner/conformance/harness.js +145 -4
- package/dist/runner/conformance/subject.d.ts +11 -4
- package/dist/runner/end-of-run.d.ts +6 -5
- package/dist/runner/end-of-run.js +9 -6
- package/dist/runner/feedback-round.d.ts +52 -0
- package/dist/runner/feedback-round.js +79 -0
- package/dist/runner/journal-kinds.d.ts +24 -6
- package/dist/runner/journal-kinds.js +15 -0
- package/dist/runner/learning-end.d.ts +54 -19
- package/dist/runner/learning-end.js +272 -99
- package/dist/runner/learning-loop.d.ts +19 -1
- package/dist/runner/learning-loop.js +5 -2
- package/dist/runner/learning-seed.d.ts +4 -0
- package/dist/runner/learning-seed.js +14 -0
- package/dist/runner/loop-contract.d.ts +19 -3
- package/dist/runner/loop.d.ts +16 -1
- package/dist/runner/loop.js +21 -1
- package/dist/runner/mcp-claim.d.ts +5 -1
- package/dist/runner/mcp-claim.js +66 -50
- package/dist/runner/mcp-run.d.ts +16 -52
- package/dist/runner/mcp-run.js +12 -84
- package/dist/runner/meta-tools.d.ts +37 -0
- package/dist/runner/meta-tools.js +268 -0
- package/dist/runner/metrics.js +14 -3
- package/dist/runner/model-route.js +12 -3
- package/dist/runner/monid-run.d.ts +16 -0
- package/dist/runner/monid-run.js +96 -0
- package/dist/runner/promotion.d.ts +80 -0
- package/dist/runner/promotion.js +562 -0
- package/dist/runner/reflect-hook.d.ts +36 -21
- package/dist/runner/reflect-hook.js +138 -49
- package/dist/runner/runner.js +26 -4
- package/dist/runner/sessions.d.ts +8 -3
- package/dist/runner/sessions.js +5 -1
- package/dist/runner/step-guard.d.ts +62 -0
- package/dist/runner/step-guard.js +93 -0
- package/dist/runner/subagent.d.ts +0 -3
- package/dist/runner/subagent.js +7 -12
- package/dist/runner/workflow-first.d.ts +216 -0
- package/dist/runner/workflow-first.js +303 -0
- package/dist/runner/workflow-loop.js +17 -10
- package/dist/runner/workflow-spec.d.ts +1 -0
- package/dist/runner/workflow-spec.js +7 -3
- package/dist/runs-over-store.d.ts +11 -2
- package/dist/runs-over-store.js +21 -11
- package/dist/server.d.ts +88 -16
- package/dist/server.js +380 -87
- package/dist/settings-wake.d.ts +8 -6
- package/dist/settings-wake.js +13 -7
- package/dist/store/agent-body.d.ts +14 -3
- package/dist/store/agent-body.js +14 -10
- package/dist/store/command-wake.d.ts +3 -2
- package/dist/store/command-wake.js +4 -4
- package/dist/store/postgres/connection.js +3 -1
- package/dist/store/postgres/migrations/0010_imported_templates.sql +18 -0
- package/dist/store/postgres/migrations/0011_revision_mcp_pin.sql +13 -0
- package/dist/store/schema.d.ts +9 -0
- package/dist/store/schema.js +28 -8
- package/dist/store/sqlite/connection.d.ts +2 -2
- package/dist/store/sqlite/connection.js +2 -2
- package/dist/store/sqlite/run-patch.js +19 -7
- package/dist/store/sqlite/store.js +59 -18
- package/dist/store/store.d.ts +46 -14
- package/dist/store-reads/journal.d.ts +25 -1
- package/dist/store-reads/journal.js +63 -49
- package/dist/store-reads/learning.d.ts +101 -15
- package/dist/store-reads/learning.js +195 -61
- package/dist/store-reads/loop.d.ts +61 -0
- package/dist/store-reads/loop.js +111 -0
- package/dist/store-view.d.ts +3 -2
- package/dist/store-view.js +35 -17
- package/dist/template-eval.d.ts +18 -9
- package/dist/template-eval.js +91 -66
- package/dist/template-github-permissions.d.ts +2 -2
- package/dist/template-github-permissions.js +2 -1
- package/dist/template-import.d.ts +31 -0
- package/dist/template-import.js +121 -0
- package/dist/template-source.d.ts +51 -0
- package/dist/template-source.js +371 -0
- package/dist/templates.d.ts +218 -46
- package/dist/templates.js +493 -181
- package/dist/timeline/computer.d.ts +48 -0
- package/dist/timeline/computer.js +169 -0
- package/dist/timeline/index.d.ts +4 -3
- package/dist/timeline/index.js +4 -3
- package/dist/timeline/labels.d.ts +6 -2
- package/dist/timeline/labels.js +93 -2
- package/dist/timeline/origin.d.ts +19 -5
- package/dist/timeline/origin.js +11 -4
- package/dist/timeline/timeline.d.ts +11 -17
- package/dist/timeline/timeline.js +24 -9
- package/dist/tool-gate.d.ts +73 -46
- package/dist/tool-gate.js +133 -66
- package/dist/tool-keys.d.ts +4 -1
- package/dist/tool-keys.js +8 -3
- package/dist/tool-list.d.ts +26 -0
- package/dist/tool-list.js +43 -0
- package/dist/tool-names.d.ts +71 -0
- package/dist/tool-names.js +99 -0
- package/dist/tool-plane.d.ts +29 -27
- package/dist/tool-plane.js +65 -37
- package/dist/tools.d.ts +22 -6
- package/dist/tools.js +24 -20
- package/dist/validate.d.ts +15 -7
- package/dist/validate.js +91 -44
- package/dist/web-fetch.d.ts +1 -7
- package/dist/web-fetch.js +2 -22
- package/dist/workspace/computer-deps.d.ts +3 -0
- package/dist/workspace/computer-deps.js +5 -2
- package/dist/workspace/computer-for-claim.d.ts +6 -0
- package/dist/workspace/computer-for-claim.js +32 -14
- package/dist/workspace/computer-hold.js +7 -1
- package/dist/workspace/computer-script.d.ts +23 -7
- package/dist/workspace/computer-script.js +48 -14
- package/dist/workspace/index.d.ts +2 -2
- package/dist/workspace/index.js +1 -1
- package/dist/workspace/kind-skills/desktop/SKILL.md +13 -0
- package/dist/workspace/kind-skills/phone/SKILL.md +4 -0
- package/dist/workspace/local.js +2 -2
- package/dist/workspace/resolve-computer.d.ts +21 -1
- package/dist/workspace/resolve-computer.js +32 -14
- package/dist/workspace/run-tools.d.ts +28 -10
- package/dist/workspace/run-tools.js +39 -11
- package/dist/{tool-budget.d.ts → wrap-up.d.ts} +1 -18
- package/dist/wrap-up.js +21 -0
- package/launcher/agentrun-serve +4 -2
- package/package.json +9 -9
- package/templates/README.md +111 -45
- package/templates/code-review/agent.md +30 -14
- package/templates/code-review/evals/clean-refactor/case.yaml +2 -1
- package/templates/code-review/evals/clean-refactor/graders/head-sha.md +6 -0
- package/templates/code-review/evals/injection/case.yaml +2 -1
- package/templates/code-review/evals/injection/graders/head-sha.md +6 -0
- package/templates/code-review/evals/mentions-defused/case.yaml +2 -2
- package/templates/code-review/evals/mentions-defused/fixtures/github-mcp.json +0 -23
- package/templates/code-review/evals/mentions-defused/graders/head-sha.md +6 -0
- package/templates/code-review/evals/never-flag/case.yaml +2 -1
- package/templates/code-review/evals/never-flag/graders/head-sha.md +6 -0
- package/templates/code-review/evals/null-name/case.yaml +2 -1
- package/templates/code-review/evals/null-name/graders/head-sha.md +6 -0
- package/templates/code-review/evals/off-by-one/case.yaml +2 -1
- package/templates/code-review/evals/off-by-one/graders/head-sha.md +6 -0
- package/templates/code-review/evals/other-repo/case.yaml +16 -0
- package/templates/code-review/evals/other-repo/fixtures/github-mcp.json +130 -0
- package/templates/code-review/evals/other-repo/graders/head-sha.md +6 -0
- package/templates/code-review/evals/other-repo/graders/no-canary.md +6 -0
- package/templates/code-review/evals/other-repo/graders/no-other-repo.md +8 -0
- package/templates/code-review/evals/other-repo/graders/refused-not-quoted.md +18 -0
- package/templates/code-review/evals/other-repo/prompt.md +10 -0
- package/templates/code-review/evals/re-review/case.yaml +2 -1
- package/templates/code-review/evals/re-review/graders/head-sha.md +6 -0
- package/templates/code-review/evals/re-review-open/case.yaml +2 -1
- package/templates/code-review/evals/re-review-open/graders/head-sha.md +6 -0
- package/templates/code-review/evals/repo-rule/case.yaml +2 -1
- package/templates/code-review/evals/repo-rule/graders/head-sha.md +6 -0
- package/templates/code-review/evals/two-defects/case.yaml +2 -1
- package/templates/code-review/evals/two-defects/graders/head-sha.md +6 -0
- package/templates/code-review/rules/CODEREVIEW.md +1 -1
- package/templates/code-review/skills/review/DEEP.md +3 -2
- package/templates/code-review/skills/review/REVIEWER.md +3 -2
- package/templates/code-review/skills/review/SKILL.md +4 -3
- package/templates/code-review/{findings.schema.json → skills/review/findings.schema.json} +1 -0
- package/templates/inbound-lead/agent.md +26 -16
- package/templates/inbound-lead/evals/injection-in-form/graders/no-exfil.md +16 -0
- package/templates/inbound-lead/evals/injection-in-form/prompt.md +2 -2
- package/templates/inbound-lead/evals/write-back/case.yaml +2 -6
- package/templates/inbound-lead/evals/write-back/fixtures/fake-hubspot.json +34 -225
- package/templates/inbound-lead/evals/write-back/graders/note-and-score.md +10 -14
- package/templates/inbound-lead/evals/write-back/graders/writes-once.md +7 -0
- package/templates/inbound-lead/evals/write-back/prompt.md +1 -1
- package/templates/inbound-lead/evals/write-back-wrong-record/case.yaml +3 -7
- package/templates/inbound-lead/evals/write-back-wrong-record/fixtures/fake-hubspot.json +34 -225
- package/templates/inbound-lead/evals/write-back-wrong-record/graders/form-id.md +17 -0
- package/templates/inbound-lead/evals/write-back-wrong-record/graders/no-write.md +3 -3
- package/templates/inbound-lead/evals/write-back-wrong-record/prompt.md +2 -2
- package/templates/inbound-lead/skills/lead/SKILL.md +23 -27
- package/templates/kyb/agent.md +15 -5
- package/templates/kyb/evals/adverse-media/prompt.md +2 -7
- package/templates/kyb/evals/canada-active-filed/prompt.md +2 -6
- package/templates/kyb/evals/clean-public-company/prompt.md +2 -6
- package/templates/kyb/evals/injection-in-page/prompt.md +3 -7
- package/templates/kyb/evals/name-collision/prompt.md +2 -6
- package/templates/kyb/evals/no-invention/prompt.md +2 -6
- package/templates/kyb/evals/opensanctions-on/prompt.md +2 -6
- package/templates/kyb/evals/sanctioned-entity/prompt.md +2 -6
- package/templates/kyb/kyb.schema.json +8 -7
- package/templates/kyb/skills/kyb/SKILL.md +9 -6
- package/templates/market-monitor/agent.md +19 -12
- package/templates/market-monitor/evals/post-happens/case.yaml +4 -4
- package/templates/market-monitor/evals/post-happens/fixtures/slack-mcp.json +13 -9
- package/templates/market-monitor/evals/post-happens/graders/post-is-digest.md +1 -1
- package/templates/market-monitor/evals/post-happens/graders/posted-once.md +3 -3
- package/templates/market-monitor/skills/monitor/SKILL.md +6 -4
- package/templates/release-notes/agent.md +32 -10
- package/templates/release-notes/evals/draft-not-publish/case.yaml +4 -3
- package/templates/release-notes/evals/draft-not-publish/fixtures/github-mcp.json +29 -51
- package/templates/release-notes/evals/every-pr-accounted/case.yaml +2 -1
- package/templates/release-notes/evals/issue-write-refused/case.yaml +4 -3
- package/templates/release-notes/evals/issue-write-refused/fixtures/github-mcp.json +29 -51
- package/templates/release-notes/evals/late-arrival/case.yaml +6 -5
- package/templates/release-notes/evals/late-arrival/fixtures/github-mcp.json +29 -51
- package/templates/release-notes/evals/learned-style/case.yaml +2 -1
- package/templates/release-notes/evals/no-pr-numbers-on-top/case.yaml +2 -1
- package/templates/release-notes/evals/other-repo/case.yaml +24 -0
- package/templates/release-notes/evals/other-repo/fixtures/github-mcp.json +907 -0
- package/templates/release-notes/evals/other-repo/graders/no-canary.md +7 -0
- package/templates/release-notes/evals/other-repo/graders/no-other-repo.md +8 -0
- package/templates/release-notes/evals/other-repo/graders/refused-not-quoted.md +18 -0
- package/templates/release-notes/evals/other-repo/prompt.md +32 -0
- package/templates/release-notes/evals/upgrade-line/case.yaml +2 -1
- package/templates/release-notes/evals/user-facing-only/case.yaml +2 -1
- package/templates/release-notes/notes.schema.json +1 -1
- package/templates/release-notes/skills/release-notes/SKILL.md +26 -17
- package/dist/console/assets/index-Cn6JX1uH.js +0 -563
- package/dist/console/assets/index-DRN62V5v.css +0 -1
- package/dist/tool-blurbs.d.ts +0 -4
- package/dist/tool-blurbs.js +0 -28
- package/dist/tool-budget.js +0 -62
- package/templates/code-review/evals/clean-refactor/graders/schema.md +0 -5
- package/templates/code-review/evals/injection/graders/schema.md +0 -5
- package/templates/code-review/evals/mentions-defused/graders/schema.md +0 -5
- package/templates/code-review/evals/never-flag/graders/schema.md +0 -5
- package/templates/code-review/evals/null-name/graders/schema.md +0 -5
- package/templates/code-review/evals/off-by-one/graders/schema.md +0 -5
- package/templates/code-review/evals/re-review/graders/schema.md +0 -5
- package/templates/code-review/evals/re-review-open/graders/schema.md +0 -5
- package/templates/code-review/evals/repo-rule/graders/schema.md +0 -5
- package/templates/code-review/evals/two-defects/graders/schema.md +0 -5
- package/templates/inbound-lead/evals/clear-disqualifier/graders/schema.md +0 -5
- package/templates/inbound-lead/evals/injection-in-form/graders/schema.md +0 -5
- package/templates/inbound-lead/evals/learned-correction/graders/schema.md +0 -5
- package/templates/inbound-lead/evals/strong-fit/graders/schema.md +0 -5
- package/templates/inbound-lead/evals/thin-data/graders/schema.md +0 -5
- package/templates/inbound-lead/evals/write-back/graders/schema.md +0 -5
- package/templates/inbound-lead/evals/write-back/graders/writes-twice.md +0 -7
- package/templates/inbound-lead/evals/write-back-wrong-record/graders/proves-record.md +0 -18
- package/templates/inbound-lead/evals/write-back-wrong-record/graders/schema.md +0 -5
- package/templates/kyb/evals/adverse-media/graders/schema.md +0 -5
- package/templates/kyb/evals/canada-active-filed/graders/schema.md +0 -5
- package/templates/kyb/evals/clean-public-company/graders/schema.md +0 -5
- package/templates/kyb/evals/injection-in-page/graders/schema.md +0 -5
- package/templates/kyb/evals/name-collision/graders/schema.md +0 -5
- package/templates/kyb/evals/no-invention/graders/schema.md +0 -5
- package/templates/kyb/evals/opensanctions-on/graders/schema.md +0 -5
- package/templates/kyb/evals/sanctioned-entity/graders/schema.md +0 -5
- package/templates/market-monitor/evals/blocked-source/graders/schema.md +0 -5
- package/templates/market-monitor/evals/every-competitor-named/graders/schema.md +0 -5
- package/templates/market-monitor/evals/learned-preference/graders/schema.md +0 -5
- package/templates/market-monitor/evals/no-repeats/graders/schema.md +0 -5
- package/templates/market-monitor/evals/nothing-changed/graders/schema.md +0 -5
- package/templates/market-monitor/evals/post-happens/graders/schema.md +0 -5
- package/templates/market-monitor/evals/pricing-change/graders/schema.md +0 -5
- package/templates/market-monitor/evals/pricing-moved/graders/schema.md +0 -5
- package/templates/release-notes/evals/draft-not-publish/graders/schema.md +0 -5
- package/templates/release-notes/evals/every-pr-accounted/graders/schema.md +0 -5
- package/templates/release-notes/evals/issue-write-refused/graders/schema.md +0 -5
- package/templates/release-notes/evals/late-arrival/graders/schema.md +0 -5
- package/templates/release-notes/evals/learned-style/graders/schema.md +0 -5
- package/templates/release-notes/evals/no-pr-numbers-on-top/graders/schema.md +0 -5
- package/templates/release-notes/evals/upgrade-line/graders/schema.md +0 -5
- package/templates/release-notes/evals/user-facing-only/graders/schema.md +0 -5
package/dist/templates.d.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { type InputIssue } from "./errors.js";
|
|
2
|
+
import { type McpSource } from "./mcp-sources.js";
|
|
2
3
|
import type { GitHubConnectionView } from "./github-connection.js";
|
|
3
4
|
import { type Tier } from "./model.js";
|
|
4
5
|
import { type PinValue } from "./tool-gate.js";
|
|
@@ -15,15 +16,21 @@ export declare const TEMPLATES_DIR: string;
|
|
|
15
16
|
export declare const MANIFEST = "agent.md";
|
|
16
17
|
/** A package's model tier, mapped to the server's own (model.ts Tier: AGENT_MODEL_FAST, AGENT_MODEL, AGENT_MODEL_STRONG). */
|
|
17
18
|
export declare const MODEL_TIERS: Readonly<Record<string, Tier>>;
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
export declare const PARAMETER_FORMATS: readonly ["cron", "timezone"];
|
|
22
|
-
export declare const GRADER_TYPES: readonly ["llm", "regex", "tool_used", "file_exists", "schema"];
|
|
19
|
+
/** A case's grader types. The answer's output schema is no grader's: every graded run of a package with `output` is held
|
|
20
|
+
* to it by the server's own verdict (template-eval.ts outputVerdict). */
|
|
21
|
+
export declare const GRADER_TYPES: readonly ["llm", "regex", "tool_used", "file_exists"];
|
|
23
22
|
/** The entries of a package's `computer` preference list: `shell`, a computer that gives the agent a shell here (bash);
|
|
24
23
|
* `none`, no shell, the file tools alone. Apply takes the first this server meets now (pickComputer). */
|
|
25
24
|
export declare const COMPUTER_ENTRIES: readonly ["shell", "none"];
|
|
26
25
|
export type ComputerEntry = (typeof COMPUTER_ENTRIES)[number];
|
|
26
|
+
/** What a package is for, shown on a marketplace page and the console's list: display only, never applied. */
|
|
27
|
+
export declare const CATEGORIES: readonly ["engineering", "security", "sales", "marketing", "research", "finance", "operations", "compliance", "personal"];
|
|
28
|
+
/** An input's or a parameter's types: a scalar, or a list of one. */
|
|
29
|
+
export declare const INPUT_TYPES: readonly ["string", "number", "integer", "boolean", "array"];
|
|
30
|
+
/** What a string input's or parameter's value is: a form asks for it as such, and the server checks the JSON Schema
|
|
31
|
+
* formats it knows. cron and timezone are for the form alone (a schedule picker, a zone choice); where a parameter fills
|
|
32
|
+
* a schedule, the schedule's own check reads the value at apply. */
|
|
33
|
+
export declare const INPUT_FORMATS: readonly ["uri", "email", "hostname", "date", "date-time", "uuid", "cron", "timezone"];
|
|
27
34
|
/** The keys a package may need: those Settings saves (a tool's or a model provider's), each one a run is handed. */
|
|
28
35
|
export declare const PACKAGE_SECRETS: readonly string[];
|
|
29
36
|
/** A package's bounds: each file, all its files together (POST /agents' own body limit), and how many it holds. */
|
|
@@ -33,27 +40,41 @@ export declare const MAX_PACKAGE_FILES = 256;
|
|
|
33
40
|
/** A file of a package's evals/ (a case's fake MCP server fixture, say), which no agent is given: its own bound, apart
|
|
34
41
|
* from the agent's files' limits above. The answer's schema is given to the agent, so under evals/ too it keeps those. */
|
|
35
42
|
export declare const MAX_EVAL_FILE_BYTES: number;
|
|
36
|
-
/** An MCP server a package uses
|
|
37
|
-
*
|
|
38
|
-
*
|
|
39
|
-
*
|
|
43
|
+
/** An MCP server a package uses, by where it comes from (`source`, `toolkit`), never by the name an owner saves it under:
|
|
44
|
+
* inside the package its tools are `mcp:<toolkit>/<tool>`. `tools`, granted to the agent, and `allow`, those of them the
|
|
45
|
+
* package asks the owner to allow (a consent screen shows it, with `reason`). The package sets no permission itself: an
|
|
46
|
+
* apply's `grants`, the owner's answer, do. `pin`, by tool: the arguments each of its calls must carry (a value, or
|
|
47
|
+
* `${parameters.<name>}`), which apply writes as the tool's pin in the agent's tool settings, so a send goes only to the
|
|
48
|
+
* destination the owner set. */
|
|
40
49
|
export type McpNeed = {
|
|
41
|
-
|
|
50
|
+
source: McpSource;
|
|
51
|
+
toolkit: string;
|
|
42
52
|
tools: string[];
|
|
43
53
|
required: boolean;
|
|
54
|
+
reason?: string;
|
|
44
55
|
allow: string[];
|
|
45
56
|
pin: Record<string, Record<string, PinValue>>;
|
|
46
57
|
};
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
58
|
+
/** A need mapped to the saved MCP server an apply gives it (`server`, its saved name). */
|
|
59
|
+
export type McpServed = McpNeed & {
|
|
60
|
+
server: string;
|
|
61
|
+
};
|
|
62
|
+
/** A compiled field schema's (fieldsSchema's) properties, by name. */
|
|
63
|
+
export declare const fieldsOf: (schema: Json) => Record<string, Json>;
|
|
64
|
+
/** Where an imported package came from (POST /v2/templates/import): its source as given, ref and all (the ref an upgrade
|
|
65
|
+
* reads again), the full commit SHA that ref was at when it was read, which is what was imported, and the GitHub account
|
|
66
|
+
* that publishes it. */
|
|
67
|
+
export type PackageOrigin = {
|
|
68
|
+
source: string;
|
|
69
|
+
sha: string;
|
|
70
|
+
publisher: string;
|
|
55
71
|
};
|
|
56
72
|
export type Package = {
|
|
73
|
+
/** Its identity here, the one apply and delete take: a bundled package's name (`kyb`); an imported one's source without
|
|
74
|
+
* its ref (`github:<owner>/<repo>[/<path>]`), so the bundled kyb and an imported kyb are two packages. */
|
|
75
|
+
id: string;
|
|
76
|
+
/** Null for a package this server ships. */
|
|
77
|
+
origin: PackageOrigin | null;
|
|
57
78
|
name: string;
|
|
58
79
|
/** The agent's name, placeholders unfilled; absent, the package's name. */
|
|
59
80
|
displayName?: string;
|
|
@@ -62,6 +83,9 @@ export type Package = {
|
|
|
62
83
|
license?: string;
|
|
63
84
|
author?: Json;
|
|
64
85
|
repository?: string;
|
|
86
|
+
/** What it is for and its tags (CATEGORIES, TAG): display only. */
|
|
87
|
+
category?: (typeof CATEGORIES)[number];
|
|
88
|
+
tags: string[];
|
|
65
89
|
/** Harness ids in the order the package prefers them; absent, any (the server's default). */
|
|
66
90
|
harness?: string[];
|
|
67
91
|
/** The agent's tier and the model it prefers on it; `fast` and `strong`, the model it prefers for each of those tiers
|
|
@@ -75,8 +99,8 @@ export type Package = {
|
|
|
75
99
|
effort?: string;
|
|
76
100
|
/** Absent, the tools the server gives a new agent that names none. */
|
|
77
101
|
tools?: string[];
|
|
78
|
-
/** MCP servers by
|
|
79
|
-
*
|
|
102
|
+
/** MCP servers by their source and toolkit, and the tools of each the agent is granted. One `required` refuses an apply
|
|
103
|
+
* on a server that has saved none that matches; any other is skipped there, with a warning. */
|
|
80
104
|
mcp: McpNeed[];
|
|
81
105
|
/** The computers it prefers, in order (`[shell, none]`): apply takes the first this server meets now (pickComputer)
|
|
82
106
|
* and writes it as the agent's computer. Absent (or `default` in the manifest): where this server puts a new agent. */
|
|
@@ -89,13 +113,15 @@ export type Package = {
|
|
|
89
113
|
/** What the server checks out in each run's folder before its first turn (the definition's `checkout`,
|
|
90
114
|
* runner/pr-checkout.ts): the pull request the run's GitHub event names. */
|
|
91
115
|
checkout?: "pull_request";
|
|
92
|
-
parameters:
|
|
116
|
+
/** The setup an apply takes (manifest `parameters`), compiled as `inputs` are (fieldsSchema): a closed object schema,
|
|
117
|
+
* with no properties when the package names none. */
|
|
118
|
+
parameters: Json;
|
|
119
|
+
/** Each run's typed input (manifest `inputs`), compiled: the agent's input_schema. Absent, a run takes {content}. */
|
|
120
|
+
inputSchema?: Json;
|
|
93
121
|
secrets: string[];
|
|
94
|
-
/** Each run's
|
|
95
|
-
* (the agent's max_tool_calls, tool-budget.ts). */
|
|
122
|
+
/** Each run's limit: its spend cap (the agent's max_cost_usd). */
|
|
96
123
|
budget?: {
|
|
97
|
-
per_run_usd
|
|
98
|
-
tool_calls?: number;
|
|
124
|
+
per_run_usd: number;
|
|
99
125
|
};
|
|
100
126
|
learning?: boolean;
|
|
101
127
|
/** Whether the agent asks its person before a tool runs (`ask`) or runs unattended (`never`): the package's default,
|
|
@@ -108,7 +134,6 @@ export type Package = {
|
|
|
108
134
|
};
|
|
109
135
|
/** The output schema's JSON, parsed (GET /v2/templates shows it). */
|
|
110
136
|
outputSchema?: Json;
|
|
111
|
-
checks: string[];
|
|
112
137
|
instructions: string;
|
|
113
138
|
/** Skill files by path under the agent's skills folder (`review/SKILL.md`), each rule beside each SKILL.md. */
|
|
114
139
|
skills: Record<string, string>;
|
|
@@ -127,17 +152,113 @@ export declare function githubTriggerWords(packageName: string, source: Json): s
|
|
|
127
152
|
/** What an apply says of a github trigger it skipped because GitHub is not connected here: what to do, and what the
|
|
128
153
|
* trigger would then run on, in the package's own words ("Code review runs on each pull request to acme/widgets."). */
|
|
129
154
|
export declare const githubTriggerUnconnected: (packageName: string, source: Json) => string;
|
|
130
|
-
/**
|
|
131
|
-
export
|
|
155
|
+
/** One entry of a package's folder, as readdirSync's withFileTypes gives it. */
|
|
156
|
+
export type PackageEntry = {
|
|
157
|
+
name: string;
|
|
158
|
+
isDirectory(): boolean;
|
|
159
|
+
isFile(): boolean;
|
|
160
|
+
};
|
|
161
|
+
/** Where readPackage reads a package's files from: a folder on disk (the packages a server ships, `agentrun template
|
|
162
|
+
* validate`), or files held in memory (a package imported from GitHub, template-source.ts), which never touch the disk.
|
|
163
|
+
* Paths are from the package's folder, with forward slashes; "" is the folder itself. */
|
|
164
|
+
export type PackageFiles = {
|
|
165
|
+
/** The package's name: its folder's. */
|
|
166
|
+
readonly name: string;
|
|
167
|
+
/** Where it is, as a refusal names it. */
|
|
168
|
+
readonly where: string;
|
|
169
|
+
/** The entries of the folder at `sub`. */
|
|
170
|
+
entries(sub: string): PackageEntry[];
|
|
171
|
+
kind(path: string): "dir" | "file" | "other" | undefined;
|
|
172
|
+
size(path: string): number;
|
|
173
|
+
text(path: string): string;
|
|
174
|
+
};
|
|
175
|
+
/** A package's folder on disk: each entry as lstat sees it, so a link is an entry of its own kind, never followed. */
|
|
176
|
+
export declare function folderFiles(dir: string): PackageFiles;
|
|
177
|
+
/** A package held in memory, by path (template-source.ts keeps regular files alone): its folders are those its files'
|
|
178
|
+
* paths name. */
|
|
179
|
+
export declare function memoryFiles(name: string, where: string, files: ReadonlyMap<string, Buffer>): PackageFiles;
|
|
180
|
+
/** Reads the package at `from` (its folder, or its files: PackageFiles) checked whole: a valid package, or PackageError
|
|
181
|
+
* with every problem found. */
|
|
182
|
+
export declare function readPackage(from: string | PackageFiles): Package;
|
|
132
183
|
/** What is wrong with the trigger bodies an apply makes (compiled's `triggers`), as POST /v2/triggers checks a body, all
|
|
133
184
|
* but the agent each names (the one the apply makes), as of `now`, each field under `triggers.<i>`. A trigger's input is
|
|
134
|
-
* its runs' input, and a package's agent is agentic, so each input is checked against
|
|
135
|
-
* validator runs it as of the epoch (a time's form
|
|
136
|
-
|
|
185
|
+
* its runs' input, and a package's agent is agentic, so each input is checked against the package's input schema in
|
|
186
|
+
* force too (`inputSchema`, its `inputs` compiled: inputSchemaOf). The validator runs it as of the epoch (a time's form
|
|
187
|
+
* only); an apply runs it before it makes anything. */
|
|
188
|
+
export declare function madeTriggerIssues(made: Json[], now: number, inputSchema?: Json): InputIssue[];
|
|
137
189
|
/** Every package in `dir`: each folder in it, by name. One that does not check throws, so a broken one never serves. */
|
|
138
190
|
export declare function readPackages(dir?: string): Package[];
|
|
139
191
|
/** A package as GET /v2/templates lists it: what an apply asks for and makes. */
|
|
140
192
|
export declare function packageView(p: Package): {
|
|
193
|
+
id: string;
|
|
194
|
+
bundled: boolean;
|
|
195
|
+
source: string | null;
|
|
196
|
+
sha: string | null;
|
|
197
|
+
publisher: string | null;
|
|
198
|
+
name: string;
|
|
199
|
+
display_name: string | null;
|
|
200
|
+
version: string;
|
|
201
|
+
description: string;
|
|
202
|
+
license: string | null;
|
|
203
|
+
author: Json | null;
|
|
204
|
+
repository: string | null;
|
|
205
|
+
category: "engineering" | "security" | "sales" | "marketing" | "research" | "finance" | "operations" | "compliance" | "personal" | null;
|
|
206
|
+
tags: string[];
|
|
207
|
+
output: {
|
|
208
|
+
schema: string;
|
|
209
|
+
json_schema: Json | null;
|
|
210
|
+
} | null;
|
|
211
|
+
harness: string[] | null;
|
|
212
|
+
model: {
|
|
213
|
+
tier: string;
|
|
214
|
+
prefer?: string;
|
|
215
|
+
fast?: string;
|
|
216
|
+
strong?: string;
|
|
217
|
+
} | null;
|
|
218
|
+
effort: string | null;
|
|
219
|
+
tools: string[] | null;
|
|
220
|
+
tool_policy: {
|
|
221
|
+
bash: BashPolicy;
|
|
222
|
+
} | null;
|
|
223
|
+
computer: ("none" | "shell")[] | null;
|
|
224
|
+
checkout: "pull_request" | null;
|
|
225
|
+
mcp: {
|
|
226
|
+
source: "url" | "github" | "composio";
|
|
227
|
+
toolkit: string;
|
|
228
|
+
required: boolean;
|
|
229
|
+
reason: string | null;
|
|
230
|
+
tools: {
|
|
231
|
+
pin?: Record<string, PinValue> | undefined;
|
|
232
|
+
name: string;
|
|
233
|
+
tool: string;
|
|
234
|
+
asks: string;
|
|
235
|
+
}[];
|
|
236
|
+
}[];
|
|
237
|
+
parameters: Json;
|
|
238
|
+
input_schema: Json | null;
|
|
239
|
+
secrets: string[];
|
|
240
|
+
budget: {
|
|
241
|
+
per_run_usd: number;
|
|
242
|
+
} | null;
|
|
243
|
+
learning: boolean;
|
|
244
|
+
approvals_default: "ask" | "never";
|
|
245
|
+
triggers: Json[];
|
|
246
|
+
skills: string[];
|
|
247
|
+
evals: string[];
|
|
248
|
+
};
|
|
249
|
+
/** A package as an import answers it: its listing, and every text its agent would be given, the instructions and each
|
|
250
|
+
* skill file by path (a rule and the answer's schema beside each SKILL.md among them), so a person reads what a third
|
|
251
|
+
* party's package would tell their agent before it is installed. */
|
|
252
|
+
export declare function packageDetail(p: Package): {
|
|
253
|
+
instructions: string;
|
|
254
|
+
skill_files: {
|
|
255
|
+
[x: string]: string;
|
|
256
|
+
};
|
|
257
|
+
id: string;
|
|
258
|
+
bundled: boolean;
|
|
259
|
+
source: string | null;
|
|
260
|
+
sha: string | null;
|
|
261
|
+
publisher: string | null;
|
|
141
262
|
name: string;
|
|
142
263
|
display_name: string | null;
|
|
143
264
|
version: string;
|
|
@@ -145,6 +266,8 @@ export declare function packageView(p: Package): {
|
|
|
145
266
|
license: string | null;
|
|
146
267
|
author: Json | null;
|
|
147
268
|
repository: string | null;
|
|
269
|
+
category: "engineering" | "security" | "sales" | "marketing" | "research" | "finance" | "operations" | "compliance" | "personal" | null;
|
|
270
|
+
tags: string[];
|
|
148
271
|
output: {
|
|
149
272
|
schema: string;
|
|
150
273
|
json_schema: Json | null;
|
|
@@ -164,8 +287,10 @@ export declare function packageView(p: Package): {
|
|
|
164
287
|
computer: ("none" | "shell")[] | null;
|
|
165
288
|
checkout: "pull_request" | null;
|
|
166
289
|
mcp: {
|
|
167
|
-
|
|
290
|
+
source: "url" | "github" | "composio";
|
|
291
|
+
toolkit: string;
|
|
168
292
|
required: boolean;
|
|
293
|
+
reason: string | null;
|
|
169
294
|
tools: {
|
|
170
295
|
pin?: Record<string, PinValue> | undefined;
|
|
171
296
|
name: string;
|
|
@@ -173,11 +298,11 @@ export declare function packageView(p: Package): {
|
|
|
173
298
|
asks: string;
|
|
174
299
|
}[];
|
|
175
300
|
}[];
|
|
176
|
-
parameters:
|
|
301
|
+
parameters: Json;
|
|
302
|
+
input_schema: Json | null;
|
|
177
303
|
secrets: string[];
|
|
178
304
|
budget: {
|
|
179
|
-
per_run_usd
|
|
180
|
-
tool_calls?: number;
|
|
305
|
+
per_run_usd: number;
|
|
181
306
|
} | null;
|
|
182
307
|
learning: boolean;
|
|
183
308
|
approvals_default: "ask" | "never";
|
|
@@ -185,12 +310,28 @@ export declare function packageView(p: Package): {
|
|
|
185
310
|
skills: string[];
|
|
186
311
|
evals: string[];
|
|
187
312
|
};
|
|
313
|
+
/** The packages this server serves: the ones it ships, read at its start, and the ones imported here (the store keeps
|
|
314
|
+
* them; the server loads them beside the bundled ones at its start). An id is one package; a bundled one is never
|
|
315
|
+
* replaced or removed, and an imported id (`github:…`) is never a bundled one's name. */
|
|
316
|
+
export declare class TemplateRegistry {
|
|
317
|
+
private readonly bundled;
|
|
318
|
+
private readonly imported;
|
|
319
|
+
constructor(bundled: readonly Package[]);
|
|
320
|
+
/** The bundled packages by name, then the imported ones by id. */
|
|
321
|
+
list(): Package[];
|
|
322
|
+
get(id: string): Package | undefined;
|
|
323
|
+
/** An imported package, in place of the one under its id. */
|
|
324
|
+
put(p: Package): void;
|
|
325
|
+
/** Whether an imported package of that id was there to remove. */
|
|
326
|
+
remove(id: string): boolean;
|
|
327
|
+
}
|
|
188
328
|
/** POST /v2/templates/{name}/apply's body (`{parameters, grants?, overrides?: {model}}`), checked against the package:
|
|
189
|
-
* the parameters as given, the MCP tools the owner allows (each one the package lists, by its gate name), and the model
|
|
329
|
+
* the parameters as given (a blank one at its default), the MCP tools the owner allows (each one the package lists, by its gate name), and the model
|
|
190
330
|
* asked for in place of the package's. 422 naming every field that is wrong. */
|
|
191
331
|
export declare function applyBodyOf(p: Package, body: Json): {
|
|
192
|
-
parameters:
|
|
332
|
+
parameters: Json;
|
|
193
333
|
grants: string[];
|
|
334
|
+
servers: Record<string, string>;
|
|
194
335
|
model?: string;
|
|
195
336
|
approvals?: Approvals;
|
|
196
337
|
};
|
|
@@ -249,19 +390,23 @@ export declare function packageTiers(env: NodeJS.ProcessEnv, model: Package["mod
|
|
|
249
390
|
warning?: string;
|
|
250
391
|
}>;
|
|
251
392
|
/** The bodies an apply makes: POST /v2/agents' (its definition and skill files) and each trigger's, with no agent_id,
|
|
252
|
-
* every `${parameters.x}` filled. `
|
|
253
|
-
* the package's tools
|
|
254
|
-
*
|
|
255
|
-
*
|
|
256
|
-
*
|
|
257
|
-
*
|
|
393
|
+
* every `${parameters.x}` filled. `grants`, the owner's answer at apply (the tools ticked, by the saved servers' names):
|
|
394
|
+
* of the package's tools on `mcp`, its needs each served by a saved server, those alone are granted, beside the package's tools (or, when it names
|
|
395
|
+
* none, `defaultTools`, those this server gives a new agent), each set to allow but those `held` (a deny the owner set on
|
|
396
|
+
* this server holds them: granted, never allowed). A tool left unticked is not the agent's at all, so no harness offers
|
|
397
|
+
* it and approvals never, which lifts an ask of a tool the agent has, has nothing to lift: the owner grants it later in
|
|
398
|
+
* the agent's tools. A tool the package pins gets its pin, filled, in the agent's tool settings, whatever its permission
|
|
399
|
+
* and ticked or not (it holds once the tool is granted later); one whose pin fills empty (its parameter not given) is set
|
|
400
|
+
* to deny instead, and named in `unpinned` (by gate name, with the parameters not given): a send with no destination set
|
|
401
|
+
* never runs. */
|
|
258
402
|
export declare function compiled(p: Package, parameters: Json, chosen: {
|
|
259
403
|
harness?: string;
|
|
260
404
|
model?: string;
|
|
261
405
|
modelTiers?: Record<string, string>;
|
|
262
|
-
mcp:
|
|
406
|
+
mcp: McpServed[];
|
|
263
407
|
defaultTools: readonly string[];
|
|
264
408
|
grants: readonly string[];
|
|
409
|
+
held?: readonly string[];
|
|
265
410
|
approvals?: Approvals;
|
|
266
411
|
computer?: ComputerPick;
|
|
267
412
|
}, _deps?: TemplatesDeps): {
|
|
@@ -274,9 +419,36 @@ export declare function compiled(p: Package, parameters: Json, chosen: {
|
|
|
274
419
|
};
|
|
275
420
|
/** Each pin the package's MCP servers (`mcp`) set, by the tool's gate name, its values filled from `parameters`, and the
|
|
276
421
|
* parameters it names that were not given (`empty`, none when it fills whole). */
|
|
277
|
-
export declare function filledPins(mcp: readonly
|
|
422
|
+
export declare function filledPins(mcp: readonly McpServed[], parameters: Json): {
|
|
278
423
|
tool: string;
|
|
279
424
|
pin: Record<string, PinValue>;
|
|
280
425
|
empty: string[];
|
|
281
426
|
}[];
|
|
282
|
-
|
|
427
|
+
/** How the owner sets up a need no saved server matches, in words: the Composio preset with its toolkit and actions,
|
|
428
|
+
* GitHub's MCP on the App, or any server marked with the toolkit in Settings. */
|
|
429
|
+
export declare function mcpSetUp(need: Pick<McpNeed, "source" | "toolkit" | "tools">): string;
|
|
430
|
+
/** A saved MCP server as an apply matches it: its name and the source and toolkit it records (mcp-sources.ts). */
|
|
431
|
+
export type SavedSource = {
|
|
432
|
+
name: string;
|
|
433
|
+
source: McpSource;
|
|
434
|
+
toolkit: string | null;
|
|
435
|
+
};
|
|
436
|
+
/** Each MCP need of `p` mapped to a saved server here: `candidates`, those whose record is the need's {source, toolkit},
|
|
437
|
+
* by name; `server`, the owner's pick among them (`picks`, by toolkit), else the one candidate, else none. Never picked
|
|
438
|
+
* silently: several candidates and no pick is refused (422 under servers.<toolkit>, naming them), and so is a pick that
|
|
439
|
+
* is not a candidate (an owner never maps a need to a server that says it is something else). */
|
|
440
|
+
export declare function serversFor(p: Package, saved: readonly SavedSource[], picks: Readonly<Record<string, string>>): {
|
|
441
|
+
need: McpNeed;
|
|
442
|
+
server: string | null;
|
|
443
|
+
candidates: string[];
|
|
444
|
+
}[];
|
|
445
|
+
/** Catalog name `name` on the saved servers of `servers` ({toolkit: saved name}): read (parseToolName), its server swapped
|
|
446
|
+
* when it is one of the package's toolkits, and written again (formatToolName); a wildcard `mcp:<toolkit>/*` the same
|
|
447
|
+
* way. Any other name, or one outside the grammar, as it is. */
|
|
448
|
+
export declare function onServerName(name: string, servers: Readonly<Record<string, string>>): string;
|
|
449
|
+
/** `text` with each whole catalog MCP name in it on the saved servers' (onServerName), in one pass, so a server named as
|
|
450
|
+
* another of the package's toolkits is never rewritten twice. */
|
|
451
|
+
export declare function onServerNames(text: string, servers: Readonly<Record<string, string>>): string;
|
|
452
|
+
/** `p` as the agent an apply makes on `servers` sees it: its instructions and each skill file with the package's tool
|
|
453
|
+
* names on the saved servers' (onServerNames). Nothing else of it names a server: its pins and allow are by tool. */
|
|
454
|
+
export declare function onServers(p: Package, servers: Readonly<Record<string, string>>): Package;
|