code: def select_args(xmrs, nodeid=None, rargname=None, value=None):
      
      argmatch = lambda a: ((nodeid is None or a[0] == nodeid) and
                            (rargname is None or
                             a[1].upper() == rargname.upper()) and
                            (value is None or a[2] == value))
      all_args = (
          (nid, role, val)
          for nid in xmrs.nodeids()
          for role, val in sorted(
              xmrs.args(nid).items(),
              key=lambda i: rargname_sortkey(i[0])
          )
      )
      return list(filter(argmatch, all_args))
docs: Return the list of matching (nodeid, role, value) triples in *xmrs*.
  
      Predication arguments in *xmrs* match if the `nodeid` of the
      :class:`~delphin.mrs.components.ElementaryPredication` they are
      arguments of match *nodeid*, their role matches *rargname*, and
      their value matches *value*. The *nodeid*, *rargname*, and *value*
      filters are ignored if they are `None`.
  
      Note:
          The *value* filter matches the variable, handle, or constant
          that is the overt value for the argument. If you want to find
          arguments that target a particular nodeid, look into
          :meth:`Xmrs.incoming_args() <delphin.mrs.xmrs.Xmrs.incoming_args>`.
          If you want to match a target value to its resolved object, see
          :func:`find_argument_target`.
      Args:
          xmrs (:class:`~delphin.mrs.xmrs.Xmrs`): semantic structure to
              query
          nodeid (optional): nodeid to match
          rargname (str, optional): role name to match
          value (str, optional): argument value to match
      Returns:
          list: matching arguments as (nodeid, role, value) triples