@Override
  public @NotNull List<IntentionActionWithTextCaching> getSortedIntentions(@NotNull CachedIntentions context,
                                                                           @NotNull List<IntentionActionWithTextCaching> intentions) {
    return StreamEx.of(intentions)
      .mapToEntry(intention -> getWeight(context, intention))
      .sorted((weightedIntention1, weightedIntention2) -> {
        int intentionWeightComparison = Integer.compare(weightedIntention1.getValue(), weightedIntention2.getValue());
        if (intentionWeightComparison != 0) return -intentionWeightComparison; //desc sorting for weight
        return weightedIntention1.getKey().compareTo(weightedIntention2.getKey()); //asc sorting for text
      })
      .keys()
      .toList();
  }
@Override
  public @NotNull List<IntentionActionWithTextCaching> getSortedIntentions(@NotNull CachedIntentions context,
                                                                           @NotNull List<IntentionActionWithTextCaching> intentions)