@introspection-ai/recipes 0.13.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.
Files changed (161) hide show
  1. package/LICENSE +191 -0
  2. package/README.md +184 -0
  3. package/dist/agent-tool.d.ts +42 -0
  4. package/dist/agent-tool.d.ts.map +1 -0
  5. package/dist/agent-tool.js +159 -0
  6. package/dist/agent-tool.js.map +1 -0
  7. package/dist/child-agent-completions.d.ts +61 -0
  8. package/dist/child-agent-completions.d.ts.map +1 -0
  9. package/dist/child-agent-completions.js +135 -0
  10. package/dist/child-agent-completions.js.map +1 -0
  11. package/dist/child-agent-store.d.ts +48 -0
  12. package/dist/child-agent-store.d.ts.map +1 -0
  13. package/dist/child-agent-store.js +98 -0
  14. package/dist/child-agent-store.js.map +1 -0
  15. package/dist/child-agent.d.ts +43 -0
  16. package/dist/child-agent.d.ts.map +1 -0
  17. package/dist/child-agent.js +268 -0
  18. package/dist/child-agent.js.map +1 -0
  19. package/dist/direct-cli.d.ts +9 -0
  20. package/dist/direct-cli.d.ts.map +1 -0
  21. package/dist/direct-cli.js +22 -0
  22. package/dist/direct-cli.js.map +1 -0
  23. package/dist/index.d.ts +14 -0
  24. package/dist/index.d.ts.map +1 -0
  25. package/dist/index.js +14 -0
  26. package/dist/index.js.map +1 -0
  27. package/dist/inspect.d.ts +26 -0
  28. package/dist/inspect.d.ts.map +1 -0
  29. package/dist/inspect.js +70 -0
  30. package/dist/inspect.js.map +1 -0
  31. package/dist/interactions.d.ts +204 -0
  32. package/dist/interactions.d.ts.map +1 -0
  33. package/dist/interactions.js +358 -0
  34. package/dist/interactions.js.map +1 -0
  35. package/dist/mcp-catalog.d.ts +8 -0
  36. package/dist/mcp-catalog.d.ts.map +1 -0
  37. package/dist/mcp-catalog.js +60 -0
  38. package/dist/mcp-catalog.js.map +1 -0
  39. package/dist/mcp-cli-core.d.ts +79 -0
  40. package/dist/mcp-cli-core.d.ts.map +1 -0
  41. package/dist/mcp-cli-core.js +1717 -0
  42. package/dist/mcp-cli-core.js.map +1 -0
  43. package/dist/mcp-cli-help.d.ts +2 -0
  44. package/dist/mcp-cli-help.d.ts.map +1 -0
  45. package/dist/mcp-cli-help.js +36 -0
  46. package/dist/mcp-cli-help.js.map +1 -0
  47. package/dist/mcp-cli-policy.d.ts +17 -0
  48. package/dist/mcp-cli-policy.d.ts.map +1 -0
  49. package/dist/mcp-cli-policy.js +230 -0
  50. package/dist/mcp-cli-policy.js.map +1 -0
  51. package/dist/mcp-cli.d.ts +3 -0
  52. package/dist/mcp-cli.d.ts.map +1 -0
  53. package/dist/mcp-cli.js +33 -0
  54. package/dist/mcp-cli.js.map +1 -0
  55. package/dist/mcp-client.d.ts +3 -0
  56. package/dist/mcp-client.d.ts.map +1 -0
  57. package/dist/mcp-client.js +86 -0
  58. package/dist/mcp-client.js.map +1 -0
  59. package/dist/mcp-command-context.d.ts +13 -0
  60. package/dist/mcp-command-context.d.ts.map +1 -0
  61. package/dist/mcp-command-context.js +29 -0
  62. package/dist/mcp-command-context.js.map +1 -0
  63. package/dist/mcp-contract.d.ts +16 -0
  64. package/dist/mcp-contract.d.ts.map +1 -0
  65. package/dist/mcp-contract.js +306 -0
  66. package/dist/mcp-contract.js.map +1 -0
  67. package/dist/mcp-daemon-client.d.ts +10 -0
  68. package/dist/mcp-daemon-client.d.ts.map +1 -0
  69. package/dist/mcp-daemon-client.js +119 -0
  70. package/dist/mcp-daemon-client.js.map +1 -0
  71. package/dist/mcp-daemon-protocol.d.ts +64 -0
  72. package/dist/mcp-daemon-protocol.d.ts.map +1 -0
  73. package/dist/mcp-daemon-protocol.js +6 -0
  74. package/dist/mcp-daemon-protocol.js.map +1 -0
  75. package/dist/mcp-daemon.d.ts +3 -0
  76. package/dist/mcp-daemon.d.ts.map +1 -0
  77. package/dist/mcp-daemon.js +76880 -0
  78. package/dist/mcp-daemon.js.map +1 -0
  79. package/dist/mcp-run-worker.d.ts +2 -0
  80. package/dist/mcp-run-worker.d.ts.map +1 -0
  81. package/dist/mcp-run-worker.js +76579 -0
  82. package/dist/mcp-run-worker.js.map +1 -0
  83. package/dist/mcp.d.ts +168 -0
  84. package/dist/mcp.d.ts.map +1 -0
  85. package/dist/mcp.js +558 -0
  86. package/dist/mcp.js.map +1 -0
  87. package/dist/pi-extension.d.ts +30 -0
  88. package/dist/pi-extension.d.ts.map +1 -0
  89. package/dist/pi-extension.js +880 -0
  90. package/dist/pi-extension.js.map +1 -0
  91. package/dist/provider-env.d.ts +2 -0
  92. package/dist/provider-env.d.ts.map +1 -0
  93. package/dist/provider-env.js +21 -0
  94. package/dist/provider-env.js.map +1 -0
  95. package/dist/recipe/resolve.d.ts +30 -0
  96. package/dist/recipe/resolve.d.ts.map +1 -0
  97. package/dist/recipe/resolve.js +131 -0
  98. package/dist/recipe/resolve.js.map +1 -0
  99. package/dist/recipe-agent.d.ts +71 -0
  100. package/dist/recipe-agent.d.ts.map +1 -0
  101. package/dist/recipe-agent.js +555 -0
  102. package/dist/recipe-agent.js.map +1 -0
  103. package/dist/recipe-extensions.d.ts +9 -0
  104. package/dist/recipe-extensions.d.ts.map +1 -0
  105. package/dist/recipe-extensions.js +81 -0
  106. package/dist/recipe-extensions.js.map +1 -0
  107. package/dist/recipe-mcp-config.d.ts +15 -0
  108. package/dist/recipe-mcp-config.d.ts.map +1 -0
  109. package/dist/recipe-mcp-config.js +82 -0
  110. package/dist/recipe-mcp-config.js.map +1 -0
  111. package/dist/recipe-model.d.ts +49 -0
  112. package/dist/recipe-model.d.ts.map +1 -0
  113. package/dist/recipe-model.js +299 -0
  114. package/dist/recipe-model.js.map +1 -0
  115. package/dist/recipe-package.d.ts +79 -0
  116. package/dist/recipe-package.d.ts.map +1 -0
  117. package/dist/recipe-package.js +479 -0
  118. package/dist/recipe-package.js.map +1 -0
  119. package/dist/recipe-skills.d.ts +7 -0
  120. package/dist/recipe-skills.d.ts.map +1 -0
  121. package/dist/recipe-skills.js +46 -0
  122. package/dist/recipe-skills.js.map +1 -0
  123. package/dist/run-controller.d.ts +32 -0
  124. package/dist/run-controller.d.ts.map +1 -0
  125. package/dist/run-controller.js +259 -0
  126. package/dist/run-controller.js.map +1 -0
  127. package/dist/run.d.ts +28 -0
  128. package/dist/run.d.ts.map +1 -0
  129. package/dist/run.js +84 -0
  130. package/dist/run.js.map +1 -0
  131. package/dist/session.d.ts +140 -0
  132. package/dist/session.d.ts.map +1 -0
  133. package/dist/session.js +363 -0
  134. package/dist/session.js.map +1 -0
  135. package/dist/test-utils.d.ts +32 -0
  136. package/dist/test-utils.d.ts.map +1 -0
  137. package/dist/test-utils.js +259 -0
  138. package/dist/test-utils.js.map +1 -0
  139. package/dist/testing.d.ts +25 -0
  140. package/dist/testing.d.ts.map +1 -0
  141. package/dist/testing.js +96 -0
  142. package/dist/testing.js.map +1 -0
  143. package/docs/agent-composition.md +196 -0
  144. package/docs/deployment-configuration.md +65 -0
  145. package/docs/index.md +49 -0
  146. package/docs/interactions.md +210 -0
  147. package/docs/mcp-auth.md +80 -0
  148. package/docs/mcp-configuration.md +126 -0
  149. package/docs/migration.md +70 -0
  150. package/docs/pi-extension.md +97 -0
  151. package/docs/python-bindings-release.md +47 -0
  152. package/docs/recipe-evals.md +70 -0
  153. package/docs/recipe-flow.md +41 -0
  154. package/docs/recipe-format.md +186 -0
  155. package/docs/recipe-judges.md +152 -0
  156. package/docs/runtime-library.md +171 -0
  157. package/package.json +106 -0
  158. package/vendor/mcp-client/darwin-arm64/mcp-client +0 -0
  159. package/vendor/mcp-client/darwin-x64/mcp-client +0 -0
  160. package/vendor/mcp-client/linux-arm64/mcp-client +0 -0
  161. package/vendor/mcp-client/linux-x64/mcp-client +0 -0
