"separated by", "separated with", or does it not matter?

In a passive construction with a participle like separated, by and with have different functions.

  • by marks an agent phrase: The fighters were finally separated by the referee.
  • with marks an instrumental phrase: The fighters were finally separated with a crowbar.

When you're talking about metaphoric separation -- item boundaries in a left-to-right line -- you have the option of treating the "separator" either as an agent itself, or as a tool (of another agent).

Interestingly, this is the same range of meanings as the agentive -er suffix:
a typewriter is an instrument, but a ghostwriter is a human, and therefore an agent.

  • The entries are separated by commas is the agent interpretation,
    a passive version of Commas separate the entries.

  • The entries were separated with commas is the instrument interpretation,
    a passive version of Indef separated the entries with commas.

Note the different tenses required above; being separated is either an event or a state. Permanent states normally take present tense (My car is red even though it's been red for 5 years). Events can be located on the time continuum, usually in the past tense. So past tense is likely to signal reference to an event, and present tense to a state.


Your use of with in this context is entirely appropriate.

With:

  1. a. By the means or agency of. b. By the presence or use of. (AHDEL)

Some examples of such usage:

  • Items in lists are usually separated with commas... (Grammar Monster)
  • How to: Display an Item List Separated with Commas - MSDN
  • The nonessential adjective clause (like other nonessential elements) SHOULD be separated with commas. (Towson.edu)
  • Nonessential appositives are set off from the rest of the sentence with commas. (The Editor's Blog)
  • ...as many different addresses as you want as long as the addresses are separated with commas. (cmu.edu)

I think you can feel safe in doing so.