pub struct CapabilityProfile {
pub profile_id: u64,
pub active_engines: Vec<SlgOpcode>,
pub loaded_ontologies: Vec<u64>,
pub preferred_backend: AgentBackend,
pub permitted_intent_frames: Vec<u64>,
}Expand description
A declarative allow-list that constrains what the LLM and Webizen VM are permitted to do within a given session or resource context.
Profiles are identified by a q_hash of their logical name
(e.g. q_hash("profile:health")) and are referenced from
McpIntentFrame::active_profile_id.
Fields§
§profile_id: u64Stable identity hash — e.g. q_hash("profile:phi3-mini-edge").
active_engines: Vec<SlgOpcode>If non-empty, acts as an allow-list mask over CAPABILITY_DESCRIPTORS.
Only the listed SlgOpcode variants may be dispatched in this session.
An empty vec means no engine restrictions apply at the profile layer.
loaded_ontologies: Vec<u64>Ontology namespace hashes actively mapped into the LLM context window
(e.g. q_hash("namespace:Bio2RDF")).
preferred_backend: AgentBackendPreferred inference backend for this profile.
permitted_intent_frames: Vec<u64>If non-empty, any LLM intent declared outside this set is instantly denied by the Webizen VM before the model is invoked.
Implementations§
Source§impl CapabilityProfile
impl CapabilityProfile
Sourcepub fn allows_engine(&self, opcode: &SlgOpcode) -> bool
pub fn allows_engine(&self, opcode: &SlgOpcode) -> bool
Returns true if opcode is permitted by this profile’s engine allow-list.
Sourcepub fn allows_intent(&self, intent_hash: u64) -> bool
pub fn allows_intent(&self, intent_hash: u64) -> bool
Returns true if intent_hash is an allowed intent frame.
Sourcepub fn has_ontology(&self, namespace_hash: u64) -> bool
pub fn has_ontology(&self, namespace_hash: u64) -> bool
Returns true if the requested ontology namespace is actively loaded.
Trait Implementations§
Source§impl Clone for CapabilityProfile
impl Clone for CapabilityProfile
Source§fn clone(&self) -> CapabilityProfile
fn clone(&self) -> CapabilityProfile
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreAuto Trait Implementations§
impl Freeze for CapabilityProfile
impl RefUnwindSafe for CapabilityProfile
impl Send for CapabilityProfile
impl Sync for CapabilityProfile
impl Unpin for CapabilityProfile
impl UnsafeUnpin for CapabilityProfile
impl UnwindSafe for CapabilityProfile
Blanket Implementations§
§impl<S, A> Aggregate<Result<S, Error>> for Awhere
A: Aggregate<S>,
impl<S, A> Aggregate<Result<S, Error>> for Awhere
A: Aggregate<S>,
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more