{"version":"1.0","type":"rich","title":"Gist 8716504","description":"This example shows a Rails controller and model that handle image uploads for a collection, with the model exposing an `images` accessor while the controller permits `:images` as a parameter. The code demonstrates a standard ActiveRecord setup where the `Collection` model inherits from `ActiveRecord::Base` and uses `attr_accessor` to manage image data without a database column. The controller’s `collection_params` method uses `params.require` and `params.permit` to whitelist the `:name`, `:token`, `:user_id`, `:status`, and `:images` fields, illustrating a typical Rails strong-parameters pattern for accepting nested or file-upload attributes. No visualization library is present in this code.","provider_name":"VizHub AI Studio","provider_url":"https://next.vizhub.com","html":"<iframe src=\"https://next.vizhub.com/viz/gist-8716504?mode=embed\" width=\"960\" height=\"500\" scrolling=\"no\" frameborder=\"1\"></iframe>","width":960,"height":500,"cache_age":3600}