how to set Elastica suggest from specific type?-open source projects ruflin/Elastica

I am faily new to elasticsearch and try to get along with elastica. I try to set suggester which suggest from a specific type. I have tried to used a method addType from \Elastica\Search, but it cann’t work.

$search = new \Elastica\Search($elasticaClient);
$suggest = new \Elastica\Suggest\Term();
$suggest->addTerm('suggest', ['text' => $query, 'term' => ['field' => '_all']]);
$search->addIndex($elasticaIndex);
$search->addType($type);
$search->addSuggest($suggest);
$result = $search->search();

may can someone help me to resolve it? Thanks