n8n-nodes-github-copilot 3.38.0 → 3.38.2
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.
|
@@ -105,6 +105,7 @@ class GitHubCopilotOpenAI {
|
|
|
105
105
|
const messagesParam = this.getNodeParameter("messages", i, {
|
|
106
106
|
message: [],
|
|
107
107
|
});
|
|
108
|
+
console.log('📥 Manual mode - messagesParam:', JSON.stringify(messagesParam, null, 2));
|
|
108
109
|
if (messagesParam.message && Array.isArray(messagesParam.message)) {
|
|
109
110
|
for (const msg of messagesParam.message) {
|
|
110
111
|
messages.push({
|
|
@@ -113,6 +114,7 @@ class GitHubCopilotOpenAI {
|
|
|
113
114
|
});
|
|
114
115
|
}
|
|
115
116
|
}
|
|
117
|
+
console.log('📥 Manual mode - parsed messages:', JSON.stringify(messages, null, 2));
|
|
116
118
|
}
|
|
117
119
|
if (messages.length === 0) {
|
|
118
120
|
messages.push({
|
|
@@ -120,6 +122,7 @@ class GitHubCopilotOpenAI {
|
|
|
120
122
|
content: "Hello! How can you help me?",
|
|
121
123
|
});
|
|
122
124
|
}
|
|
125
|
+
console.log('📤 Final messages being sent to API:', JSON.stringify(messages, null, 2));
|
|
123
126
|
let parsedTools = [];
|
|
124
127
|
if (tools) {
|
|
125
128
|
try {
|
|
@@ -193,6 +196,10 @@ class GitHubCopilotOpenAI {
|
|
|
193
196
|
if (seed > 0) {
|
|
194
197
|
requestBody.seed = seed;
|
|
195
198
|
}
|
|
199
|
+
console.log('🚀 Sending request to GitHub Copilot API:');
|
|
200
|
+
console.log(' Model:', copilotModel);
|
|
201
|
+
console.log(' Messages count:', messages.length);
|
|
202
|
+
console.log(' Request body:', JSON.stringify(requestBody, null, 2));
|
|
196
203
|
const response = await (0, utils_1.makeApiRequest)(this, GitHubCopilotEndpoints_1.GITHUB_COPILOT_API.ENDPOINTS.CHAT_COMPLETIONS, requestBody, false);
|
|
197
204
|
const retriesUsed = ((_a = response._retryMetadata) === null || _a === void 0 ? void 0 : _a.retries) || 0;
|
|
198
205
|
if (retriesUsed > 0) {
|
package/dist/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "n8n-nodes-github-copilot",
|
|
3
|
-
"version": "3.38.
|
|
3
|
+
"version": "3.38.2",
|
|
4
4
|
"description": "n8n community node for GitHub Copilot with CLI integration, Chat API access, and AI Chat Model for workflows - access GPT-5, Claude, Gemini and more using your Copilot subscription",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"homepage": "https://github.com/sufficit/n8n-nodes-github-copilot",
|
|
@@ -77,6 +77,11 @@ class DynamicModelsManager {
|
|
|
77
77
|
});
|
|
78
78
|
}
|
|
79
79
|
static modelsToN8nOptions(models) {
|
|
80
|
+
const nameCount = new Map();
|
|
81
|
+
models.forEach((model) => {
|
|
82
|
+
const displayName = model.display_name || model.name || model.id;
|
|
83
|
+
nameCount.set(displayName, (nameCount.get(displayName) || 0) + 1);
|
|
84
|
+
});
|
|
80
85
|
return models.map((model) => {
|
|
81
86
|
const badges = [];
|
|
82
87
|
if (model.capabilities) {
|
|
@@ -96,10 +101,14 @@ class DynamicModelsManager {
|
|
|
96
101
|
}
|
|
97
102
|
const displayName = model.display_name || model.name || model.id;
|
|
98
103
|
const badgesText = badges.length > 0 ? ` [${badges.join(" • ")}]` : "";
|
|
104
|
+
const hasDuplicates = (nameCount.get(displayName) || 0) > 1;
|
|
99
105
|
let description = "";
|
|
100
106
|
if (model.capabilities) {
|
|
101
107
|
const limits = model.capabilities.limits || {};
|
|
102
108
|
const parts = [];
|
|
109
|
+
if (hasDuplicates) {
|
|
110
|
+
parts.push(`ID: ${model.id}`);
|
|
111
|
+
}
|
|
103
112
|
if (limits.max_context_window_tokens) {
|
|
104
113
|
parts.push(`Context: ${(limits.max_context_window_tokens / 1000).toFixed(0)}k`);
|
|
105
114
|
}
|
|
@@ -111,6 +120,9 @@ class DynamicModelsManager {
|
|
|
111
120
|
}
|
|
112
121
|
description = parts.join(" • ");
|
|
113
122
|
}
|
|
123
|
+
else if (hasDuplicates) {
|
|
124
|
+
description = `ID: ${model.id}`;
|
|
125
|
+
}
|
|
114
126
|
return {
|
|
115
127
|
name: `${displayName}${badgesText}`,
|
|
116
128
|
value: model.id,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "n8n-nodes-github-copilot",
|
|
3
|
-
"version": "3.38.
|
|
3
|
+
"version": "3.38.2",
|
|
4
4
|
"description": "n8n community node for GitHub Copilot with CLI integration, Chat API access, and AI Chat Model for workflows - access GPT-5, Claude, Gemini and more using your Copilot subscription",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"homepage": "https://github.com/sufficit/n8n-nodes-github-copilot",
|