|
Entropic 2.14.3
Local-first agentic inference engine
|
Engine handle struct — owns all subsystems. More...
#include </home/runner/work/entropic/entropic/src/facade/engine_handle.h>

Public Attributes | |
| entropic::HookRegistry | hook_registry |
| Hook dispatch. | |
| std::mutex | api_mutex |
| Serializes API calls. | |
| std::string | last_error |
| Per-handle error message. | |
| std::atomic< bool > | configured {false} |
| True after configure() | |
| std::atomic< bool > | running {false} |
| True during run() | |
| int | log_id = 0 |
gh#59 (v2.3.1): unique handle id for per-handle log routing via entropic::log::HandleAwareSink. | |
| entropic::ParsedConfig | config |
| Parsed config. | |
| entropic::config::BundledModels | bundled_models |
| Model registry. | |
| std::unique_ptr< entropic::ModelOrchestrator > | orchestrator |
| Model pool + routing. | |
| entropic::InferenceInterface | inference_iface |
| Stable copy for validator lifetime. | |
| entropic::InterfaceContext * | inference_iface_ctx = nullptr |
| Per-handle owned context backing inference_iface.user_data. | |
| std::unique_ptr< entropic::ServerManager > | server_manager |
| MCP server lifecycle. | |
| std::unique_ptr< entropic::ToolExecutor > | tool_executor |
| Tool dispatch. | |
| std::unique_ptr< entropic::IdentityManager > | identity_manager |
| Identity lifecycle. | |
| std::unique_ptr< entropic::MCPAuthorizationManager > | mcp_auth |
| Per-identity tool auth. | |
| std::map< std::string, std::unique_ptr< EntropicWorkspace > > | workspaces |
| gh#166: named workspaces, by name. | |
| std::map< std::string, std::string > | session_workspace |
| gh#166: session key → workspace name. | |
| std::mutex | workspace_mutex |
| gh#166: guards both maps above. Held for lookups only. | |
| std::unique_ptr< entropic::AgentEngine > | engine |
| Agentic loop (owns conversation state) | |
| std::unique_ptr< entropic::SqliteStorageBackend > | storage |
| SQLite persistence. | |
| std::unique_ptr< entropic::AuditLogger > | audit_logger |
| Audit log. | |
| std::unique_ptr< entropic::SessionLogger > | session_logger |
| Model transcript log. | |
| std::unique_ptr< entropic::ConstitutionalValidator > | validator |
| Constitutional validation. | |
| std::unique_ptr< entropic::CompactorRegistry > | compactor_registry |
| Compaction strategies. | |
| std::unordered_map< std::string, std::vector< std::string > > | tier_allowed_tools |
| Per-tier allowed_tools from identity frontmatter. | |
| std::unordered_map< std::string, std::vector< std::string > > | tier_validation_rules |
| Per-tier validation_rules from identity frontmatter (v2.0.6). | |
| std::unique_ptr< entropic::ExternalBridge > | external_bridge |
| Unix socket MCP bridge. | |
| std::unique_ptr< entropic::http::HttpListener > | http_listener |
| Streamable-HTTP front end for external_bridge (gh#204). | |
| void(* | stream_observer )(const char *, size_t, void *) = nullptr |
| Global stream observer — fires for all streaming output. | |
| void * | stream_observer_data = nullptr |
| Observer user_data. | |
| void(* | state_observer )(int, void *) = nullptr |
| Observer for engine state transitions. | |
| void * | state_observer_data = nullptr |
| void(* | queue_observer )(const char *, size_t, void *) = nullptr |
| Observer fired when a queued mid-gen user message is consumed and seeded as the next turn. | |
| void * | queue_observer_data = nullptr |
| void(* | critique_start_cb )(void *) = nullptr |
| Fires before the constitutional validator's critique generate begins. | |
| void(* | critique_end_cb )(void *) = nullptr |
| Fires after the critique generate returns. | |
| void * | critique_cb_data = nullptr |
| Forwarded to both callbacks. | |
| ent_path_approval_cb | path_approval_cb = nullptr |
| Consumer's approver for filesystem access outside the root. | |
| void * | path_approval_data = nullptr |
| Forwarded to the approver. | |
| std::mutex | path_approval_mutex |
| Guards the pair above: the thunk reads it from run threads while the setter may write it from any thread. | |
Engine handle struct — owns all subsystems.
The public C API casts entropic_handle_t to/from this struct. Members are grouped by the phase that wires them.
Definition at line 108 of file engine_handle.h.
| std::mutex entropic_engine::api_mutex |
Serializes API calls.
Definition at line 111 of file engine_handle.h.
| std::unique_ptr<entropic::AuditLogger> entropic_engine::audit_logger |
Audit log.
Definition at line 159 of file engine_handle.h.
| entropic::config::BundledModels entropic_engine::bundled_models |
Model registry.
Definition at line 123 of file engine_handle.h.
| std::unique_ptr<entropic::CompactorRegistry> entropic_engine::compactor_registry |
Compaction strategies.
Definition at line 164 of file engine_handle.h.
| entropic::ParsedConfig entropic_engine::config |
Parsed config.
Definition at line 122 of file engine_handle.h.
| std::atomic<bool> entropic_engine::configured {false} |
True after configure()
Definition at line 113 of file engine_handle.h.
| void* entropic_engine::critique_cb_data = nullptr |
Forwarded to both callbacks.
Definition at line 207 of file engine_handle.h.
| void(* entropic_engine::critique_end_cb) (void *) = nullptr |
Fires after the critique generate returns.
Definition at line 205 of file engine_handle.h.
| void(* entropic_engine::critique_start_cb) (void *) = nullptr |
Fires before the constitutional validator's critique generate begins.
Stored on the handle so pre-configure registration survives validator reconstruction (the rewire_critique_callbacks helper re-applies the slot to any newly-built ConstitutionalValidator).
Definition at line 203 of file engine_handle.h.
| std::unique_ptr<entropic::AgentEngine> entropic_engine::engine |
Agentic loop (owns conversation state)
Definition at line 157 of file engine_handle.h.
| std::unique_ptr<entropic::ExternalBridge> entropic_engine::external_bridge |
Unix socket MCP bridge.
Definition at line 173 of file engine_handle.h.
| entropic::HookRegistry entropic_engine::hook_registry |
Hook dispatch.
Definition at line 110 of file engine_handle.h.
| std::unique_ptr<entropic::http::HttpListener> entropic_engine::http_listener |
Streamable-HTTP front end for external_bridge (gh#204).
Declared AFTER it so it is destroyed FIRST: it dispatches into the bridge.
Definition at line 176 of file engine_handle.h.
| std::unique_ptr<entropic::IdentityManager> entropic_engine::identity_manager |
Identity lifecycle.
Definition at line 135 of file engine_handle.h.
| entropic::InferenceInterface entropic_engine::inference_iface |
Stable copy for validator lifetime.
Definition at line 127 of file engine_handle.h.
| entropic::InterfaceContext* entropic_engine::inference_iface_ctx = nullptr |
Per-handle owned context backing inference_iface.user_data.
Pre-v2.2.6 this was a process-global static — gh#58 follow-up.
Definition at line 130 of file engine_handle.h.
| std::string entropic_engine::last_error |
Per-handle error message.
Definition at line 112 of file engine_handle.h.
| int entropic_engine::log_id = 0 |
gh#59 (v2.3.1): unique handle id for per-handle log routing via entropic::log::HandleAwareSink.
Monotonic 1.. (0 is reserved for "no handle scope"). Set in entropic_create.
Definition at line 119 of file engine_handle.h.
| std::unique_ptr<entropic::MCPAuthorizationManager> entropic_engine::mcp_auth |
Per-identity tool auth.
Definition at line 136 of file engine_handle.h.
| std::unique_ptr<entropic::ModelOrchestrator> entropic_engine::orchestrator |
Model pool + routing.
Definition at line 126 of file engine_handle.h.
| ent_path_approval_cb entropic_engine::path_approval_cb = nullptr |
Consumer's approver for filesystem access outside the root.
Stored on the handle so pre-configure registration survives server construction; the default server set's FilesystemServer holds a facade thunk that reads this slot per call. Workspaces never do.
Definition at line 214 of file engine_handle.h.
| void* entropic_engine::path_approval_data = nullptr |
Forwarded to the approver.
Definition at line 215 of file engine_handle.h.
| std::mutex entropic_engine::path_approval_mutex |
Guards the pair above: the thunk reads it from run threads while the setter may write it from any thread.
Definition at line 218 of file engine_handle.h.
| void(* entropic_engine::queue_observer) (const char *, size_t, void *) = nullptr |
Observer fired when a queued mid-gen user message is consumed and seeded as the next turn.
Stored on the handle so pre-configure registration survives engine construction.
Definition at line 194 of file engine_handle.h.
| void* entropic_engine::queue_observer_data = nullptr |
Definition at line 195 of file engine_handle.h.
| std::atomic<bool> entropic_engine::running {false} |
True during run()
Definition at line 114 of file engine_handle.h.
| std::unique_ptr<entropic::ServerManager> entropic_engine::server_manager |
MCP server lifecycle.
Definition at line 133 of file engine_handle.h.
| std::unique_ptr<entropic::SessionLogger> entropic_engine::session_logger |
Model transcript log.
Definition at line 160 of file engine_handle.h.
| std::map<std::string, std::string> entropic_engine::session_workspace |
gh#166: session key → workspace name.
A key that is absent resolves to the default workspace, so every existing consumer — which binds nothing — is unaffected.
Definition at line 152 of file engine_handle.h.
| void(* entropic_engine::state_observer) (int, void *) = nullptr |
Observer for engine state transitions.
Forwarded to engine callbacks so bridge async tasks can project VERIFYING → "validating"/"revising" phases.
Definition at line 187 of file engine_handle.h.
| void* entropic_engine::state_observer_data = nullptr |
Definition at line 188 of file engine_handle.h.
| std::unique_ptr<entropic::SqliteStorageBackend> entropic_engine::storage |
SQLite persistence.
Definition at line 158 of file engine_handle.h.
| void(* entropic_engine::stream_observer) (const char *, size_t, void *) = nullptr |
Global stream observer — fires for all streaming output.
Definition at line 180 of file engine_handle.h.
| void* entropic_engine::stream_observer_data = nullptr |
Observer user_data.
Definition at line 181 of file engine_handle.h.
| std::unordered_map<std::string, std::vector<std::string> > entropic_engine::tier_allowed_tools |
Per-tier allowed_tools from identity frontmatter.
Definition at line 168 of file engine_handle.h.
| std::unordered_map<std::string, std::vector<std::string> > entropic_engine::tier_validation_rules |
Per-tier validation_rules from identity frontmatter (v2.0.6).
Definition at line 170 of file engine_handle.h.
| std::unique_ptr<entropic::ToolExecutor> entropic_engine::tool_executor |
Tool dispatch.
Definition at line 134 of file engine_handle.h.
| std::unique_ptr<entropic::ConstitutionalValidator> entropic_engine::validator |
Constitutional validation.
Definition at line 163 of file engine_handle.h.
|
mutable |
gh#166: guards both maps above. Held for lookups only.
Definition at line 154 of file engine_handle.h.
| std::map<std::string, std::unique_ptr<EntropicWorkspace> > entropic_engine::workspaces |
gh#166: named workspaces, by name.
The DEFAULT workspace is server_manager above and is not in this map.
Definition at line 148 of file engine_handle.h.