Skip to content

feat: silo plugin registry (tessera-lake S1) - #29

Merged
rinaldofesta merged 9 commits into
mainfrom
feat/silo-registry
Jul 17, 2026
Merged

feat: silo plugin registry (tessera-lake S1)#29
rinaldofesta merged 9 commits into
mainfrom
feat/silo-registry

Conversation

@rinaldofesta

Copy link
Copy Markdown
Owner

Summary

S1 of the tessera-lake design (spec: docs/superpowers/specs/2026-07-17-tessera-lake-design.md, local): tessera's hardcoded crm/docs silo wiring becomes a plugin registry so domain packs — first: tessera-lake — can register new silo types from their own pip package.

  • New tessera.silos.registry: SiloType (server module, tool names, prompt blurb, consulted-claims credit fn, optional compile build/write hooks) + SiloRegistry singleton with lazy loading from the tessera.silo_types entry-point group. Broken third-party packs are skipped with a logged warning; built-ins always win name collisions.
  • crm/docs ported as the first two registered types (tessera.silos.builtin) — the MCP server modules and silos/access.py are untouched.
  • Three call sites go registry-driven: evals/task.py (per-blueprint MCP server launch; prompt intro assembled from blurbs, byte-identical — the _BASELINE_PROMPT SHA256 pin still passes), evals/scoring.py (consulted_claims dispatch), compiler.py (optional per-silo build/write hooks; plugins key only when a custom builder ran, so API previews are unchanged).
  • README: documented extension contract for pack authors.

Accepted deviations and S2 backlog are documented in the plan's "Deviations discovered during execution" section (notably: per-run prompt assembly deferred — scaffold constants are test-pinned; compiler stays permissive on unregistered silo names while the eval path fails loudly — to be decided before S2 ships a custom build hook).

Test plan

  • Full suite: 356 passed, 3 xfailed (pre-existing), key-free/offline — existing test files untouched.
  • New coverage: registry unit tests, builtin consulted fns, golden prompt characterization, compiler hook tests with a synthetic silo type, entry-point loading incl. broken-pack containment and builtins-win ordering.

🤖 Generated with Claude Code

rinaldofesta and others added 9 commits July 17, 2026 18:09
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
- SiloRegistry.is_registered() checks the local dict without triggering
  ensure_entry_points_loaded(), so builtin registration at import time
  no longer eagerly loads third-party entry points (which could
  silently shadow crm/docs if a pack declared the same name).
- ensure_entry_points_loaded() now wraps each entry point's load/
  normalize/register in try/except, logging and skipping broken or
  colliding packs instead of letting one bad entry point poison the
  registry for the rest of the process.
- register_builtins() now guards with is_registered() instead of
  names(), restoring "built-ins win" semantics.

Covering tests added to tests/test_silo_registry.py and
tests/test_silo_builtins.py for lazy loading, error containment, and
builtin-wins-over-entry-point precedence.
Add "Extending: adding a silo type" README section covering the
SiloType dataclass, the tessera.silo_types entry-point group, and
lazy discovery — including the per-entry-point error containment
(broken packs are skipped with a logged warning) added in the
registry review fix.
Remove dangling reference to a gitignored process file in a builtin
silo comment, document the plugins key in build_artifacts' docstring,
and note in the README that silo-type entry points may also load to
an iterable or a zero-arg callable factory.
@rinaldofesta
rinaldofesta merged commit 388fdf8 into main Jul 17, 2026
6 checks passed
@rinaldofesta
rinaldofesta deleted the feat/silo-registry branch July 17, 2026 17:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant