Commit Graph
62 Commits
Author SHA1 Message Date
sam 8bcd89e050 fix(gateway): name a plan wait's workflow from its run, not the next one
workflow.approve pre-writes the task's workflow column with the workflow
that runs once approved, so task_list named a workflow that had not
started while the task's own log named the one that produced the plan.
Chat now names the compiled workflow through the pinned definition for a
plan wait, matching the log.
2026-10-26 18:32:25 +11:00
sam 660e97f87e fix(taskactions): let the operator chat act on every task, like the dashboard
A chat profile bound to the operator identity passed a strict scope to the
action gate, so it refused root-owned tasks whose identity is the daemon's
empty sentinel (task 22: belongs to "", not "d898c8c8-..."). The dashboard
acts with a nil scope and the chat read paths already treat the operator as
acting across identities, so the write gate was the only surface that disagreed.

Exempt the operator identity from the scope comparison and share that rule with
the chat adapters that had their own copy.
2026-10-26 18:24:47 +11:00
sam 97655323b9 refactor(logging): log with the caller's context so records carry trace ids 2026-10-25 23:30:01 +11:00
sam 4b7e843ead feat(servicekit): OpenTelemetry tracer provider and RPC propagation 2026-10-25 23:11:03 +11:00
sam 74b11b331d feat(natsrpc): propagate trace context across NATS and into task runs 2026-10-25 23:03:55 +11:00
sam 29a2a782c9 refactor(controlplane): move the store-backed server out of internal/app 2026-10-25 22:49:27 +11:00
sam 5f3cceb940 feat(modelloop): run a step's tool calls in parallel as each tool's classification allows 2026-10-25 16:45:34 +11:00
sam 5c922038f9 fix(access): check the policy version before each decision
archied, archie-ui and the tool gateway re-read the stored policies on a 30s
ticker, so a forbid written seconds earlier did not stop a run. One
instance-wide revision now moves inside the transaction of every policy write,
and a decision reads it first and rebuilds the engine only when it moved.

A version read that fails, or a policy list that fails after a bump, refuses
with ErrChainUnavailable instead of standing on the last chain, so three call
sites now treat unavailable as availability rather than denial: dispatch leaves
the capture for the next cycle, a task start parks transient, and the tool
gateway reports the tool as unavailable.
2026-10-25 16:21:01 +11:00
sam 4719b9cf00 feat(chat): show each tool call where it happened in the reply 2026-10-24 20:48:43 +11:00
sam c6c4f36a09 feat(gateway): record how long each chat tool call took and show it per row 2026-10-24 20:44:40 +11:00
sam 7140af08d8 fix(archiegateway): confine non-operator chat identities to their own tasks 2026-10-22 17:32:55 +11:00
sam 72929c36af fix(archiegateway): create the chat workspace before enabling its tools 2026-10-19 11:15:20 +11:00
sam b9e2855a56 fix(gateway): chat acts as the control-plane operator and sees every task 2026-10-19 11:12:34 +11:00
sam aadeac9221 feat(gateway): read instructions and access policies from the workflow tools
settings_get now reads three more kinds:
- soul, the instruction text layered into a workflow run;
- task-policy, the diff cap and alert delivery settings;
- org-model-policy, which models an org may use.

None of them holds a secret value: task-policy's notify_secret and the
secrets elsewhere in the readable kinds are SecretRef references (engine and
key), never the resolved value.

access_policies_list is new: the caller org's Cedar policies (id, level,
scope, text), and the instance policies when the caller owns the instance,
which is what the dashboard lists for the same read. It is guarded as
access.ActionRead on access.KindPolicy, the check the dashboard makes.
IntegrationSource gained Policies, implemented over the State Store's
ListPolicies.

workflow_get now says how its instructions field layers: after the
instance's and the organisation's, before the repository's.
2026-10-18 02:39:25 +11:00
sam aea236b60b fix(gateway): workflow and integration tools ask the access policies as their caller 2026-10-18 02:35:59 +11:00
sam 8b3d7864ba feat(gateway): workflow and integration tools for chat and Kit harnesses alike 2026-10-18 02:32:30 +11:00
sam 3f553bb6f2 feat(kit): central tools for harnesses through the egress proxy and gateway task-tool RPCs 2026-10-17 23:42:37 +11:00
sam 51145eda78 refactor(servicekit): stop linking the State Store and control plane into archie-messaging 2026-10-17 17:22:53 +11:00
sam 5c8e8b0fcb refactor(archied): discover issues through organisation connections 2026-10-17 13:38:46 +11:00
sam 2ec8c1c684 fix(e2e): recover reliable local stack startup 2026-10-16 22:25:49 +11:00
sam 78e162fa0a refactor: remove personas
Personas were a misread requirement: SOUL is the chat identity and
identities are per action. The selected persona's prompt never reached the
model. Drops the resource, /personality, the chat selector, the settings
page and ChatService.SetPersona, and deletes stored persona documents.
2026-10-16 03:57:08 +11:00
sam 94aed042c9 feat(gateway): chat reads workflows and validates drafts
workflow_list, workflow_get and workflow_step_types read the org's
definitions and step catalog; workflow_validate runs the editor's save
check on a proposed definition without saving it.
2026-10-16 03:46:27 +11:00
sam f2a30cc9f2 fix(rpc): bound gRPC servers and return listener failures
Cap concurrent streams, the handshake and dead peers' streams on every
service, drain shutdown for at most 10s, and stop messaging when its
listener dies instead of running on without Deliver.
2026-10-16 02:57:26 +11:00
sam d3e2a67222 feat(identity): add browser setup and user accounts 2026-10-16 02:41:24 +11:00
sam 53c95038de feat(rpc): mTLS between services from operator-issued certificates
Replace the service bearer tokens with [tls] ca_file and cert_dir. Caller
identity comes from the verified certificate, not metadata. Without TLS,
services listen and dial on loopback only. Task containers get only the CA
and keep their grant.
2026-10-16 02:37:51 +11:00
sam d45385652c fix(gateway): isolate model selections by org 2026-10-14 21:19:34 +11:00
sam 5e653def04 fix(gateway): restore provider model selection in chat
Restore provider groups and concrete model references in chat snapshots. Permit catalog selections while retaining named aliases and tenant model restrictions. Show the active model in /profile without requiring a task identity.

