How marktechstation/videocode works
This repository is a collection of tutorial examples for building agents and connecting them through ReAct, MCP, A2A, and RAG. The clearest end-to-end paths are the ReAct agent’s model/tool loop, MarkChat’s chat-to-tool flow, MCP weather tools’ calls to the National Weather Service, and A2A weather/flight task handling. Several modules are represented only by their tree entries, so their internal wiring is not inferred.
Main entry points: agent.py ReAct loop · backend.py Chat backend · weather/__main__.py Weather A2A server · flight/__main__.py Flight A2A server
Components 19
ReAct agent
- Agent CLI
Agent的概念、原理与构建模式/agent.py - ReAct loop
Agent的概念、原理与构建模式/agent.py - Prompt template
Agent的概念、原理与构建模式/prompt_template.py - File and shell tools
Agent的概念、原理与构建模式/agent.py
MCP examples
- Chat interface
MCP 与 Function Calling 到底什么关系/MarkChat/static/script.js - Chat backend
MCP 与 Function Calling 到底什么关系/MarkChat/backend.py - MCP client
MCP 与 Function Calling 到底什么关系/MarkChat/mcp_client.py - Search server
MCP 与 Function Calling 到底什么关系/MarkChat/mcp_server.py - Weather tools
MCP终极指南-进阶篇/weather/weather.py
A2A agents
- Weather A2A server
A2A协议深度解析(1)/weather/__main__.py - Weather executor
A2A协议深度解析(1)/weather/agent_executor.py - In-memory task store
A2A协议深度解析(1)/weather/__main__.py - Flight A2A server
A2A协议深度解析(2)/flight/__main__.py - Flight executor
A2A协议深度解析(2)/flight/agent_executor.py - In-memory task store
A2A协议深度解析(2)/flight/__main__.py
RAG example
- RAG workflow
使用Python构建RAG系统/rag
Other components
- User
- OpenRouter model
- NWS API
Connections 15
- User → Agent CLI: enters task
- Agent CLI → ReAct loop: runs
- ReAct loop → Prompt template: renders
- ReAct loop → OpenRouter model: requests completion
- ReAct loop → File and shell tools: executes action
- User → Chat interface: sends message
- Chat interface → Chat backend: POST /chat
- Chat backend → OpenRouter model: requests completion
- Chat backend → MCP client: optional MCP call
- MCP client → Search server: calls tool
- Weather tools → NWS API: requests weather data
- Weather A2A server → Weather executor: dispatches tasks
- Weather A2A server → In-memory task store: configures task storage
- Flight A2A server → Flight executor: dispatches tasks
- Flight A2A server → In-memory task store: configures task storage