Expand description
Team rules for every agent of a vault (rc4-69).
A team decision reaches agents only after a person’s “Send to agents”
(owner decision rc3-69). The Cloud records that send on the decision
itself: each entry of GET /v1/vaults/{id}/decisions carries sent_at,
set by the confirmed send of an active decision and cleared by the Cloud
on every later change of its status, title, statement or successor (a
decision made by supersede starts unsent). Each knowledge sync (pull)
lists the vault’s decisions and keeps exactly the entries that are
active with a sent_at, with the text of that same entry: in
decisions-cache.json for the session briefing (briefing) and as
facts in the project knowledge of each linked root (category
cloud/{ns}/{name}, tag cloud-repo:@ns/name@d), so ctx_knowledge
recalls them in any agent.
An older Cloud lists no sent_at. Only then the local record of the
decision.changed frames (note_sent, decisions-sent.json) decides:
an active decision that was sent as active and not edited since
(updated_at pinned at first sight). Both state files are changed only
under their lock and re-read inside it.
The text is other members’ content: it is stored and delivered inside the X5 wrapper, labelled as a team rule, and bounded in length. Output is deterministic (ordered by id, no time or counter).
Structs§
- Team
Rule - One team rule as it is delivered.
Constants§
- MAX_
BRIEFED - Team rules a session briefing names at most.
Functions§
- briefing
- The team rules of the vault
project_rootis linked to, for the session briefing: the largest block of at mostMAX_BRIEFEDrules thatfitsaccepts. From the local cache only; never waits for the Cloud. - note_
sent - Record a
decision.changedframe: the decision was sent to agents (or its sent status changed). Used only when the Cloud lists nosent_at; kept for vaults linked on this machine only. - pull
- Sync the vault’s team rules: list its decisions, keep the sent active
ones, and store them for the briefing and the project knowledge.
Returns how many there are when they changed,
Noneotherwise. When this machine may no longer list them (403, 404), the rules kept from earlier syncs are removed.