diff --git a/.beads/interactions.jsonl b/.beads/interactions.jsonl index 183422e1a..4a39b0120 100644 --- a/.beads/interactions.jsonl +++ b/.beads/interactions.jsonl @@ -44,3 +44,5 @@ {"id":"int-56c541cf59441d3b82a65bc0ee53e38c","kind":"field_change","created_at":"2026-08-22T11:55:20.137923996Z","actor":"Sam Catlow","issue_id":"archie-core-1ysw.4","extra":{"field":"status","new_value":"closed","old_value":"in_progress","reason":"Retry refresh now removes all non-HEAD worktree content including ignored output while preserving .git, tracked symlinks, and gitlinks; missing bases fail closed."}} {"id":"int-91757c22c0f3dff173e70e5eeff9447c","kind":"field_change","created_at":"2026-08-22T11:59:36.859035164Z","actor":"Sam Catlow","issue_id":"archie-core-1ysw.5","extra":{"field":"status","new_value":"closed","old_value":"in_progress","reason":"Three-dot diff operations now fail closed when base and HEAD have no common ancestor; regression covers Diff, ChangedFiles, and ChangedLines."}} {"id":"int-2fceaface0b1804f99343a043a446532","kind":"field_change","created_at":"2026-08-22T12:16:02.43722871Z","actor":"Sam Catlow","issue_id":"archie-core-azbo","extra":{"field":"status","new_value":"closed","old_value":"in_progress","reason":"Removed the unwired BasePlatformAdapter, SendResult, ChatInfo, and their test-only stub. CapabilitiesOf is absent from the current checkout/history. Gateway and worktree tests pass. task check passes all packages except the pre-existing tracked agentworker architecture failure archie-core-hqst."}} +{"id":"int-41f3180369b3e3d59287b8b661403433","kind":"field_change","created_at":"2026-08-22T15:03:38.692577153Z","actor":"Sam Catlow","issue_id":"archie-core-1786637493329-136-49b39c78","extra":{"field":"status","new_value":"closed","old_value":"in_progress","reason":"Media portion delivered: gateway.MediaSender + telegramMediaSender + TurnStream.Media wiring in Telegram's liveReply. Typing/edit/delete indicators from this issue's original scope are NOT done -- splitting them out if still wanted, since they're unrelated to the video-gen work that drove this."}} +{"id":"int-46b6d680396e11becb59162374a2ab2d","kind":"field_change","created_at":"2026-08-22T15:34:28.584715451Z","actor":"Sam Catlow","issue_id":"archie-core-3ghy","extra":{"field":"status","new_value":"closed","old_value":"open","reason":"Shipped and verified: task check equivalent (fmt/vet/build/test/lint) is clean across every touched package, red-then-green throughout. See the issue description for what's in scope and what's explicitly deferred."}} diff --git a/.beads/issues.jsonl b/.beads/issues.jsonl index 2f5d78b0f..65d68a106 100644 --- a/.beads/issues.jsonl +++ b/.beads/issues.jsonl @@ -40,6 +40,7 @@ {"_type":"issue","id":"archie-core-g7tm","title":"telegram: finalize the reply through a live context, matching the error branch","description":"The success path calls live.finalize(turnCtx, reply) with the raw cancellable turn context (telegram.go:582), while the error branch two lines above deliberately uses context.WithoutCancel(turnCtx). If /stop lands during finalize, the rich edit, the plain-text retry, and the split-send fallback all abort with context.Canceled (go-telegram/bot builds requests with NewRequestWithContext), so the authoritative reply is never delivered and the live message keeps the ▌ cursor forever. The reply is persisted to the ledger, so the loss is delivery-level — but the user sees a frozen half-answer.\n\nFailure: a long tool-using turn is /stop-ped as it completes; turnCtx is cancelled mid-finalize; every send fails on the dead context; the chat shows the last live frame with a blinking cursor and no final answer.\n\nFound by code-review of PR #476 (feat/467, merged 98e8dda).","design":"live.finalize(context.WithoutCancel(turnCtx), reply) — the one-liner the error branch already uses. Consider making finalize take a live context internally rather than trusting each caller to remember.","acceptance_criteria":"A /stop landing mid-finalize still delivers the authoritative reply and drops the cursor; a test covers the cancellable-context finalize path.","status":"closed","priority":1,"issue_type":"bug","assignee":"Sam Catlow","owner":"sam@catlow.tech","created_at":"2026-08-14T14:43:08Z","created_by":"Sam Catlow","updated_at":"2026-08-14T15:07:36Z","started_at":"2026-08-14T14:53:28Z","closed_at":"2026-08-14T15:03:28Z","close_reason":"Fixed in internal/channels/telegram/live.go and telegram.go: finalize/abandon strip context cancellation before sending (mirroring each other), ToolCall escapes Markdown metacharacters via bot.EscapeMarkdown, splitLongMessage splits on rune boundaries. All new/changed tests verified red-then-green; task check clean; adversarial review pass found no blocking issues.","external_ref":"https://github.com/samcharles93/archie-core/issues/484","labels":["code-review","streaming","telegram"],"dependency_count":0,"dependent_count":0,"comment_count":0} {"_type":"issue","id":"archie-core-tb3a","title":"Fix streaming review blockers for inline tool calls","description":"Resolve the four evidence-gated findings in merged inline tool-call streaming: preserve the authoritative Telegram reply when final edits fail; keep Telegram network I/O off the model FullStream consumer and cancellable; correlate tool inputs with results and render a bounded redacted parameter summary; snapshot show_tool_calls per live reply to avoid reload races. Add regression tests for every path and run task check plus lint/race validation.","acceptance_criteria":"Regression tests fail on the merged implementation and pass after the fix. Final edit failure falls back to normal split delivery. Delta and ToolCall callbacks do not wait on Telegram HTTP and stop cancels in-flight rendering. Completed tool events include bounded redacted parameters correlated by tool-call ID. Reload cannot race an in-flight reply's show_tool_calls setting. task check passes, golangci-lint reports no new findings, and focused race tests pass.","notes":"Implemented in worktree /tmp/archie-core-tb3a on branch fix/archie-core-tb3a. Added cancellable async Telegram rendering, final edit failure fallback through normal split delivery, call-ID-correlated bounded conservative parameter summaries, atomic per-reply show_tool_calls snapshots, SSE/UI parameter rendering, rebuilt ui/dist, and regression tests. Validation: GOFLAGS=-buildvcs=false task check passed; golangci-lint --new-from-rev=HEAD ./... reported 0 issues; focused race suite passed; fresh adversarial reviewer reported PASS with zero findings. Plain task check is blocked in linked worktrees by Go VCS stamping exit 128, hence buildvcs override.","status":"closed","priority":1,"issue_type":"bug","assignee":"Sam Catlow","owner":"sam@catlow.tech","created_at":"2026-08-13T18:05:35Z","created_by":"Sam Catlow","updated_at":"2026-08-14T15:07:36Z","started_at":"2026-08-13T18:05:39Z","closed_at":"2026-08-13T18:35:26Z","close_reason":"Completed and independently reviewed; worktree left uncommitted per conservative repository policy.","external_ref":"https://github.com/samcharles93/archie-core/issues/485","dependency_count":0,"dependent_count":0,"comment_count":0} {"_type":"issue","id":"archie-core-dzx","title":"Remove duplicate archie-agent safe.directory setup","description":"## Problem\\ncmd/archie-agent/main.go configures git safe.directory inline and then calls markWorktreeSafe, so startup writes the same global git configuration twice.\\n\\n## Scope\\nKeep markWorktreeSafe as the single tested production path and remove the older inline exec.Command block/import. Add regression coverage proving startup wiring has exactly one authoritative safe-directory call.\\n\\n## Acceptance\\n- archie-agent startup invokes markWorktreeSafe exactly once\\n- no second inline safe.directory command remains in main.go\\n- cmd/archie-agent tests and repository quality gate pass","acceptance_criteria":"Single tested safe.directory setup path remains; duplicate inline command is removed; tests and task check pass","notes":"Red proof: TestMainConfiguresWorktreeSafetyOnce failed with 2 setup paths before implementation. Green proof: go test/vet/build ./cmd/archie-agent/... passed; golangci-lint --new-from-rev=HEAD reported 0 issues. Fresh adversarial review found no blockers. Full task check was not run because the working tree contains unrelated in-progress changes and task check rewrites files; scoped package gate used per repository protocol.","status":"closed","priority":1,"issue_type":"bug","assignee":"Sam Catlow","owner":"sam@catlow.tech","created_at":"2026-08-13T16:10:09Z","created_by":"Sam Catlow","updated_at":"2026-08-13T16:13:48Z","started_at":"2026-08-13T16:10:24Z","closed_at":"2026-08-13T16:13:48Z","close_reason":"Removed duplicate inline safe.directory setup; markWorktreeSafe is now the single tested production path","external_ref":"https://github.com/samcharles93/archie-core/issues/470","dependency_count":0,"dependent_count":0,"comment_count":0} +{"_type":"issue","id":"archie-core-3ghy","title":"Wire generate_video (MiniMax) tool end-to-end","description":"Implemented the MiniMax text-to-video generation tool and wired it through the media-delivery pipeline built for this: tool -\u003e tools.MultimodalResult -\u003e drainChatStream detection -\u003e gateway.TurnStream.Media -\u003e gateway.MediaSender (Telegram delivers inline; webui falls back to a link).\n\n## What shipped\n- internal/tools/minimax: API client (create+poll against MiniMax's v2/video_generation and v2/query/video_generation/{id}), a builtin tools.ToolEntry (generate_video), fully test-first with an injected-clock poll loop (no real sleep in tests).\n- internal/tools: extended tools.MultimodalResult with a URLs []MediaRef field, for tool results whose media lives at a remote hosted URL rather than local bytes (the existing Files field).\n- cmd/archied/telegram_setup.go: drainChatStream now detects a MultimodalResult in a tool result's Output and calls turn.Media(...) per URL, alongside the existing turn.ToolCall(...) reporting.\n- internal/config: MinimaxConfig (off by default, unlike web_fetch -- this spends real API credits per call), api_key via the existing secret.SecretRef pattern.\n- cmd/archied/bootstrap.go: registerMinimaxTool -- only registers the tool once an API key actually resolves, matching the 'do not advertise a broken capability' pattern web_fetch already uses.\n- config.example.toml: documented [tools.minimax].\n\n## Scope deliberately left out (by explicit instruction: URL-only, get it working first)\n- Image-to-video (image_url content items) -- text-to-video only.\n- Local byte/file upload delivery path -- URL-only, matches gateway.MediaSender's current URL-only design.\n- Email/webhook channel delivery -- only Telegram implements gateway.MediaSender today; other channels have no inline media path, and webui falls back to a text link (see archie-core-1786748942243-6-f109697e for the still-open 'deliver generated images through channel and web abstractions' work).\n- No OpenAI video provider -- only MiniMax implemented, per this issue's scope. A second provider should follow the same tool-package shape (internal/tools/\u003cprovider\u003e) if wanted.\n- No spend guard / approval gate on the tool despite it costing real credits per call (classified ClassMutating, not RequiresApproval) -- flagged in tool.go's doc comment as a candidate follow-up if usage shows it's needed.","acceptance_criteria":"task check passes; go test ./... green except the pre-existing unrelated internal/app/agentworker architecture-test failure; golangci-lint clean on every touched package; config.example.toml documents [tools.minimax].","status":"closed","priority":2,"issue_type":"feature","owner":"sam@catlow.tech","created_at":"2026-08-22T15:34:24Z","created_by":"Sam Catlow","updated_at":"2026-08-22T15:34:29Z","closed_at":"2026-08-22T15:34:29Z","close_reason":"Shipped and verified: task check equivalent (fmt/vet/build/test/lint) is clean across every touched package, red-then-green throughout. See the issue description for what's in scope and what's explicitly deferred.","dependency_count":0,"dependent_count":0,"comment_count":0} {"_type":"issue","id":"archie-core-azbo","title":"Remove dead BasePlatformAdapter interface from internal/gateway","description":"`gateway.BasePlatformAdapter` (internal/gateway/adapter.go, Connect/Disconnect/Send/ChatInfo) is implemented by nothing outside its own test stub. It landed in commit bc1caf6 alongside the Session types and was never wired.\n\nEvery live channel instead implements `channels.Channel` (= `gateway.Gateway`: Name/Start/Stop, plus ConfigSchema/ValidateConfig) -- asserted at internal/channels/telegram/telegram.go:1229, internal/channels/email/email.go:389, internal/channels/webhook/webhook.go:224. So the repo carries two parallel channel abstractions and the newer one is inert.\n\nIt also has an internal contradiction that is likely why it was never implemented: the doc comment says the daemon instantiates 'one adapter per active bot identity x platform' (adapter.go:59) but `ChatInfo(ctx) (ChatInfo, error)` is documented as 'static metadata about the conversation a platform adapter is connected to' (adapter.go:36-38) with no chat argument. Telegram's Gateway is a single instance serving many chats, so ChatInfo(ctx) has no single answer. Send(ctx, MessageEvent) is fine for both models since MessageEvent carries ChannelID; ChatInfo is the part that only makes sense per-conversation.\n\nOutbound delivery is assigned to the not-yet-built `internal/domain/messaging` by docs/architecture/migration-decisions.md section 2, so this interface should not be revived in place -- it should be deleted and its intent re-expressed there.\n\n## Scope\n\n- Delete BasePlatformAdapter and its test stub from internal/gateway/adapter.go / adapter_test.go.\n- Keep SendResult and ChatInfo structs if domain/messaging or the media work still wants them; they are separable from the interface.\n- Decouple gateway.CapabilitiesOf from BasePlatformAdapter (it currently takes one) so the capability mechanism survives the removal.\n\n## Acceptance criteria\n\n- BasePlatformAdapter no longer exists; `task check` passes.\n- No behaviour change: nothing implemented it, so nothing should need rewiring.\n- Any type retained from adapter.go has at least one live consumer, or is removed too.","notes":"Discovery confirmed CapabilitiesOf is absent from the current checkout and gateway history. SendResult and ChatInfo have no live consumers, so all three legacy declarations are removed. Red test: TestLegacyPlatformAdapterTypesAreRemoved failed on BasePlatformAdapter, ChatInfo, and SendResult before deletion; gateway package suite passes after deletion. Full task check currently reaches one unrelated pre-existing failure: internal/app/agentworker TestApplicationOwnsNoTransportWireMechanics reports persistent_runner.go imports JSON wire encoding.","status":"closed","priority":2,"issue_type":"task","assignee":"Sam Catlow","owner":"sam@catlow.tech","created_at":"2026-08-22T12:04:10Z","created_by":"Sam Catlow","updated_at":"2026-08-22T12:16:02Z","started_at":"2026-08-22T12:08:39Z","closed_at":"2026-08-22T12:16:02Z","close_reason":"Removed the unwired BasePlatformAdapter, SendResult, ChatInfo, and their test-only stub. CapabilitiesOf is absent from the current checkout/history. Gateway and worktree tests pass. task check passes all packages except the pre-existing tracked agentworker architecture failure archie-core-hqst.","dependency_count":0,"dependent_count":0,"comment_count":0} {"_type":"issue","id":"archie-core-hqst","title":"TestApplicationOwnsNoTransportWireMechanics fails: persistent_runner.go imports encoding/json","description":"internal/app/agentworker/architecture_test.go's TestApplicationOwnsNoTransportWireMechanics fails on main (pre-existing, unrelated to archie-core-qk8m): persistent_runner.go imports encoding/json, tripping the check that agentworker's app layer owns no transport wire mechanics. Introduced by e351581 (feat(storage): persist agent project state). Confirmed via git stash that this fails identically with none of the mcp-npm-cache changes applied.","status":"in_progress","priority":2,"issue_type":"bug","assignee":"Sam Catlow","owner":"sam@catlow.tech","created_at":"2026-08-22T11:09:58Z","created_by":"Sam Catlow","updated_at":"2026-08-22T12:16:11Z","started_at":"2026-08-22T12:16:11Z","dependency_count":0,"dependent_count":0,"comment_count":0} {"_type":"issue","id":"archie-core-1ysw.9","title":"Align branch naming behavior, API, tests, and documentation","description":"branchPrefix ignores title and body despite the documented title-prefix contract, contains a checked-in lint-failing FIXME and a no-op, and branchSlug documents 40 characters while implementing 60.","acceptance_criteria":"The chosen title/label precedence is explicit and tested for unlabeled and conflicting inputs; dead parameters and no-op residue are removed; slug documentation and boundary tests agree with 60; scoped lint passes.","status":"open","priority":2,"issue_type":"bug","owner":"sam@catlow.tech","created_at":"2026-08-22T11:01:48Z","created_by":"Sam Catlow","updated_at":"2026-08-22T11:01:48Z","dependencies":[{"issue_id":"archie-core-1ysw.9","depends_on_id":"archie-core-1ysw","type":"parent-child","created_at":"2026-08-22T21:01:48Z","created_by":"Sam Catlow","metadata":"{}"}],"dependency_count":0,"dependent_count":0,"comment_count":0} @@ -378,9 +379,9 @@ {"_type":"issue","id":"archie-core-1786637493467-141-ffb91b17","title":"ToolEntry data type definition","description":"Design and implement the ToolEntry data type carrying: name, toolset (which tool group this belongs to), schema (JSON Schema for invocation), handler (function ref), check_fn (availability predicate), requires_env (env vars needed), is_async (async/sync distinction), description, emoji, max_result_size_chars (per-tool result cap), and dynamic_schema_overrides (runtime schema mutations). This is the foundational type that everything in the tools subsystem builds upon.","status":"closed","priority":2,"issue_type":"task","created_at":"2026-08-08T14:38:14Z","updated_at":"2026-08-08T14:38:16Z","closed_at":"2026-08-08T14:38:17Z","external_ref":"https://github.com/samcharles93/archie-core/issues/162","source_system":"github:https://github.com/samcharles93/archie-core/issues/162:162","metadata":null,"labels":["task"],"dependency_count":0,"dependent_count":0,"comment_count":0} {"_type":"issue","id":"archie-core-1786637493439-140-2cee2e9b","title":"[EPIC] Tools: central registry, MCP client, guardrails","description":"Central tool infrastructure to match Hermes parity:\n\n1. **Tool registry**: A central registry where tool modules register themselves with name, schema, handler, toolset membership, and availability check. Dynamic discovery of built-in tools. This replaces the current pattern of manually constructing core.ToolSet maps per invocation.\n\n2. **MCP client**: Connect to external MCP servers via stdio, HTTP/StreamableHTTP, or SSE transport. Discover their tools and register them into the tool registry. Support automatic reconnection with backoff, configurable timeouts, per-server parallel tool call opt-in.\n\n3. **Guardrails**: Tool-call loop detection (repeated calls, repeated failures, no-progress loops). Idempotent/mutating tool classification. Warning vs hard-stop decisions.\n\n4. **Progressive disclosure**: When tool schemas exceed a context-window threshold, replace them with bridge tools (tool_search/tool_describe/tool_call) and surface on demand. Core tools are always visible.\n\nRef: docs/prds/hermes-gap-analysis.md section 3\n\n### Acceptance Criteria\n\nMCP servers can be configured with a TOML block and their tools appear alongside built-ins. The agent loop is protected against tool-call loops. Tool schemas stay within context budget.\n","notes":"docs/prds/hermes-gap-analysis.md (referenced above) was intentionally deleted in commit 65aa5b4 ('chore: cleanup', 2026-07-28) after it had already spawned this and ~14 sibling beads issues from its 60 identified gaps — it is not a broken link to restore. This issue's description is the surviving record of its slice of that analysis.","status":"open","priority":2,"issue_type":"epic","created_at":"2026-08-08T14:38:11Z","updated_at":"2026-08-15T12:47:30Z","external_ref":"https://github.com/samcharles93/archie-core/issues/161","source_system":"github:https://github.com/samcharles93/archie-core/issues/161:161","metadata":null,"labels":["epic"],"dependency_count":0,"dependent_count":0,"comment_count":0} {"_type":"issue","id":"archie-core-1786637493413-139-d157cc71","title":"SessionSource struct for platform identity","status":"closed","priority":2,"issue_type":"task","created_at":"2026-08-08T14:38:06Z","updated_at":"2026-08-08T14:38:08Z","closed_at":"2026-08-08T14:38:09Z","external_ref":"https://github.com/samcharles93/archie-core/issues/160","source_system":"github:https://github.com/samcharles93/archie-core/issues/160:160","metadata":null,"labels":["task"],"dependency_count":0,"dependent_count":0,"comment_count":0} -{"_type":"issue","id":"archie-core-1786637493387-138-cad8e7a7","title":"Platform capability flags for adapters","description":"A capability-flag mechanism so callers can ask an adapter which optional features it supports (typing indicator, edit, delete, media send, clarify/approval/picker UI) instead of discovering support by a failed type assertion or a runtime error.\n\n### Context for implementers\n\nThis depends on the optional-method interfaces this issue is meant to describe: `archie-core-1786637493329-136-49b39c78` (typing/edit/delete/media) and `archie-core-1786637493357-137-35af7083` (clarify/approval/pickers). Implement after (or in close coordination with) those two, since the flag set should mirror whatever optional interfaces they land — don't invent a flag taxonomy ahead of the methods it describes.\n\n### Acceptance Criteria\n\n`BasePlatformAdapter` (`internal/gateway/adapter.go`) or a wrapping type exposes a capability query (e.g. `Capabilities() AdapterCapabilities`) that reports which optional methods an adapter implements. Every existing adapter's reported capabilities match its actual method set (a regression test should fail if an adapter claims a capability it doesn't implement, or vice versa).\n","status":"in_progress","priority":2,"issue_type":"task","assignee":"Sam Catlow","created_at":"2026-08-08T14:38:02Z","updated_at":"2026-08-22T11:53:10Z","started_at":"2026-08-22T11:53:10Z","external_ref":"https://github.com/samcharles93/archie-core/issues/159","source_system":"github:https://github.com/samcharles93/archie-core/issues/159:159","metadata":null,"labels":["task"],"dependencies":[{"issue_id":"archie-core-1786637493387-138-cad8e7a7","depends_on_id":"archie-core-1786637493357-137-35af7083","type":"blocks","created_at":"2026-08-15T12:46:57Z","created_by":"Sam Catlow","metadata":"{}"},{"issue_id":"archie-core-1786637493387-138-cad8e7a7","depends_on_id":"archie-core-1786637493329-136-49b39c78","type":"blocks","created_at":"2026-08-15T12:46:57Z","created_by":"Sam Catlow","metadata":"{}"}],"dependency_count":2,"dependent_count":0,"comment_count":0} +{"_type":"issue","id":"archie-core-1786637493387-138-cad8e7a7","title":"Platform capability flags for adapters","description":"A capability-flag mechanism so callers can ask an adapter which optional features it supports (typing indicator, edit, delete, media send, clarify/approval/picker UI) instead of discovering support by a failed type assertion or a runtime error.\n\n### Context for implementers\n\nThis depends on the optional-method interfaces this issue is meant to describe: `archie-core-1786637493329-136-49b39c78` (typing/edit/delete/media) and `archie-core-1786637493357-137-35af7083` (clarify/approval/pickers). Implement after (or in close coordination with) those two, since the flag set should mirror whatever optional interfaces they land — don't invent a flag taxonomy ahead of the methods it describes.\n\n### Acceptance Criteria\n\n`BasePlatformAdapter` (`internal/gateway/adapter.go`) or a wrapping type exposes a capability query (e.g. `Capabilities() AdapterCapabilities`) that reports which optional methods an adapter implements. Every existing adapter's reported capabilities match its actual method set (a regression test should fail if an adapter claims a capability it doesn't implement, or vice versa).\n","notes":"Partial: the mechanism itself (gateway.CapabilityReporter, CapabilitiesOf, AdapterCapabilities) is built and covered by a regression test, scoped to Media only -- see archie-core-1786637493329-136-49b39c78 (closed, media portion). Still blocked on archie-core-1786637493357-137-35af7083 (clarify/approval/pickers) since AdapterCapabilities needs those flags added too before this is fully done.","status":"in_progress","priority":2,"issue_type":"task","assignee":"Sam Catlow","created_at":"2026-08-08T14:38:02Z","updated_at":"2026-08-22T15:03:49Z","started_at":"2026-08-22T11:53:10Z","external_ref":"https://github.com/samcharles93/archie-core/issues/159","source_system":"github:https://github.com/samcharles93/archie-core/issues/159:159","metadata":null,"labels":["task"],"dependencies":[{"issue_id":"archie-core-1786637493387-138-cad8e7a7","depends_on_id":"archie-core-1786637493357-137-35af7083","type":"blocks","created_at":"2026-08-15T12:46:57Z","created_by":"Sam Catlow","metadata":"{}"},{"issue_id":"archie-core-1786637493387-138-cad8e7a7","depends_on_id":"archie-core-1786637493329-136-49b39c78","type":"blocks","created_at":"2026-08-15T12:46:57Z","created_by":"Sam Catlow","metadata":"{}"}],"dependency_count":2,"dependent_count":0,"comment_count":0} {"_type":"issue","id":"archie-core-1786637493357-137-35af7083","title":"BasePlatformAdapter interactive UX methods (clarify, approval, pickers)","description":"Add adapter-facing methods for interactive UX: presenting a clarifying question, an approval prompt, and a picker (multi-choice selection) natively on the platform, rather than as plain text the user has to reply to by hand.\n\n### Context for implementers\n\nThe approval *decision* plumbing already exists — `internal/tools/approval.go`, re-exported through `internal/gateway/approval.go` (`ApprovalRequester`, `ApprovalDecision`, `WithApprovalRequester`/`ApprovalFromContext`). What's missing is the adapter-side rendering: `BasePlatformAdapter` (`internal/gateway/adapter.go`) has no method for an adapter to display an approval/clarify/picker UI and report back a decision through that existing plumbing. This issue wires a new adapter method (or interface) into the existing `ApprovalRequester` flow — it should not duplicate or replace the decision model in `internal/tools/approval.go`. Sibling of `archie-core-1786637493329-136-49b39c78` (typing/edit/delete/media) — same \"optional adapter capability\" shape, different capability set.\n\n### Acceptance Criteria\n\nAn adapter can render a clarify/approval/picker prompt and the user's response is delivered back through the existing `ApprovalRequester`/`ApprovalDecision` flow in `internal/tools/approval.go`, not a parallel mechanism. Platforms without native UI (e.g. plain text-only channels) degrade to a text-based fallback rather than failing. Covered by a test double adapter, not a live platform.\n","status":"open","priority":2,"issue_type":"task","created_at":"2026-08-08T14:37:59Z","updated_at":"2026-08-15T12:46:48Z","external_ref":"https://github.com/samcharles93/archie-core/issues/158","source_system":"github:https://github.com/samcharles93/archie-core/issues/158:158","metadata":null,"labels":["task"],"dependency_count":0,"dependent_count":1,"comment_count":0} -{"_type":"issue","id":"archie-core-1786637493329-136-49b39c78","title":"BasePlatformAdapter optional methods (typing, edit, delete, media)","description":"Extend adapter capability beyond the four required `BasePlatformAdapter` methods with optional per-platform methods: typing indicator, message edit, message delete, and media-specific send.\n\n### Context for implementers\n\n`internal/gateway/adapter.go` today defines `BasePlatformAdapter` with exactly four methods: `Connect`, `Disconnect`, `Send`, `ChatInfo` (see full listing — the file is 80 lines). Not every platform supports typing/edit/delete/media uniformly, so these should be a separate optional interface(s) that callers type-assert for, not additions to the required interface (that would break every existing adapter implementation). Pairs with `archie-core-1786637493387-138-cad8e7a7` (platform capability flags) — callers need a way to know *ahead of a type assertion* whether an adapter supports a given optional method, rather than probing via failed assertions at call time.\n\n### Acceptance Criteria\n\nOptional methods are defined on a separate interface (or interfaces) from `BasePlatformAdapter`, so existing adapters keep compiling unchanged. At least one adapter implementation exercises each optional method in a test. Callers that invoke an optional method on an adapter that doesn't implement it get a defined, non-panicking behavior.\n","status":"in_progress","priority":2,"issue_type":"task","assignee":"Sam Catlow","created_at":"2026-08-08T14:37:57Z","updated_at":"2026-08-22T11:53:09Z","started_at":"2026-08-22T11:53:09Z","external_ref":"https://github.com/samcharles93/archie-core/issues/157","source_system":"github:https://github.com/samcharles93/archie-core/issues/157:157","metadata":null,"labels":["task"],"dependency_count":0,"dependent_count":1,"comment_count":0} +{"_type":"issue","id":"archie-core-1786637493329-136-49b39c78","title":"BasePlatformAdapter optional methods (typing, edit, delete, media)","description":"Extend adapter capability beyond the four required `BasePlatformAdapter` methods with optional per-platform methods: typing indicator, message edit, message delete, and media-specific send.\n\n### Context for implementers\n\n`internal/gateway/adapter.go` today defines `BasePlatformAdapter` with exactly four methods: `Connect`, `Disconnect`, `Send`, `ChatInfo` (see full listing — the file is 80 lines). Not every platform supports typing/edit/delete/media uniformly, so these should be a separate optional interface(s) that callers type-assert for, not additions to the required interface (that would break every existing adapter implementation). Pairs with `archie-core-1786637493387-138-cad8e7a7` (platform capability flags) — callers need a way to know *ahead of a type assertion* whether an adapter supports a given optional method, rather than probing via failed assertions at call time.\n\n### Acceptance Criteria\n\nOptional methods are defined on a separate interface (or interfaces) from `BasePlatformAdapter`, so existing adapters keep compiling unchanged. At least one adapter implementation exercises each optional method in a test. Callers that invoke an optional method on an adapter that doesn't implement it get a defined, non-panicking behavior.\n","status":"closed","priority":2,"issue_type":"task","assignee":"Sam Catlow","created_at":"2026-08-08T14:37:57Z","updated_at":"2026-08-22T15:03:39Z","started_at":"2026-08-22T11:53:09Z","closed_at":"2026-08-22T15:03:39Z","close_reason":"Media portion delivered: gateway.MediaSender + telegramMediaSender + TurnStream.Media wiring in Telegram's liveReply. Typing/edit/delete indicators from this issue's original scope are NOT done -- splitting them out if still wanted, since they're unrelated to the video-gen work that drove this.","external_ref":"https://github.com/samcharles93/archie-core/issues/157","source_system":"github:https://github.com/samcharles93/archie-core/issues/157:157","metadata":null,"labels":["task"],"dependency_count":0,"dependent_count":1,"comment_count":0} {"_type":"issue","id":"archie-core-1786637493304-135-95070200","title":"BasePlatformAdapter interface with required methods","status":"closed","priority":2,"issue_type":"task","created_at":"2026-08-08T14:37:51Z","updated_at":"2026-08-08T14:37:54Z","closed_at":"2026-08-08T14:37:55Z","external_ref":"https://github.com/samcharles93/archie-core/issues/156","source_system":"github:https://github.com/samcharles93/archie-core/issues/156:156","metadata":null,"labels":["task"],"dependency_count":0,"dependent_count":0,"comment_count":0} {"_type":"issue","id":"archie-core-1786637493282-134-cf46838e","title":"EphemeralReply type with auto-delete TTL","description":"An `EphemeralReply` type for messages the gateway sends that should self-delete after a TTL — status/progress placeholders (\"thinking…\", \"running tool X…\") that shouldn't linger in the chat history once superseded.\n\n### Context for implementers\n\nNo ephemeral-reply file exists yet in `internal/gateway`. Deletion requires adapter support: `BasePlatformAdapter` (`internal/gateway/adapter.go`) currently exposes only `Connect`/`Disconnect`/`Send`/`ChatInfo` — no delete method. This depends on (or should land alongside) `archie-core-1786637493329-136-49b39c78` (BasePlatformAdapter optional methods, which includes delete) — an adapter without a delete method can't honor the TTL.\n\n### Acceptance Criteria\n\nAn `EphemeralReply` carries a TTL after which the gateway issues a delete against the originating adapter. Adapters without delete support degrade gracefully (e.g. leave the message, log once) rather than erroring the turn. TTL firing is covered by a test using an injected clock, not a real sleep.\n","status":"open","priority":2,"issue_type":"task","created_at":"2026-08-08T14:37:48Z","updated_at":"2026-08-15T12:46:47Z","external_ref":"https://github.com/samcharles93/archie-core/issues/155","source_system":"github:https://github.com/samcharles93/archie-core/issues/155:155","metadata":null,"labels":["task"],"dependencies":[{"issue_id":"archie-core-1786637493282-134-cf46838e","depends_on_id":"archie-core-1786637493329-136-49b39c78","type":"related","created_at":"2026-08-15T12:46:57Z","created_by":"Sam Catlow","metadata":"{}"}],"dependency_count":0,"dependent_count":0,"comment_count":0} {"_type":"issue","id":"archie-core-1786637493254-133-444ec94e","title":"Telegram: interactive /model selector","description":"When /model is invoked without an argument, present Telegram-native interactive controls rather than only plain text usage. Use the pinned go-telegram/bot SDK inline keyboard and callback query APIs; preserve /model provider/model for typed selection and enforce the existing sender allowlist on callbacks.\n\n### Acceptance Criteria\n\nAn allowlisted user invoking /model receives an inline keyboard of configured models with the active model marked; tapping a model switches it through gateway.ModelManager, acknowledges the callback, and updates the message; unauthorized or malformed callbacks cannot switch models; empty model catalogs degrade safely.","status":"closed","priority":2,"issue_type":"feature","created_at":"2026-08-08T14:37:45Z","updated_at":"2026-08-15T02:48:49Z","closed_at":"2026-08-15T02:48:49Z","external_ref":"https://github.com/samcharles93/archie-core/issues/154","source_system":"github:https://github.com/samcharles93/archie-core/issues/154:154","metadata":null,"labels":["enhancement"],"dependency_count":0,"dependent_count":0,"comment_count":0}