rtrt-agent 0.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 Kim DaeHyun (kernalix7@kodenet.io)
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.ko.md ADDED
@@ -0,0 +1,40 @@
1
+ # rtrt-agent
2
+
3
+ `rtrt-agent`는 RTRT의 OpenCode provenance 플러그인입니다. 지원되는 OpenCode
4
+ hook 사이에서 상위 session, agent, worktree, invocation 및 permission broker 문맥을
5
+ 보존하며 broker는 loopback에서만 실행됩니다.
6
+
7
+ ## 설치
8
+
9
+ ```sh
10
+ npm install rtrt-agent@0.1.0
11
+ ```
12
+
13
+ `opencode.json`의 단수형 `plugin` 배열에 패키지를 등록합니다.
14
+
15
+ ```json
16
+ {
17
+ "plugin": ["rtrt-agent"]
18
+ }
19
+ ```
20
+
21
+ OpenCode는 이름 있는 `RtrtProvenance` export를 로드합니다. 이 패키지는 의도적으로
22
+ default export를 제공하지 않습니다. 선택 사항인 RTRT TUI statusline은 별도 소스
23
+ 통합으로 유지되며 이 패키지에서 export하거나 pack하지 않습니다.
24
+
25
+ `rtrt setup --agent opencode --apply`는 다른 setup write보다 먼저 인식된 legacy RTRT
26
+ plugin을 제거합니다. Setup은 전체 RTRT 통합을 관리하지만 npm 설치는 수행하지 않으며,
27
+ 설정된 패키지는 OpenCode가 시작할 때 설치합니다. Setup은 `rtrt-agent`의 정확히 일치하는
28
+ bare, pinned, ranged, tuple, object 형식만 소유하며 bare `"rtrt-agent"` string 하나로
29
+ 정규화합니다. 이전의 미게시 `rtrt`와 초안 `rtrt-opencode` 패키지 spec은 외부 값이며 순서를
30
+ 유지합니다. 위 직접 등록과 `opencode plugin rtrt-agent --global`은 계속 유효합니다.
31
+
32
+ 관리 agent 소유권 상태는 다음 순서의 첫 비어 있지 않은 root에서 읽습니다.
33
+ `$OPENCODE_CONFIG_DIR`, `$XDG_CONFIG_HOME/opencode`, `~/.config/opencode`. 공존은 OMO
34
+ 4.19.4를 대상으로 CI에서 검사하고 OpenCode 1.18.29에서 직접 검증했으며, 어느 쪽도
35
+ 미래 버전 지원을 보장하지 않습니다. RTRT CLI 릴리스가 이를 등록하기 전에
36
+ `rtrt-agent@0.1.0`을 게시해야 합니다.
37
+
38
+ ## 라이선스
39
+
40
+ MIT
package/README.md ADDED
@@ -0,0 +1,41 @@
1
+ # rtrt-agent
2
+
3
+ `rtrt-agent` is RTRT's OpenCode provenance plugin. It preserves parent session,
4
+ agent, worktree, invocation, and permission-broker context across supported OpenCode
5
+ hooks while keeping the broker loopback-only.
6
+
7
+ ## Install
8
+
9
+ ```sh
10
+ npm install rtrt-agent@0.1.0
11
+ ```
12
+
13
+ Register the package in the singular `plugin` array in `opencode.json`:
14
+
15
+ ```json
16
+ {
17
+ "plugin": ["rtrt-agent"]
18
+ }
19
+ ```
20
+
21
+ OpenCode loads the named `RtrtProvenance` export. The package intentionally has no
22
+ default export. The optional RTRT TUI statusline remains a separate source integration
23
+ and is not exported or packed by this package.
24
+
25
+ `rtrt setup --agent opencode --apply` first removes a recognized legacy RTRT plugin
26
+ before any other setup write. It manages the full RTRT integration but performs no npm
27
+ installation; OpenCode installs the configured package at startup. Setup owns exact bare,
28
+ pinned, ranged, tuple, and object forms of `rtrt-agent` only, and normalizes them to one
29
+ bare `"rtrt-agent"` string. Old unpublished `rtrt` and draft `rtrt-opencode` package specs
30
+ are foreign and retain their order. The direct registration above and
31
+ `opencode plugin rtrt-agent --global` remain valid.
32
+
33
+ Managed-agent ownership state is read from the first nonempty root in this order:
34
+ `$OPENCODE_CONFIG_DIR`, `$XDG_CONFIG_HOME/opencode`, then `~/.config/opencode`.
35
+ Coexistence is CI-gated against OMO 4.19.4 and was verified on OpenCode 1.18.29; neither
36
+ is a future-version guarantee. `rtrt-agent@0.1.0` must be published before an RTRT CLI
37
+ release registers it.
38
+
39
+ ## License
40
+
41
+ MIT
package/index.js ADDED
@@ -0,0 +1 @@
1
+ export { RtrtProvenance } from "./rtrt-provenance.js"
package/package.json ADDED
@@ -0,0 +1,43 @@
1
+ {
2
+ "name": "rtrt-agent",
3
+ "version": "0.1.0",
4
+ "description": "RTRT provenance and permission-broker plugin for OpenCode",
5
+ "type": "module",
6
+ "main": "./index.js",
7
+ "exports": {
8
+ ".": "./index.js"
9
+ },
10
+ "files": [
11
+ "index.js",
12
+ "rtrt-provenance.js",
13
+ "README.md",
14
+ "README.ko.md",
15
+ "LICENSE"
16
+ ],
17
+ "scripts": {
18
+ "test": "node --test rtrt-provenance.test.mjs package.test.mjs tui/rtrt-statusline.test.mjs"
19
+ },
20
+ "engines": {
21
+ "node": ">=20"
22
+ },
23
+ "keywords": [
24
+ "opencode",
25
+ "plugin",
26
+ "provenance",
27
+ "rtrt"
28
+ ],
29
+ "author": "Kim DaeHyun <kernalix7@kodenet.io>",
30
+ "license": "MIT",
31
+ "repository": {
32
+ "type": "git",
33
+ "url": "git+https://github.com/kernalix7/rtrt.git",
34
+ "directory": "plugins/opencode"
35
+ },
36
+ "homepage": "https://github.com/kernalix7/rtrt#readme",
37
+ "bugs": {
38
+ "url": "https://github.com/kernalix7/rtrt/issues"
39
+ },
40
+ "dependencies": {
41
+ "@opencode-ai/sdk": "1.15.13"
42
+ }
43
+ }