@@ -0,0 +1,80 @@
1
+ # MCP authentication in recipe sessions
2
+
3
+ This page covers authentication after capability has been declared and selected.
4
+ Start with [MCP configuration](mcp-configuration.md) for the complete policy and
5
+ endpoint model.
6
+
7
+ Recipe MCP authentication follows the endpoint source that made an
8
+ already-approved server reachable: a configured package manifest or a local/host
9
+ binding. Authentication never selects a server or grants tools; the package and
10
+ active/visible-agent selections still determine the final server/tool inventory.
11
+
12
+ ## Local OAuth
13
+
14
+ Local users may declare OAuth on a server in the workspace- or recipe-local
15
+ `.pi/mcp.local.json`:
16
+
17
+ ```json
18
+ {
19
+ "servers": [
20
+ {
21
+ "id": "linear",
22
+ "transport": "streamable_http",
23
+ "url": "https://mcp.linear.app/mcp",
24
+ "auth": "oauth",
25
+ "oauthClientId": "optional-pre-registered-client-id",
26
+ "oauthClientSecretEnv": "LINEAR_OAUTH_CLIENT_SECRET",
27
+ "oauthRedirectUrl": "http://127.0.0.1:8787/callback",
28
+ "oauthScope": "optional provider-specific scopes"
29
+ }
30
+ ]
31
+ }
32
+ ```
33
+
34
+ Only `auth: "oauth"` enables mcporter OAuth for that local definition. Recipe
35
+ startup and the agent-facing `mcp` command use cached credentials only and never
36
+ start a browser flow. A local user completes or refreshes OAuth outside the
37
+ agent session with mcporter directly, using the same server name and OAuth
38
+ settings, then retries the recipe operation. They can use their normal mcporter
39
+ config, or the generated session projection when it exists, for example:
40
+
41
+ ```bash
42
+ npx mcporter auth linear --config .pi/mcporter.json
43
+ ```
44
+
45
+ The session CLI does not accept OAuth URLs, ad-hoc servers, config imports, or
46
+ configuration mutation. A local user configures connectivity outside the agent
47
+ through `.pi/mcp.local.json` or their normal mcporter configuration. The agent
48
+ cannot initiate authentication.
49
+
50
+ ## Hosted bindings
51
+
52
+ Hosted runtimes adapt their endpoint and credential systems into the same
53
+ `.pi/mcp.local.json` shape before starting Recipes. Header values remain
54
+ environment references, so credentials are resolved at runtime rather than
55
+ written into the recipe workspace. Deployment-specific bootstrap, token, and
56
+ egress behavior belongs to the hosting adapter, not this package.
57
+
58
+ Regardless of where a recipe runs, the agent sees one rule: MCP operations are
59
+ headless. When authentication is missing, it receives a deployment-neutral
60
+ recovery telling it to ask the user to authenticate the connection outside the
61
+ agent session and then retry; `mcp run --json-errors` reports this as
62
+ `authentication_required` with action `ask_user_to_authenticate`.
63
+ Deployment-specific credential handling is not part of the agent's
64
+ instructions.
65
+
66
+ ## Agent-facing command boundary
67
+
68
+ Recipe sessions expose only `mcp search`, `mcp list`, `mcp call`, and `mcp run`.
69
+ Interactive authentication and administrative and
70
+ developer commands (`config`, `vault`, `generate-cli`, `emit-ts`, `record`,
71
+ `replay`, `daemon`, and `serve`) are intentionally unavailable. URL selectors,
72
+ ad-hoc HTTP/stdio transports, config overrides, and persistence flags are also
73
+ rejected. The upstream `--tail-log` call flag is also unavailable because it
74
+ reads an absolute local path supplied by an MCP result; server output must not
75
+ choose files for an agent session to read.
76
+
77
+ This command policy prevents accidental escape from the materialized MCP
78
+ surface. It is not an OS or network sandbox: the enclosing local shell or
79
+ managed runtime remains responsible for filesystem, process, and egress
80
+ isolation.
@@ -0,0 +1,126 @@
1
+ # MCP configuration
2
+
3
+ MCP authorization is the intersection of two fail-closed policy gates: the
4
+ package boundary and the subsets selected by the active agent and its visible
5
+ subagents. The authorized server must
6
+ also have a reachable endpoint, supplied either by a package-declared MCP
7
+ manifest or by a local/host binding. A binding supplies connectivity; it never
8
+ expands authorization.
9
+
10
+ ```text
11
+ package policy ∩ active/visible-agent selections = authorized tools
12
+ package.json#pi.mcp agents/*.yaml#mcp
13
+ +
14
+ endpoint from package manifest or local/host binding
15
+
16
+ session-local mcp CLI
17
+ ```
18
+
19
+ ## 1. Declare the package boundary
20
+
21
+ `package.json#pi.mcp` declares the servers a recipe may use and the maximum
22
+ tool set available from each one. It can also reference portable MCP manifests.
23
+
24
+ ```json
25
+ {
26
+ "pi": {
27
+ "mcp": {
28
+ "manifest": "mcp.json",
29
+ "servers": [
30
+ {
31
+ "id": "contacts",
32
+ "required": true,
33
+ "tools": {
34
+ "include": ["search_contacts", "get_contact"],
35
+ "exclude": []
36
+ }
37
+ }
38
+ ]
39
+ }
40
+ }
41
+ }
42
+ ```
43
+
44
+ Prefer exact tool names. `"*"` explicitly permits the package-visible tool set,
45
+ including tools a server may add later; patterns such as `search_*` are invalid.
46
+
47
+ `manifest` accepts a single path; `manifests` accepts an array, and either the
48
+ `mcp` value or a manifest reference may be given as a string shorthand for a
49
+ single path. A server marked `"required": true` must resolve to a bound endpoint
50
+ at session materialization or the session fails closed rather than starting
51
+ without the capability.
52
+
53
+ ## 2. Narrow access for each agent
54
+
55
+ An agent selects a subset of the package-permitted servers and tools. It cannot
56
+ add capability that the package did not declare.
57
+
58
+ ```yaml
59
+ tools:
60
+ - bash
61
+ mcp:
62
+ contacts:
63
+ include:
64
+ - search_contacts
65
+ ```
66
+
67
+ Omitting a server—or the entire agent `mcp` block—means no access. `exclude`
68
+ removes exact names after inclusion and always wins. MCP tools are selected here,
69
+ not in the agent's ordinary `tools` list.
70
+
71
+ ## 3. Supply endpoint configuration
72
+
73
+ A referenced MCP manifest can carry a portable configured endpoint and catalog.
74
+ When connectivity varies by environment, provide an endpoint and credential
75
+ references in `.pi/mcp.local.json` for local runs, or through a host binding:
76
+
77
+ ```json
78
+ {
79
+ "servers": [
80
+ {
81
+ "id": "contacts",
82
+ "transport": "streamable_http",
83
+ "url": "https://contacts.example.com/mcp",
84
+ "headers": {
85
+ "Authorization": "Bearer ${CONTACTS_MCP_TOKEN}"
86
+ }
87
+ }
88
+ ]
89
+ }
90
+ ```
91
+
92
+ The `${CONTACTS_MCP_TOKEN}` reference is resolved from the environment at launch,
93
+ so export it before running the recipe locally:
94
+
95
+ ```bash
96
+ export CONTACTS_MCP_TOKEN='...'
97
+ pi --recipe . --agent agent
98
+ ```
99
+
100
+ Do not commit or distribute `.pi/mcp.local.json`; publish validation rejects
101
+ local configuration. Commit `.pi/mcp.local.example.json` when a binding template
102
+ is helpful. A hosted runtime binds its own endpoint and credential system to the
103
+ same shape. A binding overrides a package-manifest endpoint with the same id,
104
+ but a server that the package does not permit, or that none of the active/visible
105
+ agents permit, remains unavailable.
106
+
107
+ When the local file is absent, manifest-supplied endpoints remain usable.
108
+ Required servers that need environment-specific bindings fail closed until the
109
+ local Pi environment or embedding host supplies them.
110
+
111
+ ## Use capabilities from an agent
112
+
113
+ When the active agent or one of its visible subagents has MCP access, the
114
+ extension creates a session-local `mcp` command from their combined selections.
115
+ Discover narrowly, inspect one schema, then call or compose:
116
+
117
+ ```bash
118
+ mcp search "contact lookup"
119
+ mcp list contacts.search_contacts --schema
120
+ mcp call contacts.search_contacts query="Ada Lovelace"
121
+ ```
122
+
123
+ The command is headless and cannot add servers, mutate configuration, or start
124
+ browser authentication. See [MCP authentication](mcp-auth.md) for OAuth and
125
+ hosted binding details, and [Recipes extension](pi-extension.md#mcp) for the
126
+ full runtime contract.
@@ -0,0 +1,70 @@
1
+ # Migration to Recipes
2
+
3
+ The project and npm package are now **Recipes**:
4
+
5
+ ```text
6
+ @introspection-ai/pi-recipes → @introspection-ai/recipes
7
+ Pi Recipes → Recipes
8
+ ```
9
+
10
+ The artifact remains **a Recipe**. The package format and focused runtime
11
+ entrypoints remain source-compatible unless noted below.
12
+
13
+ ## Package imports
14
+
15
+ ```diff
16
+ - import { resolveRecipe } from "@introspection-ai/pi-recipes/recipe";
17
+ + import { resolveRecipe } from "@introspection-ai/recipes/recipe";
18
+
19
+ - import { createRecipeSession } from "@introspection-ai/pi-recipes/session";
20
+ + import { createRecipeSession } from "@introspection-ai/recipes/session";
21
+ ```
22
+
23
+ The same replacement applies to `/run`, `/pi`, `/interactions`, and
24
+ `/test-utils`. The former `/tracing` entrypoint is removed: pass a host-owned
25
+ tracer through `createRecipeSession({ otel })` instead.
26
+
27
+ ## Pi extension
28
+
29
+ ```bash
30
+ pi remove npm:@introspection-ai/pi-recipes
31
+ pi install npm:@introspection-ai/recipes
32
+ ```
33
+
34
+ The Recipe extension factory is now `createRecipesExtension`.
35
+ `createPiRecipesExtension` remains as a deprecated source-compatible alias.
36
+
37
+ Recipe-owned extensions that still import
38
+ `@introspection-ai/pi-recipes/interactions` are aliased to the current runtime
39
+ while they migrate.
40
+
41
+ ## CLI
42
+
43
+ The standalone `recipes` executable has been retired. Use:
44
+
45
+ ```bash
46
+ introspection init
47
+ introspection check
48
+ introspection local
49
+ introspection dev
50
+ ```
51
+
52
+ Use ordinary Git and filesystem operations to clone, fork, copy, and publish
53
+ Recipe source.
54
+
55
+ ## Hosting
56
+
57
+ `serveRecipe` and `@introspection-ai/recipes/serve` are not part of the new
58
+ package. Hosts integrate at `createRecipeSession`; HTTP protocols, persistence,
59
+ auth, and deployment adapters belong to the host.
60
+
61
+ `runRecipe` remains as the small one-turn convenience above the session API.
62
+
63
+ ## Validation
64
+
65
+ The root npm package no longer downloads a platform-specific
66
+ `recipe-check` executable. Validation remains available through:
67
+
68
+ - `introspection check`;
69
+ - the `pi-recipe-check` Rust crate and binary;
70
+ - the `pi-recipe-check` Python package.
@@ -0,0 +1,97 @@
1
+ # Recipes extension for Pi
2
+
3
+ The Recipes extension teaches [Pi](https://pi.dev/docs/latest) to load a
4
+ Recipe package with:
5
+
6
+ ```bash
7
+ pi --recipe ./path/to/recipe --agent agent
8
+ ```
9
+
10
+ Pi is the harness. The extension resolves the selected Recipe, configures its
11
+ model and tools, loads its skills and extensions, materializes its declared
12
+ capabilities, and registers its subagents.
13
+
14
+ ## Installation
15
+
16
+ The recommended workflow lets the Introspection CLI provision compatible
17
+ versions:
18
+
19
+ ```bash
20
+ npm install -g @introspection-ai/cli
21
+ introspection init
22
+ introspection local
23
+ ```
24
+
25
+ For direct Pi use:
26
+
27
+ ```bash
28
+ pi install npm:@introspection-ai/recipes
29
+ ```
30
+
31
+ Recipes currently requires Node.js 24 or later and Pi `^0.82`.
32
+
33
+ ## Selection
34
+
35
+ `--recipe` accepts a local directory:
36
+
37
+ ```bash
38
+ pi --recipe . --agent agent
39
+ pi --recipe ./recipes/research --agent researcher
40
+ ```
41
+
42
+ The extension no longer maintains a separate installed-Recipe store. Git,
43
+ package managers, and ordinary paths own distribution.
44
+
45
+ The selected path and agent are exposed to Recipe-owned tools as
46
+ `PI_RECIPE_DIR` and `PI_AGENT_NAME`.
47
+
48
+ ## What is loaded
49
+
50
+ For the selected agent, the extension:
51
+
52
+ 1. reads the root `package.json#pi` resource declarations;
53
+ 2. resolves the agent YAML, including `from:` inheritance;
54
+ 3. selects the model, thinking level, and tool allowlist;
55
+ 4. loads selected skills, prompts, and Recipe-owned extensions;
56
+ 5. materializes declared MCP bindings from host or local configuration;
57
+ 6. exposes only the declared subagents through the shared `agent` tool.
58
+
59
+ See [Recipe Format](recipe-format.md) for the authored contract and
60
+ [Agent composition](agent-composition.md) for inheritance and selection.
61
+
62
+ ## Local capability bindings
63
+
64
+ Recipe source may include `.pi/mcp.local.example.json`, but secrets belong in
65
+ the environment or an ignored `.pi/mcp.local.json`. A host may synthesize the
66
+ same bindings in memory.
67
+
68
+ Bindings are resolved fail-closed for required servers. Optional servers may
69
+ remain unavailable. See [MCP configuration](mcp-configuration.md).
70
+
71
+ ## Recipe-owned extensions
72
+
73
+ TypeScript extension sources declared by `package.json#pi.extensions` are
74
+ loaded relative to the Recipe. Agent-level `extensions.include` and
75
+ `extensions.exclude` select which declared extensions participate.
76
+
77
+ Recipe extensions can import runtime helpers from `@introspection-ai/recipes`.
78
+ The loader also aliases the previous `@introspection-ai/pi-recipes` name during
79
+ the migration period so existing Recipe source shares the same runtime state.
80
+
81
+ ## Validation
82
+
83
+ Run:
84
+
85
+ ```bash
86
+ introspection check
87
+ ```
88
+
89
+ The runtime also performs the minimum validation required to fail safely before
90
+ constructing a session. Static authoring diagnostics remain the CLI validator's
91
+ job.
92
+
93
+ ## Host parity
94
+
95
+ The Pi extension and embedded hosts consume the same resolver and session
96
+ semantics. Hosts should run the conformance cases exported from
97
+ `@introspection-ai/recipes/test-utils`.
@@ -0,0 +1,47 @@
1
+ # Python bindings release
2
+
3
+ The `pi-recipe-check` Rust crate and Python distribution are two artifacts of
4
+ one validator product and always use the same version. The binding's Cargo
5
+ package and dependency on the core must both match the core crate version.
6
+ `scripts/check-recipe-check-versions.mjs` enforces this invariant in CI.
7
+
8
+ Release Please owns both versions, changelogs, component tags, and GitHub
9
+ releases. Its `linked-versions` plugin advances both components to the same
10
+ version whenever either has a releasable change. The `cargo-workspace` plugin
11
+ keeps the local dependency current, but leaves candidate merging to
12
+ `linked-versions`. A Python-only fix therefore creates a patch release for
13
+ both artifacts, and a core release always includes a matching Python release.
14
+ Routine releases must not bump either Cargo version manually.
15
+
16
+ When Release Please creates a Python binding release, the release workflow:
17
+
18
+ 1. Builds `abi3` wheels compatible with CPython 3.10 and newer for Linux
19
+ x86-64 and ARM64, macOS Apple Silicon and Intel, and Windows x86-64.
20
+ 2. Builds a source distribution containing the local Rust workspace
21
+ dependency.
22
+ 3. Waits for the matching `pi-recipe-check` crate publication to succeed.
23
+ 4. Publishes all Python artifacts to PyPI through trusted publishing.
24
+
25
+ ## One-time PyPI setup
26
+
27
+ Before the first release, create a pending trusted publisher for the unclaimed
28
+ `pi-recipe-check` project on PyPI with:
29
+
30
+ - Owner: `introspection-org`
31
+ - Repository: `pi-recipes`
32
+ - Workflow: `release-please.yml`
33
+ - Environment: `publish`
34
+
35
+ The GitHub `publish` environment should retain its existing deployment
36
+ protection. No long-lived PyPI API token is required.
37
+
38
+ Local release artifact checks use the locked development environment and the
39
+ same pinned maturin version as CI:
40
+
41
+ ```sh
42
+ uv sync --project bindings/python --locked
43
+ uv run --project bindings/python --locked maturin build --locked --release --out dist \
44
+ --manifest-path bindings/python/Cargo.toml
45
+ uv run --project bindings/python --locked maturin sdist --out dist \
46
+ --manifest-path bindings/python/Cargo.toml
47
+ ```
@@ -0,0 +1,70 @@
1
+ # Recipe eval declarations
2
+
3
+ A Recipe may pin offline evaluation suites without owning the evaluation
4
+ runner. The declaration makes quality inputs portable and reproducible; a host
5
+ or external tool decides when and where to execute them.
6
+
7
+ ## Registry suite
8
+
9
+ ```json
10
+ {
11
+ "pi": {
12
+ "evals": {
13
+ "suites": [
14
+ {
15
+ "name": "smoke",
16
+ "type": "registry",
17
+ "dataset": "acme/coding-smoke",
18
+ "version": "1.2.0"
19
+ }
20
+ ]
21
+ }
22
+ }
23
+ }
24
+ ```
25
+
26
+ Registry suites MUST pin an exact dataset version. Mutable aliases such as
27
+ `latest` are invalid.
28
+
29
+ ## Git suite
30
+
31
+ ```json
32
+ {
33
+ "pi": {
34
+ "evals": {
35
+ "suites": [
36
+ {
37
+ "name": "terminal",
38
+ "type": "git",
39
+ "repo": "https://github.com/acme/agent-evals.git",
40
+ "rev": "4f7c2b0d6d8a...",
41
+ "dataset": "terminal"
42
+ }
43
+ ]
44
+ }
45
+ }
46
+ }
47
+ ```
48
+
49
+ Git suites SHOULD pin a commit SHA. The dataset path MUST stay inside the
50
+ checkout.
51
+
52
+ ## Validation
53
+
54
+ ```bash
55
+ introspection check
56
+ ```
57
+
58
+ The validator checks declaration shape, unique suite names, immutable pins,
59
+ safe paths, and supported suite types without cloning or running the suite.
60
+
61
+ ## Runtime boundary
62
+
63
+ Recipe sessions do not load or execute eval suites. The declaration belongs to
64
+ the portable artifact because it identifies the authored evidence associated
65
+ with that agent. Harbor, CI, Introspection, or another evaluation system may
66
+ adapt that declaration into its own execution model.
67
+
68
+ The selected Recipe agent remains the source of truth for model and behavior.
69
+ An eval runner MUST make any override explicit rather than silently changing
70
+ the agent under test.
@@ -0,0 +1,41 @@
1
+ # Recipe workflow
2
+
3
+ The `introspection` CLI owns the developer workflow. The Recipes npm package is
4
+ the format implementation and Pi runtime extension; it does not install a
5
+ second CLI.
6
+
7
+ ## Create and run locally
8
+
9
+ ```bash
10
+ npm install -g @introspection-ai/cli
11
+ introspection init
12
+ introspection check
13
+ introspection local
14
+ ```
15
+
16
+ `introspection init` scaffolds a Recipe and ensures compatible versions of Pi
17
+ and the Recipes extension are present. `introspection check` runs the Recipe
18
+ Format validator. `introspection local` resolves the repository's local runtime
19
+ manifest and launches Pi with the Recipe path.
20
+
21
+ The local path requires no login and no Introspection cloud runtime.
22
+
23
+ ## Run Pi directly
24
+
25
+ ```bash
26
+ pi install npm:@introspection-ai/recipes
27
+ pi --recipe ./my-recipe --agent agent
28
+ ```
29
+
30
+ Recipes are ordinary Git-backed source packages. Clone, fork, or copy them with
31
+ normal Git and filesystem tools. There is no Recipe-specific install store or
32
+ publish command.
33
+
34
+ ## Deploy
35
+
36
+ The Recipe remains unchanged across hosts. A host calls
37
+ `createRecipeSession()` and supplies its own credentials, task lifecycle,
38
+ persistence, isolation, and protocol surface.
39
+
40
+ Use Introspection when you want the managed host. Use a host adapter when you
41
+ want to operate the same Recipe on another platform.