mirror of
https://github.com/czlonkowski/n8n-mcp.git
synced 2026-02-06 05:23:08 +00:00
feat: add incremental template updates and fix metadata generation
Template Updates: - Add npm script for incremental template fetch (fetch:templates:update) - Create MEMORY_TEMPLATE_UPDATE.md with comprehensive documentation - Update 48 new templates (2598 → 2646 total) - Latest template now from September 24, 2025 Metadata Generation Fixes: - Update model from gpt-4o-mini to gpt-5-mini-2025-08-07 - Remove temperature parameter (not supported in batch API) - Increase max_completion_tokens from 1000 to 3000 - Add comprehensive error file handling to batch-processor - Process failed requests and assign default metadata - Save error files for debugging (temp/batch/) Test Updates: - Update all test files to use gpt-5-mini-2025-08-07 model - 3 test assertions updated in metadata-generator.test.ts - 1 test option updated in batch-processor.test.ts Documentation: - Add troubleshooting section for metadata generation - Include error handling examples - Document incremental vs full rebuild modes 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
@@ -71,7 +71,7 @@ describe('BatchProcessor', () => {
|
||||
|
||||
options = {
|
||||
apiKey: 'test-api-key',
|
||||
model: 'gpt-4o-mini',
|
||||
model: 'gpt-5-mini-2025-08-07',
|
||||
batchSize: 3,
|
||||
outputDir: './test-temp'
|
||||
};
|
||||
|
||||
@@ -18,7 +18,7 @@ describe('MetadataGenerator', () => {
|
||||
let generator: MetadataGenerator;
|
||||
|
||||
beforeEach(() => {
|
||||
generator = new MetadataGenerator('test-api-key', 'gpt-4o-mini');
|
||||
generator = new MetadataGenerator('test-api-key', 'gpt-5-mini-2025-08-07');
|
||||
});
|
||||
|
||||
describe('createBatchRequest', () => {
|
||||
@@ -35,7 +35,7 @@ describe('MetadataGenerator', () => {
|
||||
expect(request.custom_id).toBe('template-123');
|
||||
expect(request.method).toBe('POST');
|
||||
expect(request.url).toBe('/v1/chat/completions');
|
||||
expect(request.body.model).toBe('gpt-4o-mini');
|
||||
expect(request.body.model).toBe('gpt-5-mini-2025-08-07');
|
||||
expect(request.body.response_format.type).toBe('json_schema');
|
||||
expect(request.body.response_format.json_schema.strict).toBe(true);
|
||||
expect(request.body.messages).toHaveLength(2);
|
||||
@@ -217,7 +217,7 @@ describe('MetadataGenerator', () => {
|
||||
// but should not cause any injection in our code
|
||||
expect(userMessage).toContain('<script>alert("xss")</script>');
|
||||
expect(userMessage).toContain('javascript:alert(1)');
|
||||
expect(request.body.model).toBe('gpt-4o-mini');
|
||||
expect(request.body.model).toBe('gpt-5-mini-2025-08-07');
|
||||
});
|
||||
|
||||
it('should handle extremely long template names', () => {
|
||||
|
||||
Reference in New Issue
Block a user