Files

84 lines
1.9 KiB
Markdown
Raw Permalink Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
# AI Tool Station 🚀
一个开箱即用的 **AI 工具聚合站**,内置多种热门 AI 小工具,界面现代美观,一键部署,谁用谁火。
## ✨ 功能特性
- 🎨 现代化 UI,响应式设计,移动端友好
- 🧰 内置多个 AI 小工具:
- 文本改写
- 代码解释
- 文案生成
- 中英翻译
- 内容总结
- ⚡ 纯前端实现,零依赖,一键部署到任意静态托管
- 🔌 支持接入任意 OpenAI 兼容 API(可选)
- 🧪 内置本地模拟模式,无需 API Key 也能体验
## 📁 目录结构
```
ai-tool-station/
├── index.html # 主页面
├── css/
│ └── style.css # 样式文件
├── js/
│ ├── app.js # 主逻辑
│ └── tools.js # AI 工具定义与模拟实现
├── README.md
```
## 🚀 一键部署
### 方式一:直接打开
下载后双击 `index.html` 即可在浏览器中使用。
### 方式二:Vercel / Netlify
1. 将本项目推送到 GitHub
2. 在 Vercel / Netlify 中导入仓库
3. 无需构建命令,直接部署
### 方式三:GitHub Pages
1. 推送到 GitHub 仓库
2. Settings → Pages → 选择 `main` 分支根目录
3. 访问 `https://<你的用户名>.github.io/<仓库名>/`
### 方式四:本地服务
```bash
python3 -m http.server 8080
# 打开 http://localhost:8080
```
## 🔑 接入真实 AI API(可选)
在页面右上角点击 ⚙️ 设置,填入:
- API Base URL(例如 `https://api.openai.com/v1`)
- API Key
- 模型名称(例如 `gpt-4o-mini`)
保存后所有工具将调用真实 API。留空则使用内置模拟模式。
## 🧩 添加新工具
编辑 `js/tools.js`,在 `TOOLS` 数组中添加一个新的工具对象即可:
```js
{
id: 'my-tool',
name: '我的工具',
icon: '✨',
desc: '工具描述',
placeholder: '请输入内容...',
prompt: (input) => `请处理以下内容:\n${input}`
}
```
## 📄 License
MIT