Softanza
StartFrançais
Softanza
The library documents itself · Agents & conversation

stzAgentHost

46 own methods · 4 forms written with extensions, listed under their method

the source: base/agentic/stzAgentHost.ring(opens in a new tab) · All classes · The area reference: Agents & conversation

Under each method, its extensions (Q CS XT Z ZZ IB W U): bold and ticked, it exists; struck, it does not. The extensions and what they mean

No method of this class is run on this page: the class reaches files, the network, processes, the clock, chance or sound, and an example run here would only be an example of its effects. Each method carries the explanation the library gives of itself.

Method
Explanation, as the source carries it
init
(no comment in the source: the name reads as a sentence) initno extension
SetReactor
Share another host's loop (e.g. an stzAppServer's) instead of owning one -- "the agent host is the same host".no extension
ReactorQ
(no comment in the source: the name reads as a sentence) reactor qno extension
Why
(no comment in the source: the name reads as a sentence) whyno extension
SetRetirementGovernance
The governance whose decommission contract gates Retire(). NOTE: the stored @oGov is a COPY (governance is pure Haro lists -- no shared engine handle), so the decommission contract MUST be declared and fulfilled THROUGH THE HOST (below), which mutates this live copy. Fulfilling on the caller's original would leave the host's copy stale (the Haro aliasing doctrine).no extension
DeclareDecommission
Declare an agent's decommission obligations (retirement is earned only once all are fulfilled).no extension
FulfillObligation
Fulfill one obligation (mutates the host's live governance copy).no extension
GovernanceQ
(no comment in the source: the name reads as a sentence) governance qno extension
Supervise
supervision ----------------------------------------------------- Register an agent to be ticked every nTickMs. The agent must be fully configured (skills, governance) BEFORE this call.no extension
SuperviseOnEvent
EVENT-DRIVEN supervision (R5 reactor-runtime): tick the agent once per EVENT emitted on pcChannel (the engine event bus, stzEventBus), not on a timer. The perceive-decide-act loop becomes a true event loop -- the agent reacts to what happens, when it happens. Past events are NOT replayed (the baseline is the channel's current count at registration).no extension
ChannelOf
The channel an agent is event-supervised on ("" if timer-supervised).no extension
NumberOfAgents
(no comment in the source: the name reads as a sentence) number of agentsno extension
NameAt
The nth supervised agent's NAME -- enumeration for an observer (the appserver's /agents surface) that must not hold the agent itself.no extension
IsSupervising
(no comment in the source: the name reads as a sentence) is supervisingno extension
IsActive
(no comment in the source: the name reads as a sentence) is activeno extension
TicksOf
(no comment in the source: the name reads as a sentence) ticks ofno extension
AgentQ
The live supervised agent (reach it here, not via a stale ref).no extension
Trace
(no comment in the source: the name reads as a sentence) traceno extension
UseAgentsFrom
AND THE REFUSALS ARE NOT SWALLOWED. AgentLoadRefusals() carries every file the folder would not admit, in the unified finding shape, and CiteAgentLoadRefusals() prints them. A host that mounted three agents out of five and said nothing is the shape this exists to prevent.QCSXTZZZIBWU
AgentFolderQ
(no comment in the source: the name reads as a sentence) agent folder qno extension
IsUsingAgentFolder
(no comment in the source: the name reads as a sentence) is using agent folderno extension
AgentLoadRefusals
(no comment in the source: the name reads as a sentence) agent load refusalsno extension
CiteAgentLoadRefusals
(no comment in the source: the name reads as a sentence) cite agent load refusalsno extension
RescanAgents
Returns [ :added, :changed, :removed ] -- the file names that moved.no extension
Declare
the engine loop (Zig owns the tick) ----------------------------- Declare an agent's COVERAGE STATEMENT and REVERSIBILITY CLASS -- what law 18 obliges before anything schedules it. Needed only for agents that do not answer CoverageStatement() / ReversibilityClass() themselves; the host asks the agent first.QCSXTZZZIBWU
SetPriority
Higher runs first in a pass. Ties break on registration order, so the order is total and reproducible whether or not priorities are set.QCSXTZZZIBWU
PriorityOf
(no comment in the source: the name reads as a sentence) priority ofno extension
UseEngineLoop
Adopt the Zig loop as this host's pump. Agents already supervised are registered now, so the call order does not matter -- and a refusal raises HERE, carrying the engine's own diagnostic.QCSXTZZZIBWU
UseRingLoop
(no comment in the source: the name reads as a sentence) use ring loopno extension
IsUsingEngineLoop
(no comment in the source: the name reads as a sentence) is using engine loopno extension
EngineLoopWhy
The engine's last refusal, verbatim. A refusal names its code, its subject and what to do -- do not paraphrase it.no extension
EngineSlotOf
The engine slot an agent occupies (-1 when the Haro pump is driving).no extension
TickDue
the perceive-act runtime --------------------------------------- Tick every ACTIVE, non-retired agent whose interval has elapsed: run ONE Cycle() (perceive-decide-act) through the live index. Returns the number of skill-firings verified this pass.no extension
RunFor
Drive the loop for nMs, ticking due agents. The inter-tick wait is a REAL libuv timer awaited on the engine loop thread (falls back to a Haro sleep only when no reactor DLL is present -- LAW 2).no extension
RunToQuiet
Run until every supervised agent reaches fixpoint (a full pass with zero firings) or the cap is hit -- the cascade at host level.no extension
Cancel
cancellation + governed decommission --------------------------- Stop ticking an agent WITHOUT retiring it (reversible pause).no extension
Resume
(no comment in the source: the name reads as a sentence) resumeno extension
SetActionBudget
One agent acting in a loop floods everything downstream of it -- the cascading failure. A budget caps the ACTIONS (skill firings: what causes effects) an agent may take in a sliding window. An agent that exceeds it is QUARANTINED, not merely slowed: a runaway is a containment event, it stays stopped until an effectful actor releases it, and the reason says how far over it went. Both pumps account.no extension
ActionBudgetOf
[ :max, :windowMs, :acts ] -- the acts counted in the current windowno extension
Quarantine
Between a pause and a retirement: the agent stops being run, with the REASON kept, and it stays stopped -- Resume() refuses while it is quarantined. Only Release(), by an effectful, non-sandboxed actor, lifts it. A Cancel is an operator's pause; a quarantine is a containment act.no extension
IsQuarantined
(no comment in the source: the name reads as a sentence) is quarantinedno extension
QuarantineOf
[ :reason, :at ] or [] when the agent is not quarantinedno extension
Release
(no comment in the source: the name reads as a sentence) releaseno extension
Retire
DECOMMISSION (R4b): retirement is EARNED. When a governance is wired, the agent may retire ONLY once every declared obligation is fulfilled (MayRetire). A retired agent stops ticking permanently. Returns TRUE on retirement, FALSE (with Why()) on refusal.no extension
IsRetired
(no comment in the source: the name reads as a sentence) is retiredno extension
Shutdown
teardownno extension