@sezzlee/core
v1.1.0
Published
TypeScript reference implementation of sezzlee's HTTP catalog spec: naming, selection, curation, search, request composition and error mapping.
Maintainers
Readme
@sezzlee/core
The language-neutral reference implementation of the sezzlee spec, in TypeScript.
Status:
1.1.0, stable. Published so that@sezzlee/sdk-nestjs,@sezzlee/openapiand@sezzlee/openapi-mcpcan depend on it; it has no runtime dependencies.
You do not install this package yourself: an SDK or the gateway pulls it in. Its exports follow the spec; a change that breaks them is a major version.
core is not file-core. This package is the HTTP catalog implementation;
@sezzlee/file-core is the shared machinery for file-backed MCP servers. Neither depends
on the other, in either direction.
What lives here
One module per spec concept. The source is a click away, so this list points rather than describes.
| Area | Files |
| ---------------- | ----------------------------------------------------------------------- |
| Naming | naming.ts |
| Selection | selection.ts |
| Tool assembly | tool.ts, tool-definition.ts, argument-names.ts |
| Request path | request-template.ts, request-composer.ts |
| Schema pipeline | schema-simplification.ts, json-schema.ts |
| Search and cards | search.ts, card.ts |
| Visibility | visibility.ts |
| Errors | error-mapping.ts, leak-filter.ts, errors.ts |
| Cache | cache/ |
| Retained results | results/, meta-tools/read-result.ts, meta-tools/execute-result.ts |
The optional result execution adapter accepts a host-supplied
DataExecutor. @sezzlee/compute-core supplies the bounded QuickJS implementation; the HTTP
core imports no engine at runtime and keeps no runtime dependencies. Use
executeStoredResult inside the existing emitGuarded response gate with the caller's
ResultShelf, so both ordinary and derived results keep the same response budget and
producing-tool ownership. The NestJS SDK wires this through its resultExecutor extension.
src/index.ts is the barrel and may only re-export from the canonical file for each concept. In
particular it must never re-export the embedded EndpointDescriptor / ToolDefinition copies
inside generated/fixture.ts — one definition per type, from one place.
Generated code
src/generated/ is produced from ../spec/schemas by
scripts/generate-types.mjs (@apidevtools/json-schema-ref-parser +
json-schema-to-typescript):
pnpm turbo run genCommitted, and never hand-edited. Always build through turbo — pnpm --filter @sezzlee/core build
skips generation and can compile against stale types.
Tests and the conformance corpus
pnpm turbo run test --filter=@sezzlee/coretest/conformance-fixtures.spec.ts runs the shared corpus in ../conformance.
Core runs those same JSON files alongside packages/http/conformance/validate.mjs and
sdks/nestjs/test/conformance-fixtures.spec.ts. That is what makes parity a test result instead of
an assertion.
A rule change that does not move a fixture has not been made.
Search benchmark
pnpm --filter @sezzlee/core bench:search
pnpm --filter @sezzlee/core bench:search -- --quickThe deterministic benchmark compares the original linear scan, a byte-trigram candidate index, and the production posting index. Each algorithm runs in an isolated Node process with explicit GC. Output includes build time, retained heap plus array-buffer memory, query p50/p95, and a JSON report. A digest mismatch between algorithms fails the run before results are reported.
Relationship to the NestJS SDK
@sezzlee/sdk-nestjs depends on this package and re-exports the parts its users need, so NestJS
consumers never import core directly.
Related
../spec— the normative rules and the schemas types come from../conformance— the fixture corpusapps/docs— the public documentation site (English)
