Skip to content

Commit c4eacb3

Browse files
feat: add Engilsh README (#57)
1 parent 48b0f12 commit c4eacb3

2 files changed

Lines changed: 52 additions & 13 deletions

File tree

‎README.md‎

Lines changed: 11 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -2,17 +2,15 @@
22

33
<h1 align="center">LAYA SERVER</h1>
44

5-
<p align="center">基于 <a href="https://github.com/NandhaKishorM/laya">Laya</a> 的 System One HTTP 服务与单管理员控制台。</p>
5+
<p align="center">English | <a href="README.zh-CN.md">简体中文</a></p>
66

7-
## 功能
7+
## About LAYA SERVER
88

9-
- 通过 `POST /v1/systemone` 和 Bearer API Key 调用 Laya 推理,支持 `noul`、`choice` 和 `score` 问题。
10-
- 在控制台创建、撤销 API Key,使用 Playground 调试请求,并查看 token 用量与每日趋势。
11-
- FastAPI、React 和 SQLite 部署在同一容器中;控制台支持简体中文、英语和繁体中文。
9+
LAYA SERVER packages the System One inference capabilities of [upstream Laya](https://github.com/NandhaKishorM/laya) as a standalone service, making them easier to deploy and use in your applications.
1210

13-
## 快速开始
11+
## Quick Start
1412

15-
镜像发布后,安装 Docker 并运行(如需固定版本,将 `latest` 换成对应标签):
13+
Once the image is published, install Docker and run the following command. Replace `latest` with a version tag to pin a release.
1614

1715
```sh
1816
docker run -d --name laya-server --init --restart unless-stopped \
@@ -23,11 +21,11 @@ docker run -d --name laya-server --init --restart unless-stopped \
2321
1panel/laya-server:latest
2422
```
2523

26-
将示例密码换成自己的密码,访问 `http://YOUR_SERVER_IP:8080` 登录,在 **API Keys** 页面创建密钥;完整密钥只显示一次。`/health/ready` 可用于检查模型文件。数据保存在 `laya-data` 卷中。
24+
Replace the sample password with your own, then sign in at `http://YOUR_SERVER_IP:8080`. Create a key on the **API Keys** page; the full key is shown only once. `/health/ready` checks the model files. Data is stored in the `laya-data` volume.
2725

28-
`YOUR_SERVER_IP` 是服务器 IP。若通过域名访问,可在反向代理上配置 HTTPS 并转发到服务器的 8080 端口。
26+
`YOUR_SERVER_IP` is your server's IP address. To use a domain name, configure HTTPS on a reverse proxy and forward requests to port 8080 on the server.
2927

30-
## 调用 API
28+
## Call the API
3129

3230
```sh
3331
curl -X POST http://YOUR_SERVER_IP:8080/v1/systemone \
@@ -36,8 +34,8 @@ curl -X POST http://YOUR_SERVER_IP:8080/v1/systemone \
3634
-d '{"state":{"message":"I was charged twice"},"questions":{"refund":{"type":"noul","instructions":"Does the customer ask for a refund?"}}}'
3735
```
3836

39-
成功响应包含 `answers`、`model` 和实际的 `usage` token 计数。发布镜像内置 multilingual 模型;`model=auto`(默认)和 `model=multilingual` 均可使用。更多请求格式见控制台 **Documentation** 页面。
37+
Successful responses include `answers`, `model`, and actual token counts in `usage`. The published image includes the multilingual model; `model=auto` (the default) and `model=multilingual` are available. See **Documentation** in the console for more request examples.
4038

41-
## 许可与反馈
39+
## License and Feedback
4240

43-
本项目采用 [Apache License 2.0](LICENSE) 许可证。问题和建议请提交至 [GitHub Issues](https://github.com/1Panel-dev/laya-server/issues)。
41+
This project is licensed under [Apache License 2.0](LICENSE). For issues and suggestions, visit [GitHub Issues](https://github.com/1Panel-dev/laya-server/issues).

‎README.zh-CN.md‎

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
<p align="center"><img src="frontend/public/laya-server-logo-black.png" alt="LAYA SERVER" width="120" /></p>
2+
3+
<h1 align="center">LAYA SERVER</h1>
4+
5+
<p align="center"><a href="README.md">English</a> | 简体中文</p>
6+
7+
## 关于 LAYA SERVER
8+
9+
LAYA SERVER 将[上游 Laya](https://github.com/NandhaKishorM/laya) 的 System One 推理能力封装为独立服务,方便开发者在自己的应用中部署和使用。
10+
11+
## 快速开始
12+
13+
镜像发布后,安装 Docker 并运行(如需固定版本,将 `latest` 换成对应标签):
14+
15+
```sh
16+
docker run -d --name laya-server --init --restart unless-stopped \
17+
-p 8080:8080 \
18+
-v laya-data:/data \
19+
-e LAYA_ADMIN_USERNAME=admin \
20+
-e LAYA_ADMIN_PASSWORD='change-this-admin-password' \
21+
1panel/laya-server:latest
22+
```
23+
24+
将示例密码换成自己的密码,访问 `http://YOUR_SERVER_IP:8080` 登录,在 **API Keys** 页面创建密钥;完整密钥只显示一次。`/health/ready` 可用于检查模型文件。数据保存在 `laya-data` 卷中。
25+
26+
`YOUR_SERVER_IP` 是服务器 IP。若通过域名访问,可在反向代理上配置 HTTPS 并转发到服务器的 8080 端口。
27+
28+
## 调用 API
29+
30+
```sh
31+
curl -X POST http://YOUR_SERVER_IP:8080/v1/systemone \
32+
-H 'Authorization: Bearer YOUR_API_KEY' \
33+
-H 'Content-Type: application/json' \
34+
-d '{"state":{"message":"I was charged twice"},"questions":{"refund":{"type":"noul","instructions":"Does the customer ask for a refund?"}}}'
35+
```
36+
37+
成功响应包含 `answers`、`model` 和实际的 `usage` token 计数。发布镜像内置 multilingual 模型;`model=auto`(默认)和 `model=multilingual` 均可使用。更多请求格式见控制台 **Documentation** 页面。
38+
39+
## 许可与反馈
40+
41+
本项目采用 [Apache License 2.0](LICENSE) 许可证。问题和建议请提交至 [GitHub Issues](https://github.com/1Panel-dev/laya-server/issues)。

0 commit comments

Comments
 (0)