Files
opencode/packages/web/src/content/docs/zh-cn/share.mdx

129 lines
2.6 KiB
Plaintext
Raw 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.
---
title: 分享
description: 分享您的 opencode 对话。
---
opencode 的共享功能允许您建立指向 opencode 对话的公共链接,以便您可以与蓝牙进行战斗或从其他人那里获得帮助。
:::note
任何知道链接的人都可以公開访问共享对话。
:::
---
## 它是如何運作的
当您分享对话时opencode
1. 为您的会话建立唯一的公共 URL
2. 将您的对话歷史記錄同步到我们的服务器
3. 通过可共享链接访问对话 — `opncd.ai/s/<share-id>`
---
## 分享
opencode 支持清晰控制对话共享方式的共享模式:
---
### 手动(默认)
在默认情况下opencode 使用手动共享模式。会话不会自动共享,但您可以使用 `/share` 命令手动共享它们:
```
/share
```
这将生成一个唯一的 URL将其复制到您的剪贴簿中。
要在[配置文件](/docs/config) 中显式设置手动模式:
```json title="opencode.json"
{
"$schema": "https://opncd.ai/config.json",
"share": "manual"
}
```
---
### 自动分享
您可以通过将 [config file](/docs/config) 中的 `share` 选项设置为 `"auto"` 来为所有新对话启用自动共享:
```json title="opencode.json"
{
"$schema": "https://opncd.ai/config.json",
"share": "auto"
}
```
启用自动共享後,每个新对话都会自动共享并生成链接。
---
### 已禁用
您可以通过将 [config file](/docs/config) 中的 `share` 选项设置为 `"disabled"` 来完全禁用共享:
```json title="opencode.json"
{
"$schema": "https://opncd.ai/config.json",
"share": "disabled"
}
```
To enforce this across your team for a given project, add it to the `opencode.json` in your project and check into Git.
---
## 取消共享
要停止共享对话并将其從公共访问中删除:
```
/unshare
```
这将删除共享链接并删除与对话相关的数据。
---
## 隱私
分享对话時需要記住一些事項。
---
### 数据保留
共享对话仍然可以访问,直到您明確取消共享。这
包括:
- 完整的对话歷史記錄
- 所有消息和回复
- 会话元数据
---
### 建議
- 仅共享不包含敏感資訊的对话。
- 分享之前查看对话內容。
- 協作完成後取消共享对话。
- 避免与专有程式碼或機密数据共享对话。
- 对于敏感专案,完全禁用共享。
---
## 对于企業
对于企業部署,共享功能可以是:
- **出于安全合規性完全禁用**
- **仅限** 仅通过 SSO 进行身份验证的用户
- **在您自己的基礎設施上自行託管**
[了解更多关于在您的组织中使用opencode的](/docs/enterprise)。