class_docstr: Completer which can be used for autocompletion according to variables in
  the grammar. Each variable can have a different autocompleter.
  
  :param compiled_grammar: `GrammarCompleter` instance.
  :param completers: `dict` mapping variable names of the grammar to the
                     `Completer` instances to be used for each variable.
class_docstr_tok: ["Completer","which","can","be","used","for","autocompletion","according","to","variables","in","the","grammar",".","Each","variable","can","have","a","different","autocompleter",".",":","param","compiled_grammar",":","`","GrammarCompleter","`","instance",".",":","param","completers",":","`","dict","`","mapping","variable","names","of","the","grammar","to","the","`","Completer","`","instances","to","be","used","for","each","variable","."]
docstr: Remove duplicates, while keeping the order.
  (Sometimes we have duplicates, because the there several matches of the
  same grammar, each yielding similar completions.)
docstr_tok: ["Remove","duplicates",",","while","keeping","the","order",".","(","Sometimes","we","have","duplicates",",","because","the","there","several","matches","of","the","same","grammar",",","each","yielding","similar","completions",".",")"]
code: def _remove_duplicates(
      self, items: Iterable[Completion]
  ) -> list[Completion]:
      """
      Remove duplicates, while keeping the order.
      (Sometimes we have duplicates, because the there several matches of the
      same grammar, each yielding similar completions.)
      """
      result: list[Completion] = []
      for i in items:
          if i not in result:
              result.append(i)
      return result
  
file_path: catboost/contrib/python/prompt-toolkit/py3/prompt_toolkit/contrib/regular_languages/completion.py
imports: from __future__ import annotations
  from typing import Iterable
  from prompt_toolkit.completion import CompleteEvent, Completer, Completion
  from prompt_toolkit.document import Document
  from .compiler import Match, _CompiledGrammar
label_desc: Use image node_id 4 for calling the GrammarCompleter obj's underlying member method code with example usage: obj._remove_duplicates(items) and returns: result