Nylon bag: Put everything into a thin-mesh "hop bag" -- for example the "feet" part of pantyhose can work well (preferably obtained new). But a bag may be difficult to insert into (and remove from) a glass carboy. The PET plastic carboys, however, have bigger openings and can accommodate the bag better, depending on how many ingredients you have in the bag.
Nylon "filter": This would go onto your siphon/racking tube on the end that you insert into the carboy of green beer. Just cut a few square inches of pantyhose (preferably obtained new) and fasten this piece over the opening of the siphon tube using a sanitized tie-wrap. This end-piece will act as a filter against even fairly small particles and works well also in wine making to prevent loose oak chipsparticles from being racked further.