regex-mcp
Version:
正则表达式生成器MCP服务,支持纳税人识别号、企业名称、法人姓名、法人身份证、法人电话等要素。
21 lines (20 loc) • 777 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.getAllRegex = getAllRegex;
exports.getRegexByKey = getRegexByKey;
exports.exportRegexMarkdown = exportRegexMarkdown;
const regex_service_1 = require("../core/regex.service");
const markdown_1 = require("../utils/markdown");
// 示例:获取所有正则表达式项
function getAllRegex() {
return (0, regex_service_1.getAllRegexPatterns)();
}
// 示例:根据关键要素获取正则表达式项
function getRegexByKey(key) {
return (0, regex_service_1.getRegexPatternByKey)(key);
}
// 示例:导出Markdown文件
function exportRegexMarkdown(filePath) {
const patterns = (0, regex_service_1.getAllRegexPatterns)();
(0, markdown_1.exportMarkdown)(filePath, patterns);
}