Composability, the capability to select and assemble offthe-shelf model components in various combinations to satisfy user requirements, is an appealing approach in reducing the time and costs of developing complex simulation. This paper discusses CODES, a hierarchical component framework to support component-based modeling and simulation. We propose the use of EBNF based grammars to specify syntactic composability rules with the aims of achieving syntax consistency for model components to operate together. EBNF production strings associated with each composed models are transformed into a unique identifier to support distributed DHT-based model discovery. The hierarchical design supports the sharing and reuse of models and model components across application domains, and facilitates the verification of composed models. We present a prototype of the framework implemented using the Scalable Simulation Framework, and illustrate this approach by modeling a grid computing system.