Realtor AI Assistant is a full-stack LangGraph real estate agent with a Python backend and a React chat widget. It coordinates lead intake, property-search criteria, database lookup, Google Calendar scheduling, and chat, SMS, and voice entry points, with human approval before sensitive appointment actions.
-
Property Information Inquiry
- Provides detailed property information, including square footage, pricing, condition, and amenities.
-
Appointment Scheduling
- Integrates with Google Calendar to facilitate the scheduling of property viewings and consultations.
-
Multi-Platform Access
- Accessible through chat-widgets, text messaging, and phone calls, ensuring real-time communication with clients across various channels.
-
24/7 Availability
- Operates around the clock, ensuring no inquiries go unanswered, reducing missed opportunities, and enhancing client satisfaction.
- Initialization: Starts at the
__start__node. - Main Interaction Hub: The
main_agentdirects users to specific functionalities. - Property Inquiry Process: Routes users to
search_criteria_agentandquery_database. - Appointment Management: Guides users through the
appointment_agentandappointment_tools. - Human-in-the-Loop: Ensures accuracy for complex tasks.
- Conclusion of Interaction: Returns to
main_agentand ends at__end__node.
-
Install dependencies
pip install -r requirements.txt
-
Set up environment variables
- Create a
.envfile in the root directory of the project. - Add the necessary environment variables.
- Create a
-
Download and set up data
- Download the real estate dataset from Kaggle and place it in the
/datafolder. - Run
csv_to_sql.pyto convert the CSV file into an SQL database.
- Download the real estate dataset from Kaggle and place it in the
-
Run the main application
- Terminal:
python main.py - Local server:
- Run the
ngrok.exefile. - Start the server:
uvicorn app-retell.server:app --reload
- Run the
- Terminal:
- Real-time chat interface with an AI assistant
- Responsive design for various screen sizes
- WebSocket integration for live communication
- Tailwind CSS for styling
- TypeScript for type safety
-
Install dependencies:
npm install
or
yarn install
-
Create a
.envfile in the root directory and add any necessary environment variables.
To run the development server:
npm run dev
or
yarn dev
Open http://localhost:5173 to view it in the browser.
To create a production build:
npm run build
or
yarn build
To use the ChatbotWidget in your React application:
import ChatbotWidget from './components/chatbot-widget'
function App() {
return (
<div className="App">
<ChatbotWidget websiteId="your-website-id" />
</div>
)
}Replace "your-website-id" with the appropriate identifier for your website.
- The WebSocket connection URL is currently set to
ws://127.0.0.1:8000/ws/${websiteId}/${threadId}. Update this inchatbot-widget.tsxif your backend is hosted elsewhere. - Tailwind CSS configuration can be modified in
tailwind.config.js. - TypeScript configuration is split between
tsconfig.json,tsconfig.app.json, andtsconfig.node.json.
Contributions are welcome! Please feel free to submit a Pull Request for either the backend or frontend components.
This project is licensed under the GNU General Public License v3.0. See the LICENSE file in the backend directory for details.
