cortexweaver
Version:
CortexWeaver is a command-line interface (CLI) tool that orchestrates a swarm of specialized AI agents, powered by Claude Code and Gemini CLI, to assist in software development. It transforms a high-level project plan (plan.md) into a series of coordinate
77 lines • 2.29 kB
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.CritiqueAgentIntegration = void 0;
/**
* Critique Agent Integration Operations
* Handles operations specific to the Critique agent
*/
class CritiqueAgentIntegration {
constructor(driver) {
this.driver = driver;
}
/**
* Get artifact details by ID (for Critique agent)
*/
async getArtifactDetails(artifactId) {
const session = this.driver.session();
try {
const result = await session.run(`
MATCH (a)
WHERE a.id = $artifactId
RETURN a
`, { artifactId });
if (result.records.length === 0) {
return null;
}
return result.records[0].get('a').properties;
}
finally {
await session.close();
}
}
/**
* Create critique node (for Critique agent)
*/
async createCritiqueNode(critiqueData) {
const session = this.driver.session();
try {
const result = await session.run(`
CREATE (c:Critique {
id: $id,
issues: $issues,
suggestions: $suggestions,
severity: $severity,
createdAt: $createdAt
})
RETURN c.id as id
`, {
id: critiqueData.id || `critique-${Date.now()}`,
issues: critiqueData.issues || [],
suggestions: critiqueData.suggestions || [],
severity: critiqueData.severity || 'medium',
createdAt: new Date().toISOString()
});
return result.records[0].get('id');
}
finally {
await session.close();
}
}
/**
* Link critique to artifact (for Critique agent)
*/
async linkCritiqueToArtifact(critiqueId, artifactId) {
const session = this.driver.session();
try {
await session.run(`
MATCH (c:Critique {id: $critiqueId}), (a {id: $artifactId})
CREATE (c)-[:CRITIQUES]->(a)
`, { critiqueId, artifactId });
}
finally {
await session.close();
}
}
}
exports.CritiqueAgentIntegration = CritiqueAgentIntegration;
//# sourceMappingURL=agent-integration-critique.js.map