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

Remove read_only parameter at database level #560

Closed
gunthercox opened this issue Jan 7, 2017 · 0 comments
Closed

Remove read_only parameter at database level #560

gunthercox opened this issue Jan 7, 2017 · 0 comments
Assignees

Comments

@gunthercox
Copy link
Owner

gunthercox commented Jan 7, 2017

The ChatBot class currently takes a read_only parameter that controls if the storage adapter can write to the database. This needs to be changed so that the read_only parameter only controls statements being saved at the ChatBot class level (essentially read only just controls if the chat bot can learn).

The reason this change is needed is because:

  1. It is largely inconsistent with how Django handles it's storage and as ChatterBot improves support for integration with Django supporting a passive read-only database option will become increasingly difficult.
  2. Changes have been made in the past to allow training to occur when read_only is set to True. (The addition of a force parameter to the storage adapter). Removing storage adapter-level write access control will allow this code to be simplified.

This also simplifies storage adapters and makes it easier for developers to create new ones.

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

1 participant