Repository navigation
Description
RFC for discussion. The activity interfaces below are proposals, not existing Spec Kit APIs.
Problem Statement
When several agents work on a Spec Kit feature, a task checkbox or a recorded implementing status tells us about the plan, not whether a worker is actually active now. A project overview can consequently show stale or misleading activity, especially across worktrees, parallel workers, blocked sessions, or after a crash.
I would like a reliable way for dashboards and other tools to show which workers are currently associated with which feature and phase, while clearly distinguishing observed activity from task completion and from unknown state.
Proposed Solution
Discuss a small, opt-in, harness-neutral activity observation contract, with host-specific adapters responsible for reporting only what their host can actually observe. A consumer such as a dashboard could then present the same information without understanding every harness.
Proposed interface and integration
The diagram distinguishes existing artifacts and consumers from proposed activity
interfaces and components. The box represents Spec Kit tooling, including proposed
additions; whether those additions belong in core, an extension, or another project
remains open. Assignment, Observation, and ActivitySnapshot are proposed
shared contract data definitions inside that boundary, not runtime objects confined
to it: adapters and consumers would exchange or interpret their data across the
boundary. Adapters report only what their harness can provide; no live Copilot
activity feed is assumed to exist.
Legend: blue = existing; amber = proposed; grey = illustrative consumer.
Labels also identify each status.
classDiagram
namespace Spec_Kit_tooling {
class TasksFile {
<<existing artifact>>
tasks.md
}
class ActivityPublisher {
<<proposed interface>>
+publishAssignment(Assignment)
+publishObservation(Observation)
}
class ActivityReader {
<<proposed interface>>
+readSnapshot() ActivitySnapshot
+subscribe() UpdateStream
}
class LocalActivityProvider {
<<proposed component>>
}
class Assignment {
<<proposed data definition>>
+sourceId
+workerId
+repositoryId
+featureId
+worktreeId
+revision
+taskIds
+phaseId
}
class Observation {
<<proposed data definition>>
+state
+observedAt
+expiresAt
}
class ActivitySnapshot {
<<proposed data definition>>
+assignments
+observations
+coverage
}
}
class CopilotAdapter {
<<proposed adapter>>
}
class OtherHarnessAdapter {
<<proposed adapter>>
}
class CopilotCanvas {
<<existing project-local canvas>>
}
class OtherConsumer {
<<illustrative consumer>>
}
CopilotAdapter ..> ActivityPublisher : reports supported events
OtherHarnessAdapter ..> ActivityPublisher : reports supported events
LocalActivityProvider ..|> ActivityPublisher : implements
LocalActivityProvider ..|> ActivityReader : implements
ActivityPublisher ..> Assignment : accepts
ActivityPublisher ..> Observation : accepts
ActivityReader ..> ActivitySnapshot : returns
ActivitySnapshot o-- Assignment
ActivitySnapshot o-- Observation
CopilotCanvas ..> ActivityReader : reads and subscribes
OtherConsumer ..> ActivityReader : reads and subscribes
CopilotCanvas ..> TasksFile : reads existing artifacts
style TasksFile fill:#dbeafe,stroke:#1d4ed8,color:#172554
style CopilotCanvas fill:#dbeafe,stroke:#1d4ed8,color:#172554
style ActivityPublisher fill:#fef3c7,stroke:#a16207,color:#422006
style ActivityReader fill:#fef3c7,stroke:#a16207,color:#422006
style LocalActivityProvider fill:#fef3c7,stroke:#a16207,color:#422006
style CopilotAdapter fill:#fef3c7,stroke:#a16207,color:#422006
style OtherHarnessAdapter fill:#fef3c7,stroke:#a16207,color:#422006
style Assignment fill:#fef3c7,stroke:#a16207,color:#422006
style Observation fill:#fef3c7,stroke:#a16207,color:#422006
style ActivitySnapshot fill:#fef3c7,stroke:#a16207,color:#422006
style OtherConsumer fill:#f3f4f6,stroke:#4b5563,color:#111827
The contract would separate:
- Assignment: an explicit association between a worker and a repository, feature, worktree/revision and stable task or phase identifier. Multiple workers and assignments must be representable; task IDs alone are not globally unique.
- Observation: a source-reported worker state and observation time.
activemeans the source actually reports activity—not merely that a task is unchecked or was assigned. Distinguishblockedandidlewhere the source exposes them. - Freshness and coverage: missing, ambiguous, expired, disconnected or unsupported observations are unknown, never silently treated as active, idle, or completed. A stopped producer must not leave a worker permanently active.
Illustrative data shape only; names, transport and lifecycle need design review:
{
"schema_version": 1,
"source": "example-harness-adapter",
"worker_id": "worker-1",
"assignment": {
"repository_id": "example/project",
"feature_id": "042-example-feature",
"worktree_id": "local-worktree-1",
"revision": "example-revision",
"task_ids": ["T012"],
"phase_id": "phase-4"
},
"observation": {
"state": "active",
"observed_at": "2026-01-01T10:00:00Z",
"expires_at": "2026-01-01T10:01:00Z"
}
}A consumer would validate feature/worktree identity, resolve the task against the matching revision, and display uncertainty if the mapping is absent or conflicting. Assignment and observation may need separate events or a snapshot-plus-update model; this example is not a proposed final schema.
Example: Copilot canvas
The same reader contract could serve other dashboards; only the adapter and
consumer at the edges are Copilot-specific. The blue box is an existing host;
the amber boxes contain proposed components or the Spec Kit tooling boundary with
proposed additions. The existing task file inside that boundary is labelled
separately. Final placement is not decided. Arrows involving activity are proposed interactions, not existing
interfaces; this sequence requires an authorized, supported host source.
sequenceDiagram
box rgb(219, 234, 254) Existing host
participant H as Copilot host (existing)
end
box rgb(254, 243, 199) Proposed adapter
participant A as Copilot adapter (proposed)
end
box rgb(254, 243, 199) Spec Kit tooling - proposed additions
participant P as Activity provider (proposed)
participant T as tasks.md (existing artifact)
end
participant C as Project-local canvas (existing)
H->>A: Proposed supported host observation
A->>P: Proposed publisher interface: assignment and observation
P-->>C: Proposed reader interface: snapshot or update
C->>T: Read existing task data
C->>C: Validate task, phase and revision
C-->>C: Show active, blocked or idle
Note over A,C: If observations expire or the source disconnects
P-->>C: Missing, expired or unavailable evidence
C-->>C: Show unknown without inferring completion
Prefer a local, opt-in integration that does not alter tasks.md, expose raw prompts, credentials or sensitive tool output, or require access to another harness's private session internals. Storage should be bounded and protected against concurrent writes and unsafe paths. The activity data is informational, not an authorization or completion decision. A host that cannot provide a reliable event must say so; adapters must not infer it from branch names, free text, or task checkboxes.
Component / AI Agent
- Component: Agent integrations (command files, workflows); exact ownership is an open question.
- AI Agent: All agents; initial use case is GitHub Copilot. Other harnesses would need their own supported adapter.
Use Cases
- Show a project's active phases and multiple workers without confusing open tasks with active execution.
- Surface a worker waiting for input when the host exposes that state.
- Keep separate worktrees and feature revisions distinct, and show stale or missing observations honestly.
- Allow independent dashboards or extensions to consume the same observations.
Acceptance Criteria
- A documented, versioned and opt-in contract separates explicit assignments, observed state, source identity, and freshness.
- Multiple workers, reassignment, different worktrees, task/phase mapping and conflicting identities are handled without guessing.
- Missing, stale, interrupted and unsupported observations are visibly unknown; completion remains sourced from the task/workflow ledger.
- A reference adapter and consumer demonstrate real transitions using a supported host interface, including active, idle, blocked where supported, and expiry after disconnect.
- Tests cover concurrent updates, stale events, malformed input, privacy, and unsupported or unavailable hosts.
- No existing task files, host settings or permissions are changed without explicit opt-in; the report never claims to authorize actions.
Alternatives and Related Work
- SpecKit Companion #782 and PR #839 record the assistant to which a spec step was last sent. Their documented limitations include not observing live chat or waiting-for-input state.
- Sanduq Progress already reports workstreams, stages and host-hook observations, with explicit bindings and uncertainty; its documentation describes Claude Code and Codex. Could its existing data model or extension be reused or extended for other hosts rather than creating a parallel contract?
- Spec Kit #5052 discusses an integration-neutral contract for configuring native event hooks. It is related infrastructure, not an activity-state proposal.
- Continue using per-host dashboards or manual status reports. They can work, but do not offer a shared, well-defined view across integrations.
Scope and Open Questions
- Is an extension, an existing community project, or a small core contract the right home?
- Can existing Sanduq or Companion contracts be reused, and what additional host capabilities are necessary?
- Which sources can reliably report blocked or stopped states, and how should lack of coverage be represented?
- What stable identity, storage, access and expiry rules work across worktrees and platforms without leaking local paths or session data?
- What would constitute a minimal, maintainable reference implementation and real-host validation?
Prototype status: A project-local consumer prototype demonstrated activity transitions with a synthetic provider, and shows unknown when evidence is unavailable. An automatic live Copilot producer has not been implemented; the prototype is not claimed to be an upstream-ready or Sanduq-compatible integration.
AI Disclosure
Drafted by GitHub Copilot in Auto mode under human supervision, including research and issue drafting. The specific model and reasoning-effort setting were not exposed to the agent. The human contributor reviewed and approved this issue before submission.
Activity
alfredoperez commentedon Nov 22, 2026
Thanks @pgfeller, this isn't a waste of time. The problem is real, and I'd like SpecKit Companion (and its Copilot canvas) to read whatever comes out of it. Some facts that should make it smaller and easier to land:
The adapters already exist. spec-kit has six canonical runtime events (
session_start,pre_tool_use,post_tool_use,session_end,user_prompt_submit,stop), mapped per integration, including Copilot (stop→agentStop). Extensions subscribe inextension.yml; Companion already usesuser_prompt_submitandstop. So a Copilot producer is possible today, with no private session access. Worth checking whether the Copilot app runs the same hooks as Copilot CLI.Sanduq Progress already does part of this. It listens to these events and reports unknown where a host is silent. Worth checking what it could share before defining something new. cc @samykabu
What's actually missing upstream:
expires_at, kept apart fromtasks.mdand the progress records. Then Sanduq, Companion and the canvas can read each other's state instead of each keeping its own.pre_tool_usefires on every tool call (Runtime events: a slow handler can block the agent, and a handler can't tell which event fired #5336).Why it matters to Companion: we guess "still running?" from file times today. That has given false alarms and runs that showed as running for a month. Real active / waiting / unknown states would replace the guess.
I'd suggest reframing the RFC around points 1–4. Any extension that already listens to these events could be the first producer, and Companion or the Copilot canvas could be a reader.
github-actions commentedon Nov 23, 2026
Feature assessment — harness-neutral-worker-activity · Stage 1/5: Intake
Idea Intake: Harness-neutral live worker and phase activity
Idea (as captured)
Restated
The request asks for a shared way to represent live worker activity across integrations without conflating assignment, execution state, and task completion. The objective is to let dashboards/readers present active/idle/blocked/unknown status consistently while preserving uncertainty and source limitations.
Origin & Context
First-Glance Unknowns
github-actions commentedon Nov 23, 2026
Feature assessment — harness-neutral-worker-activity · Stage 2/5: Research
Idea Research: Harness-neutral live worker and phase activity
Users & Demand
Prior Art
session_start,pre_tool_use,post_tool_use,session_end,user_prompt_submit,stop) and Copilot-native mappings, so baseline hook plumbing exists. — [source:src/specify_cli/events/__init__.py,src/specify_cli/integrations/copilot/__init__.py] (confidence: high)progressextension entry, indicating adjacent "progress/activity" problem space is already being explored outside core. — [source:extensions/catalog.community.json] (confidence: medium)Market & Context
Data & Constraints
ActivitySnapshot,publishObservation,worker_id+expires_atcontract) were found during repository search, suggesting this is net-new at core-contract level. — [source: repository text search acrosssrc/andextensions/] (confidence: medium)Evidence Against the Idea
triage-out-of-scopelabel] (confidence: medium)Gaps & Open Questions
Sources
src/specify_cli/events/__init__.py(repo source)src/specify_cli/integrations/copilot/__init__.py(repo source)extensions/catalog.community.json(repo source)github-actions commentedon Nov 23, 2026
Feature assessment — harness-neutral-worker-activity · Stage 3/5: Problem
Problem Definition: Reliable cross-harness activity visibility
Problem Statement
Teams running multiple AI workers cannot reliably tell which worker is actively executing versus merely assigned, stale, blocked, or unsupported by host telemetry. This ambiguity causes incorrect operational decisions and weakens confidence in project-level status views.
Affected Users & Stakeholders
Goals
unknown) rather than guessing.Non-Goals
Success Metrics
Cost of Inaction
Status tooling continues to duplicate heuristics, producing inconsistent and sometimes misleading state across integrations. Users continue paying coordination and verification overhead, and ecosystem tools remain hard to interoperate.
Open Questions
github-actions commentedon Nov 23, 2026
Feature assessment — harness-neutral-worker-activity · Stage 4/5: Concept
Concept: Harness-neutral activity observation contract
Options
Option A — Minimal core contract now
Option B — Contract-first extension pilot
Option C — Do nothing in core; rely on host-specific tools
Recommendation
Recommend Option B. It best fits the goals with the current evidence quality: there is clear demand and prior art, but unresolved ownership and host-capability questions make an immediate core commitment premature. A contract-first pilot can validate semantics (especially unknown-state and expiry behavior) before any broader standardization decision.
Out of Scope (for the recommended option)
Assumptions to Validate
github-actions commentedon Nov 23, 2026
Feature assessment — harness-neutral-worker-activity · Stage 5/5: Decision — verdict needs-clarification
Decision: Harness-neutral live worker and phase activity
Scorecard
Verdict & Rationale
Verdict: needs-clarification. The problem is valid and promising, and a bounded pilot concept exists, but risk posture is currently too weak for a
go. The decision is blocked by unresolved ownership/governance and host-capability boundaries; proceeding directly to specification would likely overcommit scope without agreed constraints.If needs-clarification
If go — Handoff to
/speckit-specifypgfeller commentedon Nov 25, 2026
@samykabu, would you and the Sanduq Progress maintainers be interested in exploring interoperability with Spec Kit Companion?
Basen on the reply from @alfredoperez and our ai based analysis of Sanduq Progress we agree that you have already useful adjacent building blocks: host adapters, per-session snapshots, assignments, and feature-scoped progress projections implemented. Reusing or mapping to that work seems preferable to creating a parallel publisher/reader API.
Likely impact
A read-only mapping and one verified-host pilot look manageable. A general cross-host activity contract would be a larger effort: current progress is feature/worktree-scoped, host signals differ, and states such as waiting or stopped may not be consistently observable. It could also require freshness/expiry semantics, privacy-safe identity, contract/versioning work, and coordination with the upstream source for vendored code.
Potential benefits
Less duplicated infrastructure, a chance to extend existing host integrations, and validation by an independent reader.
Tradeoffs
Added compatibility and maintenance burden, uneven host coverage, and the risk of treating missing or stale evidence as current activity.
➡️Would you be interested to elaborate the feasibility of extending the scope of your project considering those pro and cons?
with kind regards,
Patrik
This message was created with the help of an AI