Sorry for a basic question but I wasted 5 days for that problem
// communicate with AI service
result, err := witClient.Parse(&witai.MessageRequest{
Query: textMessage,
})
if err != nil { // handle error
}
// we have `result` (witai.MessageResponse) here
data := []byte(result.Entities) // cannot continue because error convert from interface{} to []byte
I cannot continue because error convert from interface{} to []byte.
I want to extract entities key to an array and entities content to an another.
Hello,
Sorry for a basic question but I wasted 5 days for that problem
I cannot continue because error convert from
interface{}
to[]byte
.I want to extract entities key to an array and entities content to an another.
Hope you can guide me how to extract that.
Thanks in advanced !