Skip to content

Commit 6913fbe

Browse files
committed
feat(*):Add Chinese README
1 parent 37057a8 commit 6913fbe

File tree

1 file changed

+205
-0
lines changed

1 file changed

+205
-0
lines changed

README-CN.md

Lines changed: 205 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,205 @@
1+
<p align="center">
2+
<h1 align="center">DeepSeek PHP Client</h1>
3+
<p align="center">🚀 社区驱动的 PHP SDK,用于 DeepSeek AI 接口集成</p>
4+
5+
<p align="center">
6+
<a href="https://packagist.org/packages/deepseek-php/deepseek-php-client">
7+
<img src="https://img.shields.io/packagist/v/deepseek-php/deepseek-php-client" alt="Latest Version">
8+
</a>
9+
<a href="https://php.net">
10+
<img src="https://img.shields.io/badge/PHP-8.1%2B-blue" alt="PHP Version">
11+
</a>
12+
<a href="LICENSE.md">
13+
<img src="https://img.shields.io/badge/license-MIT-brightgreen" alt="License">
14+
</a>
15+
<a href="https://github.com/deepseek-php/deepseek-php-client/actions">
16+
<img src="https://img.shields.io/github/actions/workflow/status/deepseek-php/deepseek-php-client/tests.yml" alt="Tests Status">
17+
</a>
18+
</p>
19+
</p>
20+
21+
## 目录
22+
- [✨ 特性](#-特性)
23+
- [📦 安装](#-安装)
24+
- [🚀 快速入门](#-快速入门)
25+
- [基本用法](#基本用法)
26+
- [高级配置](#高级配置)
27+
- [获取模型列表](#获取模型列表)
28+
- [框架集成](#-框架集成)
29+
- [🆕 迁移指南](#-迁移指南)
30+
- [📝 更新日志](#-更新日志)
31+
- [🧪 测试](#-测试)
32+
- [🔒 安全](#-安全)
33+
- [🤝 贡献者](#-贡献者)
34+
- [📄 许可](#-许可)
35+
36+
---
37+
38+
## ✨ 特性
39+
40+
- **无缝 API 集成**: DeepSeek AI 功能的 PHP 优先接口
41+
- **构建器模式**: 直观的链接请求构建方法
42+
- **企业级别**: 符合 PSR-18 规范
43+
- **模型灵活性**: 支持多种 DeepSeek 模型(Coder、Chat 等)
44+
- **流式传输**: 内置对实时响应处理的支持
45+
- **框架友好**: 提供 Laravel 和 Symfony 包
46+
47+
---
48+
49+
## 📦 安装
50+
51+
通过 Composer 安装:
52+
53+
```bash
54+
composer require deepseek-php/deepseek-php-client
55+
```
56+
57+
**要求**:
58+
- PHP 8.1+
59+
60+
---
61+
62+
## 🚀 快速入门
63+
64+
### 基本用法
65+
66+
只需两行代码即可开始:
67+
68+
```php
69+
use DeepSeek\DeepSeekClient;
70+
71+
$response = DeepSeekClient::build('your-api-key')
72+
->query('Explain quantum computing in simple terms')
73+
->run();
74+
75+
echo $response;
76+
```
77+
78+
📌 默认配置:
79+
- Model: `deepseek-chat`
80+
- Temperature: 0.8
81+
82+
### 高级配置
83+
84+
```php
85+
use DeepSeek\DeepSeekClient;
86+
use DeepSeek\Enums\Models;
87+
88+
$response = DeepSeekClient::build('your-api-key')
89+
->withBaseUrl('https://api.deepseek.com/v2')
90+
->withModel(Models::CODER->value)
91+
->withTemperature(1.2)
92+
->run();
93+
94+
echo 'API Response:'.$response;
95+
```
96+
97+
### 获取模型列表
98+
99+
```php
100+
use DeepSeek\DeepSeekClient;
101+
102+
$response = DeepSeekClient::build('your-api-key')
103+
->getModelsList()
104+
->run();
105+
106+
echo $response; // {"object":"list","data":[{"id":"deepseek-chat","object":"model","owned_by":"deepseek"},{"id":"deepseek-reasoner","object":"model","owned_by":"deepseek"}]}
107+
```
108+
109+
### 🛠 框架集成
110+
111+
### [Laravel Deepseek Package](https://github.com/deepseek-php/deepseek-laravel)
112+
113+
### [Symfony Deepseek Package](https://github.com/deepseek-php/deepseek-symfony)
114+
115+
---
116+
117+
## 🚧 迁移指南
118+
119+
从 v1.x 升级?请查看我们全面的 [迁移指南](MIGRATION.md) 了解重大变更和升级说明。
120+
121+
---
122+
123+
## 📝 更新日志
124+
125+
详细的发布说明可在 [CHANGELOG.md](CHANGELOG.md) 查看。
126+
127+
---
128+
129+
## 🧪 测试
130+
131+
```bash
132+
./vendor/bin/pest
133+
```
134+
135+
测试覆盖范围涵盖 v2.1。
136+
137+
---
138+
139+
## 🔒 安全
140+
141+
**报告漏洞**: [omaralwi2010@gmail.com](mailto:omaralwi2010@gmail.com)
142+
143+
---
144+
145+
## 🤝 贡献者
146+
147+
非常感谢为这个项目做出贡献的人! 🎉💖
148+
149+
<table>
150+
<tr>
151+
<td align="center">
152+
<a href="https://github.com/omaralalwi">
153+
<img src="https://avatars.githubusercontent.com/u/25439498?v=4" width="60px;" style="border-radius:50%;" alt="Omar AlAlwi"/>
154+
<br />
155+
<b>Omar AlAlwi</b>
156+
</a>
157+
<br />
158+
🏆 Creator
159+
</td>
160+
<td align="center">
161+
<a href="https://github.com/aymanalhattami">
162+
<img src="https://avatars.githubusercontent.com/u/34315778?v=4" width="60px;" style="border-radius:50%;" alt="Ayman Alhattami"/>
163+
<br />
164+
<b>Ayman Alhattami</b>
165+
</a>
166+
<br />
167+
⭐ Contributor
168+
</td>
169+
<td align="center">
170+
<a href="https://github.com/moassaad">
171+
<img src="https://avatars.githubusercontent.com/u/155223476?v=4" width="60px;" style="border-radius:50%;" alt="Mohammad Asaad"/>
172+
<br />
173+
<b>Mohammad Asaad</b>
174+
</a>
175+
<br />
176+
⭐ Contributor
177+
</td>
178+
<td align="center">
179+
<a href="https://github.com/OpadaAlzaiede">
180+
<img src="https://avatars.githubusercontent.com/u/48367429?v=4" width="60px;" style="border-radius:50%;" alt="Opada Alzaiede"/>
181+
<br />
182+
<b>Opada Alzaiede</b>
183+
</a>
184+
<br />
185+
⭐ Contributor
186+
</td>
187+
<td align="center">
188+
<a href="https://github.com/hishamco">
189+
<img src="https://avatars.githubusercontent.com/u/3237266?v=4" width="60px;" style="border-radius:50%;" alt="Hisham Bin Ateya"/>
190+
<br />
191+
<b>Hisham Bin Ateya</b>
192+
</a>
193+
<br />
194+
⭐ Contributor
195+
</td>
196+
</tr>
197+
</table>
198+
199+
**想要贡献?** 查看 [contributing guidelines](./CONTRIBUTING.md) 并提交拉取请求! 🚀
200+
201+
---
202+
203+
## 📄 许可
204+
205+
基于 [MIT License](LICENSE.md) 开源协议。

0 commit comments

Comments
 (0)