System Overview
Home · Generic Index · Chain Overlays
This document provides the highest-level architecture view of the Credible Layer system as implemented in this workspace.
It combines the docs in phylax-docs/ with code-level findings across each repository.
System Context
Key Relationships
credible-sdkprovides the Assertion Enforcer sidecar, Assertion DA, PCL CLI, and assertion execution components.credible-layer-besu-pluginintegrates Besu with the sidecar using the TransactionSelectionService hook and JSON-RPC or gRPC transports.credible-layer-dappcontains the Next.js dApp, ts-rest API, Inngest background jobs, Ponder indexer, and Supabase data model.invalidating-traceis an external tracer service that the dApp calls to produce Foundry debug traces for incident investigations.phylax-docsprovides architectural references (system overview + OP Stack integration) aligned with the code.- The dApp integrates with external services (Airtable for manual verification, Slack/PagerDuty for incident notifications).
linea-monorepoprovides the Linea sequencer plugins used alongside the Credible plugin in Besu.
Primary Flows (Summary)
- Assertion authoring:
pclbuilds and stores assertion bytecode in Assertion DA, then submits assertions to the dApp. The dApp deploys registry updates on-chain (State Oracle). - Assertion indexing: Sidecar indexer monitors State Oracle events and pulls assertion bytecode from Assertion DA into the local assertion store for enforcement.
- Transaction enforcement: Block builders send transactions to the sidecar during block production; sidecar executes assertions via PhEVM and responds with allow/reject decisions.
- Incident reporting: When assertions fail, the sidecar emits incident reports to the dApp API, which processes them asynchronously via Inngest and stores in Supabase. Notification jobs can forward alerts to Slack/PagerDuty.
- Debug tracing: Inngest triggers a trace request to the tracer service; tracer callbacks return trace output to the dApp API for storage and UI display.
- Ops automation: Inngest jobs track enforcer status, prune history, check chain landing events, and orchestrate staging cleanup via admin wallet transactions.
Next: dive into the runtime enforcement architecture in docs/generic/credible-layer-runtime.md.