kernex-core
Foundation types, traits, and error handling for the Kernex AI agent runtime.
This crate is the dependency-free root of the workspace. It defines:
ProviderandHookRunnertraits — the integration points every other crate builds onContext,Request,Response,CompletionMeta— the shared message typesKernexError— the unified error enumPermissionRules— declarative tool allow/deny patternsGuardrailRunner— pre/post-message safety hooks- Built-in helpers for sanitization, pricing tables, and UTF-8 boundary handling
You usually do not depend on kernex-core directly. Pull in kernex-runtime (or the kernex umbrella) and its public surface re-exports what you need.
Documentation
- API reference: https://docs.rs/kernex-core
- Project overview: https://github.com/kernex-dev/kernex
License
Apache-2.0 OR MIT.