@providerkit/agents 0.1.0 → 0.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE-APACHE-2.0 +202 -0
- package/README.md +2108 -52
- package/THIRD_PARTY_NOTICES.md +521 -0
- package/dist/a2a/auth.d.ts +10 -0
- package/dist/a2a/auth.d.ts.map +1 -0
- package/dist/a2a/auth.js +52 -0
- package/dist/a2a/auth.js.map +1 -0
- package/dist/a2a/client.d.ts +74 -0
- package/dist/a2a/client.d.ts.map +1 -0
- package/dist/a2a/client.js +601 -0
- package/dist/a2a/client.js.map +1 -0
- package/dist/a2a/index.d.ts +22 -0
- package/dist/a2a/index.d.ts.map +1 -0
- package/dist/a2a/index.js +11 -0
- package/dist/a2a/index.js.map +1 -0
- package/dist/a2a/memory-runs.d.ts +62 -0
- package/dist/a2a/memory-runs.d.ts.map +1 -0
- package/dist/a2a/memory-runs.js +349 -0
- package/dist/a2a/memory-runs.js.map +1 -0
- package/dist/a2a/policy.d.ts +15 -0
- package/dist/a2a/policy.d.ts.map +1 -0
- package/dist/a2a/policy.js +114 -0
- package/dist/a2a/policy.js.map +1 -0
- package/dist/a2a/push.d.ts +34 -0
- package/dist/a2a/push.d.ts.map +1 -0
- package/dist/a2a/push.js +180 -0
- package/dist/a2a/push.js.map +1 -0
- package/dist/a2a/remote.d.ts +155 -0
- package/dist/a2a/remote.d.ts.map +1 -0
- package/dist/a2a/remote.js +1196 -0
- package/dist/a2a/remote.js.map +1 -0
- package/dist/a2a/server.d.ts +110 -0
- package/dist/a2a/server.d.ts.map +1 -0
- package/dist/a2a/server.js +1139 -0
- package/dist/a2a/server.js.map +1 -0
- package/dist/a2a/signing.d.ts +21 -0
- package/dist/a2a/signing.d.ts.map +1 -0
- package/dist/a2a/signing.js +305 -0
- package/dist/a2a/signing.js.map +1 -0
- package/dist/a2a/tasks.d.ts +88 -0
- package/dist/a2a/tasks.d.ts.map +1 -0
- package/dist/a2a/tasks.js +170 -0
- package/dist/a2a/tasks.js.map +1 -0
- package/dist/a2a/wire.d.ts +267 -0
- package/dist/a2a/wire.d.ts.map +1 -0
- package/dist/a2a/wire.js +1202 -0
- package/dist/a2a/wire.js.map +1 -0
- package/dist/background-types.d.ts +76 -0
- package/dist/background-types.d.ts.map +1 -0
- package/dist/background-types.js +2 -0
- package/dist/background-types.js.map +1 -0
- package/dist/child.d.ts +25 -0
- package/dist/child.d.ts.map +1 -0
- package/dist/child.js +129 -0
- package/dist/child.js.map +1 -0
- package/dist/code-driver.d.ts +40 -0
- package/dist/code-driver.d.ts.map +1 -0
- package/dist/code-driver.js +2 -0
- package/dist/code-driver.js.map +1 -0
- package/dist/code-mode.d.ts +3 -0
- package/dist/code-mode.d.ts.map +1 -0
- package/dist/code-mode.js +2 -0
- package/dist/code-mode.js.map +1 -0
- package/dist/code-script.d.ts +3 -0
- package/dist/code-script.d.ts.map +1 -0
- package/dist/code-script.js +149 -0
- package/dist/code-script.js.map +1 -0
- package/dist/code.d.ts +75 -0
- package/dist/code.d.ts.map +1 -0
- package/dist/code.js +326 -0
- package/dist/code.js.map +1 -0
- package/dist/compaction.d.ts +15 -0
- package/dist/compaction.d.ts.map +1 -0
- package/dist/compaction.js +168 -0
- package/dist/compaction.js.map +1 -0
- package/dist/delegation.d.ts +85 -16
- package/dist/delegation.d.ts.map +1 -1
- package/dist/delegation.js +240 -106
- package/dist/delegation.js.map +1 -1
- package/dist/evals/driver.d.ts +10 -0
- package/dist/evals/driver.d.ts.map +1 -0
- package/dist/evals/driver.js +192 -0
- package/dist/evals/driver.js.map +1 -0
- package/dist/evals/journal.d.ts +26 -0
- package/dist/evals/journal.d.ts.map +1 -0
- package/dist/evals/journal.js +483 -0
- package/dist/evals/journal.js.map +1 -0
- package/dist/evals/judge.d.ts +31 -0
- package/dist/evals/judge.d.ts.map +1 -0
- package/dist/evals/judge.js +142 -0
- package/dist/evals/judge.js.map +1 -0
- package/dist/evals/report.d.ts +38 -0
- package/dist/evals/report.d.ts.map +1 -0
- package/dist/evals/report.js +241 -0
- package/dist/evals/report.js.map +1 -0
- package/dist/evals/runner.d.ts +24 -0
- package/dist/evals/runner.d.ts.map +1 -0
- package/dist/evals/runner.js +655 -0
- package/dist/evals/runner.js.map +1 -0
- package/dist/evals/scorers.d.ts +36 -0
- package/dist/evals/scorers.d.ts.map +1 -0
- package/dist/evals/scorers.js +259 -0
- package/dist/evals/scorers.js.map +1 -0
- package/dist/evals/simulation.d.ts +7 -0
- package/dist/evals/simulation.d.ts.map +1 -0
- package/dist/evals/simulation.js +38 -0
- package/dist/evals/simulation.js.map +1 -0
- package/dist/evals/testing.d.ts +36 -0
- package/dist/evals/testing.d.ts.map +1 -0
- package/dist/evals/testing.js +87 -0
- package/dist/evals/testing.js.map +1 -0
- package/dist/evals/trajectory.d.ts +11 -0
- package/dist/evals/trajectory.d.ts.map +1 -0
- package/dist/evals/trajectory.js +180 -0
- package/dist/evals/trajectory.js.map +1 -0
- package/dist/evals/types.d.ts +431 -0
- package/dist/evals/types.d.ts.map +1 -0
- package/dist/evals/types.js +4 -0
- package/dist/evals/types.js.map +1 -0
- package/dist/evals.d.ts +14 -0
- package/dist/evals.d.ts.map +1 -0
- package/dist/evals.js +9 -0
- package/dist/evals.js.map +1 -0
- package/dist/extensions.d.ts +33 -0
- package/dist/extensions.d.ts.map +1 -0
- package/dist/extensions.js +188 -0
- package/dist/extensions.js.map +1 -0
- package/dist/handoff.d.ts +58 -0
- package/dist/handoff.d.ts.map +1 -0
- package/dist/handoff.js +160 -0
- package/dist/handoff.js.map +1 -0
- package/dist/index.d.ts +14 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +8 -0
- package/dist/index.js.map +1 -1
- package/dist/input.d.ts +42 -0
- package/dist/input.d.ts.map +1 -0
- package/dist/input.js +266 -0
- package/dist/input.js.map +1 -0
- package/dist/mcp.d.ts +77 -0
- package/dist/mcp.d.ts.map +1 -0
- package/dist/mcp.js +505 -0
- package/dist/mcp.js.map +1 -0
- package/dist/memory-store.d.ts +11 -0
- package/dist/memory-store.d.ts.map +1 -0
- package/dist/memory-store.js +272 -0
- package/dist/memory-store.js.map +1 -0
- package/dist/memory.d.ts +212 -0
- package/dist/memory.d.ts.map +1 -0
- package/dist/memory.js +613 -0
- package/dist/memory.js.map +1 -0
- package/dist/otel.d.ts +74 -0
- package/dist/otel.d.ts.map +1 -0
- package/dist/otel.js +427 -0
- package/dist/otel.js.map +1 -0
- package/dist/progress.d.ts +17 -0
- package/dist/progress.d.ts.map +1 -0
- package/dist/progress.js +193 -0
- package/dist/progress.js.map +1 -0
- package/dist/quickjs.d.ts +19 -0
- package/dist/quickjs.d.ts.map +1 -0
- package/dist/quickjs.js +519 -0
- package/dist/quickjs.js.map +1 -0
- package/dist/recovery.d.ts +10 -0
- package/dist/recovery.d.ts.map +1 -0
- package/dist/recovery.js +62 -0
- package/dist/recovery.js.map +1 -0
- package/dist/request.d.ts +88 -0
- package/dist/request.d.ts.map +1 -0
- package/dist/request.js +422 -0
- package/dist/request.js.map +1 -0
- package/dist/run.d.ts +16 -4
- package/dist/run.d.ts.map +1 -1
- package/dist/run.js +2016 -245
- package/dist/run.js.map +1 -1
- package/dist/runs.d.ts +77 -34
- package/dist/runs.d.ts.map +1 -1
- package/dist/runs.js +267 -85
- package/dist/runs.js.map +1 -1
- package/dist/schema-to-ts.d.ts +4 -0
- package/dist/schema-to-ts.d.ts.map +1 -0
- package/dist/schema-to-ts.js +191 -0
- package/dist/schema-to-ts.js.map +1 -0
- package/dist/session.d.ts +23 -0
- package/dist/session.d.ts.map +1 -0
- package/dist/session.js +137 -0
- package/dist/session.js.map +1 -0
- package/dist/snapshot.d.ts +57 -8
- package/dist/snapshot.d.ts.map +1 -1
- package/dist/snapshot.js +1206 -109
- package/dist/snapshot.js.map +1 -1
- package/dist/steering.d.ts +75 -0
- package/dist/steering.d.ts.map +1 -0
- package/dist/steering.js +214 -0
- package/dist/steering.js.map +1 -0
- package/dist/subagents.d.ts +141 -0
- package/dist/subagents.d.ts.map +1 -0
- package/dist/subagents.js +746 -0
- package/dist/subagents.js.map +1 -0
- package/dist/tool-retry.d.ts +12 -0
- package/dist/tool-retry.d.ts.map +1 -0
- package/dist/tool-retry.js +53 -0
- package/dist/tool-retry.js.map +1 -0
- package/dist/tree.d.ts +62 -6
- package/dist/tree.d.ts.map +1 -1
- package/dist/tree.js +192 -23
- package/dist/tree.js.map +1 -1
- package/dist/types.d.ts +767 -52
- package/dist/types.d.ts.map +1 -1
- package/dist/workflow-snapshot.d.ts +8 -0
- package/dist/workflow-snapshot.d.ts.map +1 -0
- package/dist/workflow-snapshot.js +276 -0
- package/dist/workflow-snapshot.js.map +1 -0
- package/dist/workflow-types.d.ts +171 -0
- package/dist/workflow-types.d.ts.map +1 -0
- package/dist/workflow-types.js +2 -0
- package/dist/workflow-types.js.map +1 -0
- package/dist/workflow.d.ts +19 -0
- package/dist/workflow.d.ts.map +1 -0
- package/dist/workflow.js +1053 -0
- package/dist/workflow.js.map +1 -0
- package/examples/a2a-remote.ts +85 -0
- package/examples/a2a-server.ts +100 -0
- package/examples/background.ts +18 -4
- package/examples/code-mode.ts +76 -0
- package/examples/conversation.ts +57 -0
- package/examples/evals.ts +79 -0
- package/examples/guardrails.ts +56 -0
- package/examples/handoff.ts +79 -0
- package/examples/memory.ts +44 -0
- package/examples/otel.ts +99 -0
- package/examples/steering.ts +69 -0
- package/examples/structured-handoff.ts +92 -0
- package/examples/subagents.ts +127 -0
- package/examples/workflow.ts +74 -0
- package/package.json +58 -6
- package/src/a2a/auth.ts +62 -0
- package/src/a2a/client.ts +733 -0
- package/src/a2a/index.ts +74 -0
- package/src/a2a/memory-runs.ts +448 -0
- package/src/a2a/policy.ts +148 -0
- package/src/a2a/push.ts +251 -0
- package/src/a2a/remote.ts +1652 -0
- package/src/a2a/server.ts +1390 -0
- package/src/a2a/signing.ts +348 -0
- package/src/a2a/tasks.ts +260 -0
- package/src/a2a/wire.ts +1443 -0
- package/src/background-types.ts +86 -0
- package/src/child.ts +181 -0
- package/src/code-driver.ts +48 -0
- package/src/code-mode.ts +12 -0
- package/src/code-script.ts +149 -0
- package/src/code.ts +424 -0
- package/src/compaction.ts +212 -0
- package/src/delegation.ts +444 -155
- package/src/evals/driver.ts +222 -0
- package/src/evals/journal.ts +605 -0
- package/src/evals/judge.ts +188 -0
- package/src/evals/report.ts +295 -0
- package/src/evals/runner.ts +826 -0
- package/src/evals/scorers.ts +339 -0
- package/src/evals/simulation.ts +46 -0
- package/src/evals/testing.ts +126 -0
- package/src/evals/trajectory.ts +223 -0
- package/src/evals/types.ts +463 -0
- package/src/evals.ts +72 -0
- package/src/extensions.ts +247 -0
- package/src/handoff.ts +214 -0
- package/src/index.ts +51 -0
- package/src/input.ts +319 -0
- package/src/mcp.ts +690 -0
- package/src/memory-store.ts +366 -0
- package/src/memory.ts +893 -0
- package/src/otel.ts +568 -0
- package/src/progress.ts +214 -0
- package/src/quickjs.ts +524 -0
- package/src/recovery.ts +90 -0
- package/src/request.ts +513 -0
- package/src/run.ts +2678 -313
- package/src/runs.ts +464 -133
- package/src/schema-to-ts.ts +194 -0
- package/src/session.ts +178 -0
- package/src/snapshot.ts +1595 -124
- package/src/steering.ts +329 -0
- package/src/subagents.ts +1084 -0
- package/src/tool-retry.ts +86 -0
- package/src/tree.ts +223 -27
- package/src/types.ts +711 -52
- package/src/workflow-snapshot.ts +366 -0
- package/src/workflow-types.ts +213 -0
- package/src/workflow.ts +1316 -0
|
@@ -0,0 +1,521 @@
|
|
|
1
|
+
# Third-party notices
|
|
2
|
+
|
|
3
|
+
Parts of `@providerkit/agents` are adapted from the open source projects below. Each adapted
|
|
4
|
+
block has a short comment that names its source. Their copyright notices and licenses follow.
|
|
5
|
+
|
|
6
|
+
## TanStack AI
|
|
7
|
+
|
|
8
|
+
- Tracing source: `packages/ai/src/middlewares/otel.ts`.
|
|
9
|
+
Used in `src/otel.ts`: explicit parent contexts and operation spans. Changed: SDK attempt
|
|
10
|
+
identities, bounded observation and callback composition; Core's public adapter owns provider
|
|
11
|
+
CLIENT spans and reported usage. No content capture, exporter or context manager is installed.
|
|
12
|
+
|
|
13
|
+
- Code-mode sources: `packages/ai-code-mode/src/type-generator/json-schema-to-ts.ts`,
|
|
14
|
+
`packages/ai-code-mode/src/code-wrapper.ts`, `create-code-mode-tool.ts`,
|
|
15
|
+
`bindings/tool-to-binding.ts`, `create-system-prompt.ts` and `packages/ai-isolate-quickjs`.
|
|
16
|
+
- Used in: `src/code.ts`, `src/schema-to-ts.ts`, `src/code-script.ts`, `src/quickjs.ts` and their tests.
|
|
17
|
+
Changed: code descriptors dispatch through the existing run journal rather than invoking tools
|
|
18
|
+
from an engine. Control tools stay direct, host decisions are checked immediately before effects,
|
|
19
|
+
and a program never resumes a half-run VM. Reference aliases are scoped to each tool and schema document; nullable unions are
|
|
20
|
+
deduplicated. Guest programs cannot access raw host bridges. JSON values cross as strings,
|
|
21
|
+
each job gets a fresh runtime, and settled programs cannot start more host calls. CPU time,
|
|
22
|
+
admission and cleanup are bounded; optional engine dependencies load only in the driver.
|
|
23
|
+
|
|
24
|
+
- Workflow source: `packages/ai-harness/src/durable-tool.ts`, `createToolStep`.
|
|
25
|
+
Used in `src/workflow.ts`: unique keys, JSON copies on first execution and replay, and saved
|
|
26
|
+
wake times. Changed: interrupted effects fail closed; repeatability needs explicit read-only
|
|
27
|
+
policy or authoritative reconciliation. Storage uses the existing tree checkpoint barrier.
|
|
28
|
+
|
|
29
|
+
- Source: [TanStack/ai](https://github.com/TanStack/ai/tree/1888233ddb501d14b17aa9a5f3497373a0e9242e),
|
|
30
|
+
`packages/ai-harness/src/inline-media.ts`, `packages/ai-harness/src/media.ts`,
|
|
31
|
+
`packages/ai-harness/src/handoff.ts`, `packages/ai-harness/src/log-records.ts`,
|
|
32
|
+
`packages/ai-harness/src/log.ts`,
|
|
33
|
+
`packages/ai-harness/src/session/turn-parts.ts` (`steering` and `joinSteers`) and
|
|
34
|
+
`packages/ai/src/interrupt-serialization.ts`, `packages/ai/src/utilities/tool-result.ts`
|
|
35
|
+
and `packages/ai-compaction/src/index.ts` (`evictOldest`, `summarizeOldest` and checkpoint reuse),
|
|
36
|
+
plus `packages/ai-harness/src/first-party/agents.ts` (`allowedTools` and child continuation),
|
|
37
|
+
`packages/ai-memory/src/internal/store.ts` (`sameScope`, `lexicalOverlap`, `defaultRenderMemory`)
|
|
38
|
+
and `packages/ai-memory/src/testkit/contract.ts`.
|
|
39
|
+
- Used in: `src/memory.ts`, `src/memory-store.ts` and `test/memory.test.ts`, exact scope matching,
|
|
40
|
+
word ranking, JSON-quoted memory and the disposable store contract check. Changed: all four
|
|
41
|
+
scope dimensions match exactly; empty labels are refused; words support Unicode and accent
|
|
42
|
+
folding. Version checks and erasure generations are atomic. Ingestion is explicit and commits
|
|
43
|
+
a receipt with its writes. Recall is journaled user data, never system instructions.
|
|
44
|
+
- Used in: `src/subagents.ts`, limiting helper tools to the creator's available tools.
|
|
45
|
+
Changed: exact tool object identity replaces glob matching. Grants and host configuration
|
|
46
|
+
live in child snapshots instead of an in-memory tool map; hidden tools cannot be invoked.
|
|
47
|
+
Follow-ups keep an admitted helper's history and provider session identity. Changed: an opaque
|
|
48
|
+
stored id is scoped to one creator and root. Each turn is a journaled child; unfinished work,
|
|
49
|
+
changed grants and concurrent follow-ups to one helper are refused.
|
|
50
|
+
- Used in: `src/compaction.ts` and `src/run.ts`, a saved model-only view separate from the full
|
|
51
|
+
transcript, usage plus new-message estimates and checkpoint-before-apply.
|
|
52
|
+
Changed: core owns the cut and tool pairing; unread steers stay verbatim. Summary calls use
|
|
53
|
+
the existing model guards, admissions and usage receipts, and interrupted summaries never
|
|
54
|
+
replay automatically. `test/compaction.test.ts` checks session identity, pairing and recovery.
|
|
55
|
+
- Used in: `src/extensions.ts`, detection and normalization of rich tool content arrays.
|
|
56
|
+
Changed: core's outcome, text and image types are reused; files and references are refused.
|
|
57
|
+
JSON output stays in the private receipt; model history uses the tool's text summary and images.
|
|
58
|
+
`test/extensions.test.ts` checks real model/tool turns, limits, sessions and resume.
|
|
59
|
+
- Used in: `src/progress.ts`, adjacent delta folding, timed batching and a single writer.
|
|
60
|
+
Changed: only compatible text or reasoning folds, never tool calls. Buffers have count and
|
|
61
|
+
byte limits. Unknown writes are not replayed; a new persisted gap record is required before
|
|
62
|
+
execution continues. The host owns sequence numbers and uncertain-write reconciliation.
|
|
63
|
+
`test/progress.test.ts` checks fold equivalence, barriers, bounds and failures.
|
|
64
|
+
- Used in: `src/steering.ts`, joining queued user messages before a model call, in order,
|
|
65
|
+
committing them before removing them from pending delivery, and excluding delegated children.
|
|
66
|
+
Changed: a bounded host inbox supplies immutable ids; the existing execution journal records
|
|
67
|
+
positions before idempotent acknowledgement. A completed model receipt confirms consumption.
|
|
68
|
+
Unconsumed messages stay with the host, with no automatic follow-up run. `src/input.ts` folds
|
|
69
|
+
these positions between whole tool rounds; `test/steering.test.ts` checks admission and recovery.
|
|
70
|
+
- Used in: `src/handoff.ts`, a transfer notice appended after existing history, fixed-target
|
|
71
|
+
guards and the active-agent fold. `test/handoff.test.ts` carries the transfer, self-target,
|
|
72
|
+
conflict and resume cases. Changed: every transfer is a journaled child with shared budgets;
|
|
73
|
+
only a root's own handoff chain changes its conversation owner, and notes use JSON quoting.
|
|
74
|
+
- Used in: `src/request.ts`, canonical JSON ordering for request definition hashes. Our JSON
|
|
75
|
+
validator checks values first; Web Crypto supplies SHA-256 instead of a copied hash function.
|
|
76
|
+
- Used in: `src/snapshot.ts`, the base64 check and the byte count read from its length;
|
|
77
|
+
`src/input.ts` and `src/run.ts`, a media reference swapped for its bytes only in the provider
|
|
78
|
+
request, loaded once per id per run.
|
|
79
|
+
- Changed: whitespace is refused and padding is required, because the text goes to the provider
|
|
80
|
+
as given. A missing file fails the run instead of becoming a text note.
|
|
81
|
+
|
|
82
|
+
```text
|
|
83
|
+
MIT License
|
|
84
|
+
|
|
85
|
+
Copyright (c) 2025 Tanner Linsley
|
|
86
|
+
|
|
87
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
88
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
89
|
+
in the Software without restriction, including without limitation the rights
|
|
90
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
91
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
92
|
+
furnished to do so, subject to the following conditions:
|
|
93
|
+
|
|
94
|
+
The above copyright notice and this permission notice shall be included in all
|
|
95
|
+
copies or substantial portions of the Software.
|
|
96
|
+
|
|
97
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
98
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
99
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
100
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
101
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
102
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
103
|
+
SOFTWARE.
|
|
104
|
+
```
|
|
105
|
+
|
|
106
|
+
## OpenAI Agents JS
|
|
107
|
+
|
|
108
|
+
- Source: [openai/openai-agents-js](https://github.com/openai/openai-agents-js/tree/8aeac0eb255dbdff9adcdc65a0eae638cbcea74f),
|
|
109
|
+
`packages/agents-core/src/memory/memorySession.ts`, `packages/agents-core/src/agent.ts`,
|
|
110
|
+
`packages/agents-core/src/tool.ts`, `packages/agents-core/src/runner/modelSettings.ts`,
|
|
111
|
+
`packages/agents-core/src/runner/toolExecution.ts`, `packages/agents-core/src/handoff.ts`,
|
|
112
|
+
`packages/agents-core/src/extensions/handoffFilters.ts`, `packages/agents-core/src/runState.ts`,
|
|
113
|
+
`packages/agents-core/src/result.ts`, `packages/agents-core/src/runner/turnResolution.ts`,
|
|
114
|
+
`packages/agents-core/src/guardrail.ts` and `packages/agents-core/src/testing/scriptedModel.ts`.
|
|
115
|
+
- Used in: `src/evals/testing.ts`, a finite scripted provider for offline evaluation. Changed:
|
|
116
|
+
core chunks replace vendor messages; tool calls and usage use core's portable public contract.
|
|
117
|
+
- Used in: `src/types.ts`, `src/extensions.ts` and `src/run.ts`, explicit input/output verdicts
|
|
118
|
+
and blocking checks before tool dispatch from `guardrail.ts` and `runner/toolExecution.ts`.
|
|
119
|
+
Changed: checks always block, cannot waive host authorization and have recorded identities
|
|
120
|
+
and verdicts. Guarded model output is bounded and withheld before disclosure. Rejected checks
|
|
121
|
+
stop rather than retry effects; interrupted guards require host reconciliation.
|
|
122
|
+
- Used in: `src/handoff.ts`, the history-filter context, removal of tools and reasoning, and the
|
|
123
|
+
duplicate-agent identity check. Changed: assistant text survives without its private fields;
|
|
124
|
+
target identity is saved before approval. `test/handoff.test.ts` checks history filtering,
|
|
125
|
+
next-turn routing, interrupted transfer reuse and cancellation before admission.
|
|
126
|
+
- Used in: `src/run.ts`, `src/types.ts` and `src/handoff.ts`, handoff output union inference from
|
|
127
|
+
`agent.ts` (`HandoffsOutputUnion`, `Agent.create`) and active-agent validation from `result.ts`
|
|
128
|
+
(`finalOutput`) and `runner/turnResolution.ts` (`processFinalOutput`). Changed: infer from the
|
|
129
|
+
registered tools, without casts; restore the owning child's runtime instead of swapping the
|
|
130
|
+
source's agent pointer. Raw candidates stay in the existing child journal. Only the target
|
|
131
|
+
validates its output, never the source's different schema. `test/structured-handoff.test.ts`
|
|
132
|
+
checks distinct schemas, transformed values, validation failure, resume and public inference.
|
|
133
|
+
- Used in: `src/session.ts`, `createMemorySession`: a run id that already appended the same turn
|
|
134
|
+
succeeds without writing it again, and the same run id with another turn fails.
|
|
135
|
+
- Used in: `src/types.ts` and `src/run.ts`, dynamic instructions, enabled tools, resetting a
|
|
136
|
+
forced tool choice after tool use, and selecting a tool result as the final answer.
|
|
137
|
+
- Changed: instructions and enabled tools resolve once at creation, are saved in the journal,
|
|
138
|
+
and never resolve again on resume. The run's tool selection may only narrow the agent's.
|
|
139
|
+
Only successful, validated stopping-tool results finish a run, after all calls settle; the
|
|
140
|
+
selected raw candidate is saved so restoring cannot repeat an effect.
|
|
141
|
+
|
|
142
|
+
```text
|
|
143
|
+
MIT License
|
|
144
|
+
|
|
145
|
+
Copyright (c) 2025 OpenAI
|
|
146
|
+
|
|
147
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
148
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
149
|
+
in the Software without restriction, including without limitation the rights
|
|
150
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
151
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
152
|
+
furnished to do so, subject to the following conditions:
|
|
153
|
+
|
|
154
|
+
The above copyright notice and this permission notice shall be included in all
|
|
155
|
+
copies or substantial portions of the Software.
|
|
156
|
+
|
|
157
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
158
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
159
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
160
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
161
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
162
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
163
|
+
SOFTWARE.
|
|
164
|
+
```
|
|
165
|
+
|
|
166
|
+
## PydanticAI
|
|
167
|
+
|
|
168
|
+
- Source: [pydantic/pydantic-ai](https://github.com/pydantic/pydantic-ai/tree/f93bcff0c72caa0d5b0e2ead8b550d9674c8c9c4),
|
|
169
|
+
`pydantic_ai_slim/pydantic_ai/conversation_store.py` and
|
|
170
|
+
`pydantic_ai_slim/pydantic_ai/settings.py`,
|
|
171
|
+
`pydantic_ai_slim/pydantic_ai/tool_manager.py` (`_check_max_retries`),
|
|
172
|
+
`src/pydantic_ai_harness/pydantic_ai_harness/ask_user/_types.py`,
|
|
173
|
+
`pydantic_evals/pydantic_evals/evaluators/agentic.py` and
|
|
174
|
+
`pydantic_evals/pydantic_evals/evaluators/llm_as_a_judge.py`.
|
|
175
|
+
- Used in: `src/evals/trajectory.ts`, `scorers.ts` and `judge.ts`, trajectory/argument matching
|
|
176
|
+
and explicit model judging. Changed: journals replace spans, matching includes child work,
|
|
177
|
+
reasons omit private values by default, and judges require explicit bounded execution.
|
|
178
|
+
- Used in: `src/tool-retry.ts`, `src/types.ts` and `src/run.ts`, per-tool attempt ceilings.
|
|
179
|
+
Changed: default zero retries, with exact operation receipts rather than model-directed
|
|
180
|
+
permission. Read-only calls require explicit policy and current host authorization; writes
|
|
181
|
+
require authoritative not-run reconciliation. Requests and control tools cannot gain a replay
|
|
182
|
+
path. `test/tool-retry.test.ts` checks budgets, saved failures and unsafe retry refusals.
|
|
183
|
+
- Used in: `src/request.ts`, answer checks for offered choices, repeated selections, blank text
|
|
184
|
+
and cancellation. Changed to our keyed requests and host-authorized decisions.
|
|
185
|
+
- Used in: `src/session.ts`, `createMemorySession`: the revision check on every append, and a
|
|
186
|
+
copy on every read and write.
|
|
187
|
+
- Used in: `src/run.ts`, merging model settings with the run's values preferred over the
|
|
188
|
+
agent's. Provider defaults stay in core; `undefined` fields inherit.
|
|
189
|
+
|
|
190
|
+
```text
|
|
191
|
+
The MIT License (MIT)
|
|
192
|
+
|
|
193
|
+
Copyright (c) Pydantic Services Inc. 2024 to present
|
|
194
|
+
|
|
195
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
196
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
197
|
+
in the Software without restriction, including without limitation the rights
|
|
198
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
199
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
200
|
+
furnished to do so, subject to the following conditions:
|
|
201
|
+
|
|
202
|
+
The above copyright notice and this permission notice shall be included in
|
|
203
|
+
all copies or substantial portions of the Software.
|
|
204
|
+
|
|
205
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
206
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
207
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
208
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
209
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
210
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
|
211
|
+
THE SOFTWARE.
|
|
212
|
+
```
|
|
213
|
+
|
|
214
|
+
## PydanticAI Harness and Vstorm
|
|
215
|
+
|
|
216
|
+
- Sources: [pydantic/pydantic-ai](https://github.com/pydantic/pydantic-ai),
|
|
217
|
+
`src/pydantic_ai_harness/pydantic_ai_harness/sub_agents/_toolset.py` (`create_agent`,
|
|
218
|
+
`_build_created` and replay reconstruction), `_control.py` (`DynamicAgentSpec`, name validation
|
|
219
|
+
and the tool-free default), and `tests/harness/sub_agents/test_task_control.py` and
|
|
220
|
+
`test_dbos.py`, and `src/pydantic_ai_harness/pydantic_ai_harness/memory/_capability.py`
|
|
221
|
+
(user-role memory snapshots and `_neutralize`).
|
|
222
|
+
- Used in: `src/memory.ts`, keeping recalled data out of system instructions and neutralizing
|
|
223
|
+
stored framing tags. Changed: every `<` is escaped inside JSON text. One bounded recall lives
|
|
224
|
+
in the run journal and is reattached to the model view after compaction, not to session history.
|
|
225
|
+
- Used in: `src/subagents.ts` and `test/subagents.test.ts`, names, model menus, bounded creation
|
|
226
|
+
and rebuilding from saved definitions without asking the model again. Changed: versioned
|
|
227
|
+
host templates run through providerkit's existing child journal, guards and limits. Names are
|
|
228
|
+
private; positional keys identify children. Host policy can narrow grants, never add authority.
|
|
229
|
+
- PydanticAI Harness's `THIRD_PARTY_NOTICES.md` identifies dynamic agents as a port of
|
|
230
|
+
[vstorm-co/subagents-pydantic-ai](https://github.com/vstorm-co/subagents-pydantic-ai).
|
|
231
|
+
Both notices are retained below.
|
|
232
|
+
|
|
233
|
+
```text
|
|
234
|
+
The MIT License (MIT)
|
|
235
|
+
|
|
236
|
+
Copyright (c) 2026 Pydantic Services Inc.
|
|
237
|
+
|
|
238
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
239
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
240
|
+
in the Software without restriction, including without limitation the rights
|
|
241
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
242
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
243
|
+
furnished to do so, subject to the following conditions:
|
|
244
|
+
|
|
245
|
+
The above copyright notice and this permission notice shall be included in all
|
|
246
|
+
copies or substantial portions of the Software.
|
|
247
|
+
|
|
248
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
249
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
250
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
251
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
252
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
253
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
254
|
+
SOFTWARE.
|
|
255
|
+
```
|
|
256
|
+
|
|
257
|
+
```text
|
|
258
|
+
MIT License
|
|
259
|
+
|
|
260
|
+
Copyright (c) 2026 Vstorm
|
|
261
|
+
|
|
262
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
263
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
264
|
+
in the Software without restriction, including without limitation the rights
|
|
265
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
266
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
267
|
+
furnished to do so, subject to the following conditions:
|
|
268
|
+
|
|
269
|
+
The above copyright notice and this permission notice shall be included in all
|
|
270
|
+
copies or substantial portions of the Software.
|
|
271
|
+
|
|
272
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
273
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
274
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
275
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
276
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
277
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
278
|
+
SOFTWARE.
|
|
279
|
+
```
|
|
280
|
+
|
|
281
|
+
## Microsoft Agent Framework
|
|
282
|
+
|
|
283
|
+
- Serving sources: `dotnet/src/Microsoft.Agents.AI.Hosting.A2A/IsolationKeyScopedTaskStore.cs`
|
|
284
|
+
and `A2AAgentHandler.cs`. Used in `src/a2a/tasks.ts` and `server.ts`: caller-scoped task
|
|
285
|
+
storage and generic failure responses. Changed: owner, actor and tenant form the partition;
|
|
286
|
+
revision checks protect message receipts and physical-segment updates.
|
|
287
|
+
|
|
288
|
+
- A2A source: `python/packages/a2a/agent_framework_a2a/_agent.py`, remote input occurrences.
|
|
289
|
+
Used in `src/a2a/remote.ts`: remote questions become request-keyed local asks. Changed:
|
|
290
|
+
the existing request journal owns decisions, current host authority checks every answer,
|
|
291
|
+
and peer approvals or client-tool grants are refused.
|
|
292
|
+
|
|
293
|
+
- Workflow source: `python/packages/core/agent_framework/_workflows/_functional.py`, explicit
|
|
294
|
+
replay-key uniqueness and incompatible-definition refusal. Used in `src/workflow.ts`.
|
|
295
|
+
Changed: explicit versions and JSON identities replace code hashes and positional keys.
|
|
296
|
+
|
|
297
|
+
- Source: [microsoft/agent-framework](https://github.com/microsoft/agent-framework),
|
|
298
|
+
`python/packages/core/agent_framework/_tools.py`, `_reset_required_tool_choice` and the
|
|
299
|
+
final tool-free call after the iteration allowance.
|
|
300
|
+
- Used in: `src/run.ts`, resetting a forced choice and requesting one final answer with no
|
|
301
|
+
tools after the local turn limit.
|
|
302
|
+
- Changed: the final call still counts against the tree's model-call and time budgets. It
|
|
303
|
+
cannot execute tools even if the provider returns them. Checked-output agents skip it,
|
|
304
|
+
because they need the reserved result tool to finish.
|
|
305
|
+
|
|
306
|
+
```text
|
|
307
|
+
MIT License
|
|
308
|
+
|
|
309
|
+
Copyright (c) Microsoft Corporation.
|
|
310
|
+
|
|
311
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
312
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
313
|
+
in the Software without restriction, including without limitation the rights
|
|
314
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
315
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
316
|
+
furnished to do so, subject to the following conditions:
|
|
317
|
+
|
|
318
|
+
The above copyright notice and this permission notice shall be included in all
|
|
319
|
+
copies or substantial portions of the Software.
|
|
320
|
+
|
|
321
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
322
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
323
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
324
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
325
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
326
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
327
|
+
SOFTWARE
|
|
328
|
+
```
|
|
329
|
+
|
|
330
|
+
## LangGraph.js
|
|
331
|
+
|
|
332
|
+
- Workflow source: `libs/langgraph-core/src/pregel/retry.ts`, retry exclusions. Used in
|
|
333
|
+
`src/workflow.ts`. Changed: core classifies provider errors, retries require repeatability,
|
|
334
|
+
each attempt remains in the journal and delayed retries return control to the host.
|
|
335
|
+
|
|
336
|
+
- Source: [langchain-ai/langgraphjs](https://github.com/langchain-ai/langgraphjs),
|
|
337
|
+
`libs/langgraph-core/src/interrupt.ts`.
|
|
338
|
+
- Used in: `src/delegation.ts`, returning a saved answer when pure coordination replays and
|
|
339
|
+
validating it before returning to the coordinator.
|
|
340
|
+
- Changed: stable question keys replace positional matching. Requests and decisions stay in
|
|
341
|
+
the existing effect journal, and host authorization is required before accepting an answer.
|
|
342
|
+
|
|
343
|
+
```text
|
|
344
|
+
The MIT License
|
|
345
|
+
|
|
346
|
+
Copyright (c) 2024 LangChain
|
|
347
|
+
|
|
348
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
349
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
350
|
+
in the Software without restriction, including without limitation the rights
|
|
351
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
352
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
353
|
+
furnished to do so, subject to the following conditions:
|
|
354
|
+
|
|
355
|
+
The above copyright notice and this permission notice shall be included in
|
|
356
|
+
all copies or substantial portions of the Software.
|
|
357
|
+
|
|
358
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
359
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
360
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
361
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
362
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
363
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
|
364
|
+
THE SOFTWARE.
|
|
365
|
+
```
|
|
366
|
+
|
|
367
|
+
## Google ADK
|
|
368
|
+
|
|
369
|
+
- Serving sources: `google/adk-js/core/src/a2a/agent_to_a2a.ts` and
|
|
370
|
+
`core/src/agents/processors/request_confirmation_llm_request_processor.ts`.
|
|
371
|
+
Used in `src/a2a/server.ts`: authentication is required by default, input is JSON only,
|
|
372
|
+
and a peer cannot answer an operator approval without an explicit host opt-in. Changed:
|
|
373
|
+
current host claims remain authoritative and all private output needs explicit projection.
|
|
374
|
+
|
|
375
|
+
- A2A sources: `google/adk-js`, `core/src/a2a/agent_card.ts` and `core/src/a2a/auth.ts`;
|
|
376
|
+
`google/adk-python`, `src/google/adk/a2a/agent/_remote_a2a_agent.py`.
|
|
377
|
+
Used in `src/a2a/policy.ts`, `client.ts`, `auth.ts` and the remote runtime: endpoint checks,
|
|
378
|
+
required authentication and refusal of incomplete streams. Changed: the host owns DNS,
|
|
379
|
+
credentials and egress; Web Crypto replaces Node-only crypto. Abort detaches observation
|
|
380
|
+
and never grants permission to cancel a remote task. Mutating requests never retry.
|
|
381
|
+
|
|
382
|
+
- Workflow sources: `google/adk-js`, `core/src/workflow/dynamic_node_scheduler.ts` and
|
|
383
|
+
`core/src/workflow/node_context.ts`, saved child results and suspension propagation.
|
|
384
|
+
Used in `src/workflow.ts`. Changed: duplicates are refused rather than deduplicated, the
|
|
385
|
+
existing SDK child executor owns execution, and every started branch settles before return.
|
|
386
|
+
|
|
387
|
+
Copyright 2026 Google LLC. Licensed under Apache 2.0; the full license is included as
|
|
388
|
+
`LICENSE-APACHE-2.0`.
|
|
389
|
+
|
|
390
|
+
- Sources: [google/adk-python](https://github.com/google/adk-python),
|
|
391
|
+
`src/google/adk/evaluation/_multi_run_aggregation_methods.py` and
|
|
392
|
+
`src/google/adk/evaluation/simulation/llm_backed_user_simulator_prompts.py`;
|
|
393
|
+
[google/adk-js](https://github.com/google/adk-js), `core/src/cli/cli_eval.ts`.
|
|
394
|
+
- Used in: `src/evals/report.ts`, `scorers.ts`, `simulation.ts` and `driver.ts`, multi-run
|
|
395
|
+
aggregation, ROUGE-1, bounded user simulation and mock matching. Changed: products replace
|
|
396
|
+
combinations, excluded outcomes remain counted, words use Unicode segmentation, simulation
|
|
397
|
+
requires explicit provider consent, and mocks never fall through to real tool execution.
|
|
398
|
+
|
|
399
|
+
## Mastra
|
|
400
|
+
|
|
401
|
+
- Serving sources: `packages/server/src/server/handlers/a2a.ts`,
|
|
402
|
+
`packages/server/src/server/a2a/agent-card-v1.ts`, `agent-card-signing.ts` and
|
|
403
|
+
`push-notification-sender.ts`, plus `client-sdks/client-js/src/utils/verify-agent-card-signature.ts`.
|
|
404
|
+
Used in `src/a2a/server.ts`, `signing.ts` and `push.ts`: explicit version selection, cards,
|
|
405
|
+
detached signatures and callback checks. Changed: Web Crypto replaces signing dependencies;
|
|
406
|
+
host egress policy replaces Node-only networking, and uncertain pushes are not replayed.
|
|
407
|
+
|
|
408
|
+
- A2A sources: `packages/core/src/a2a/compat/v1.ts` and `packages/core/src/a2a/a2a-agent.ts`.
|
|
409
|
+
Used in `src/a2a/wire.ts` and `remote.ts`: version mapping, terminal/interrupted states,
|
|
410
|
+
artifact replacement and task observation. Changed: messages have pre-send receipts,
|
|
411
|
+
unknown delivery never replays, and remote nodes share the existing child/run journal.
|
|
412
|
+
Completed output is validated before reuse. Remote billing stays unknown.
|
|
413
|
+
|
|
414
|
+
Copyright (c) 2025 Kepler Software, Inc. Licensed under Apache 2.0; the full license is included
|
|
415
|
+
as `LICENSE-APACHE-2.0`. No code from `ee/` is used.
|
|
416
|
+
|
|
417
|
+
- Code-mode sources: `packages/core/src/tools/code-mode/stub-generator.ts`,
|
|
418
|
+
`code-mode/quickjs/src/transport.ts` and `code-mode/quickjs/src/transport.test.ts`.
|
|
419
|
+
- Used in: `src/schema-to-ts.ts`, `src/quickjs.ts` and their tests. Changed: safe quoted
|
|
420
|
+
property names, empty enums, dictionary types and scoped schema references. The driver
|
|
421
|
+
owns one fresh runtime per job, uses string-only bridges and drops late replies. Cleanup
|
|
422
|
+
disables host work, frees deferred handles and discards a broken shared engine module.
|
|
423
|
+
|
|
424
|
+
- Source: [mastra-ai/mastra](https://github.com/mastra-ai/mastra),
|
|
425
|
+
`packages/core/src/evals/not-scorable.ts`, `packages/core/src/evals/hooks.ts`
|
|
426
|
+
and `packages/core/src/agent-controller/tools.ts` (forked helper history).
|
|
427
|
+
- Used in: `src/subagents.ts` and `test/subagents.test.ts`, a fork starts a child from earlier
|
|
428
|
+
conversation. Changed: task-only is the default. A bounded host filter selects sanitized
|
|
429
|
+
messages, and the journal saves their exact bytes before execution. Source system prompts,
|
|
430
|
+
tool rounds and private reasoning do not cross this boundary; approvals are never disabled.
|
|
431
|
+
- Used in: `src/evals/types.ts` and `runner.ts`, cross-copy skip branding and deterministic
|
|
432
|
+
six-byte SHA-256 sampling. Changed: skips require a reason, the brand is providerkit's, hashing
|
|
433
|
+
uses Web Crypto, and scoring has no automatic hook wiring or telemetry.
|
|
434
|
+
|
|
435
|
+
## CrewAI
|
|
436
|
+
|
|
437
|
+
- Push source: `lib/crewai/src/crewai/a2a/updates/push_notifications/signature.py`.
|
|
438
|
+
Used in `src/a2a/push.ts`: timestamped HMAC-SHA256 signatures. Changed: Web Crypto,
|
|
439
|
+
explicit host keys and a host replay check; this remains an optional providerkit extension.
|
|
440
|
+
|
|
441
|
+
- Source: [crewAIInc/crewAI](https://github.com/crewAIInc/crewAI),
|
|
442
|
+
`lib/crewai/src/crewai/a2a/wrapper.py` and `a2a/updates/polling/config.py`.
|
|
443
|
+
- Used in `src/a2a/remote.ts`: bounded polling and parent-routed questions. Changed: handles
|
|
444
|
+
name a completed child in the same root and specialist scope, not a peer task ID. Each
|
|
445
|
+
follow-up is a new journaled child; message budgets include earlier children in that chain.
|
|
446
|
+
|
|
447
|
+
```text
|
|
448
|
+
MIT License
|
|
449
|
+
|
|
450
|
+
Copyright (c) 2025 crewAI, Inc.
|
|
451
|
+
|
|
452
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
453
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
454
|
+
in the Software without restriction, including without limitation the rights
|
|
455
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
456
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
457
|
+
furnished to do so, subject to the following conditions:
|
|
458
|
+
|
|
459
|
+
The above copyright notice and this permission notice shall be included in all
|
|
460
|
+
copies or substantial portions of the Software.
|
|
461
|
+
|
|
462
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
463
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
464
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
465
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
466
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
467
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
468
|
+
SOFTWARE.
|
|
469
|
+
```
|
|
470
|
+
|
|
471
|
+
## A2A JavaScript SDK
|
|
472
|
+
|
|
473
|
+
- Source: [a2aproject/a2a-js](https://github.com/a2aproject/a2a-js), version 1.3.0,
|
|
474
|
+
`src/signature.ts` and the A2A 1.0 card schema. Licensed under Apache 2.0;
|
|
475
|
+
the full license is included as `LICENSE-APACHE-2.0`.
|
|
476
|
+
- Used in `src/a2a/signing.ts`: normalization of known protobuf card fields and removal of
|
|
477
|
+
default and empty values before canonical JSON signing. Changed: a portable, bounded reader
|
|
478
|
+
and Web Crypto, without a runtime dependency on the SDK. Tests use the official SDK separately
|
|
479
|
+
to check wire and signature interoperability.
|
|
480
|
+
|
|
481
|
+
## Vercel AI SDK
|
|
482
|
+
|
|
483
|
+
- Code-mode sources: `packages/code-mode/src/run-code-mode.ts`, `tool-prompt.ts` and `types.ts`.
|
|
484
|
+
Used as policy references for `src/code.ts`, `src/code-script.ts` and `test/code.test.ts`:
|
|
485
|
+
explicit tool bindings, guest tool errors, source lines and separate byte/time/call limits.
|
|
486
|
+
Changed: no signed replay continuation. Inner calls use providerkit's shared authorization,
|
|
487
|
+
retry, tree serialization and checkpoint path; failures retain bounded call receipts.
|
|
488
|
+
|
|
489
|
+
- The full Apache 2.0 license is included as `LICENSE-APACHE-2.0`.
|
|
490
|
+
- Source: [vercel/ai](https://github.com/vercel/ai/tree/8ba3940d3dd1f3cd3c4365bbaec505c6ef0eb1e3),
|
|
491
|
+
`packages/ai/src/prompt/convert-to-language-model-prompt.ts` and
|
|
492
|
+
`packages/workflow/src/do-stream-step.ts` and
|
|
493
|
+
`packages/ai/src/agent/tool-loop-agent-settings.ts`.
|
|
494
|
+
- Used in: `src/extensions.ts`, `src/types.ts` and `src/run.ts`, lifecycle boundaries around
|
|
495
|
+
runs, model calls and tool execution. Changed: callbacks are ordered, cancellable observers,
|
|
496
|
+
separate from guards and host permission checks. Raw inspection is distinct from guarded
|
|
497
|
+
progress, and callback failures do not grant or deny work.
|
|
498
|
+
- Used in: `src/run.ts`, the restart marker before replacement model output.
|
|
499
|
+
- Changed: restart is opt-in for inference-only and trusted read-only work, retains every
|
|
500
|
+
attempt's measured usage, and names the stable operation plus old and new attempts. It does
|
|
501
|
+
not reset an entire workflow step or promise durable partial output.
|
|
502
|
+
- Used in: `test/input.test.ts`, the check that a request never reaches a user turn, or its end,
|
|
503
|
+
while a tool call is unanswered. This test is not in the published package.
|
|
504
|
+
- Changed: it returns the unanswered ids instead of throwing, and it also reports a tool result
|
|
505
|
+
that answers no call.
|
|
506
|
+
|
|
507
|
+
```text
|
|
508
|
+
Copyright 2023 Vercel, Inc.
|
|
509
|
+
|
|
510
|
+
Licensed under the Apache License, Version 2.0 (the "License");
|
|
511
|
+
you may not use this file except in compliance with the License.
|
|
512
|
+
You may obtain a copy of the License at
|
|
513
|
+
|
|
514
|
+
http://www.apache.org/licenses/LICENSE-2.0
|
|
515
|
+
|
|
516
|
+
Unless required by applicable law or agreed to in writing, software
|
|
517
|
+
distributed under the License is distributed on an "AS IS" BASIS,
|
|
518
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
519
|
+
See the License for the specific language governing permissions and
|
|
520
|
+
limitations under the License.
|
|
521
|
+
```
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
export interface A2APrincipal {
|
|
2
|
+
owner: string;
|
|
3
|
+
actorId: string;
|
|
4
|
+
}
|
|
5
|
+
export type A2AAuthenticate = (request: Request) => A2APrincipal | null | Promise<A2APrincipal | null>;
|
|
6
|
+
/** A host-owned secret maps to a host-owned principal, never to a card or message claim. */
|
|
7
|
+
export declare function bearerToken(secret: string, principal: A2APrincipal): A2AAuthenticate;
|
|
8
|
+
/** Server integrations use this before any task lookup. Missing authentication refuses access. */
|
|
9
|
+
export declare function authenticateA2A(request: Request, authenticate?: A2AAuthenticate): Promise<A2APrincipal | null>;
|
|
10
|
+
//# sourceMappingURL=auth.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"auth.d.ts","sourceRoot":"","sources":["../../src/a2a/auth.ts"],"names":[],"mappings":"AAIA,MAAM,WAAW,YAAY;IAC3B,KAAK,EAAE,MAAM,CAAC;IACd,OAAO,EAAE,MAAM,CAAC;CACjB;AACD,MAAM,MAAM,eAAe,GAAG,CAC5B,OAAO,EAAE,OAAO,KACb,YAAY,GAAG,IAAI,GAAG,OAAO,CAAC,YAAY,GAAG,IAAI,CAAC,CAAC;AAExD,4FAA4F;AAC5F,wBAAgB,WAAW,CAAC,MAAM,EAAE,MAAM,EAAE,SAAS,EAAE,YAAY,GAAG,eAAe,CA4BpF;AAED,kGAAkG;AAClG,wBAAsB,eAAe,CACnC,OAAO,EAAE,OAAO,EAChB,YAAY,CAAC,EAAE,eAAe,GAC7B,OAAO,CAAC,YAAY,GAAG,IAAI,CAAC,CAc9B"}
|
package/dist/a2a/auth.js
ADDED
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
// Bearer authentication policy adapted from google-adk-js core/src/a2a/auth.ts.
|
|
2
|
+
// Copyright 2026 Google LLC. SPDX-License-Identifier: Apache-2.0
|
|
3
|
+
import { A2AError } from "./wire.js";
|
|
4
|
+
/** A host-owned secret maps to a host-owned principal, never to a card or message claim. */
|
|
5
|
+
export function bearerToken(secret, principal) {
|
|
6
|
+
if (!/^[A-Za-z0-9\-._~+/]+=*$/.test(secret) ||
|
|
7
|
+
secret.length > 8192 ||
|
|
8
|
+
!principal.owner ||
|
|
9
|
+
!principal.actorId)
|
|
10
|
+
throw new A2AError("invalid");
|
|
11
|
+
const identity = { owner: principal.owner, actorId: principal.actorId };
|
|
12
|
+
const encoder = new TextEncoder();
|
|
13
|
+
// WebCrypto verifies a fixed-length MAC; no JavaScript string comparison of the secret.
|
|
14
|
+
const key = crypto.subtle.generateKey({ name: "HMAC", hash: "SHA-256" }, false, [
|
|
15
|
+
"sign",
|
|
16
|
+
"verify",
|
|
17
|
+
]);
|
|
18
|
+
const expected = key.then((k) => crypto.subtle.sign("HMAC", k, encoder.encode(secret)));
|
|
19
|
+
return async (request) => {
|
|
20
|
+
const header = request.headers.get("authorization");
|
|
21
|
+
const token = header && /^Bearer ([A-Za-z0-9\-._~+/]+=*)$/i.exec(header)?.[1];
|
|
22
|
+
if (!token || token.length > 8192)
|
|
23
|
+
return null;
|
|
24
|
+
try {
|
|
25
|
+
return (await crypto.subtle.verify("HMAC", await key, await expected, encoder.encode(token)))
|
|
26
|
+
? { ...identity }
|
|
27
|
+
: null;
|
|
28
|
+
}
|
|
29
|
+
catch {
|
|
30
|
+
return null;
|
|
31
|
+
}
|
|
32
|
+
};
|
|
33
|
+
}
|
|
34
|
+
/** Server integrations use this before any task lookup. Missing authentication refuses access. */
|
|
35
|
+
export async function authenticateA2A(request, authenticate) {
|
|
36
|
+
if (!authenticate)
|
|
37
|
+
return null;
|
|
38
|
+
try {
|
|
39
|
+
const principal = await authenticate(request);
|
|
40
|
+
return principal &&
|
|
41
|
+
typeof principal.owner === "string" &&
|
|
42
|
+
principal.owner.length > 0 &&
|
|
43
|
+
typeof principal.actorId === "string" &&
|
|
44
|
+
principal.actorId.length > 0
|
|
45
|
+
? { owner: principal.owner, actorId: principal.actorId }
|
|
46
|
+
: null;
|
|
47
|
+
}
|
|
48
|
+
catch {
|
|
49
|
+
return null;
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
//# sourceMappingURL=auth.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"auth.js","sourceRoot":"","sources":["../../src/a2a/auth.ts"],"names":[],"mappings":"AAAA,gFAAgF;AAChF,iEAAiE;AACjE,OAAO,EAAE,QAAQ,EAAE,MAAM,WAAW,CAAC;AAUrC,4FAA4F;AAC5F,MAAM,UAAU,WAAW,CAAC,MAAc,EAAE,SAAuB;IACjE,IACE,CAAC,yBAAyB,CAAC,IAAI,CAAC,MAAM,CAAC;QACvC,MAAM,CAAC,MAAM,GAAG,IAAI;QACpB,CAAC,SAAS,CAAC,KAAK;QAChB,CAAC,SAAS,CAAC,OAAO;QAElB,MAAM,IAAI,QAAQ,CAAC,SAAS,CAAC,CAAC;IAChC,MAAM,QAAQ,GAAG,EAAE,KAAK,EAAE,SAAS,CAAC,KAAK,EAAE,OAAO,EAAE,SAAS,CAAC,OAAO,EAAE,CAAC;IACxE,MAAM,OAAO,GAAG,IAAI,WAAW,EAAE,CAAC;IAClC,wFAAwF;IACxF,MAAM,GAAG,GAAG,MAAM,CAAC,MAAM,CAAC,WAAW,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,SAAS,EAAE,EAAE,KAAK,EAAE;QAC9E,MAAM;QACN,QAAQ;KACT,CAAC,CAAC;IACH,MAAM,QAAQ,GAAG,GAAG,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,MAAM,CAAC,MAAM,CAAC,IAAI,CAAC,MAAM,EAAE,CAAC,EAAE,OAAO,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC;IACxF,OAAO,KAAK,EAAE,OAAO,EAAE,EAAE;QACvB,MAAM,MAAM,GAAG,OAAO,CAAC,OAAO,CAAC,GAAG,CAAC,eAAe,CAAC,CAAC;QACpD,MAAM,KAAK,GAAG,MAAM,IAAI,mCAAmC,CAAC,IAAI,CAAC,MAAM,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC;QAC9E,IAAI,CAAC,KAAK,IAAI,KAAK,CAAC,MAAM,GAAG,IAAI;YAAE,OAAO,IAAI,CAAC;QAC/C,IAAI,CAAC;YACH,OAAO,CAAC,MAAM,MAAM,CAAC,MAAM,CAAC,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,EAAE,MAAM,QAAQ,EAAE,OAAO,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC,CAAC;gBAC3F,CAAC,CAAC,EAAE,GAAG,QAAQ,EAAE;gBACjB,CAAC,CAAC,IAAI,CAAC;QACX,CAAC;QAAC,MAAM,CAAC;YACP,OAAO,IAAI,CAAC;QACd,CAAC;IACH,CAAC,CAAC;AACJ,CAAC;AAED,kGAAkG;AAClG,MAAM,CAAC,KAAK,UAAU,eAAe,CACnC,OAAgB,EAChB,YAA8B;IAE9B,IAAI,CAAC,YAAY;QAAE,OAAO,IAAI,CAAC;IAC/B,IAAI,CAAC;QACH,MAAM,SAAS,GAAG,MAAM,YAAY,CAAC,OAAO,CAAC,CAAC;QAC9C,OAAO,SAAS;YACd,OAAO,SAAS,CAAC,KAAK,KAAK,QAAQ;YACnC,SAAS,CAAC,KAAK,CAAC,MAAM,GAAG,CAAC;YAC1B,OAAO,SAAS,CAAC,OAAO,KAAK,QAAQ;YACrC,SAAS,CAAC,OAAO,CAAC,MAAM,GAAG,CAAC;YAC5B,CAAC,CAAC,EAAE,KAAK,EAAE,SAAS,CAAC,KAAK,EAAE,OAAO,EAAE,SAAS,CAAC,OAAO,EAAE;YACxD,CAAC,CAAC,IAAI,CAAC;IACX,CAAC;IAAC,MAAM,CAAC;QACP,OAAO,IAAI,CAAC;IACd,CAAC;AACH,CAAC"}
|