Updated BaseModel, added version constant, cleaned framework.php