MCPcopy Create free account
hub / github.com/DeusData/codebase-memory-mcp / subjectLine

Function subjectLine

graph-ui/src/twin/render-model.ts:740–751  ·  view source on GitHub ↗

The first factual sentence on every level, including the positive leaf case.

(ir: SemanticIR)

Source from the content-addressed store, hash-verified

738
739/** The first factual sentence on every level, including the positive leaf case. */
740function subjectLine(ir: SemanticIR): string {
741 const lines = Math.max(1, ir.symbol.range.end.line - ir.symbol.range.start.line);
742 const file = displayFile(ir.symbol.uri) ?? ir.symbol.uri;
743 if (ir.steps.value.length === 0) {
744 return `${ir.symbol.name} is a ${plainKind(ir.symbol.kind)} spanning ${lines} lines in ${file}. `
745 + 'The index resolves no outgoing calls from this symbol.';
746 }
747 const start = ir.symbol.range.start.line + 1;
748 const end = ir.symbol.range.end.line;
749 return `${ir.symbol.name} is a ${plainKind(ir.symbol.kind)} spanning ${lines} lines in ${file}, `
750 + `from line ${start} through line ${end}.`;
751}
752
753/** Type references whose declaration lies outside the focused symbol. */
754function sharedNames(ir: SemanticIR): string[] {

Callers 1

emptyModelFunction · 0.85

Calls 2

displayFileFunction · 0.90
plainKindFunction · 0.90

Tested by

no test coverage detected