Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Renaming an Intent don't change it's ID #6

Closed
Seraf opened this issue Aug 9, 2013 · 8 comments
Closed

Renaming an Intent don't change it's ID #6

Seraf opened this issue Aug 9, 2013 · 8 comments

Comments

@Seraf
Copy link

Seraf commented Aug 9, 2013

I renamed an intent from "hello" to "chatterbot_hello"

The "chatterbot_hello" is displayed on the console, in the inbox too, but the id in the url is "hello" and the intent returned to me is "hello".

@ar7hur
Copy link
Contributor

ar7hur commented Aug 9, 2013

By design the JSON output for an intent does not change when you change the name of the intent. We want the name to be human-friendly and flexible (good naming scheme emerge with usage, it's hard to find good names when you just start).

That being said, we could add a feature that enables you to change the JSON output name of the intent if you need it.

@Seraf
Copy link
Author

Seraf commented Aug 10, 2013

Yes please, it would be great as it's what we receive in the API. So to match it correctly in our app (sometime we will have constraints about it) we need a little control on it.

@Seraf
Copy link
Author

Seraf commented Aug 12, 2013

@alxbrun : we should be able to rename entities too !

@blandinw
Copy link
Contributor

Renaming is available, see #11.
The feature enabling you to customize the JSON response is on its way too :)

@jejacks0n
Copy link

I just wanted to add to this. @ar7hur is correct, and that's good to do the current behavior by default, but the ability to change the intent name as presented in the JSON would be great too.

@jejacks0n
Copy link

I had another thought on this this weekend. I sort of use the intent "ids" that come back from the api as a path, used by a router to some degree.. I initially tried the concept of namespaces for intents, but yeah, the concept that I ended up with was more of a router (but I couldn't do this fully).

I started with something like "heroku:app:config", which allows you to configure a heroku app, but I landed on something more like "heroku/app/config", which if the "/"'s made it through the api, I would've been able to use to route a given intent to a controller and then the controller could delegate to an action. The code structure is not setup this way because it wasn't possible, but it seems like it might be useful to edit the intent "id"'s because during development I found myself restructuring that routing.

Anyway, yeah, I'd like some special chars to come through (eg. more of a path, instead of an identifier), and I think this should be something that can be changed. Maybe not in the most obvious of ways, but yes. =) What if the intent was restricted to valid uri characters, instead of stripping everything?

@ar7hur
Copy link
Contributor

ar7hur commented Nov 25, 2013

Got you. The plan is for each intent to have 3 IDs:

  • one human readable "description" that you see in the web console, intents dropdown, etc.
  • one JSON name that you get in the API output: you'll be totally free to use any string for that, including URIs
  • one internal ID that you never see

@ar7hur
Copy link
Contributor

ar7hur commented Dec 25, 2013

Please see https://wit.ai/blog/2013/12/25/update-on-intents-and-entities-naming
Now JSON output names always match the name you see in the console.

@ar7hur ar7hur closed this as completed Dec 25, 2013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants