protected void fired(double currentTime, Future<VocalizationCommand> commandFuture) {
      IPerceptualBuffer pBuffer = (IPerceptualBuffer) getBuffer();
      IModel model = pBuffer.getModel();
      try {
        VocalizationCommand command = commandFuture.get();
        ActualState state = command.getActualState();
        if (state != ActualState.COMPLETED)
          throw new IllegalStateException(
              "Execution of vocalization failed : " + command.getResult());

        String msg = "Execution of vocalization completed";
        if (LOGGER.isDebugEnabled()) LOGGER.debug(msg);
        if (Logger.hasLoggers(model)) Logger.log(model, Logger.Stream.VOCAL, msg);

        IChunk free = model.getDeclarativeModule().getFreeChunk();

        pBuffer.setExecutionChunk(free);
        pBuffer.setStateChunk(free);
      } catch (InterruptedException e) {
        return;
      } catch (Exception e) {
        String msg = e.getMessage();
        if (e instanceof ExecutionException) msg = ((ExecutionException) e).getCause().getMessage();

        if (LOGGER.isDebugEnabled()) LOGGER.debug(msg);
        if (Logger.hasLoggers(model)) Logger.log(model, Logger.Stream.VOCAL, msg);

        IChunk error = model.getDeclarativeModule().getErrorChunk();

        pBuffer.setExecutionChunk(error);
        pBuffer.setStateChunk(error);
      }
    }
  @Override
  protected double computeHarvestTime(
      IRequest request, IChunk result, double startTime, Object... parameters) {
    IIdentifier commandIdentifier = (IIdentifier) parameters[0];
    AbstractVocalModule module = getModule();
    IModel model = module.getModel();

    IAgent agent = ACTRRuntime.getRuntime().getConnector().getAgent(model);
    VocalizationCommand command =
        (VocalizationCommand) agent.getEfferentCommandManager().get(commandIdentifier);

    double computedDuration =
        getModule().getExecutionTimeEquation().compute(command.getText(), getModule());

    double estimatedDuration = command.getEstimatedDuration();
    double actualDuration = computedDuration;

    if (Math.abs(estimatedDuration - computedDuration) >= 0.01) {
      switch (module.getExecutionTimeResolution()) {
        case ACTR:
          actualDuration = computedDuration;
          break;
        case CR:
          actualDuration = estimatedDuration;
          break;
        case MINIMUM:
          actualDuration = Math.min(estimatedDuration, computedDuration);
          break;
        case MAXIMUM:
          actualDuration = Math.max(estimatedDuration, computedDuration);
          break;
      }

      String msg =
          "CR and jACT-R disagree as to the vocalization duration, "
              + estimatedDuration
              + " & "
              + computedDuration
              + " respectively. Using "
              + actualDuration;

      if (Logger.hasLoggers(model)) Logger.log(model, Logger.Stream.VOCAL, msg);

      if (LOGGER.isWarnEnabled()) LOGGER.warn(msg);
    }

    return startTime + actualDuration;
  }
  @Override
  protected void finishRequest(IRequest request, IActivationBuffer buffer, Object startValue) {
    final IModel model = buffer.getModel();
    VocalizationCommand command = null;
    IChunk error = model.getDeclarativeModule().getErrorChunk();
    IChunk free = model.getDeclarativeModule().getFreeChunk();
    IChunk busy = model.getDeclarativeModule().getBusyChunk();
    IPerceptualBuffer pBuffer = (IPerceptualBuffer) buffer;
    String rejection = null;
    try {
      command = ((Future<VocalizationCommand>) startValue).get();
    } catch (InterruptedException e) {
      // bail
      return;
    } catch (ExecutionException e) {
      rejection = e.getCause().getMessage();
      LOGGER.error("Failed to get vocalization future ", e);
    }

    if (command != null && command.getActualState() == ActualState.REJECTED)
      rejection = "Vocalization was rejected : " + command.getResult();

    if (rejection != null) {
      if (LOGGER.isDebugEnabled()) LOGGER.debug(rejection);
      if (Logger.hasLoggers(model)) Logger.log(model, Logger.Stream.VOCAL, rejection);

      pBuffer.setPreparationChunk(error);
      pBuffer.setStateChunk(error);
      return;
    }

    String msg = "Vocalization prepared.";

    if (LOGGER.isDebugEnabled()) LOGGER.debug(msg);
    if (Logger.hasLoggers(model)) Logger.log(model, Logger.Stream.VOCAL, msg);

    pBuffer.setPreparationChunk(free);

    /*
     * now to actually execute, we use another drifting timed event.. two
     * actually..
     */
    Future<VocalizationCommand> executeFuture = _vocal.execute(command);

    double start = ACTRRuntime.getRuntime().getClock(model).getTime();
    double procEnd = model.getProceduralModule().getDefaultProductionFiringTime() + start;
    double execEnd = _vocal.getExecutionTimeEquation().compute(getText(request), _vocal);

    ProcessTimedEvent procEvent = new ProcessTimedEvent(start, procEnd, executeFuture, buffer);

    ExecuteTimedEvent execEvent = new ExecuteTimedEvent(start, execEnd, executeFuture, buffer);

    /*
     * set some flags
     */
    pBuffer.setProcessorChunk(busy);
    pBuffer.setExecutionChunk(busy);

    model.getTimedEventQueue().enqueue(procEvent);
    model.getTimedEventQueue().enqueue(execEvent);
  }