API Reference scoria v#0.1.0

Copy Markdown View Source

Modules

Public facade for Phoenix-hosted Scoria runtime integration.

Single source of truth for adopter-facing README and support-doc contracts.

Summarizes uncompacted workflow events into durable compacted memories.

Lightweight token estimator used by the compaction worker.

Thin connector read-model helpers for the embedded operator surface.

Browser redirect auth flow handling for remote connectors.

Minimal PKCE-style state envelope for connector auth redirects.

Lightweight post-auth hook placeholder for connector grant refresh work.

Replay-aware connector invocation that gates remote tool execution before reaching the MCP executor.

The Eval context for managing datasets, evaluation specs, and runs.

Durable worker envelope for one eval campaign target shard.

Builds frozen workflow-source dataset item snapshots and inserts them immutably.

Canonical runtime identity envelope and Phoenix-edge adapters.

Canonical installer contract: planner classifications, operator projection, automation trailer prefix, and default verify command.

Persists and loads .scoria/install/manifest.json as the last-applied install snapshot.

Builds install plans from live host surface analyzers.

Durable knowledge context for corpus ingestion, retrieval, citations, and grounding.

Executes MCP tools in an isolated Task with strict timeouts. Emits telemetry events for auditing.

JSON-RPC 2.0 parsing and formatting for the MCP Gateway.

Plug router for handling incoming MCP (Model Context Protocol) JSON-RPC 2.0 requests.

Behaviour for defining an MCP tool.

Validates arguments against a tool's defined schema.

Utility for scrubbing sensitive data (PII, secrets, API keys) from telemetry events.

Recursive fallback mechanism for LLM requests.

Canonical public prompt-policy noun for runtime defaults and governance.

The PromptRegistry context for managing prompt templates and their lifecycle.

Stateless utility module for accurately estimating token usage of prompt templates. Uses Tiktoken under the hood to ensure operators are warned before hitting context limits.

Provides the attach/2 function to add Scoria's resiliency and model routing steps to a Req pipeline.

Req request step that checks the circuit breaker state before executing the request.

Req response and error steps that track successes and failures in the circuit breaker.

Advanced runtime lifecycle and inspection APIs behind the Scoria facade.

Resolves baseline and identity-aware runtime defaults exactly once.

Normalizes public runtime inputs into explicit start and resume contracts.

Middleware that enforces release gating rules before a run is executed. Specifically prevents draft prompts from being served in production paths.

Builds curated original-versus-replay evidence maps for workflow steps.

Curated public detail DTO for advanced run inspection.

Stable public summary DTO for lifecycle, polling, and resume flows.

Public Phase 7 context boundary for runtime governance, alerts, incidents, and audit export.

Optional Chimeway-facing alert adapter.

Optional Mailglass-facing alert adapter.

Translates Scoria telemetry envelopes into dependency-free Parapet-facing maps.

Optional Threadline-facing audit adapter.

Behavior for optional alert delivery sinks.

Behavior for optional audit export sinks.

Integration-scoped Fuse helpers for external-effect boundaries.

Budget reservation and loop-guard decisions for workflow and MCP execution.

Routes alert envelopes into durable incidents, alert rows, and append-only incident events.

Supervised durable fanout worker for audit outbox rows and notification deliveries.

Public Phase 7 telemetry helpers for SLI and breaker evidence.

Builds the canonical low-cardinality SRE identity contract.

Durable semantic-cache context for persisted reusable answers and lifecycle events.

Compatibility helpers for conservative semantic-cache reuse.

Conservative semantic-cache eligibility and scope derivation.

Transactional stale and invalidation state transitions for semantic-cache entries.

Exact-text-first semantic lookup with conservative compatibility checks.

Public semantic-lane contract for explicit semantic-cache admission.

Canonical verification lane contract for adopter-facing and maintainer-facing proofs.

Parses .planning/WARNING-BASELINE.md accepted warning debt rows for executable expiry enforcement.

Parses and classifies compiler warning output for maintainer inventory runs.

Stable cluster registry for compiler warning classification.

SSOT for high-signal warning-as-errors test paths (WARN-06).

Durable workflow persistence and lifecycle transitions.

Provides bulk chunking and enqueueing of Oban jobs into target queues.

Workflow-owned approval wrapper for sealed dataset baseline promotion.

Optional adapter that translates Jido-style directives into Scoria workflow primitives.

Event-driven workflow service for prompt release approvals.

Startup and transition boundary that finds runnable steps and dispatches them safely.

Curated operator-facing projection for remote approval inbox and lineage reads.

Resolves seam-level replay outcomes from local classification, source evidence, replay approval context, and replay overrides.

Thin recovery entrypoints that reconstruct the next action from durable workflow state.

Executes bounded workflow steps under supervision and persists stable outcomes.

Provides presence tracking for channels and processes.

Provides the scoria_dashboard macro to mount the Scoria LiveView dashboard in a host Phoenix application.

Mix Tasks