title: ActiveRecord: Best way to add a 'fake' model class?
body: <p>In our Rails application, the <code>Post</code> resource can be made by either a <code>User</code> or an <code>Admin</code>.</p>
  
  <p>Thus, we have an ActiveRecord model class called <code>Post</code>, with a <code>belongs_to :author, polymorphic: true</code>.</p>
  
  <p>However, in certain conditions, the system <em>itself</em> is supposed to be able to create posts.
  Therefore, I'm looking for a way to add e.g. <code>System</code> as <code>author</code>.</p>
  
  <p>Obviously, there will only ever be one <code>System</code>, so it is not stored in the database.</p>
  
  <p>Naïvely attempting to just add an instance (e.g. the singleton instance) of <code>class System; end</code> as author returns errors like <code>NoMethodError: undefined method `primary_key' for System:Class</code>.</p>
  
  <p>What would be the cleanest way to solve this?</p>
  
  <p>Is there a way to write a 'fake' ActiveRecord model that is not actually part of the database?</p>