Skip to content

[Feature]: let graphify query start from caller-chosen nodes (--seed) #4293

Description

@devkancheti4-design

Problem or use case

Keyword seed selection keeps coming up: #445 (image and doc captions win the seeds), #2381 (test and doc rationale
nodes take over the seeds), #2384 (local variables win the seeds), #3810 (single words from the question cross
domains). Each of those asks for smarter automatic seeding.

Often, though, the caller already knows where to start: an agent that has the file open, a user who knows the symbol,
or an external retriever (embeddings, hybrid search, a learned ranker). Today there is no way to tell query "start
here". You have to word the question so the keyword scorer happens to land there.

Proposed solution

graphify query "<question>" --seed X [--seed Y ...]

  • Each value resolves exactly as affected resolves its seed (affected.resolve_seed): node id, unique label,
    callable name, or a repo-relative or absolute file path anchored to the graph's root. There is one interpretation of
    a node reference.
  • It fails closed. Values that do not resolve to exactly one node are listed as skipped. If none resolve, the command
    reports it and does not fall back to keyword seeds.
  • The header shows Start (given): [...]. Without --seed, nothing changes.

Implemented in #4289 (62 lines and 7 tests; it passes on Python 3.10 and 3.13).

Alternatives considered

Area

Graph building or querying

Are you willing to submit a PR?

Yes, I can work on this (already open: #4289)

Activity

  1. github-actions commented on Oct 10, 2026

    @github-actions

    Thanks for opening this issue, @devkancheti4-design. A maintainer will take a look soon.

    If you would like to discuss it in real time, come say hi on our Discord server. For longer-form questions and ideas there is also GitHub Discussions.

    To help us triage, please make sure the report includes what you expected, what actually happened, and the steps (and a small sample) to reproduce it.

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

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions