@passioncode-ai/fabric-agent-adapter 0.22.0 → 0.24.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/CHANGELOG.md +98 -0
- package/README.md +1 -1
- package/package.json +1 -1
- package/plugins/fabric-agent-adapter/.claude-plugin/plugin.json +1 -1
- package/plugins/fabric-agent-adapter/skills/adapting-projects-to-fabric/SKILL.md +3 -3
- package/plugins/fabric-agent-adapter/skills/adapting-projects-to-fabric/scripts/adapt_project.py +2 -2
- package/plugins/fabric-agent-adapter/skills/building-fabric-services/SKILL.md +7 -4
- package/plugins/fabric-agent-adapter/skills/building-fabric-services/references/dashboard-kit.md +7 -4
- package/plugins/fabric-agent-adapter/skills/building-fabric-services/references/delegation.md +10 -7
- package/plugins/fabric-agent-adapter/skills/building-fabric-services/references/estate-record.md +32 -15
- package/plugins/fabric-agent-adapter/skills/building-fabric-services/references/lifecycle.md +64 -14
- package/plugins/fabric-agent-adapter/skills/building-fabric-services/references/protocol.md +9 -5
- package/plugins/fabric-agent-adapter/skills/building-fabric-services/scripts/check_service.py +24 -4
- package/plugins/fabric-agent-adapter/skills/building-fabric-services/scripts/fabric-delegation.mjs +35 -20
- package/plugins/fabric-agent-adapter/skills/building-fabric-services/scripts/fabric-estate.mjs +77 -9
- package/plugins/fabric-agent-adapter/skills/building-fabric-services/scripts/fabric-service.mjs +317 -45
- package/plugins/fabric-agent-adapter/skills/building-fabric-services/scripts/fabric_delegation.py +53 -19
- package/plugins/fabric-agent-adapter/skills/building-fabric-services/scripts/fabric_estate.py +107 -16
- package/plugins/fabric-agent-adapter/skills/building-fabric-services/scripts/fabric_service.py +472 -62
- package/plugins/fabric-agent-adapter/skills/building-fabric-services/scripts/sample_service.py +10 -3
- package/plugins/fabric-agent-adapter/skills/creating-fabric-agents/SKILL.md +3 -3
- package/plugins/fabric-agent-adapter/skills/working-with-fabric/SKILL.md +1 -1
- package/plugins/fabric-agent-adapter/skills/working-with-fabric/scripts/fabric_session.py +1 -1
package/plugins/fabric-agent-adapter/skills/building-fabric-services/scripts/sample_service.py
CHANGED
|
@@ -350,7 +350,8 @@ def register(args: argparse.Namespace) -> int:
|
|
|
350
350
|
else {"manager": "none"},
|
|
351
351
|
"paths": {"data": str(data), "logs": []},
|
|
352
352
|
"fabricManifest": str(manifest),
|
|
353
|
-
|
|
353
|
+
# DEC-0061: who installed it, by role and never by name — a person runs this register command.
|
|
354
|
+
"installedAt": fs.now_iso(), "installedBy": {"by": "person", "role": "operator", "tool": "sample_service.py register %s" % VERSION},
|
|
354
355
|
}
|
|
355
356
|
try:
|
|
356
357
|
path = fs.write_descriptor(descriptor, Path(args.services_dir) if args.services_dir else None)
|
|
@@ -361,11 +362,13 @@ def register(args: argparse.Namespace) -> int:
|
|
|
361
362
|
return 0
|
|
362
363
|
|
|
363
364
|
|
|
364
|
-
def
|
|
365
|
+
def build_parser() -> argparse.ArgumentParser:
|
|
365
366
|
parser = argparse.ArgumentParser(description=__doc__, formatter_class=argparse.RawDescriptionHelpFormatter)
|
|
367
|
+
fs.add_supervisor_argument(parser) # the marker a supervisor passes (DEC-0057), before or after the command
|
|
366
368
|
sub = parser.add_subparsers(dest="command", required=True)
|
|
367
369
|
for name in ("serve", "register"):
|
|
368
370
|
p = sub.add_parser(name)
|
|
371
|
+
fs.add_supervisor_argument(p)
|
|
369
372
|
p.add_argument("--port", type=int, required=True)
|
|
370
373
|
p.add_argument("--data-dir", required=True)
|
|
371
374
|
p.add_argument("--token-file")
|
|
@@ -378,7 +381,11 @@ def main(argv: Optional[list] = None) -> int:
|
|
|
378
381
|
p.add_argument("--services-dir")
|
|
379
382
|
p.add_argument("--label")
|
|
380
383
|
p.add_argument("--plist")
|
|
381
|
-
|
|
384
|
+
return parser
|
|
385
|
+
|
|
386
|
+
|
|
387
|
+
def main(argv: Optional[list] = None) -> int:
|
|
388
|
+
args = build_parser().parse_args(argv)
|
|
382
389
|
return serve(args) if args.command == "serve" else register(args)
|
|
383
390
|
|
|
384
391
|
|
|
@@ -5,9 +5,9 @@ license: AGPL-3.0-only OR LicenseRef-PassionCode-Commercial
|
|
|
5
5
|
compatibility: Requires filesystem access and Python 3.9+. Exact schema checks additionally need git, Node.js, pnpm, and the pinned fabric-agent-contract checkout (a public repository). Works without those tools in an explicitly degraded structural-check mode. Ships in one plugin with adapting-projects-to-fabric, whose scripts it reuses.
|
|
6
6
|
metadata:
|
|
7
7
|
author: PassionCode.ai
|
|
8
|
-
version: "0.
|
|
8
|
+
version: "0.24.0"
|
|
9
9
|
contract-version: "0.1.0"
|
|
10
|
-
contract-commit: "
|
|
10
|
+
contract-commit: "fe55fc67cba1a9e34a736da7d148d4fe2a8fbfa0"
|
|
11
11
|
---
|
|
12
12
|
|
|
13
13
|
# Creating Fabric-compatible agents
|
|
@@ -123,7 +123,7 @@ python3 <plugin-dir>/skills/adapting-projects-to-fabric/scripts/adapt_project.py
|
|
|
123
123
|
The effect class is declared, never defaulted: ask the author what the agent does outside itself when the request
|
|
124
124
|
does not say. Cost presets are only for a run whose cost varies; their amounts come from the author or measured runs.
|
|
125
125
|
|
|
126
|
-
Pin exactly contract `0.1.0` at commit `
|
|
126
|
+
Pin exactly contract `0.1.0` at commit `fe55fc67cba1a9e34a736da7d148d4fe2a8fbfa0` and
|
|
127
127
|
read the pinned guide before implementing protocol details. If this skill is installed
|
|
128
128
|
without its sibling, the scaffolder is absent: create the bundle by hand from the pinned
|
|
129
129
|
contract's `docs/guides/connecting-compatible-agents.md` and mark the structural check
|
|
@@ -60,7 +60,7 @@ WATCH_MAX_BACKOFF_S = 900
|
|
|
60
60
|
SESSION_ID = re.compile(r"[A-Za-z0-9._:-]{1,128}")
|
|
61
61
|
LOOPBACK_ORIGIN = re.compile(r"http://127\.0\.0\.1:(\d{1,5})")
|
|
62
62
|
LOCAL_ORIGIN = re.compile(r'"origin": "http://(?:127\.0\.0\.1|localhost)')
|
|
63
|
-
VERSION = "0.
|
|
63
|
+
VERSION = "0.24.0"
|
|
64
64
|
HOSTS = {"claude": "Claude Code", "codex": "Codex", "kimi": "Kimi Code"}
|
|
65
65
|
# A session Fabric launched. FABRIC_LAUNCHED_SESSION=1 is the marker Fabric is asked to set (need D6); the others are
|
|
66
66
|
# what Fabric already gives a launched session (fabric sessionBundle.ts): only their NAMES are looked at, never a value
|