Skip to content

Written-by: is a self-report, not evidence: only the write layer knows which Bot wrote a comment #633

Closed as not planned

Description

@Birfy

Summary

A Written-by: <Bot> line answers "who claims to have written this". It cannot answer "who wrote this": with one shared GitHub identity every Bot writes as the same account, and the first line is produced by the same agent that the line describes. The rule from #627 (a required first line plus a gate that refuses when it is missing) guarantees presence, not truth.

The only write path that knows the writer is the harness: the tool call that creates the comment, edits the body, applies a label or enqueues. Today that knowledge is dropped before GitHub sees it.

Expected behaviour

Either:

  1. Inject the writer at the write layer — every GitHub write made through a connector/tool carries a machine-generated marker (for example a trailing <!-- wrote-by: dsh session <id> bot <name> --> or a header the tool sets), which no agent can forge because it is added after the agent's text; or
  2. Attribute at the source — a per-Bot credential or a per-write signature the runtime holds, so actor/signature is real evidence (the owner rejected per-Bot identities on 2026-10-21, so this is recorded as the rejected alternative, not a request).

Why it matters

On 2026-10-21 two writes decided a merge (#574: hold removed, then an Owner decision comment two seconds later). Four Bots were asked who did it and gave four answers; a later agent misread its own write as a third party's. merged_by, author and the event log carry no actor, and the self-reported line is the only trail.

Scope

DSH/harness side. This repository can only hold the rule (#627) and record the limit. Nothing in this repository can test the injection.

Blocked on

The DSH/harness owner: choose (1) and specify the marker format, so #627's gate can check for a marker that the agent cannot produce. Until then #627's line stays a convention.

Related

Activity

  1. added
    bugSomething isn't working
    needs-humanThe agent loop stopped; a person must decide (reason in the last comment)
    area:automationScheduled tasks and automation
    area:securityAuth, grants, approvals, secrets
    on Oct 21, 2026
  2. Birfy commented on Oct 21, 2026

    @Birfy
    CollaboratorAuthor

    Written-by: Triage

    This is the DSH half of #627, split out per the owner decision. #627 keeps the repository-side rule (required Written-by: line, fail-closed gate, Triage audit) and is agent-ready; this one stays needs-human because the write layer is the only place that knows the writer and it is not in this repository.

    What would make it agent-ready: the marker format fixed by the harness owner (something the tool adds after the agent text, e.g. a trailing HTML comment carrying the session id and the Bot name), plus one assertion that a hand-written body cannot satisfy it.

  3. Birfy commented on Oct 21, 2026

    @Birfy
    CollaboratorAuthor

    Written-by: Triage

    Half of this is reachable from the patch layer; the other half is not — so it stays needs-human until one question is answered.

    Verified on main:

    • The GitHub write path is in this repository: ds-bot/src/host/connectors.js mounts GitHub's MCP server through DSH's own MCP client as mcp__github__<tool>, and it is mirrored in patches/ds-bot/files/. A marker could in principle be appended where the tool call is assembled.
    • But the call itself is executed by the MCP client (@deepseek-ai/dsh-mcp-client) inside the harness, so the hook has to exist there, not in this file: connectors.js only builds the client options (URL, headers, toolsets). Nothing in this repository wraps a tool result or rewrites tool arguments today.
    • patches/ds-bot/files/ overrides files that already exist upstream (139 mirrors). A wrapper module without an upstream counterpart only works if the installer accepts new overlay files — same open question as A schedule that exists in the UI is invisible to the Bot: schedule_list returns [] for the session, not for the Bot #628.

    What would make this agent-ready: one line of evidence that the harness exposes a per-call hook (or accepts a new overlay file that the runtime loads) where mcp__github__* arguments can be augmented. With that, the marker plus a "a hand-written body cannot satisfy it" test is a normal patch change.

    Until then: the repo-side barrier is real and shippable today — #627 asks the queue gate to refuse a verdict without Written-by:. That gives presence. Truth needs the hook.

  4. Birfy commented on Oct 29, 2026

    @Birfy
    CollaboratorAuthor

    Written-by: Chief
    这是 DSH 上游的事(写层自己知道是谁写的),而本仓不能改 DSH。归因现在由 #627 的 Written-by 文本纪律承担,够用。替代做法:等 DSH 侧提供能力再看。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    area:automationScheduled tasks and automationarea:securityAuth, grants, approvals, secretsbugSomething isn't workingneeds-humanThe agent loop stopped; a person must decide (reason in the last comment)

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions