Files
hack/tools/scripts/llm-key-hunter/results/_cache/content/amadeussasuke_amadeussasuke.github.io.json
OpenCode 68a9071cf1 feat: reconcile local master with origin (exa/hot-platform hunters, leaks ledger, latest results)
Local branch had diverged from origin/master (sibling commits on the same base). Rewrote local history linearly on top of origin/master, folding in all local content: exa/hot-platform discovery hunters, leaks ledger, nightly sweep orchestrator, updated .gitignore and skill docs, plus the latest hunt output and vault state. Remote-only files (vault keys, channel scripts) were restored rather than dropped, so the resulting tree is a full union of both sides.
2026-08-07 12:53:47 +08:00

1 line
7.0 KiB
JSON

{"repo": "amadeussasuke/amadeussasuke.github.io", "files": {"index.html": {"df48f73b9fc97c872d33145609dfefaa6049ef7b": {"t": 1786067750.179868, "n": 6105, "h": "2fc90c0c69a16bae", "c": "<!DOCTYPE html>\r\n<html lang=\"zh-CN\">\r\n<head>\r\n <meta charset=\"UTF-8\">\r\n <meta name=\"viewport\" content=\"width=device-width, initial-scale=1.0\">\r\n <title>智能图书馆管理系统</title>\r\n <link href=\"https://cdn.bootcdn.net/ajax/libs/twitter-bootstrap/5.1.3/css/bootstrap.min.css\" rel=\"stylesheet\">\r\n <link rel=\"stylesheet\" href=\"styles.css\">\r\n</head>\r\n<body>\r\n <div class=\"container py-5\">\r\n <h1 class=\"mb-4 text-center\">智能图书馆管理系统</h1>\r\n \r\n <!-- 文件上传模块 -->\r\n <div class=\"card shadow mb-4\">\r\n <div class=\"card-body\">\r\n <h5 class=\"card-title\"><i class=\"bi bi-upload\"></i> 文件上传</h5>\r\n <div class=\"input-group\">\r\n <input type=\"file\" id=\"fileInput\" class=\"form-control\" accept=\".txt\">\r\n <button class=\"btn btn-primary\" id=\"uploadBtn\">上传文件</button>\r\n </div>\r\n <div class=\"progress mt-3\" style=\"height: 25px; display: none;\" id=\"progressBar\">\r\n <div class=\"progress-bar progress-bar-striped bg-success\" \r\n role=\"progressbar\" style=\"width: 0%\">0%</div>\r\n </div>\r\n </div>\r\n </div>\r\n\r\n <!-- 检索模块 -->\r\n <div class=\"card shadow mb-4\">\r\n <div class=\"card-body\">\r\n <h5 class=\"card-title\"><i class=\"bi bi-search\"></i> 图书检索</h5>\r\n <div class=\"input-group\">\r\n <input type=\"text\" id=\"searchInput\" class=\"form-control\" \r\n placeholder=\"输入书名、作者或分类标签\">\r\n <button class=\"btn btn-outline-secondary\" id=\"searchBtn\">搜索</button>\r\n </div>\r\n </div>\r\n </div>\r\n\r\n <!-- 图书展示 -->\r\n <div class=\"card shadow\">\r\n <div class=\"card-body\">\r\n <h5 class=\"card-title\"><i class=\"bi bi-book\"></i> 馆藏目录</h5>\r\n <table class=\"table table-hover\" id=\"bookTable\">\r\n <thead>\r\n <tr>\r\n <th>书名</th>\r\n <th>分类标签</th>\r\n <th>中图法编号</th>\r\n <th>文件大小</th>\r\n </tr>\r\n </thead>\r\n <tbody id=\"bookList\"></tbody>\r\n </table>\r\n <button class=\"btn btn-success float-end\" id=\"exportBtn\">导出ZIP</button>\r\n </div>\r\n </div>\r\n </div>\r\n\r\n <!-- 依赖脚本 -->\r\n <script src=\"https://cdn.bootcdn.net/ajax/libs/jquery/3.6.0/jquery.min.js\"></script>\r\n <script src=\"https://cdn.bootcdn.net/ajax/libs/jszip/3.7.1/jszip.min.js\"></script>\r\n <script>\r\n // 配置参数\r\n const CONFIG = {\r\n API_KEY: 'sk-yrskfylzspmvypkvmzneelrqhnzpuzwdwhuoklpmutdopbgf', // 替换为实际API密钥\r\n MAX_FILE_SIZE: 5 * 1024 * 1024, // 5MB\r\n SUPPORTED_ENCODINGS: ['gbk', 'utf-8']\r\n };\r\n\r\n // 编码检测器\r\n function detectEncoding(buffer) {\r\n const bytes = new Uint8Array(buffer);\r\n if (bytes.length >= 3 && bytes[0] === 0xEF && bytes[1] === 0xBB && bytes[2] === 0xBF) {\r\n return 'utf-8';\r\n }\r\n try {\r\n new TextDecoder('gbk').decode(bytes.slice(0, 1000));\r\n return 'gbk';\r\n } catch {\r\n return 'utf-8';\r\n }\r\n }\r\n\r\n // 文件上传处理器\r\n async function handleFileUpload(file) {\r\n try {\r\n // 显示进度条\r\n $('#progressBar').show().find('.progress-bar')\r\n .css('width', '10%').text('读取文件中...');\r\n\r\n // 读取文件内容\r\n const buffer = await file.arrayBuffer();\r\n const encoding = detectEncoding(buffer);\r\n const decoder = new TextDecoder(encoding);\r\n const content = decoder.decode(buffer);\r\n\r\n // 更新进度\r\n updateProgress(30, 'AI智能分类中...');\r\n\r\n // 调用分类API\r\n const classification = await classifyContent(content);\r\n \r\n // 保存文件\r\n updateProgress(70, '保存文件中...');\r\n await saveFile(file.name, content, classification);\r\n\r\n // 完成处理\r\n updateProgress(100, '上传完成!');\r\n setTimeout(() => $('#progressBar').hide(), 1000);\r\n refreshBookList();\r\n\r\n } catch (error) {\r\n console.error('上传失败:', error);\r\n $('#progressBar').hide();\r\n alert(`上传失败: ${error.message}`);\r\n }\r\n }\r\n\r\n // 分类函数\r\n async function classifyContent(text) {\r\n const response = await fetch('https://api.deepseek.com/v1/classify', {\r\n method: 'POST',\r\n headers: {\r\n 'Content-Type': 'application/json',\r\n 'Authorization': `Bearer ${CONFIG.API_KEY}`\r\n },\r\n body: JSON.stringify({\r\n text: text.slice(0, 5000),\r\n categories: ['恋爱', '悬疑', '科幻', '历史', '奇幻', '恐怖', '励志', '教育']\r\n })\r\n });\r\n\r\n if (!response.ok) throw new Error('分类服务不可用');\r\n const data = await response.json();\r\n \r\n return {\r\n tag: data.top_category || '其他',\r\n clc: mapCLC(data.top_category)\r\n };\r\n }\r\n\r\n // 中图法映射\r\n function mapCLC(tag) {\r\n const mapping = {\r\n '恋爱': 'I247.5',\r\n '悬疑': 'I247.56',\r\n '科幻': 'I247.55',\r\n '历史': 'K20',\r\n '奇幻': 'I247.59',\r\n '恐怖': 'I247.57',\r\n '励志': 'B821',\r\n '教育': 'G40'\r\n };\r\n return mapping[tag] || 'Z';\r\n }\r\n\r\n // DOM绑定\r\n $('#uploadBtn').click(() => $('#fileInput').click());\r\n $('#fileInput').change(async function() {\r\n const file = this.files[0];\r\n if (file) await handleFileUpload(file);\r\n });\r\n </script>\r\n</body>\r\n</html>\r\n"}}}}