How rrusson/virtualryan works
VirtualRyan is a resume and professional-background question-answering chatbot, with both a browser chat interface and an A2A interface for agent clients. In the browser workflow, a visitor submits a question, the client sends it to the chat API, and the server retrieves conversation history before asking the LLM; the response and updated history return to the interface, which can also speak the answer. The shared chat library adds resume context from text files. A2A clients use a separate handler and agent-card discovery path. The README documents GitHub Models as the intended provider; the sampled library supports configurable OpenAI-compatible endpoints, so the provider connection is shown generically. The A2A and frontend subsystem links reflect documented capabilities and tree paths; their unsampled implementation details are not inferred.
Main entry points: ChatController.cs Chat endpoint · ResumeChat.tsx Chat interface · RyanChat.cs Chat client · Program.cs HTTP hosting
Components 21
Browser chat
- Browser app
virtualryan.client/src/App.tsx - Chat interface
virtualryan.client/src/ResumeChat.tsx - Chat state
virtualryan.client/src/hooks/useChat.ts - Speech I/O
virtualryan.client/src/speechToText.ts - Text-to-speech
virtualryan.client/src/textToSpeech.ts
Chat API
- Chat endpoint
VirtualRyan.Server/Controllers/ChatController.cs - Conversation history
VirtualRyan.Server/Services/ConversationHistoryService.cs - A2A rate middleware
VirtualRyan.Server/Middleware/RateLimitingMiddleware.cs - Rate limits
VirtualRyan.Server/Services/RateLimitingService.cs - HTTP hosting
VirtualRyan.Server/Program.cs
A2A access
- A2A endpoints
VirtualRyan.Server/Program.cs - A2A handler
VirtualRyan.Server/Services/A2AService.cs - Agent card
VirtualRyan.Server/Services/A2AService.cs - Caller card lookup
VirtualRyan.Server/Services/A2AService.cs
Answer generation
- Chat client
ChatBotLibrary/RyanChat.cs - Resume context
ChatBotLibrary/Context/RussonResume2026.txt - Context reader
ChatBotLibrary/TextFileReader.cs
Other components
- Visitor
- A2A client
- LLM provider
- Agent-card resolver
Connections 21
- Visitor → Browser app: opens
- Browser app → Chat interface: renders
- Chat interface → Chat state: manages messages
- Chat interface → Speech I/O: captures speech
- Chat state → Text-to-speech: speaks answer
- Chat interface → Chat endpoint: posts question
- Chat endpoint → Conversation history: loads history
- Chat endpoint → Chat client: asks with history
- Chat endpoint → Conversation history: saves updated history
- Chat client → Context reader: reads context
- Context reader → Resume context: loads text
- Chat client → LLM provider: sends prompt
- Chat endpoint → HTTP hosting: served by
- HTTP hosting → A2A rate middleware: applies to A2A
- A2A rate middleware → Rate limits: checks requests
- A2A client → A2A endpoints: discovers or sends
- A2A endpoints → A2A handler: dispatches request
- A2A handler → Chat client: asks question
- A2A handler → Caller card lookup: resolves caller
- Caller card lookup → Agent-card resolver: fetches card
- HTTP hosting → Agent card: builds and exposes