Refs: archie-core-mvek6
2026-10-14 21:03:30 +11:00
sam bbbb527721 feat(webui): finish redesign dashboard task and secret settings 2026-10-13 16:41:35 +11:00
sam 4babf0f887 fix(servicekit): report apply status only for kinds the process re-applies live
Issue: archie-core-mt91
2026-10-13 15:28:43 +11:00
sam 3edbd6b0a7 feat(releaseupdate): transactional self-update through archied (#1633)
archied update install verifies the release zip, checks every binary
reports the release, pulls the agent image by digest, backs up the
database in-process and stages the binaries before handing off to
archied update watchdog in its own process. The watchdog restarts units
in release order, requires archied healthy for 120s and otherwise rolls
back binaries and image policy, restoring the database only when a
migration ran. Boot recovery resumes the frozen watchdog.

Deletes scripts/archie-update-install, scripts/archie-update-watchdog,
the updater's --from-source and --auto, CommandInstaller,
ScriptInstaller and the update-image and update-topology subcommands.
2026-10-12 03:21:02 +11:00
sam c185499167 feat(archiegateway): chat resolves models in the caller's org and bills it
The State Store answers the calling principal's org aliases
(CallerModels) and bills chat usage to that org; usage records no longer
carry a caller-named org. Chat lists and resolves aliases for the
caller's org and fails rather than substitute one it may not use.
2026-10-10 18:53:57 +11:00
sam 9754e49e2a feat(statestore): record a usage row for every model call
Task agent runs and MCP sampling record against their task (billed to the
task's org); gateway chat turns, titles, sampling and curators record
against the system org. Rows carry source, workflow, step, alias,
provider/model and tokens for later chargeback.
2026-10-10 18:32:43 +11:00
sam 384778e97b feat(config): model aliases replace model roles, resolved by one resolver
Agent steps, implement, pr-review, MCP sampling, chat, embedding and
transcription resolve a model alias (empty means the purpose's default)
and fail on an unknown alias instead of falling back. The step editor and
chat pick aliases; workflow definitions naming an unknown alias are
refused on save.
2026-10-10 17:29:52 +11:00
sam fc0f1dfe1b fix(archiegateway): keep the chat model list non-nil when empty 2026-10-10 11:17:37 +11:00
sam 6096f28528 refactor: slices.Sorted over map keys and one shared IsNil check 2026-10-10 11:14:36 +11:00
sam 45e908374b feat(logging): aggregate recent service logs in dashboard 2026-10-09 09:57:57 +11:00
sam 32f69a60fc fix(gateway): attribute chat settings to signed-in users 2026-10-09 09:57:57 +11:00
sam dd203997a8 fix(gateway): read task logs through state store 2026-10-09 09:57:57 +11:00
sam 88760b8d5a feat(curators): edit and apply definitions live 2026-10-09 09:57:56 +11:00
sam 6f612befb7 feat(settings): show resource consumers and apply status 2026-10-09 09:57:56 +11:00
sam 6671f23673 feat(presence): expose service dependency checks 2026-10-09 09:57:56 +11:00
sam 04692fc299 refactor(tools): back generate_video with ai-sdk's minimax video provider
Delete the hand-rolled MiniMax HTTP/poll client; ai-sdk v0.1.43 already
ships provider/minimax implementing video.Provider with the same endpoints,
defaults and poll semantics. The tool now takes a video.Provider and the
composition root builds it, matching the transcription and embedding
capabilities.
2026-10-08 22:42:49 +11:00
sam 2ca594f4c6 feat(chat): the dashboard chat records voice, downloads files a turn sends, and offers /model and /personality choices 2026-10-08 01:37:21 +11:00
sam bcc72f833d fix(gateway): providers resolve again when a secret engine starts after boot 2026-10-08 01:34:55 +11:00
sam 8a6be33a51 feat(controlplane): update commands are an update-settings kind edited on Status, defaulting to the installed scripts 2026-10-07 00:57:01 +11:00
sam c56344ea41 feat(telegram): /stop stops the chat agent, else the tasks it created, or one task; delete the dead approval actions 2026-10-06 01:12:28 +11:00
sam 27b16603ff fix(modelloop): mark reasoning models from the carried model limits, in the gateway and the agent worker 2026-10-06 00:57:20 +11:00
sam d208416e96 fix(modelloop): feed the cached model catalog to the runtime so reasoning models get the right token parameter 2026-10-06 00:45:09 +11:00
sam c660857a91 fix(archiegateway,agentexec,agentworker): rely on ai-sdk reasoning token selection
Bump github.com/samcharles93/ai-sdk v0.1.40 -> v0.1.41. ai-sdk now sends
max_completion_tokens for reasoning models and omits temperature when the
model rejects it, so the max_tokens workarounds are no longer needed: the
chat-turn bound is set directly and MCP sampling loses its reasoning
branch. Classic models keep their existing bounds.
2026-10-05 22:56:48 +11:00
sam 361a2ca136 fix(controlplane): report watch outages and align live/restart kind labels 2026-10-05 21:39:07 +11:00