```ruby
class Document < ActiveRecord::Base
end
```

Add a scope for full text search
user
```ruby
class Document < ActiveRecord::Base
  scope :full_text_search, -> (query) {
    where("MATCH(content) AGAINST(? IN BOOLEAN MODE)", "*D+ #{query}")
  }
end
```
assistant