@thanh01.pmt/project-assessment-kit
v0.1.1
Published
High-quality evidence-first assessment engine for coding projects (Scratch, Web, Python, Unity, Roblox) using 2-pass AST file selection, Scratch semantic digest, and claim verification.
Downloads
315
Readme
@thanh01.pmt/project-assessment-kit
High-quality, evidence-first assessment engine for coding projects (Scratch, Web, Python, Unity, Roblox, IoT).
Features
- 2-Pass Relevance Selection (
context-builder.ts):- Pass 1: Path heuristics via
@thanh01.pmt/domain-kit(scoreByPath). - Pass 2: Content logic signal ranking (
scoreByContent) with tiered budget allocation (Core: 12KB, Mid: 6KB, Tail: 2KB, total $\le 120$KB). - Eliminates naive 5KB/file truncations.
- Pass 1: Path heuristics via
- Scratch Semantic Digest (
scratch-digest.ts):- Parses Scratch 3.0
project.jsoninto a dense structured summary (sprite inventory, block counts, custom procedures, variables, and event wiring). - Preserves core logic scripts while replacing bulky 60KB raw JSON dumps.
- Parses Scratch 3.0
- Claim & Evidence Verifier (
claim-verifier.ts):- Follows research-kit evidence pattern to check that all cited quotes in justifications exist verbatim in the supplied context.
- Automatically tags ungrounded assertions and supports a single-pass retry repair loop.
- Academic & Objective Prompt Builder (
prompt-builder.ts):- Anchors evaluation purely on rubric level descriptors without blunt hardcoded caps.
- Retains unassigned learning objectives with
[unassigned-LO]tags.
Installation
pnpm add @thanh01.pmt/project-assessment-kitQuick Start
import { buildAssessmentContext, parseScratchProject, verifyReportGrounding } from '@thanh01.pmt/project-assessment-kit';
// 1. Build bounded context
const context = buildAssessmentContext(rawFiles, {
maxTotalBytes: 120_000,
coreBudget: 12_000,
});
// 2. Verify evidence grounding
const result = verifyReportGrounding(report, context.fullCode);
console.log('Fully grounded:', result.isFullyGrounded);