forked from cleveragents/cleveragents-core
30 lines
678 B
Python
30 lines
678 B
Python
from __future__ import annotations
|
|
|
|
import json
|
|
import sys
|
|
from pathlib import Path
|
|
|
|
from cleveragents.actor.config import ActorConfiguration
|
|
|
|
|
|
def main() -> None:
|
|
if len(sys.argv) < 2:
|
|
raise SystemExit("config path required")
|
|
|
|
config_path = Path(sys.argv[1])
|
|
config = ActorConfiguration.from_file(path=config_path)
|
|
payload = {
|
|
"provider": config.provider,
|
|
"model": config.model,
|
|
"unsafe": config.unsafe,
|
|
"graph_keys": sorted(config.graph_descriptor.keys())
|
|
if config.graph_descriptor
|
|
else [],
|
|
"options": config.options,
|
|
}
|
|
print(json.dumps(payload))
|
|
|
|
|
|
if __name__ == "__main__":
|
|
main()
|