qornanali / faq-bot Goto Github PK
View Code? Open in Web Editor NEWA messenger bot + wit.ai to help answer your customer's frequently asked question.
License: MIT License
A messenger bot + wit.ai to help answer your customer's frequently asked question.
License: MIT License
In order to prevent malicious requests, please modify the current webhook URL.
From /webhook
to /v1/external/messenger/webhook?access_token=<access_token>
where access_token
is configurable from ENV for now.
Example curl
curl --location --request POST 'https://localhost:3000/external/messenger/v1/webhook?access_token=foo' \
--header 'Content-Type: application/json' \
--data-raw '{
"object": "page",
"entry": [
{
"id": "107461401142256",
"time": 1602923843364,
"messaging": [
{
"sender": {
"id": "3394010770691329"
},
"recipient": {
"id": "107461401142256"
},
"timestamp": 1602923843223,
"message": {
"mid": "m_sFrBBrkrx2LmF8YZSBf7WeqfkEM-NXTTk34MVB5g2wYZUTOUt4RRD2EWhrrCyy4O86A6bj4NfeKid_R2johmBA",
"text": "kartu prakerja",
"nlp": {
"intents": [
{
"id": "653269161996408",
"name": "Tanya_program",
"confidence": 0.9
}
],
"entities": {
"nama_program:nama_program": [
{
"id": "387471645725440",
"name": "nama_program",
"role": "nama_program",
"start": 0,
"end": 14,
"body": "kartu prakerja",
"confidence": 0.9566,
"entities": [],
"value": "Kartu Prakerja",
"type": "value"
}
]
},
"traits": {
"wit$sentiment": [
{
"id": "5ac2b50a-44e4-466e-9d49-bad6bd40092c",
"value": "neutral",
"confidence": 0.536
}
]
},
"detected_locales": [
{
"locale": "id_ID",
"confidence": 0.9685
}
]
}
}
}
]
}
]
}'
If the incoming request has a blank access_token or incorrect, it should response with body:
FAILED
and http status 401 unauthorized
.
Messenger url in README is not working. Please fix it.
You can put https://
as the prefix of the URL.
Currently, we assign answers via rails console and it obviously not a good approach.
Please create new endpoints for this contract:
/internal/v1/answers
/internal/v1/answers/:id
/internal/v1/answers?page=1&limit=5
/internal/v1/answers/:id
/internal/v1/answers/:id
To provide information on how we build this project, please document it on the following files:
- README.md
- docs/en/...
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.