Skip to content

Measure call resolution on a pinned corpus of outside repos - #724

Open
jaywyawhare wants to merge 1 commit into
hydra-db:mainfrom
jaywyawhare:bench/code-corpus
Open

jaywyawhare wants to merge 1 commit into
hydra-db:mainfrom
jaywyawhare:bench/code-corpus

Conversation

@jaywyawhare

@jaywyawhare jaywyawhare commented Dec 5, 2026 •

Copy link
Copy Markdown
Contributor

Summary

Measure call resolution on a pinned corpus of outside repos, not mostly on SelfGraph's own code. A corpus file pins nine repos, a runner fetches and scores them, and the README results are the measured figures.

Implementation details

Decisions

  • benchmarks/code/corpus.json pins nine repos to full SHAs with root, languages, reference, and license: requests and ky at their old pins, plus sanic, aiohttp, typer, and rich in Python and zod, hono, and fp-ts in TypeScript. All MIT or Apache-2.0.
  • benchmarks/code/run_corpus.py fetches each repo at its pin into a cache (--cache), scores it with resolve_accuracy's functions, and prints one table plus a JSON file with the date, commit, and tool versions. --only picks repos and --self adds this repo's roots.
  • Precision is below 100% in three roots, each with one cause written up in the README: zod (a name declared as both value and type), hono (router.match reaching the interface method), and rich (a subclass override). sanic recall is 52.7%, mostly calls through its own package imported by absolute name.
  • The README says the outside rows are the fairer guide, since the resolver was developed against this repo.

Validation

  • The changed tests fail on base and pass here: the corpus file is valid, and run_corpus runs end to end on a local fixture repo with no network, checking the pinned commit is the one used.
  • scripts/precheck.py passes (326 changed lines, clean trial merge).
  • The full corpus run takes about 4 minutes. Ruff passes.

Limits

No resolver change.

Linked issue

Closes #720

AI Assistance

AI tools helped write and test parts of this. I reviewed and ran every change.

Checklist

  • Implements an issue a maintainer has /approved.
  • Small and scoped to that issue.
  • New errors have a code and hint, the same on API, CLI, and MCP in both SDKs (see AGENTS.md). No new codes.
  • Breaking changes described below, or none.

Breaking changes

None.


Prove it works
Open in [code]smith · Need help on this PR? Tag @codesmith-bot with what you need.

@arrry-hydraDB arrry-hydraDB added feature New capability area: parity Python vs TypeScript, conformance effort: S Under ~50 lines, one place labels Dec 5, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: parity Python vs TypeScript, conformance effort: S Under ~50 lines, one place feature New capability

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Measure call resolution on a pinned corpus of outside repos

2 participants