In the current implementation, SMART is about as generic as it can get. Every action that SMART can do is implemented as a triplet of functions: init_<function_name>, <function_name>, and close_<function_name>. For example, by lauching the "inter" top-level function, three function calls are produced: init_inter(), inter(), and close_inter().
Organisation within the source files is also rather straightforward: only the core of the SMART system is contained in the file smart.11.0/src/smart/smart.c; every other actions used by SMART is contained in independent libraries. Every library implements a hierarchy of functions, possibly containing sub-hierarchies. For example, the "index" hierarchy is contained in a library called "libindexing", which contains every sub-hierarchy and every action defined under index.* . Only a handful of other utility functions (such as functions to load the spec files) are in the library smart.11.0/src/libgeneral .
The library libproc and liblocal/libproc are a special case, also. They contain the tree data structures which describes the contents of every level of hierarchy of SMART actions. Thus, when you use any SMART action, the data structures contained therein are read and traversed to reach a single node describing the function, including function pointers to the init_<function>, <function> and close_<function> for the SMART action. If you modify SMART, likely to add a new SMART action, then the first thing to do is to create the necessary hierarchy and node describing the action.