instagit 0.1.2 → 0.1.3
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/index.js +6 -3
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -317,7 +317,7 @@ async function registerAnonymousToken(apiUrl) {
|
|
|
317
317
|
// src/index.ts
|
|
318
318
|
var server = new import_mcp.McpServer({
|
|
319
319
|
name: "instagit",
|
|
320
|
-
version: "0.1.
|
|
320
|
+
version: "0.1.3"
|
|
321
321
|
});
|
|
322
322
|
var TOOL_DESCRIPTION = `Analyze any Git repository with AI. Point it at a repo and ask questions about the codebase. Use cases include:
|
|
323
323
|
- Understanding unfamiliar codebases: 'Explain the architecture and main components'
|
|
@@ -326,7 +326,9 @@ var TOOL_DESCRIPTION = `Analyze any Git repository with AI. Point it at a repo a
|
|
|
326
326
|
- Dependency analysis: 'What external services does this app depend on?'
|
|
327
327
|
- Onboarding help: 'How would I add a new API endpoint following existing patterns?'
|
|
328
328
|
- Bug investigation: 'Where might null pointer exceptions occur in the data pipeline?'
|
|
329
|
-
- Migration planning: 'What would it take to upgrade from React 17 to 18?'
|
|
329
|
+
- Migration planning: 'What would it take to upgrade from React 17 to 18?'
|
|
330
|
+
|
|
331
|
+
If you hit a rate limit (429), the user's monthly token credits are exhausted \u2014 they can wait for the reset or upgrade their plan. Free-tier repos larger than 2 GB will be rejected with a 413 error; suggest upgrading to Pro or Max for unlimited repo size.`;
|
|
330
332
|
server.tool(
|
|
331
333
|
"ask_repo",
|
|
332
334
|
TOOL_DESCRIPTION,
|
|
@@ -340,12 +342,13 @@ server.tool(
|
|
|
340
342
|
async ({ repo, prompt, ref }, extra) => {
|
|
341
343
|
const apiUrl = getApiUrl();
|
|
342
344
|
const tracker = createProgressTracker();
|
|
345
|
+
const progressToken = extra._meta?.progressToken ?? `ask_repo_${Date.now()}`;
|
|
343
346
|
const sendProgress = async (message) => {
|
|
344
347
|
try {
|
|
345
348
|
await extra.sendNotification({
|
|
346
349
|
method: "notifications/progress",
|
|
347
350
|
params: {
|
|
348
|
-
progressToken
|
|
351
|
+
progressToken,
|
|
349
352
|
progress: tracker.outputTokens,
|
|
350
353
|
message
|
|
351
354
|
}
|