quackstack 1.0.22 → 1.0.23
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/commands/agents.js +7 -7
- package/package.json +1 -1
package/dist/commands/agents.js
CHANGED
|
@@ -16,10 +16,10 @@ async function askQuestion(query) {
|
|
|
16
16
|
});
|
|
17
17
|
}
|
|
18
18
|
export async function generateAgentMd(projectName, outputPath) {
|
|
19
|
-
const agentPath = outputPath || path.join(process.cwd(), "
|
|
19
|
+
const agentPath = outputPath || path.join(process.cwd(), "AGENTS.md");
|
|
20
20
|
const exists = await fs.access(agentPath).then(() => true).catch(() => false);
|
|
21
21
|
if (exists) {
|
|
22
|
-
const shouldOverwrite = await askQuestion("⚠️
|
|
22
|
+
const shouldOverwrite = await askQuestion("⚠️ AGENTS.md already exists. Overwrite? (y/n): ");
|
|
23
23
|
if (!shouldOverwrite) {
|
|
24
24
|
console.log("Cancelled.");
|
|
25
25
|
return;
|
|
@@ -63,11 +63,11 @@ ${s.content.slice(0, 300)}...
|
|
|
63
63
|
`;
|
|
64
64
|
const aiClient = getAIClient();
|
|
65
65
|
const prompt = `
|
|
66
|
-
You are an expert at creating
|
|
66
|
+
You are an expert at creating AGENTS.md files following the agents.md specification (https://agents.md/).
|
|
67
67
|
|
|
68
|
-
Based on the codebase context provided, generate a comprehensive
|
|
68
|
+
Based on the codebase context provided, generate a comprehensive AGENTS.md file that describes this project as an AI agent.
|
|
69
69
|
|
|
70
|
-
The
|
|
70
|
+
The AGENTS.md should include:
|
|
71
71
|
|
|
72
72
|
# Agent Metadata
|
|
73
73
|
- name: A descriptive name for this codebase agent
|
|
@@ -118,10 +118,10 @@ Make it detailed, actionable, and follow the agents.md spec format with proper m
|
|
|
118
118
|
Codebase Context:
|
|
119
119
|
${context}
|
|
120
120
|
`;
|
|
121
|
-
console.log("Generating
|
|
121
|
+
console.log("Generating AGENTS.md...");
|
|
122
122
|
const agentMd = await aiClient.generateAnswer(prompt, context);
|
|
123
123
|
await fs.writeFile(agentPath, agentMd, "utf-8");
|
|
124
|
-
console.log(`
|
|
124
|
+
console.log(`AGENTS.md generated at ${agentPath}`);
|
|
125
125
|
}
|
|
126
126
|
function detectTechnologies(snippets) {
|
|
127
127
|
const techs = new Set();
|