Commit Graph
190 Commits
Author SHA1 Message Date
sam e80b18208e feat(connectors): pick a local or remote runtime for every extension
Track 2 of the enterprise readiness plan. Extensions now start through a
Runtime: RemoteGRPCRuntime dials an endpoint the operator mapped, over mTLS for
TCP, and LocalNamespaceRuntime runs the verified binary in its own user and
network namespace. A mapped endpoint is the only runtime that may serve that
extension, so a broken endpoint refuses instead of quietly falling back to a
subprocess.

Local availability is checked instead of assumed: user and network namespace
limits read from /proc/sys/user report a stage that disabled them, which is what
restricted Pod Security Standards and hardened kernels do. A host where the
chosen runtime cannot run refuses the extension and names why both runtimes
declined, so the operator learns to configure a remote endpoint.
2026-11-27 21:04:49 +11:00
sam 6791125aab feat(connectors): add remote gRPC mTLS runtime and default catalogue override 2026-11-27 20:51:52 +11:00
sam 86b89a5957 feat(archie): add container runtime, migrate command, secret files, and proxy egress 2026-11-27 20:36:52 +11:00
sam 95ce309b3a fix(connectors): leave a package with no declared egress on the host's network
Confining it was pointless: the relay the namespace exists for is only started
when egress is non-empty, so the package got loopback and a proxy address
nothing served. Any client honouring the proxy variables then reported a dial
refused at the relay rather than reaching the host it was configured for.

Fixes #2152.
2026-11-27 20:06:45 +11:00
sam 34482c8b0c fix(dashboard): re-read on the live stream instead of polling
Every view listing runs or approvals polled on a timer: the home page made
four requests every five seconds per open tab, two of them the same run list,
and the needs-attention card asked for 200 runs to render five.

