Skip to content

Extraction prompt: PR / issue references should carry a 2-word topic #26

Description

@bobthearsonist

Observation

When the extraction prompt produces nodes that reference a PR or issue number, the label sometimes ends up as just a bare number (e.g. PR #23, Issue #22) without any clue what the PR / issue is about. A reader scanning the graph 6 months later — or any reader who wasn't around when the PR was open — has no way to tell what the node represents.

Today's example

A daily overview today rendered cleanly, but mixed labels:

  • ✅ Good: PR #23 shipped, Issue #22 decision-node alternatives, feat/issue-21 visual-fidelity, elkjs spacing bug (upstream)
  • ⚠️ Bare-ish: any node that's just PR #N or Issue #N with no second-word context (varies day to day)

The good examples already pair the reference with a short topic. The prompt should make that the rule, not the lucky case.

Suggested rule for prompts/extract-graph.md

Add a heuristic along these lines:

Whenever a node label references a PR or issue number, include a 1-2 word topic alongside the number, formatted as PR #N topic or Issue #N topic. Examples: PR #23 visual-fidelity, Issue #22 decision-nodes, Bug #156294 orphaned-records. Never produce a label that is just a PR/issue number — the reader needs to know what it's about without leaving the graph.

The topic should come from the prose surrounding the reference. If the markdown doesn't give a clear topic, fall back to a short generic ("PR #N fix" / "Issue #N feature") rather than the bare number.

Why this matters

The graph is meant to be a navigation + memory aid. A bare #23 collapses to noise when the PR is closed or the reader's context shifts. A 2-word topic is enough to triangulate without bloating the label.

Out of scope

Not blocking #21 / PR #23 — this is a prompt refinement, lands in a separate PR.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions