Shobhit1203/acme-support-agent
\# Acme Support Agent
Multi-tool agentic assistant for e-commerce customer support. Built on:
\- \\FastAPI\\ for the HTTP layer
\- \\LangGraph create\_react\_agent\\ for the agent loop
\- \\3 tools\\: retrieve\_docs (FAISS RAG), lookup\_order, escalate\_to\_human
\- \\LangSmith\\ for tracing
\- \\slowapi\\ for rate limiting
\## Endpoints
| Method | Path | Description |
|--------|------|-------------|
| GET | /healthz | Liveness probe |
| GET | /version | App version + model |
| POST | /chat | Send a question to the agent |
| POST | /feedback | Record user thumbs (0 or 1) |
| GET | /docs | Swagger UI |
\## How to call
curl -X POST "https://<your-space>.hf.space/chat" \\\\
  -H "X-API-Key: $AGENT\_API\_KEY" \\\\
  -H "Content-Type: application/json" \\\\
  -d '{"question":"How long is the warranty on the XL-200 toaster?"}'
\## Secrets
Set these in \\Space Settings → Secrets\\ (encrypted at rest):
| Name | Required | Notes |
|------|----------|-------|
| OPENAI\_API\_KEY | Yes | OpenAI key |
| AGENT\_API\_KEY | Yes | Random string clients send in X-API-Key |
| LANGCHAIN\_API\_KEY | No | Enables LangSmith tracing |
| LANGCHAIN\_PROJECT | No | LangSmith project name |
| OTEL\_ENABLE | No | "true" to enable OpenTelemetry console export |
\## Sample queries by tool
\- \\retrieve\_docs\\: "How long is the warranty on the XL-200 toaster?"
\- \\lookup\_order\\: "What is the shipping status of order ORD-1234?"
\- \\escalate\to\human\\: "I want to delete my account and dispute a charge"
\- \\multi-tool\\: "Is ORD-1234 still under warranty?"
