Modeling Rational Agents within a BDI Architecture