Skip to content

feat(miner-foundation): extract scoring preview/model modules into gittensory-engine #2282

Description

@JSONbored

Move src/scoring/preview.ts, src/scoring/model.ts, and src/scoring/pending-pr-scenarios.ts into packages/gittensory-engine/src/scoring/ (as a subdirectory, since these are a cohesive group rather than standalone signals). These give the miner the same score-preview machinery the existing gittensory_preview_local_pr_score MCP tool already calls server-side, so a miner can preview its own PR score fully locally without a network round-trip.

Deliverables

  • packages/gittensory-engine/src/scoring/preview.ts, packages/gittensory-engine/src/scoring/model.ts, packages/gittensory-engine/src/scoring/pending-pr-scenarios.ts — verbatim ports preserving the three-file structure.
  • src/scoring/preview.ts, src/scoring/model.ts, src/scoring/pending-pr-scenarios.ts become thin re-export shims from @jsonbored/gittensory-engine.
  • Existing scoring test suites pass unmodified against the shims.
  • packages/gittensory-engine/src/index.ts re-exports the new scoring/ subpath (e.g. export * as scoring from "./scoring/preview" or equivalent — pick whichever barrel shape keeps import ergonomics closest to the existing src/scoring/* call sites).

References

  • src/scoring/preview.ts, src/scoring/model.ts, src/scoring/pending-pr-scenarios.ts — the three files to port.
  • packages/gittensory-engine/ — created by the package-skeleton issue (must land first).
  • packages/gittensory-mcp/bin/gittensory-mcp.js (gittensory_preview_local_pr_score tool, ~line 448) — the existing server-side consumer this extraction gives a local-first equivalent for.

Metadata

Metadata

Assignees

No one assigned

    Labels

    gittensor:featureGittensor-scored feature linked to a feature issue — scores a 0.25x multiplier.help wantedExtra attention is needed

    Projects

    Status
    Done

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions