# yutao1024/entcollabbench architecture

> Architecture diagram of the GitHub repository yutao1024/entcollabbench, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-09-24). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/yutao1024/entcollabbench
- Repository: https://github.com/yutao1024/entcollabbench

## Overview

EntCollabBench benchmarks enterprise collaborative-agent workflows, including MCP tool use, role-specialized peer collaboration, and policy-oriented approvals. In the main runtime path, a task reaches an agent, which uses role-selected tools to execute local or Arena MCP operations; approval agents can consult mounted reference documents. The repository also includes a judge component for benchmark scoring. The excerpts do not show the benchmark runner or full agent dispatch implementation, so those connections are not inferred; the graph reflects documented capabilities and sampled module responsibilities.

Main entry points: [`agent.py`](https://github.com/yutao1024/entcollabbench/blob/main/agent.py) (Agent service), [`tool/mcp_bridge.py`](https://github.com/yutao1024/entcollabbench/blob/main/tool/mcp_bridge.py) (MCP bridge), [`tool/toolsets.py`](https://github.com/yutao1024/entcollabbench/blob/main/tool/toolsets.py) (Role toolsets), [`tool/tool_registry.py`](https://github.com/yutao1024/entcollabbench/blob/main/tool/tool_registry.py) (Tool registry)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_agent_runtime["Agent runtime"]
  node_agent["Agent service<br/>[agent.py]"]
  node_contract["Agent API contract<br/>[api_schema.py]"]
  node_sessions[("Session bindings<br/>[session_store.py]")]
end

subgraph group_tooling["Tool execution"]
  node_role_tools["Role toolsets<br/>[toolsets.py]"]
  node_registry["Tool registry<br/>[tool_registry.py]"]
  node_lc_tools["LangChain tools<br/>[langchain_tools.py]"]
  node_executor["Tool executor<br/>[tool_executor.py]"]
  node_bridge["MCP bridge<br/>[mcp_bridge.py]"]
  node_gitea_isolation["Gitea isolation<br/>[gitea_isolation.py]"]
end

subgraph group_arena["Arena services"]
  node_arena_mcp["Arena MCP services"]
  node_seed_data[("Business seed data")]
end

subgraph group_evaluation["Approval and evaluation"]
  node_approval_docs["Approval references"]
  node_judge["Benchmark judge<br/>[judge.py]"]
end

node_user(("Task requester"))
node_model_service["LLM service"]
node_redis[("Redis")]
node_benchmark(("Benchmark workflow"))

node_user -->|"submits task"| node_agent
node_agent -->|"validates requests"| node_contract
node_agent -->|"requests inference"| node_model_service
node_agent -->|"selects tools"| node_role_tools
node_role_tools -->|"resolves keys"| node_registry
node_registry -->|"loads tools"| node_lc_tools
node_lc_tools -->|"executes tools"| node_executor
node_executor -->|"dispatches MCP"| node_bridge
node_bridge -->|"calls tools"| node_arena_mcp
node_bridge -.->|"manages Gitea"| node_gitea_isolation
node_arena_mcp -.->|"loads seed data"| node_seed_data
node_agent -.->|"stores bindings"| node_sessions
node_redis -->|"persists bindings"| node_sessions
node_approval_docs -.->|"supplies references"| node_agent
node_benchmark -->|"requests scoring"| node_judge
node_judge -->|"requests evaluation"| node_model_service

click node_agent "https://github.com/yutao1024/entcollabbench/blob/main/agent.py"
click node_contract "https://github.com/yutao1024/entcollabbench/blob/main/api_schema.py"
click node_sessions "https://github.com/yutao1024/entcollabbench/blob/main/session_store.py"
click node_role_tools "https://github.com/yutao1024/entcollabbench/blob/main/tool/toolsets.py"
click node_registry "https://github.com/yutao1024/entcollabbench/blob/main/tool/tool_registry.py"
click node_lc_tools "https://github.com/yutao1024/entcollabbench/blob/main/tool/langchain_tools.py"
click node_executor "https://github.com/yutao1024/entcollabbench/blob/main/tool/tool_executor.py"
click node_bridge "https://github.com/yutao1024/entcollabbench/blob/main/tool/mcp_bridge.py"
click node_gitea_isolation "https://github.com/yutao1024/entcollabbench/blob/main/tool/gitea_isolation.py"
click node_arena_mcp "https://github.com/yutao1024/entcollabbench/tree/main/Arena"
click node_seed_data "https://github.com/yutao1024/entcollabbench/tree/main/Arena/seed"
click node_approval_docs "https://github.com/yutao1024/entcollabbench/tree/main/local_data"
click node_judge "https://github.com/yutao1024/entcollabbench/blob/main/scripts/judge/judge.py"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_agent,node_contract,node_sessions toneBlue
class node_role_tools,node_registry,node_lc_tools,node_executor,node_bridge,node_gitea_isolation,node_redis toneAmber
class node_arena_mcp,node_seed_data toneMint
class node_approval_docs,node_judge,node_user toneRose
class node_model_service,node_benchmark toneIndigo
```

## Components

### Agent runtime

- [Agent service](https://github.com/yutao1024/entcollabbench/blob/main/agent.py): `agent.py`
- [Agent API contract](https://github.com/yutao1024/entcollabbench/blob/main/api_schema.py): `api_schema.py`
- [Session bindings](https://github.com/yutao1024/entcollabbench/blob/main/session_store.py): `session_store.py`

### Tool execution

- [Role toolsets](https://github.com/yutao1024/entcollabbench/blob/main/tool/toolsets.py): `tool/toolsets.py`
- [Tool registry](https://github.com/yutao1024/entcollabbench/blob/main/tool/tool_registry.py): `tool/tool_registry.py`
- [LangChain tools](https://github.com/yutao1024/entcollabbench/blob/main/tool/langchain_tools.py): `tool/langchain_tools.py`
- [Tool executor](https://github.com/yutao1024/entcollabbench/blob/main/tool/tool_executor.py): `tool/tool_executor.py`
- [MCP bridge](https://github.com/yutao1024/entcollabbench/blob/main/tool/mcp_bridge.py): `tool/mcp_bridge.py`
- [Gitea isolation](https://github.com/yutao1024/entcollabbench/blob/main/tool/gitea_isolation.py): `tool/gitea_isolation.py`

### Arena services

- [Arena MCP services](https://github.com/yutao1024/entcollabbench/tree/main/Arena): `Arena`
- [Business seed data](https://github.com/yutao1024/entcollabbench/tree/main/Arena/seed): `Arena/seed`

### Approval and evaluation

- [Approval references](https://github.com/yutao1024/entcollabbench/tree/main/local_data): `local_data`
- [Benchmark judge](https://github.com/yutao1024/entcollabbench/blob/main/scripts/judge/judge.py): `scripts/judge/judge.py`

### Other components

- **Task requester**
- **LLM service**
- **Redis**
- **Benchmark workflow**

## Connections

- Task requester → Agent service: submits task
- Agent service → Agent API contract: validates requests
- Agent service → LLM service: requests inference
- Agent service → Role toolsets: selects tools
- Role toolsets → Tool registry: resolves keys
- Tool registry → LangChain tools: loads tools
- LangChain tools → Tool executor: executes tools
- Tool executor → MCP bridge: dispatches MCP
- MCP bridge → Arena MCP services: calls tools
- MCP bridge → Gitea isolation: manages Gitea
- Arena MCP services → Business seed data: loads seed data
- Agent service → Session bindings: stores bindings
- Redis → Session bindings: persists bindings
- Approval references → Agent service: supplies references
- Benchmark workflow → Benchmark judge: requests scoring
- Benchmark judge → LLM service: requests evaluation
