Artificial systems that generate contingency-based teleological behaviors in real-time, are difficult to model. This chapter describes a modeling and simulation (M&S) framework designed specifically to reduce this difficulty. The described Knowledge-based Contingency-driven Generative Systems (KCGS) framework combines aspects of SES theory, DEVS-based general systems theory, net-centric heterogeneous simulation, knowledge engineering, cognitive modeling, and domain-specific language development using meta-modeling. The chapter outlines the theoretical and technical foundations of the KCGS framework as realized in the Cognitive Systems Specification Framework (CS2F), a subset of KCGS. Two executable models are described to illustrate how models of autonomous, goal-pursuing cognitive systems can be modeled and simulated in the framework. The technical content and agent descriptions in the chapter illustrate how the M&S of the artificial depends critically on ontology, epistemology, and teleology in the KCGS framework.