Basic Usage Examplesο
Getting Startedο
Start Pili:
conda activate Pili
uvicorn main:app --reload
Basic Examplesο
Simple Greeting
curl -X POST "http://localhost:8000/api/chat" \
-H "Content-Type: application/json" \
-d '{"user_id": "demo", "message": "Hello Pili!"}'
Log Activity
curl -X POST "http://localhost:8000/api/chat" \
-H "Content-Type: application/json" \
-d '{"user_id": "demo", "message": "I ran 5km in 30 minutes"}'
Request Plan
curl -X POST "http://localhost:8000/api/chat" \
-H "Content-Type: application/json" \
-d '{"user_id": "demo", "message": "Create a beginner running plan"}'
Get Motivation
curl -X POST "http://localhost:8000/api/chat" \
-H "Content-Type: application/json" \
-d '{"user_id": "demo", "message": "I need motivation to exercise"}'
API Endpointsο
POST /api/chat
- Main chat interfaceGET /api/health
- Health checkGET /api/memory/stats/{user_id}
- Memory statisticsPOST /api/memory/clear
- Clear user memoryGET /api/docs
- Interactive API documentation
Next Stepsο
Learn about the Architecture Overview to understand how it works
Explore the configuration options in Configuration Guide
Tip
Use descriptive user IDs to help with debugging and conversation management.