MCPcopy Create free account
hub / github.com/IAmUnbounded/devctx / extractNextSteps

Function extractNextSteps

devctx/src/core/parser.ts:573–590  ·  view source on GitHub ↗
(messages: string[])

Source from the content-addressed store, hash-verified

571}
572
573function extractNextSteps(messages: string[]): string[] {
574 const steps: string[] = [];
575
576 for (const msg of messages.slice(-5)) {
577 const nextMatch = msg.match(
578 /(?:next steps?|todo|remaining|still need to|should also)\s*:?\s*\n?((?:\s*[-*\d.]+\s*.+\n?)+)/i
579 );
580 if (nextMatch) {
581 const items = nextMatch[1]
582 .split("\n")
583 .map((l) => l.replace(/^[\s\-*\d.]+/, "").trim())
584 .filter((l) => l.length > 5);
585 steps.push(...items);
586 }
587 }
588
589 return [...new Set(steps)].slice(0, 8);
590}
591
592function extractTaskFromMarkdown(content: string): string {
593 // Get title from first heading

Callers 1

parseClaudeSessionFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected