Skip to content

Commit 6def6dd

Browse files
authored
docs: refresh boundary and contributor guidance (#29)
1 parent 65ca4ec commit 6def6dd

11 files changed

Lines changed: 37 additions & 25 deletions

File tree

AGENTS.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@
3232

3333
- For most code changes, run `npm run format:check`, `npm run lint`, `npm run typecheck`, `npm test`, and `npm run build`.
3434
- If you change package exports, manifest fields, or published type-resolution behavior, also run `npm run package:check`.
35-
- If you change the public API of `@execbox/core`, `@execbox/core/mcp`, `@execbox/core/protocol`, `@execbox/quickjs`, `@execbox/quickjs/runner`, `@execbox/quickjs/runner/protocol-endpoint`, `@execbox/remote`, `@execbox/isolated-vm`, or `@execbox/isolated-vm/runner`, also run `npm run api:check`.
35+
- If you change the public API of any entrypoint listed in `scripts/workspace-entrypoints.ts`, including `@execbox/core/runtime` and `@execbox/quickjs/remote-endpoint`, also run `npm run api:check`.
3636
- If you change docs site content, navigation, or VitePress config, also run `npm run docs:build`.
3737
- If you touch execution boundaries, timeout handling, abort propagation, schema validation, or log/memory controls, also run `npm run test:security`.
3838
- If you touch `@execbox/isolated-vm` or codepaths guarded by `VITEST_INCLUDE_ISOLATED_VM`, run `npm run test:isolated-vm` or `npm run verify:isolated-vm`.
@@ -48,7 +48,7 @@
4848
- Use Conventional Commits for git commit messages, for example `docs: add agent and contributor guides` or `fix(worker): handle timeout classification`.
4949
- Published package releases are managed with Changesets and GitHub Actions.
5050
- Add a `.changeset/*.md` entry when a change affects published package behavior, public APIs, or release notes for one or more `@execbox/*` packages.
51-
- If you intentionally change a checked-in API report for `@execbox/core`, `@execbox/core/mcp`, `@execbox/core/protocol`, `@execbox/quickjs`, `@execbox/quickjs/runner`, `@execbox/quickjs/runner/protocol-endpoint`, `@execbox/remote`, `@execbox/isolated-vm`, or `@execbox/isolated-vm/runner`, update it with `npm run api:update` in the same change as the code and changeset.
51+
- If you intentionally change a checked-in API report for any entrypoint listed in `scripts/workspace-entrypoints.ts`, update it with `npm run api:update` in the same change as the code and changeset.
5252
- Skip a changeset for docs-only, examples-only, CI-only, or internal maintenance changes that do not affect published package behavior.
5353

5454
## Useful References

CONTRIBUTING.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,14 +27,14 @@ This guide is for both humans and coding agents. Agent-specific operating instru
2727

2828
Choose the smallest verification set that covers your change, and include the commands you ran in your PR or handoff notes when the context would help reviewers.
2929

30-
- Public API changes to `@execbox/core`, `@execbox/core/mcp`, `@execbox/core/protocol`, `@execbox/quickjs`, `@execbox/quickjs/runner`, `@execbox/quickjs/runner/protocol-endpoint`, `@execbox/remote`, `@execbox/isolated-vm`, or `@execbox/isolated-vm/runner`: run `npm run api:check`
30+
- Public API changes to any entrypoint listed in `scripts/workspace-entrypoints.ts`, including `@execbox/core/runtime` and `@execbox/quickjs/remote-endpoint`: run `npm run api:check`
3131

3232
## Changesets
3333

3434
- Add a `.changeset/*.md` file for user-facing changes to published `@execbox/*` packages.
3535
- Skip changesets for docs-only, examples-only, CI-only, or internal refactors that do not change published package behavior.
3636
- Keep the changeset summary focused on the externally visible change.
37-
- If you intentionally change a checked-in API report, update the report baseline with `npm run api:update` and add the corresponding changeset in the same change.
37+
- If you intentionally change a checked-in API report for an entrypoint listed in `scripts/workspace-entrypoints.ts`, update the report baseline with `npm run api:update` and add the corresponding changeset in the same change.
3838

3939
## Commits
4040

README.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -14,12 +14,12 @@ Execbox turns host tool catalogs into callable guest namespaces, supports MCP wr
1414

1515
## Package Map
1616

17-
| Package | npm | What it is for |
18-
| ------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------- |
19-
| [`@execbox/core`](./packages/core/) | [![npm](https://img.shields.io/npm/v/%40execbox%2Fcore?style=flat-square)](https://www.npmjs.com/package/@execbox/core) | Core execution contract, provider resolution, MCP adapters, and the `@execbox/core/protocol` transport subpath |
20-
| [`@execbox/quickjs`](./packages/quickjs/) | [![npm](https://img.shields.io/npm/v/%40execbox%2Fquickjs?style=flat-square)](https://www.npmjs.com/package/@execbox/quickjs) | QuickJS executor for inline, worker, and process hosts |
21-
| [`@execbox/remote`](./packages/remote/) | [![npm](https://img.shields.io/npm/v/%40execbox%2Fremote?style=flat-square)](https://www.npmjs.com/package/@execbox/remote) | Transport-backed remote executor |
22-
| [`@execbox/isolated-vm`](./packages/isolated-vm/) | [![npm](https://img.shields.io/npm/v/%40execbox%2Fisolated-vm?style=flat-square)](https://www.npmjs.com/package/@execbox/isolated-vm) | `isolated-vm` backend for execbox |
17+
| Package | npm | What it is for |
18+
| ------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------- |
19+
| [`@execbox/core`](./packages/core/) | [![npm](https://img.shields.io/npm/v/%40execbox%2Fcore?style=flat-square)](https://www.npmjs.com/package/@execbox/core) | Core execution contract, provider resolution, MCP adapters, and runtime/protocol subpaths |
20+
| [`@execbox/quickjs`](./packages/quickjs/) | [![npm](https://img.shields.io/npm/v/%40execbox%2Fquickjs?style=flat-square)](https://www.npmjs.com/package/@execbox/quickjs) | QuickJS executor for inline, worker, and process hosts |
21+
| [`@execbox/remote`](./packages/remote/) | [![npm](https://img.shields.io/npm/v/%40execbox%2Fremote?style=flat-square)](https://www.npmjs.com/package/@execbox/remote) | Transport-backed remote executor |
22+
| [`@execbox/isolated-vm`](./packages/isolated-vm/) | [![npm](https://img.shields.io/npm/v/%40execbox%2Fisolated-vm?style=flat-square)](https://www.npmjs.com/package/@execbox/isolated-vm) | `isolated-vm` backend for execbox |
2323

2424
## Examples
2525

docs/architecture/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ This doc set is for two audiences:
2222
```mermaid
2323
flowchart LR
2424
APP["Host application"]
25-
CORE["@execbox/core<br/>provider resolution + runner semantics + MCP adapters"]
25+
CORE["@execbox/core<br/>provider resolution + MCP adapters + runtime helpers"]
2626
QJS["@execbox/quickjs<br/>QuickJS executor + reusable runner"]
2727
REM["@execbox/remote<br/>transport-backed remote executor"]
2828
IVM["@execbox/isolated-vm<br/>in-process isolated-vm executor + reusable runner"]

docs/architecture/execbox-executors.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ flowchart LR
4747

4848
## QuickJS
4949

50-
`QuickJsExecutor` is the default reference implementation for execbox. It uses the shared runner semantics from `@execbox/core`: providers are converted to manifests, host tool calls are dispatched through the shared dispatcher helper, and the reusable QuickJS runner turns them back into guest-visible async functions.
50+
`QuickJsExecutor` is the default reference implementation for execbox. It uses the shared runner semantics from `@execbox/core/runtime`: providers are converted to manifests, host tool calls are dispatched through the shared dispatcher helper, and the reusable QuickJS runner turns them back into guest-visible async functions.
5151

5252
That design gives QuickJS two useful properties:
5353

docs/architecture/execbox-mcp-and-protocol.md

Lines changed: 10 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -50,15 +50,17 @@ It owns:
5050

5151
The architecture split is:
5252

53-
- `@execbox/core` owns provider resolution, manifest extraction, and host-side tool dispatch semantics
53+
- `@execbox/core` owns app-facing provider resolution and MCP adapters
54+
- `@execbox/core/runtime` owns manifest extraction and host-side tool dispatch helpers for runtime implementers
5455
- `@execbox/core/protocol` owns wire messages, host-session lifecycle, and host-side shell pooling utilities around those semantics
5556

5657
## How The Packages Fit Together
5758

58-
- `QuickJsExecutor` uses the shared runner semantics from `@execbox/core` directly.
59-
- `IsolatedVmExecutor` uses the same core runner semantics, but keeps a direct `isolated-vm` bridge instead of transport messages.
59+
- `QuickJsExecutor` uses the shared runner semantics from `@execbox/core/runtime` directly.
60+
- `IsolatedVmExecutor` uses the same runtime helper surface, but keeps a direct `isolated-vm` bridge instead of transport messages.
6061
- `QuickJsExecutor` in `host: "process"` and `host: "worker"` modes uses the shared host session from `@execbox/core/protocol` plus the shared QuickJS protocol endpoint inside the child or worker shell.
6162
- `RemoteExecutor` uses that same host session across an app-owned transport boundary.
63+
- The runner side of a remote deployment attaches a runtime-owned endpoint adapter; `@execbox/quickjs/remote-endpoint` is the shipped QuickJS adapter.
6264
- Pooled process and worker execution reuse only the outer host shell. Each `execute()` call still starts a fresh QuickJS runtime through the shared protocol endpoint.
6365

6466
```mermaid
@@ -76,16 +78,18 @@ flowchart TB
7678
PROTO["@execbox/core/protocol<br/>messages + host session + resource pool"]
7779
HOSTED["QuickJsExecutor host modes"]
7880
REM["RemoteExecutor"]
79-
ENDPOINT["QuickJS protocol endpoint"]
81+
QJS_ENDPOINT["QuickJS protocol endpoint<br/>worker/process side"]
82+
REMOTE_ENDPOINT["Runtime-owned remote endpoint<br/>QuickJS adapter is shipped"]
8083
end
8184
8285
CORE --> QJS
8386
CORE --> IVM
8487
CORE --> PROTO
8588
HOSTED --> PROTO
8689
REM --> PROTO
87-
HOSTED --> ENDPOINT
88-
REM --> ENDPOINT
90+
HOSTED --> QJS_ENDPOINT
91+
REM -. runner side .-> REMOTE_ENDPOINT
92+
REMOTE_ENDPOINT -. QuickJS example .-> QJS_ENDPOINT
8993
```
9094

9195
## Transport-Backed Execution Flow

docs/architecture/execbox-remote-workflow.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ sequenceDiagram
5353
participant Client as Downstream MCP client
5454
participant Wrapper as Wrapped MCP server
5555
participant Host as Host execbox session
56-
participant Runner as Remote QuickJS runner
56+
participant Runner as Remote runner
5757
participant Upstream as Upstream tools or MCP server
5858
5959
Client->>Wrapper: callTool("mcp_execute_code", { code })

docs/architecture/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ This doc set is for two audiences:
2222
```mermaid
2323
flowchart LR
2424
APP["Host application"]
25-
CORE["@execbox/core<br/>provider resolution + runner semantics + MCP adapters"]
25+
CORE["@execbox/core<br/>provider resolution + MCP adapters + runtime helpers"]
2626
QJS["@execbox/quickjs<br/>QuickJS executor + reusable runner"]
2727
REM["@execbox/remote<br/>transport-backed remote executor"]
2828
IVM["@execbox/isolated-vm<br/>in-process isolated-vm executor + reusable runner"]

docs/security.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ Execbox provides defense-in-depth controls for guest code execution. The isolati
1111
- Timeout and memory controls
1212
- Abort propagation into in-flight host tool work
1313

14-
## Important boundaries
14+
## What execbox does not provide
1515

1616
- A hard security boundary for hostile or multi-tenant code by default
1717
- That in-process runtimes are equivalent to a container, VM, or separate trust domain

packages/quickjs/README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -66,8 +66,8 @@ await executor.prewarm();
6666
## Advanced Imports
6767

6868
- `@execbox/quickjs/runner` exports the reusable QuickJS runner
69-
- `@execbox/quickjs/runner/protocol-endpoint` exports the shared protocol endpoint used by hosted and remote flows
70-
- `@execbox/quickjs/remote-endpoint` exports the QuickJS runner endpoint adapter for `@execbox/remote` transports
69+
- `@execbox/quickjs/runner/protocol-endpoint` exports the low-level QuickJS protocol loop used by hosted worker/process integrations
70+
- `@execbox/quickjs/remote-endpoint` adapts the QuickJS protocol loop to `@execbox/remote` runner ports
7171

7272
## Operational Notes
7373

0 commit comments

Comments
 (0)