refactor: remove built-in routers

PrismFacet is a generic framework — routers are registered by
consumers (e.g., ClawRoles), not bundled with the plugin.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
zhi
2026-04-21 10:34:57 +00:00
parent bee3dcb84c
commit 76ac2e959a
4 changed files with 0 additions and 33 deletions

1
.gitignore vendored
View File

@@ -2,4 +2,3 @@ node_modules/
dist/
plugin/**/*.js
plugin/**/*.js.map
!routers/*.js

View File

@@ -1,4 +0,0 @@
// Zero-dependency router: returns agentId directly
export function resolve(ctx) {
return ctx.agentId || "";
}

View File

@@ -1,14 +0,0 @@
// Reads agent position from ego.json (optional dependency on PaddedCell/ego-mgr)
import { readFileSync } from "node:fs";
import { homedir } from "node:os";
const EGO_PATH = `${homedir()}/.openclaw/ego.json`;
export function resolve(ctx) {
try {
const ego = JSON.parse(readFileSync(EGO_PATH, "utf8"));
return ego["agent-scope"]?.[ctx.agentId]?.position || "";
} catch {
return "";
}
}

View File

@@ -1,14 +0,0 @@
// Reads agent role from ego.json (optional dependency on PaddedCell/ego-mgr)
import { readFileSync } from "node:fs";
import { homedir } from "node:os";
const EGO_PATH = `${homedir()}/.openclaw/ego.json`;
export function resolve(ctx) {
try {
const ego = JSON.parse(readFileSync(EGO_PATH, "utf8"));
return ego["agent-scope"]?.[ctx.agentId]?.role || "";
} catch {
return "";
}
}