
.. _spruce_overview:
.. include:: ../../apps-substitutions

.. program:: spruce

======================
Overview
======================

:ref:`SPRUCE <chapter_spruce>` is an application that prepares biomolecular structure files (PDB, mmCIF, oeb, etc.) for downstream modeling applications, such as running a :ref:`BROOD <chapter_brood>` query, docking a ligand with :ref:`FRED <chapter_fred>` or :ref:`HYBRID <chapter_hybrid>`, predicting poses with :ref:`POSIT <chapter_posit>`, or for running :ref:`SZMAP <chapter_szmap>` to analyze active-site hydration thermodynamics.
SPRUCE first runs a standardization and filter check to determine the quality of the input structure (see :ref:`OESpruceFilter <chapter_sprucetk_sprucefilter>`). The filter will fail the workflow if the structure did not pass the checks. The -allow_filter_error flag will alow one to continue to the preparation workflow even when the structure did not pass the filter.
The preparation workflow from an experimental or modeled structure involves, 1) expansion of the asymmetric unit to the biological unit (if structure is from an X-ray crystallography
experiment and it is necessary), 2) enumeration (default) or collapse of alternate locations, 3) building missing pieces e.g. partial
sidechains, capping chain breaks, and modeling missing loops, 4) placement and optimization of hydrogen atoms including tautomer enumeration of ligands and cofactors,
as well as evaluation of those tautomer states in the biomolecule structure. OEReceptors are added to the design units by default so they are ready for docking applications.
The generated DU will be checked by a design unit validation function. Parts that are not successfully built in spruce preparation will be logged and styled differently.
 
.. note::
  
  Included in the Spruce product is a loop building database which can be used to build missing loops. This database is available for 
  `download <http://www.eyesopen.com/db-downloads>`_ in a platform-independent format.

.. seealso::

   * The :ref:`ReceptorInDU` section
