# Third-party notices

This package is a **Pi coding agent port** of the DeepSeek Harness plugin
`dsh-connect-trae`. The port reuses the upstream plugin's protocol core
(credential store and token refresh, device identity, loopback shim, SOLO
upstream, remote catalog, SSE bridge, usage/check-in client) under the terms of
its MIT license.

## Upstream plugin

- Package: `dsh-connect-trae` v2.3.1
- Author: dingminhua
- Copyright: Copyright (c) 2026 LaoDing
- License: MIT
- Repository: https://github.com/dingminhua/dsh-connect-trae

`lib/trae-core.js` is generated by `build-core.mjs` from the upstream bundle
`lib/index.js`. The transformation is mechanical and documented step by step in
that script:

1. replace the `@deepseek-ai/*` imports with Node built-ins / a Pi-owned path;
2. drop the DSH-only adapter region (`createTraeAdapter`, `PiAiAdapter`,
   `resolveRetryPolicy`);
3. point the plugin-owned refreshed-credential copies at
   `~/.pi/agent/cache/dsh-connect-trae/`;
4. replace `withFileLock` + `writeFileAtomic` with plain `node:fs/promises`
   writes, and `server.unref()` the shim listener;
5. keep the protocol core **and** the usage / check-in logic
   (`TraeUsageClient`, `toCredits`, `toCheckin`, `safeMessage`, the check-in
   guard), stripping only the model-config / model-detail / DSH-entry regions.

## License text

MIT License

Copyright (c) 2026 LaoDing

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.

## Trademarks

Trae is a trademark of its respective owner. This project is not affiliated
with Trae or DeepSeek. It only drives the user's own signed-in account on the
user's own machine and is intended for personal study and research.
