Version 2.46.0 Release: Autonomous Anti-Blocking Generation and Trace Relevance Refinement

This commit is contained in:
g1nation
2026-05-03 01:13:33 +09:00
parent d2c9f624b8
commit fadf867978
5 changed files with 180 additions and 17 deletions
+51 -2
View File
@@ -101,9 +101,9 @@ describe('local project path preflight', () => {
'src/',
'src/agent.ts',
'Priority file previews:',
'### package.json',
'File: package.json',
'{"name":"g1nation"}',
'### src/agent.ts',
'File: src/agent.ts',
'export class AgentExecutor {}'
].join('\n');
@@ -125,4 +125,53 @@ describe('local project path preflight', () => {
expect(agent.isBlockingProjectKnowledgeAnswer(answer)).toBe(true);
});
it('extracts only preview file markers, not markdown headings inside previews', () => {
const context: any = {
globalStorageUri: { fsPath: path.join(root, '.storage') },
workspaceState: stateStore(),
globalState: stateStore()
};
const agent = new AgentExecutor(context) as any;
const localPathContext = [
'Priority file previews:',
'File: README.md',
'### 1. 벡터화된 고성능 추론 엔진',
'File: src/agent.ts',
'export class AgentExecutor {}'
].join('\n');
expect(agent.extractPriorityPreviewFiles(localPathContext)).toEqual(['README.md', 'src/agent.ts']);
});
it('writes a project knowledge record for accessible local project context', () => {
const context: any = {
globalStorageUri: { fsPath: path.join(root, '.storage') },
workspaceState: stateStore(),
globalState: stateStore()
};
const agent = new AgentExecutor(context) as any;
const localPathContext = [
`Path: ${root}`,
'Access: succeeded',
'Type: directory',
'Scanned tree:',
'package.json',
'src/',
'Priority file previews:',
'File: package.json',
'{"name":"g1nation"}',
'File: src/features/game/systems/CombatSystem.ts',
'export class CombatSystem {}'
].join('\n');
const record = agent.writeProjectKnowledgeRecord(localPathContext);
expect(record?.filePath).toBeTruthy();
expect(fs.existsSync(record.filePath)).toBe(true);
const content = fs.readFileSync(record.filePath, 'utf8');
expect(content).toContain('Project Knowledge Overview');
expect(content).toContain('package.json');
expect(content).toContain('src/features/game/systems/CombatSystem.ts');
});
});