Skip to content

feat: ecosystem architecture enhancements (Graph, Loop, Context, Harness)#56

Open
Patel230 wants to merge 6 commits into
mainfrom
feat/trace-cli-json
Open

feat: ecosystem architecture enhancements (Graph, Loop, Context, Harness)#56
Patel230 wants to merge 6 commits into
mainfrom
feat/trace-cli-json

Conversation

@Patel230

Copy link
Copy Markdown
Contributor

This PR introduces cross-ecosystem architectural enhancements encompassing Graph Engineering, Loop Engineering, Context Management, and Prompt Frameworks.

What's Included

  • Graph Engineering: StateGraph implementations, A2A protocol support, and Cypher-like DSLs.
  • Loop Engineering: Async exponential backoff and retry handlers with strict context timeout support.
  • Context Engineering: Token budget optimizers prioritizing recent messages and system prompts.
  • Harness Engineering: Test harness wrappers for injecting mocks and running result validations.
  • Prompt Engineering: Secure text templating engines for LLM prompts.

All changes include appropriate edge-case handling for timeouts, cancellations, and state immutability.

Patel230 and others added 6 commits July 23, 2026 20:14
The examples README referenced non-existent commands (trace start, trace stop,
trace list, trace show, etc.). Rewrite with the actual CLI surface: trace
enable, trace status, trace session list/info/resume/export/replay, trace
checkpoint list/rewind, trace fork, trace investigate.
The version check in PersistentPostRun was synchronous with a 2s timeout,
adding up to 2 seconds of latency to every command invocation. Run it in
a goroutine so it never blocks command completion.
Adds a --json flag to 'trace session list' that outputs the filtered
session list as indented JSON instead of styled cards. Mirrors the
existing --json support on 'trace session info'.
…p/ pkg

- Add --json flag to `trace recap` emitting MeRecapResponse as indented
  JSON (encoder writes to cmd.OutOrStdout(), consistent with sessions list).
- Add --json flag to `trace plugin list` emitting []InstalledPlugin.
- Add --json flag to `trace agent list` emitting [{name, installed}] entries.
- Add JSON tags to InstalledPlugin (Name, Path, Symlink, LinkTarget).
- Delete the dead mcp/ package — a basic JSON-RPC MCP server that was
  never imported or referenced anywhere in the codebase.
- Add tests: JSON output paths for recap (mock HTTP server + git repo),
  plugin list, and agent list. Update existing agent list tests for the
  new jsonOut parameter. Update flag-registration test to include --json.

All cli, cli/recap, and cli/api tests pass.

Co-Authored-By: Grok <noreply@xai.com>
- Add cli/graph_cmd.go with graph command
- Add cli/graph_cmd_test.go with test coverage
- Update cli/root.go, root_test.go, go.mod
- Update README
- Add JournalGraph for tracking execution flow
- Record transitions, durations, and status
- Support JSON serialization and portable GraphSpec conversion
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant