class_docstr: Create a composition which define computations / endpoints to create & run.
  
  Any number of components are accepted, which may have aribtrary connections
  between them. The final path through the component/connection DAG is determined
  by the root/terminal node position as specified by endpoint input/outputs keys.
  
  If only ONE component is provided, there is no need to create an Endpoint object.
  The library will generate a fully connected input/ouput endpoint for the one
  component with the `route` name set by the name of the method the `@expose`
  decorator is applied to.
  
  Parameters
  ----------
  kwargs
      Assignment of human readable names to ``ModelComponent`` and ``Endpoint``
      instances. If more than one ``ModelComponent`` is passed, an ``Endpoint``
      is needed as well.
  
  Warnings
  --------
  - This is a Work In Progress interface!
  
  Todo
  ----
  *  Move to connection components together at the composition level
  *  We plan to add some user-facing API to the ``Composition`` object
     which provides introspection of components, endpoints, etc.
  *  We plan to add some user-facing API to the ``Composition`` object
     which allows for modification of the composition.
class_docstr_tok: ["Create","a","composition","which","define","computations","\/","endpoints","to","create","&","run",".","Any","number","of","components","are","accepted",",","which","may","have","aribtrary","connections","between","them",".","The","final","path","through","the","component\/connection","DAG","is","determined","by","the","root\/terminal","node","position","as","specified","by","endpoint","input\/outputs","keys",".","If","only","ONE","component","is","provided",",","there","is","no","need","to","create","an","Endpoint","object",".","The","library","will","generate","a","fully","connected","input\/ouput","endpoint","for","the","one","component","with","the","`","route","`","name","set","by","the","name","of","the","method","the","`","@","expose","`","decorator","is","applied","to",".","Parameters","--","--","--","--","--","kwargs","Assignment","of","human","readable","names","to","``","ModelComponent","``","and","``","Endpoint","``","instances",".","If","more","than","one","``","ModelComponent","``","is","passed",",","an","``","Endpoint","``","is","needed","as","well",".","Warnings","--","--","--","--","-","This","is","a","Work","In","Progress","interface","!","Todo","--","--","*","Move","to","connection","components","together","at","the","composition","level","*","We","plan","to","add","some","user-facing","API","to","the","``","Composition","``","object","which","provides","introspection","of","components",",","endpoints",",","etc",".","*","We","plan","to","add","some","user-facing","API","to","the","``","Composition","``","object","which","allows","for","modification","of","the","composition","."]
code: def component_uid_names(self) -> Dict[str, str]:
      return self._uid_names_map
  
file_path: lightning-flash/src/flash/core/serve/composition.py
imports: import itertools
  from dataclasses import asdict
  from typing import Dict, List, Tuple, Union
  from flash.core.serve.component import ModelComponent
  from flash.core.serve.core import Connection, Endpoint
  from flash.core.serve.interfaces.models import EndpointProtocol
  from flash.core.serve.server import ServerMixin
  from flash.core.utilities.imports import _CYTOOLZ_AVAILABLE
label_desc: Use image node_id 6 for calling the Composition obj's underlying member method code with example usage: obj.component_uid_names() and returns: self