A run or an approval request moving is now published on the hub and framed on
the dashboard stream, so those views re-read on the change. A reconnect still
re-reads everything, and the hub drops a reader that falls behind, which ends
its stream and reconnects it.
2026-11-27 19:44:21 +11:00
sam 77e291fdfc fix(governance): report only the dashboard sections that exist (#2147)
#2121 removed the pages behind sixteen sections and both capability handlers
still named them, so GET /api/capabilities advertised sections nothing can
render and the old service probed for pages that are gone.

The single binary now reports an organisation as unavailable (its page exists,
its writes do not) and lists nothing else it has no page for; the old service
reports only the sections and probes its pages still make.
2026-11-27 19:35:01 +11:00
sam fa96ee852c fix(governance): refuse to delete a model alias a saved workflow names (#2097)
The delete refused only a missing alias, so removing the default model, or an
alias a saved workflow still names, succeeded and those workflows failed at
their agent step.

The runs module now reports the saved workflows that give an agent step a
model, treating a step that names none as the default, and the delete is
refused with a conflict that names them. The dashboard already shows a delete's
failure inline beside the alias, so the operator sees which workflows to move
first.
2026-11-27 19:28:13 +11:00
sam a101b64703 fix(runs): a cancelled run's trail records who stopped it (#2100)
Cancelling a run moved it and the runs it called to cancelled and wrote nothing
to either trail, so a stopped run could not say when it stopped or who asked.

The stop now returns the runs it stopped and records one cancel entry on each,
in the same transaction, naming the principal that asked. The entry is a step
named cancel with the caller's identity, so the run detail shows it with the
rest of the trail.
2026-11-27 19:24:19 +11:00
sam 65cd993ee6 fix(events): keep a mapped number's exact text (#2118)
The payload was decoded into float64, so an integer id past 2^53 was rounded
before it reached the run: the event named one record and the run acted on the
one next to it.

The mapping now decodes with json.Number, which marshals back as the exact
digits the event carried, and the type check accepts it for a number field.
2026-11-27 19:18:21 +11:00
sam 27cd2d0df1 fix(memory): reach every note a person may read (#2141)
maxNotes bounds what a conversation is given, and it was also the only bound on
the inspection read a person makes and on the shared list, so past 200 notes of
one class the oldest ones were unreachable, with no total and no offset to say
the list had been cut.

The conversation read keeps the bound. The read of a person's own notes and the
shared list pass no bound, which the store reads as LIMIT NULL, so both reach
everything the caller may read.
2026-11-27 19:16:08 +11:00
sam 35688b449a fix(governance): invite a member by email without an identity provider (#2110)
Adding a member by email refused with a 409 whenever no OIDC issuer was set,
so an install with local accounts only could not invite anyone by address.

An address now reserves the identity under a local issuer instead, and a local
account made with that address adopts it: the invitation's roles carry over and
the organisation shows one member, not two. A provider subject still needs the
provider that asserts it, and the refusal says so.
2026-11-27 19:08:08 +11:00
sam aa3568dd52 fix(memory): refuse a credential written out in prose (#2069)
A note saying "the deploy token is 1234567890abcdef" was neither redacted nor
refused, because the credential check only recognised a value after a colon or
an equals sign. The copula now counts as the separator, so a credential written
out in a sentence is refused the way an assignment is.

The version read is scoped to the organisation as every other note read is, so a
note id from another organisation answers nothing, and the doc comments on
Forget and Revoke describe the order the code actually commits in. The
deletion-recording schema constant had no consumer and is removed.
2026-11-27 18:25:20 +11:00
sam 368d484410 test(memory): cover the shared half of the read boundary (#2069)
The fake's Notes filter modelled only the owner half of store.Notes, so a
regression that stopped sharing published notes would still pass. It now mirrors
the statement, and the test asserts a published note reaches both people, a
proposal reaches neither, and a disabled note is left out of a conversation read.
2026-11-27 18:19:33 +11:00
sam 6356aa5d52 feat(api): filter lists by sys_query
sys_query is conditions joined by ^, each field=value, field!=value or fieldLIKEtext. A bad condition or a field a list does not offer is a 400 naming the fields it accepts, so a typo never reads as an empty page. Runs, workflows, proposals, guards and action types take it, and the dashboard keeps the filter in the URL so a filtered list is a link.

The guard control API is list-guard-controls at /api/controls/guards: list-guards belongs to the connectors extension list, and the resource is a guard. JudgeStanding keeps its name, since it is the model judgement a guard recorded.
2026-11-27 17:06:30 +11:00
sam 6b4ff8101a fix(governance): ask for the public URL during owner setup (#2076) 2026-11-27 02:33:15 +11:00
sam 24a3efcf60 fix(connectors): keep published settings and let admins reset the catalogue (#2119) 2026-11-27 02:29:39 +11:00
sam bc4ac4436d docs(connectors): clarify catalogue and guard comments (#2119) 2026-11-27 02:21:13 +11:00
sam c538017523 fix(connectors): verify the default catalogue and roll back failed updates (#2119)
Adapt OCI reads from internal/infrastructure/signedoci and internal/infrastructure/storepkg. Keep the legacy readers while their callers still use them.
2026-11-27 02:19:21 +11:00
sam 2ea0062bef feat(ui,judgement,system): unify nav, surface built-in guards, readiness and decision reasoning 2026-11-27 02:13:28 +11:00
sam f0f09e9189 fix(events): enforce source ownership for mappings
Quality / check (pull_request) Successful in 10m21s
2026-11-26 20:35:40 +11:00
sam 8bf3ace96b feat(governance,chat): size a model's chat history by its own window (#2018)
The replay budget was fixed at half of an assumed 128k window, so a small
local model was still handed more history than it accepts.

A model now carries the context window and output limit the published
catalogue gives it, read once into the state directory and cached on
disk. Chat holds its replay to the window minus the reply and an eighth
for the system prompt and tools, and keeps the assumed budget only for a
model the catalogue publishes nothing about.
2026-11-26 04:20:11 +11:00
sam 8dd28b90be feat(chat): hold a long conversation inside the model's window (#2018)
A reply was replayed with a fixed twenty earlier turns, so a long
conversation either lost its older context or, with large replies, sent
more than the model accepts and failed the request. The replay now reads
up to two hundred turns and replaces the middle of what it cannot carry
with one summary message, keeping the newest twenty messages and always
the question being answered.

Carried from internal/gateway's compression.go before that package is
retired: the same conservative token estimate (four ASCII characters or
one non-ASCII rune), the same 50%-of-window budget, and a summary that
says what was dropped. The budget is fixed rather than derived from the
model because the module is told a model's name and nothing about its
window.
2026-11-26 04:17:16 +11:00
sam 56dbb31923 build(dev,chat): point dev server at archie and wire chat pages catalogue 2026-11-25 23:05:04 +11:00
sam c9ed3b1ae2 feat(connectors): version packages and pin installations
A package is now a set of immutable versions with declared grants and a
default version that installations run unless they pin another. Adopting a
version is what accepts its grants, replacing the per-extension lifecycle
actions with version, pin and update-policy commands.
2026-11-25 22:10:06 +11:00
sam ba077f3779 fix(events): route webhooks by source UUID (#2127) 2026-11-24 08:07:09 +11:00
sam 26e19f3de4 feat(governance,connectors,ui): identify model providers and keys by UUID (#2129) 2026-11-24 06:52:58 +11:00
sam c5591d95da feat(judgement,approvals): link decisions and approval requests by action_type_id (#2130) 2026-11-24 06:23:19 +11:00
sam 1c10378a40 refactor(events,proposals,runs,ui): rename declared event type fields to declared_event_type (#2128) 2026-11-24 06:19:35 +11:00
sam efe7069bc1 feat(events,proposals,ui): identify triggers by immutable UUID (#2126) 2026-11-24 05:36:52 +11:00
sam 67ce2901a5 feat(runs,events,ui): identify workflows by immutable UUID (#2125) 2026-11-24 05:20:18 +11:00
sam 9c04b74e6f docs: fix Vale prose findings across comments, docs and prompts
Run Vale over every tracked Go, Markdown and template file and fix the remaining findings: long sentences, repetition, UI verbs, identifiers that should be backticked, and migration narration in comments.

AGENTS.md and CLAUDE.md keep their absolute rules; the prompt heuristic against repeated absolutes is disabled for rule files.
2026-11-24 03:26:16 +11:00
sam 911152c9d1 merge: proposals module (#1995)
# Conflicts:
#	internal/platform/pg/migrations/00008_drafts.sql
#	modules/drafts/drafts.go
#	modules/drafts/internal/store/store.go
2026-11-24 03:11:07 +11:00
sam 0d25c93ea0 merge: event source IDs and scopes (#2127, #2027)
# Conflicts:
#	api/openapi.yaml
#	modules/events/events.go
2026-11-24 03:09:12 +11:00
sam f24c2b4455 feat(connectors): separate packages from scoped installations (#2027)
Packages are accepted once by the instance. Installations configure them at the instance, an organisation or a person; bindings and credentials resolve the person's, then their organisation's, then the instance's. Decisions, approval requests and held chat actions record the installation and scope that acted.

The dashboard lists packages separately from installations, shows every installation's scope, and creates, edits and disables installations at their scope.
2026-11-24 03:05:27 +11:00
sam b47e98e25f feat(proposals): add the proposals module and fold drafts and memory proposals into it (#1995) 2026-11-24 02:44:31 +11:00
sam 8265e99466 feat(runs): run an approved proposal's actions in a durable workflow step (#1995) 2026-11-24 02:44:31 +11:00
sam 30aa351eb6 feat(events,drafts): give sources an immutable id and a scope (#2127, #2027)
A source is keyed by a uuid, owned by the organisation or one person, and
labelled within that scope. The webhook path is a separate unique column, so
renaming either leaves stored events, event types, triggers, groups, mappings
and drafts alone. Delivery policies, sealed secrets and group keys use the id.
2026-11-24 02:43:51 +11:00
sam 4a9f30ef04 fix(judgement,runs,approvals): record immutable identity IDs for attribution (#2122) 2026-11-24 02:23:23 +11:00
sam dad6924a0c docs: normalise Australian English and prose across comments and docs 2026-11-24 02:02:00 +11:00
sam de05bc2cbd feat(runs): show each step's summary and target on the run page
- a finished top-level step records its summary and target in a done marker; stages return them
- a message step's summary is the message, and its target the channel and chat
- the trail no longer lists the engine's markers as entries
- run page: short run ID in the breadcrumb, copyable IDs, version badge, step rows from stages, No output for an empty result
- event detail: No payload for an empty body, and links only the dispatches that started a run
- ui/AGENTS.md lists the components that exist
2026-11-24 00:04:20 +11:00
sam 2bfb262e9c docs(judgement,events): state comments plainly 2026-11-23 23:46:27 +11:00
sam 0ad4374a2a refactor(judgement): rename action classes to action types and raises to autonomy proposals
- tables judgement.action_types, action_type_resets, action_type_approvals and autonomy_proposals (migration 00063)
- governance setting propose_autonomy_after, approval request kind autonomy, policy resource kind action_type
- /api/action-types replaces /api/classes; the detail lists autonomy_proposals
- an autonomy proposal stores the identity ID of the account that answered it
2026-11-23 23:43:45 +11:00
sam 7f5220dea3 feat(events): record failed, denied and disabled trigger outcomes (#2117)
- a mapping failure is recorded as failed, with the value found at each mistyped path
- an access policy refusal and a disabled workflow are recorded as denied and disabled
- migration 00062 renames existing skipped dispatches to failed
2026-11-23 23:35:35 +11:00
sam 062336db91 refactor: rename denial records to access decisions
- rename governance.access_denials table, indexes and API types via migration 00061
- expose /api/access/decisions and decisions payload; keep audit auth unchanged
- rename UI store, page and route from denials to decisions
2026-11-23 02:03:35 +11:00
sam 60d9b6b7aa feat: record access decisions, not just denials
- add an outcome column and migration so allowed and denied decisions share one audit trail
- fail closed when an allowed decision cannot be recorded
- expose outcome filtering in the API and dashboard

Route chat through the recording authorizer so its decisions are audited too.
2026-11-23 01:00:46 +11:00
sam e1ada94d78 fix: redact link codes and guard shipped policies
- redact single-use link codes from stored account.link events after handling, with a migration to scrub existing rows
- refuse deletion of shipped org policies and hide the delete action in the UI
- validate agent step models against the workflow model policy at save time, including the default model
2026-11-23 00:38:54 +11:00
sam 8c267b6edd feat: record skipped dispatches and approver ids
- store trigger dispatches as started or skipped, with a JSON reason surfaced in the API and UI
- persist the answering account's identity id beside its display name for approvals and judgements
- save connector acceptances and their declarations in one transaction so a refused change stores nothing
2026-11-22 23:24:30 +11:00
sam 33f7ebdff4 feat: add member candidates endpoint and approvals page
- serve active identities outside the org at /api/orgs/{id}/member-candidates and back the members page from it
- add an org approvals page for default owner, deadline and escalation path over /api/settings
2026-11-22 23:03:01 +11:00
sam e801306c15 docs(deliveries): say what each field, lease and refusal does 2026-11-22 22:31:55 +11:00
sam 4707427759 feat: trust configured proxies for webhook intake
- add trusted proxy settings, migration, API, and UI
- derive client addresses from X-Forwarded-For behind trusted hops
- enforce delivery policy for listener batches and record denials
2026-11-22 22:29:36 +11:00