A working setup for using Embabel Guide to enable "talk to your codebase" functionality. This repository documents the workarounds and configuration needed to get Guide working with custom repository URLs.
The screenshot above demonstrates Guide successfully answering questions about the datadog-drilldown repository, proving the setup works correctly.
Goal: Customize Embabel Guide to work with your own repository URLs instead of (or in addition to) the default documentation URLs.
Current Status: ✅ Working with workarounds documented below
- Java 21+
- Maven 3.6+
- Neo4j (running on localhost:7687)
- Node.js and npm (for frontend)
During setup, we discovered several workarounds needed to get Guide working properly:
Problem: ChatActions class (which contains the @Action method for responding to messages) wasn't being discovered by Guide's ComponentConfiguration, even though it was annotated with @EmbabelComponent.
Solution: Added explicit @ComponentScan annotation to GuideApplication.java:
@SpringBootApplication
@ComponentScan(basePackages = {"com.embabel"}) // ← REQUIRED WORKAROUND
@ConfigurationPropertiesScan
@EnableScheduling
@EnableDrivine
@EnableDrivinePropertiesConfig
public class GuideApplication {
// ...
}File: guide/src/main/java/com/embabel/GuideApplication.java
Why: Tests work because TestAppContext has this annotation. The main application needs it too for Spring to discover components in com.embabel.guide package.
Problem: Port 1337 may be in use by a Docker container or previous Guide instance.
Solution: Check and stop any processes using port 1337:
# Check what's using port 1337
docker ps | grep guide
lsof -ti:1337
# Stop Docker container if running
docker stop embabel-guide
# Or kill processes
pkill -f "spring-boot:run"
lsof -ti:1337 | xargs kill -9Problem: Frontend needs to connect to the correct Guide instance port.
Solution: Configure frontend to use port 1337:
// frontend/src/App.js
const API_BASE_URL = process.env.REACT_APP_API_BASE_URL || 'http://localhost:1337';git clone https://github.com/embabel/guide.git
cd guide
mvn clean installEdit src/main/java/com/embabel/GuideApplication.java and ensure it has:
@ComponentScan(basePackages = {"com.embabel"})Edit src/main/resources/application.yml to add your repository URLs:
guide:
urls:
- https://docs.embabel.com/embabel-agent/guide/0.3.1-SNAPSHOT/ # Default docs
- https://github.com/menkelabs/datadog-drilldown # Your repo
# Add more URLs hereEnsure Neo4j is running (default: localhost:7687):
# Using Docker
docker run -d \
--name neo4j \
-p 7474:7474 -p 7687:7687 \
-e NEO4J_AUTH=neo4j/brahmsian \
neo4j:latest
# Or use existing Neo4j instancecd guide
mvn spring-boot:runGuide will start on port 1337 by default. Check logs:
tail -f guide.logLook for:
Started GuideApplicationTomcat started on port 1337ComponentConfiguration initialized
cd frontend
npm install
npm startFrontend will start on http://localhost:3000 and connect to Guide on port 1337.
To add a new repository or documentation URL to Guide:
Edit guide/src/main/resources/application.yml:
guide:
urls:
- https://docs.embabel.com/embabel-agent/guide/0.3.1-SNAPSHOT/
- https://github.com/menkelabs/datadog-drilldown
- https://github.com/yourusername/your-repo # ← Add your new URL hereCreate or edit guide/src/main/resources/application-custom.yml:
server:
port: 1337
guide:
urls:
- https://github.com/yourusername/your-repo-1
- https://github.com/yourusername/your-repo-2
logging:
level:
com.embabel.agent.rag: INFO
com.embabel.guide.chat: DEBUGRun with profile:
mvn spring-boot:run -Dspring-boot.run.profiles=customEdit application.yml and append to the urls list:
guide:
urls:
# Existing URLs
- https://docs.embabel.com/embabel-agent/guide/0.3.1-SNAPSHOT/
- https://medium.com/@springrod/build-better-agents-in-java-vs-python-embabel-vs-langgraph-f7951a0d855c
# Add new URLs here (without removing existing ones)
- https://github.com/menkelabs/datadog-drilldown
- https://github.com/yourusername/another-repoBy default, Guide only reloads content from snapshots. To reload from URLs on startup:
guide:
reload-content-on-startup: true # ← Set to true to reload URLs on startupNote: Content ingestion happens on first access or when reload-content-on-startup: true. This may take several minutes for large repositories.
- Start Guide:
mvn spring-boot:runin theguidedirectory - Open Frontend: Navigate to
http://localhost:3000(or use Guide's built-in frontend) - Send Test Message: Try asking "what is datadog-drilldown" or any question about your repository
- Check Logs: Look for
ChatActions.respondbeing called in the logs
Check logs for:
ComponentConfiguration initialized: Scanning com.embabel.agent and com.embabel.example packages.
Even though it says "com.embabel.example", with the @ComponentScan fix, ChatActions in com.embabel.guide will be discovered via Spring's ApplicationContext.
Check logs for ingestion messages or query Neo4j:
MATCH (n:ContentChunk)
RETURN count(n) as total_chunksCause: ChatActions not being discovered.
Fix: Ensure @ComponentScan(basePackages = {"com.embabel"}) is in GuideApplication.java.
Fix:
docker stop embabel-guide # If Docker container
pkill -f "spring-boot:run" # If Maven process
lsof -ti:1337 | xargs kill -9 # Force killCheck:
- Frontend is connecting to
http://localhost:1337 - Guide is running and responding to
/api/hub/personas - WebSocket connection is established (check browser console)
ChatActionsis discovered (check Guide logs)
Check:
- URLs are valid and accessible
reload-content-on-startup: trueis set, or manually trigger ingestion- Neo4j is running and accessible
- Check Guide logs for ingestion errors
┌─────────────────┐
│ React │
│ Frontend │
│ (Port 3000) │
└────────┬────────┘
│ WebSocket/STOMP
│
┌────────▼────────┐
│ Guide │
│ (Port 1337) │
│ │
│ ┌───────────┐ │
│ │ChatActions│ │ ← Requires @ComponentScan fix
│ │@Action │ │
│ └───────────┘ │
│ │
│ ┌───────────┐ │
│ │DataManager│ │ ← Ingests URLs
│ └───────────┘ │
└────────┬────────┘
│
┌────────▼────────┐
│ Neo4j │
│ (Port 7687) │
│ │
│ RAG Store │
│ Content Chunks │
└─────────────────┘
guide/src/main/java/com/embabel/GuideApplication.java- Main application (requires@ComponentScanfix)guide/src/main/java/com/embabel/guide/ChatActions.java- Action handler for chat messagesguide/src/main/resources/application.yml- Main configuration (add URLs here)frontend/src/App.js- React frontend (configured for port 1337)
-
ComponentConfiguration log message: Logs still say "Scanning com.embabel.agent and com.embabel.example packages" but this is just the log message. With
@ComponentScan, components are discovered from Spring's ApplicationContext. -
Port conflicts: If you have a Docker container running Guide, it will block port 1337. Always check
docker psfirst. -
Content ingestion time: Large repositories can take several minutes to ingest. Be patient on first startup.
✅ Guide starts without errors
✅ Port 1337 is listening
✅ ChatActions is discovered (check logs for incoming requests)
✅ Frontend connects and sends/receives messages
✅ Guide responds to questions about your repository
✅ Neo4j contains ingested content chunks
As shown in the screenshot above, here's how we configured Guide for the datadog-drilldown repository:
-
Added URL to configuration:
guide: urls: - https://github.com/menkelabs/datadog-drilldown
-
Applied Component Scan fix (see workaround #1 above)
-
Started Guide and waited for ingestion
-
Tested with query: "what is datadog-drilldown"
-
Verified response: Guide correctly identified it as a project involving "Embabel and DICE for Root Cause Analysis (RCA) with Datadog"
[Add your license here]
- Embabel Guide - Original Guide repository
- Embabel Agent Framework - Core agent framework
- Embabel Documentation - Official documentation
