3gpp-mcp-server
Version:
MCP Server for querying 3GPP telecom protocol specifications
40 lines (32 loc) • 1.29 kB
text/typescript
import { TSpecLLMDownloader, DatasetConfig } from './utils/dataset-downloader';
import * as path from 'path';
async function main() {
const config: DatasetConfig = {
repositoryUrl: 'https://huggingface.co/datasets/rasoul-nikbakht/TSpec-LLM',
localPath: path.join(__dirname, '..', 'data', 'TSpec-LLM'),
formats: ['markdown', 'docx'],
};
const downloader = new TSpecLLMDownloader(config);
try {
console.log('Starting TSpec-LLM dataset download...');
await downloader.downloadDataset();
console.log('Analyzing dataset structure...');
const structure = await downloader.analyzeStructure();
console.log('\n=== Dataset Analysis ===');
console.log(`Total files: ${structure.totalFiles}`);
console.log(`Markdown files: ${structure.formats.markdown}`);
console.log(`DOCX files: ${structure.formats.docx}`);
console.log('\nReleases found:');
Object.entries(structure.releases).forEach(([release, count]) => {
console.log(` ${release}: ${count} files`);
});
console.log('\nSample files:');
structure.sampleFiles.forEach(file => {
console.log(` ${file.path} (${Math.round(file.size / 1024)}KB, ${file.format})`);
});
} catch (error) {
console.error('Error:', error);
process.exit(1);
}
}
main();