class My_model extends CI_Model { public function __construct() { parent::__construct(); } public function get_data() { // get data from database } }In this example, the My_model class inherits from the CI_Model class and defines a custom function called get_data, which retrieves data from a database. The constructor function is also defined to call the parent constructor. Package Library: CI_Model is a core component of the CodeIgniter framework. It is a part of the CodeIgniter framework and does not need to be installed separately.