How receptron/graphai works
Main Components
• Agent Modules: Include the various agent types distributed throughout the repository. You have several groups:
• agents (with subdirectories like agent_utils, data_agents, input_agents, llm_agents, service_agents, sleeper_agents, vanilla_agents, vanilla_node_agents)
• llm_agents (including modules for anthropic, gemini, groq, openai, replicate, slashgpt, token_bound_string, and tools)
• packages/agents, packages/agent_filters, and others for testing and utilities.
• CLI & Tooling: Represent the GraphAI CLI (in packages/cli) as an interface or gateway that allows users to run and interact with the engine. Also include packages/agentdoc and packages/test_utils to denote documentation and testing utilities.
• API and External Interfaces: As noted by the documentation and API references, include an API layer, and optionally external integration points (such as the web demo and Grapys GUI tool).
• Configuration and DSL Layer: Since developers define workflows in YAML/JSON (with examples in packages/samples, docs/examples, etc.), include a “Workflow Definition” component that feeds into the engine.
Architectural Patterns and Design Principles
• Modular and Plugin-like Structure: Emphasize that the system follows a plugin or modular architecture where diverse agent implementations can be added, replaced, or extended.
• Asynchronous Data Flow: Note that the engine is built around an asynchronous execution design, processing declarative data flows.
• Declarative Workflow DSL: Highlight the separation of workflow definition (YAML/JSON) from execution, similar to a configuration-driven runtime.
• Separation of Concerns: Illustrate clear demarcations – for example, the core engine versus communication with external LLM services (in llm_agents) and utility functions provided in packages.
Relevant Technologies, Frameworks, and Tools
• Node.js & TypeScript: Indications that the project is written in TypeScript (as seen in tsconfig.json files and .ts files).
• Build/Workflow Tools: Mention GitHub Actions workflows (.github/workflows folder), rollup builds (rollup.config.mjs), and linting/configuration files.