|
| 1 | +import { defineConfig } from 'vitepress' |
| 2 | + |
| 3 | +// https://vitepress.dev/reference/site-config |
| 4 | +export default defineConfig({ |
| 5 | + title: "torch-rechub", |
| 6 | + description: "A Lighting Pytorch Framework for Recommendation Models, Easy-to-use and Easy-to-extend.", |
| 7 | + head: [ |
| 8 | + ['link', { rel: 'icon', href: '/torch-rechub/favicon.ico' }] |
| 9 | + ], |
| 10 | + // GitHub Pages 部署路径(仓库名) |
| 11 | + base: '/torch-rechub/', |
| 12 | + |
| 13 | + // 路径重写:将 en/ 目录映射到根路径 |
| 14 | + rewrites: { |
| 15 | + 'en/:rest*': ':rest*' |
| 16 | + }, |
| 17 | + |
| 18 | + // 多语言配置 |
| 19 | + locales: { |
| 20 | + root: { |
| 21 | + label: 'English', |
| 22 | + lang: 'en', |
| 23 | + title: 'torch-rechub', |
| 24 | + description: 'A Lighting Pytorch Framework for Recommendation Models, Easy-to-use and Easy-to-extend.', |
| 25 | + themeConfig: { |
| 26 | + nav: [ |
| 27 | + { text: 'Home', link: '/' }, |
| 28 | + { text: 'Introduction', link: '/introduction' }, |
| 29 | + { text: 'Documentation', link: '/manual/installation' }, |
| 30 | + { text: 'API', link: '/manual/api-reference/basic' }, |
| 31 | + { text: 'Blog', link: '/blog/match' }, |
| 32 | + { text: 'Contributing', link: '/contributing' } |
| 33 | + ], |
| 34 | + sidebar: { |
| 35 | + '/manual/': [ |
| 36 | + { |
| 37 | + text: 'Getting Started', |
| 38 | + items: [ |
| 39 | + { text: 'Installation', link: '/manual/installation' }, |
| 40 | + { text: 'Getting Started', link: '/manual/getting-started' } |
| 41 | + ] |
| 42 | + }, |
| 43 | + { |
| 44 | + text: 'Tutorials', |
| 45 | + items: [ |
| 46 | + { text: 'Recall Models', link: '/manual/tutorials/matching' }, |
| 47 | + { text: 'Ranking Models', link: '/manual/tutorials/ranking' }, |
| 48 | + { text: 'Multi-Task Learning', link: '/manual/tutorials/multi-task' } |
| 49 | + ] |
| 50 | + }, |
| 51 | + { |
| 52 | + text: 'API Reference', |
| 53 | + items: [ |
| 54 | + { text: 'Basic Components', link: '/manual/api-reference/basic' }, |
| 55 | + { text: 'Models', link: '/manual/api-reference/models' }, |
| 56 | + { text: 'Trainers', link: '/manual/api-reference/trainers' }, |
| 57 | + { text: 'Utilities', link: '/manual/api-reference/utils' } |
| 58 | + ] |
| 59 | + }, |
| 60 | + { |
| 61 | + text: 'Others', |
| 62 | + items: [ |
| 63 | + { text: 'FAQ', link: '/manual/faq' } |
| 64 | + ] |
| 65 | + } |
| 66 | + ], |
| 67 | + '/blog/': [ |
| 68 | + { |
| 69 | + text: 'Blog', |
| 70 | + items: [ |
| 71 | + { text: 'Matching Training Guide', link: '/blog/match' }, |
| 72 | + { text: 'Ranking Training Guide', link: '/blog/rank' } |
| 73 | + ] |
| 74 | + } |
| 75 | + ] |
| 76 | + }, |
| 77 | + socialLinks: [ |
| 78 | + { icon: 'github', link: 'https://github.com/datawhalechina/torch-rechub' } |
| 79 | + ] |
| 80 | + } |
| 81 | + }, |
| 82 | + zh: { |
| 83 | + label: '中文', |
| 84 | + lang: 'zh-CN', |
| 85 | + title: 'torch-rechub', |
| 86 | + description: '一个基于 PyTorch 的易用、可扩展且高性能的推荐系统框架', |
| 87 | + themeConfig: { |
| 88 | + nav: [ |
| 89 | + { text: '首页', link: '/zh/' }, |
| 90 | + { text: '项目介绍', link: '/zh/introduction' }, |
| 91 | + { text: '项目文档', link: '/zh/manual/installation' }, |
| 92 | + { text: 'API', link: '/zh/manual/api-reference/basic' }, |
| 93 | + { text: '博客', link: '/zh/blog/match' }, |
| 94 | + { text: '贡献指南', link: '/zh/contributing' } |
| 95 | + ], |
| 96 | + sidebar: { |
| 97 | + '/zh/manual/': [ |
| 98 | + { |
| 99 | + text: '入门指南', |
| 100 | + items: [ |
| 101 | + { text: '安装指南', link: '/zh/manual/installation' }, |
| 102 | + { text: '快速开始', link: '/zh/manual/getting-started' } |
| 103 | + ] |
| 104 | + }, |
| 105 | + { |
| 106 | + text: '教程', |
| 107 | + items: [ |
| 108 | + { text: '召回模型', link: '/zh/manual/tutorials/matching' }, |
| 109 | + { text: '排序模型', link: '/zh/manual/tutorials/ranking' }, |
| 110 | + { text: '多任务学习', link: '/zh/manual/tutorials/multi-task' } |
| 111 | + ] |
| 112 | + }, |
| 113 | + { |
| 114 | + text: 'API 参考', |
| 115 | + items: [ |
| 116 | + { text: '基础组件', link: '/zh/manual/api-reference/basic' }, |
| 117 | + { text: '模型', link: '/zh/manual/api-reference/models' }, |
| 118 | + { text: '训练器', link: '/zh/manual/api-reference/trainers' }, |
| 119 | + { text: '工具类', link: '/zh/manual/api-reference/utils' } |
| 120 | + ] |
| 121 | + }, |
| 122 | + { |
| 123 | + text: '其他', |
| 124 | + items: [ |
| 125 | + { text: '常见问题', link: '/zh/manual/faq' }, |
| 126 | + { text: '参考资料', link: '/zh/参考资料/参考资料' } |
| 127 | + ] |
| 128 | + } |
| 129 | + ], |
| 130 | + '/zh/blog/': [ |
| 131 | + { |
| 132 | + text: '博客', |
| 133 | + items: [ |
| 134 | + { text: '召回模型训练指南', link: '/zh/blog/match' }, |
| 135 | + { text: '排序模型训练指南', link: '/zh/blog/rank' }, |
| 136 | + { text: 'HSTU 模型复现', link: '/zh/blog/hstu_reproduction' } |
| 137 | + ] |
| 138 | + } |
| 139 | + ] |
| 140 | + }, |
| 141 | + socialLinks: [ |
| 142 | + { icon: 'github', link: 'https://github.com/datawhalechina/torch-rechub' } |
| 143 | + ] |
| 144 | + } |
| 145 | + } |
| 146 | + }, |
| 147 | + |
| 148 | + themeConfig: { |
| 149 | + logo: '/img/logo.png' |
| 150 | + } |
| 151 | +}) |
0 commit comments